Bug 610182 - Timeout on initial "refresh" of pool
Timeout on initial "refresh" of pool
Status: RELEASE_PENDING
Product: Candlepin
Classification: Community
Component: candlepin (Show other bugs)
0.5
All Linux
low Severity medium
: ---
: ---
Assigned To: Bryan Kearney
Katello QA List
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-07-01 13:39 EDT by Mark Sechrest
Modified: 2015-05-14 11:23 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed:
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Mark Sechrest 2010-07-01 13:39:13 EDT
Description of problem: QE executed the following in order to pull org 4969898's subscriptions into candlepin. The request timed out at the proxy layer.

root@iolo ~]# curl -u calfonso:redhat -k --header "Content-type:
application/json" --header "Accept: application/json" --request PUT
https://candlepin1.devlab.phx1.redhat.com:443/candlepin/owners/4969868/subscriptions
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>504 Gateway Time-out</title>
</head><body>
<h1>Gateway Time-out</h1>
<p>The proxy server did not receive a timely response
from the upstream server.</p>
<hr>
<address>Apache Server at candlepin1.devlab.phx1.redhat.com Port
443</address>
</body></html>
[root@iolo ~]# curl -u calfonso:redhat -k --header "Content-type:
application/json" --header "Accept: application/json" --request PUT
https://candlepin1.devlab.phx1.redhat.com:443/candlepin/owners/4969868/subscriptions
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>504 Gateway Time-out</title>
</head><body>
<h1>Gateway Time-out</h1>
<p>The proxy server did not receive a timely response
from the upstream server.</p>
<hr>
<address>Apache Server at candlepin1.devlab.phx1.redhat.com Port
443</address>
</body></html>
[root@iolo ~]# curl -u calfonso:redhat -k --header "Content-type:
application/json" --header "Accept: application/json" --request PUT
https://candlepin1.devlab.phx1.redhat.com:443/candlepin/owners//subscriptions
[root@iolo ~]# curl -u calfonso:redhat -k --header "Content-type:
application/json" --header "Accept: application/json" --request PUT
https://candlepin1.devlab.phx1.redhat.com:443/candlepin/owners/2921212/subscriptions
[root@iolo ~]# 

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.
2.
3.
  
Actual results:
Timeout

Expected results:
No timeout

Additional info:
Comment 1 James Bowes 2010-07-13 10:07:13 EDT
This should be solved after we have our async process framework in place, schedule for sprint 13
Comment 2 Mark Sechrest 2010-07-13 10:14:40 EDT
I think Bryan wanted some tuning to be done, prior to making this an async process
Comment 3 Mark Sechrest 2010-07-13 16:43:06 EDT
Here's a sync that seems to always fail:

curl -u calfonso:redhat -k --header "Content-type: application/json" --header "Accept: application/json" --request PUT https://cert-fte-candlepin.devlab.redhat.com:443/candlepin/owners/4596037/subscriptions
Comment 4 Bryan Kearney 2010-09-10 14:39:10 EDT
this is now an async process, and should no longer time out.
Comment 5 spandey 2010-10-18 11:48:58 EDT
Verified using following setup 

candlepin : candlepin1





[root@rhel6-alpha product]# curl -u candlepin_system_admin:admin -k --header "Content-type: application/json" --header "Accept: application/json" --request PUT https://candlepin1.devlab.phx1.redhat.com:443/candlepin/owners/4969868/subscriptions
{"id":"refresh_pools_04ee5a0c-d32b-41a2-a838-60c0d0cf63ee","state":"CREATED","startTime":null,"result":null,"finishTime":null,"statusPath":"/jobs/refresh_pools_04ee5a0c-d32b-41a2-a838-60c0d0cf63ee","updated":"2010-10-18T15:45:46.953+0000","created":"2010-10-18T15:45:46.953+0000"}[root@rhel6-alpha product]# 


