Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1358393 - rfe: add a global timeout option to oc
Summary: rfe: add a global timeout option to oc
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: RFE
Version: 3.2.1
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: ---
Assignee: Juan Vallejo
QA Contact: Xingxing Xia
URL:
Whiteboard:
: 1368131 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-07-20 15:24 UTC by Sten Turpin
Modified: 2017-03-08 18:43 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-01-18 12:51:29 UTC


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2017:0066 normal SHIPPED_LIVE Red Hat OpenShift Container Platform 3.4 RPM Release Advisory 2017-01-18 17:23:26 UTC

Description Sten Turpin 2016-07-20 15:24:55 UTC
Description of problem: during the outage to the preview-prod cluster caused by https://bugzilla.redhat.com/show_bug.cgi?id=1351705 our monitoring checks, which call the oc command, got hung up for several days because oc didn't time out. 


Version-Release number of selected component (if applicable): oc v3.2.1.7


How reproducible: in cases when k8s is extremely slow, e.g. due to https://bugzilla.redhat.com/show_bug.cgi?id=1351705


Steps to Reproduce:
1. in a cluster with k8s in bad state, run "oc get projects" 

Actual results:
In some cases, this command ran for 5 days before we noticed it and killed the process. 


Expected results:
oc should time out eventually if the API is not available


Additional info:

Comment 1 Dan McPherson 2016-08-18 15:02:08 UTC
*** Bug 1368131 has been marked as a duplicate of this bug. ***

Comment 2 Juan Vallejo 2016-10-03 20:28:17 UTC
Related PR: https://github.com/openshift/origin/pull/11104

Comment 3 Xingxing Xia 2016-10-25 06:49:13 UTC
Verified with oc v3.4.0.14. Now user can use the global option --request-timeout with any oc command:
$ oc get projects --request-timeout=1h
NAME        DISPLAY NAME   STATUS
xxia-proj                  Active

Test the result when it timeouts:
$ oc get projects --request-timeout=1ms
Unable to connect to the server: net/http: request canceled while waiting for connection (Client.Timeout exceeded while awaiting headers)

Fixed. Move to VERIFIED.

Comment 5 errata-xmlrpc 2017-01-18 12:51:29 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2017:0066


Note You need to log in before you can comment on or make changes to this bug.