Opened 13 years ago
Closed 12 years ago
#6823 closed defect (fixed)
josm starts extremely slow when osm api is offline
Reported by: | Cobra | Owned by: | team |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | Core | Version: | |
Keywords: | Cc: |
Description (last modified by )
When trying to start josm while the osm api is offline, josm hangs for 10 minutes without any visible feedback or any possibility to cancel the capabilities request or exit josm.
The log doesn't tell much for ~9 Minutes:
Build-Date: 2011-08-31 16:06:11 Revision: 4385 Is-Local-Build: true loading plugin 'proj4j' (version 26509) GET http://api.openstreetmap.org/api/capabilities... GET http://api.openstreetmap.org/api/capabilities...
For the moment, is there any possibility to set a lower timeout or start josm with a "work offline" flag?
Attachments (0)
Change History (8)
comment:1 by , 13 years ago
comment:3 by , 12 years ago
I can repoduce. (Start a local server like this
#!/usr/bin/ruby require 'webrick' include WEBrick def handl(req) for i in (1..20) sleep(1) puts i end end HTTPServer.new(:Port => 3333, :DocumentRoot => Dir.pwd, :MaxClients => 1000, :RequestCallback=>lambda{|x| handl(x)}).start
and put http://localhost:3333/
as API URL.)
comment:4 by , 12 years ago
Hmm, we have already timeout variables with about 30 seconds, but they must be activated for each connection individual. Probably some are still missing these settings.
follow-up: 8 comment:6 by , 12 years ago
This fixes the specific problem. We should probably set a read timeout for the other HttpURLConnections in the code as well.
comment:8 by , 12 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Replying to bastiK:
We should probably set a read timeout for the other HttpURLConnections in the code as well.
Better set no read timeout (or several minutes) for API, WMS and similar requests, because the remote server has to "prepare" the answer and this can take some time.
Replying to Cobra:
I requested this a time ago (#4614).