projects
/
pgweb.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4ccf105
)
Attempt to set a 20 second timeout on searches
author
Magnus Hagander
<magnus@hagander.net>
Sat, 12 Jan 2013 17:11:38 +0000
(18:11 +0100)
committer
Magnus Hagander
<magnus@hagander.net>
Sat, 12 Jan 2013 17:11:38 +0000
(18:11 +0100)
pgweb/search/views.py
patch
|
blob
|
blame
|
history
diff --git
a/pgweb/search/views.py
b/pgweb/search/views.py
index 30d7aa8695f33d1f42a05dc00319f2e60d20da56..45c5efa7d61d1ce074413b078935f2108b249b9a 100644
(file)
--- a/
pgweb/search/views.py
+++ b/
pgweb/search/views.py
@@
-178,6
+178,7
@@
def search(request):
# No hits found - so try to get them from the search server
c = httplib.HTTPConnection(settings.ARCHIVES_SEARCH_SERVER, strict=True, timeout=5)
c.request('POST', '/archives-search/', urlstr)
+ c.sock.settimeout(20) # Set a 20 second timeout
r = c.getresponse()
if r.status != 200:
memc = None