Working fine 
Moving defect status from ON_QA to Verified
Comment 6 John Sefler 2010-10-18 12:06:48 EDT
VERIFIED AGAINST OWNER 1070642 (owner of user account test1) ON CANDLEPIN1 HOSTED ENVIRONMENT:
Note that due to the design change (making pool refreshes an async process), the initial request to refresh a pool returns a JSON object with an initial state of CREATED.  I then query the jobDetail looking at the state which eventually changes to "FINISHED".  Hence the design change to make refresh pools an async request avoids the request timeouts observed in the initial problem description.

[root@jsefler-itclient01 ~]# curl -k -u candlepin_system_admin:admin  --request PUT https://candlepin1.devlab.phx1.redhat.com:443/candlepin/owners/1070642/subscriptions
{"id":"refresh_pools_156a1535-b37d-42f8-bf2a-eabd48a1c369","state":"CREATED","startTime":null,"result":null,"finishTime":null,"statusPath":"/jobs/refresh_pools_156a1535-b37d-42f8-bf2a-eabd48a1c369","updated":"2010-10-18T15:54:18.468+0000","created":"2010-10-18T15:54:18.468+0000"}[root@jsefler-itclient01 ~]# 
[root@jsefler-itclient01 ~]# curl -k -u candlepin_system_admin:admin  --request GET https://candlepin1.devlab.phx1.redhat.com:443/candlepin/jobs/refresh_pools_156a1535-b37d-42f8-bf2a-eabd48a1c369
{"id":"refresh_pools_156a1535-b37d-42f8-bf2a-eabd48a1c369","state":"CREATED","startTime":"2010-10-18T15:54:18.000+0000","result":null,"finishTime":"2010-10-18T15:54:18.000+0000","statusPath":"/jobs/refresh_pools_156a1535-b37d-42f8-bf2a-eabd48a1c369","updated":"2010-10-18T15:54:18.000+0000","created":"2010-10-18T15:54:18.000+0000"}[root@jsefler-itclient01 ~]# curl -k -u candlepin_system_admin:admin  --request GET https://candlepin1.refresh_pools_156a1535-b37d-42f8-bf2a-eabd48a1c369
{"id":"refresh_pools_156a1535-b37d-42f8-bf2a-eabd48a1c369","state":"CREATED","startTime":"2010-10-18T15:54:18.000+0000","result":null,"finishTime":"2010-10-18T15:54:18.000+0000","statusPath":"/jobs/refresh_pools_156a1535-b37d-42f8-bf2a-eabd48a1c369","updated":"2010-10-18T15:54:18.000+0000","created":"2010-10-18T15:54:18.000+0000"}[root@jsefler-itclient01 ~]# curl -k -u candlepin_system_admin:admin  --request GET https://candlepin1.refresh_pools_156a1535-b37d-42f8-bf2a-eabd48a1c369
{"id":"refresh_pools_156a1535-b37d-42f8-bf2a-eabd48a1c369","state":"CREATED","startTime":"2010-10-18T15:54:18.000+0000","result":null,"finishTime":"2010-10-18T15:54:18.000+0000","statusPath":"/jobs/refresh_pools_156a1535-b37d-42f8-bf2a-eabd48a1c369","updated":"2010-10-18T15:54:18.000+0000","created":"2010-10-18T15:54:18.000+0000"}[root@jsefler-itclient01 ~]# curl -k -u candlepin_system_admin:admin  --request GET https://candlepin1.refresh_pools_156a1535-b37d-42f8-bf2a-eabd48a1c369
{"id":"refresh_pools_156a1535-b37d-42f8-bf2a-eabd48a1c369","state":"FINISHED","startTime":"2010-10-18T15:57:26.000+0000","result":"Pools refreshed for owner 1070642","finishTime":"2010-10-18T15:57:28.000+0000","statusPath":"/jobs/refresh_pools_156a1535-b37d-42f8-bf2a-eabd48a1c369","updated":"2010-10-18T15:57:28.000+0000","created":"2010-10-18T15:54:18.000+0000"}[root@jsefler-itclient01 ~]# 


MOVING TO VERIFIED
Comment 7 John Sefler 2011-05-04 10:40:29 EDT
Group move of VERIFIED Candlepin component bugs to RELEASE_PENDING

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