Closed Bug 801461 Opened 8 years ago Closed 8 years ago

Set a timeout on the http request when importing build data

Categories

(Tree Management Graveyard :: TBPL, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: nthomas, Assigned: emorley)

References

Details

(Keywords: sheriffing-P1)

Attachments

(1 file)

During the Friday network flakiness in SCL3 the cron job calling import-buildbot-data.py got hung in a state for several hours. After the network recovered the job was still hung and IT's oncall was needed to kill the process off to get the build information flowing in to tbpl's db again.

Adding a timeout to the request for builds-4hrs.js.gz would be one way to work around this. If it's running on Python 2.6 then urllib2.urlopen can be passed a timeout argument at 
http://hg.mozilla.org/users/mstange_themasta.com/tinderboxpushlog/file/default/dataimport/import-buildbot-data.py#l155
I don't know how long the transfer takes but it might be worth setting a timeout like 60 seconds in case it's slow in some circumstances we don't want to give up too soon.
And again today - bug 821232. What is a sensible timeout value ?
(In reply to Nick Thomas [:nthomas] from comment #2)
> And again today - bug 821232. What is a sensible timeout value ?

The file at the moment is 1.4MB, which takes me 2-3s locally to download.

30-60s should allow plenty of wiggle room.
Assignee: nobody → edmorley.bz
Status: NEW → ASSIGNED
Keywords: sheriffing-P1
Hardware: x86 → All
Version: other → Trunk
Oops and now bug 827443.

I have a WIP in my mq from before Christmas - will try and find some time for it this week.
Attached patch Patch v1Splinter Review
Attachment #701793 - Flags: review?(nthomas)
Comment on attachment 701793 [details] [diff] [review]
Patch v1

Seems fine to me.
Attachment #701793 - Flags: review?(nthomas) → review+
Depends on: 833358
In production.
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Product: Webtools → Tree Management
Product: Tree Management → Tree Management Graveyard
You need to log in before you can comment on or make changes to this bug.