Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DoCache: Use HttpURLConnection #21

Open
jperedadnr opened this issue May 9, 2018 · 0 comments
Open

DoCache: Use HttpURLConnection #21

jperedadnr opened this issue May 9, 2018 · 0 comments

Comments

@jperedadnr
Copy link
Contributor

Instead of URLConnection, and call disconnect() at the end.

It may help closing too many open files exception on iOS.

May 09, 2018 8:17:35 AM com.gluonhq.impl.maps.tile.osm.CachedOsmTileRetriever
SEVERE: null
java.net.SocketException: Too many open files
	at java.lang.Throwable.fillInStackTrace(Unknown Source)
	at java.lang.Throwable.<init>(Unknown Source)
	at java.lang.Exception.<init>(Unknown Source)
	at java.io.IOException.<init>(Unknown Source)
	at java.net.SocketException.<init>(Unknown Source)
	at java.net.Socket.createImpl(Unknown Source)
	at java.net.Socket.connect(Unknown Source)
	at sun.net.NetworkClient.doConnect(Unknown Source)
	at sun.net.www.http.HttpClient.openServer(Unknown Source)
	at sun.net.www.http.HttpClient.openServer(Unknown Source)
	at sun.net.www.http.HttpClient.<init>(Unknown Source)
	at sun.net.www.http.HttpClient.New(Unknown Source)
	at sun.net.www.http.HttpClient.New(Unknown Source)
	at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(Unknown Source)
	at sun.net.www.protocol.http.HttpURLConnection.plainConnect0(Unknown Source)
	at sun.net.www.protocol.http.HttpURLConnection.plainConnect(Unknown Source)
	at sun.net.www.protocol.http.HttpURLConnection.connect(Unknown Source)
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(Unknown Source)
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
	at com.gluonhq.impl.maps.tile.osm.CachedOsmTileRetriever$CacheThread.doCache(Unknown Source)
	at com.gluonhq.impl.maps.tile.osm.CachedOsmTileRetriever$CacheThread.run(Unknown Source)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant