Sign In Register

How can we help you today?

Start a new topic

Automatic reconnection flooding logs ?

Hello,


We're studying how GameSparks reacts when the collection is lost and found again, or when there's no connection at all whatsoever. We are using the Java/Android SDK. With my phone in plane mod, I get a massive, massive error spam in logcat, of this kind :


 

08-12 07:21:07.976 11645-11702/fr.uncanny I/System.out: GSConnection. gs.currentUrl: wss://preview-b314713vRYh3.ws.gamesparks.net/ws/device/b314713vRYh3
08-12 07:21:07.979 11645-11702/fr.uncanny W/System.err: com.neovisionaries.ws.client.WebSocketException: Failed to connect to 'preview-b314713vRYh3.ws.gamesparks.net:443': Host is unresolved: preview-b314713vRYh3.ws.gamesparks.net
08-12 07:21:07.979 11645-11702/fr.uncanny W/System.err:     at com.neovisionaries.ws.client.SocketConnector.doConnect(SocketConnector.java:120)
08-12 07:21:07.979 11645-11702/fr.uncanny W/System.err:     at com.neovisionaries.ws.client.SocketConnector.connect(SocketConnector.java:82)
08-12 07:21:07.980 11645-11702/fr.uncanny W/System.err:     at com.neovisionaries.ws.client.WebSocket.connect(WebSocket.java:1743)
08-12 07:21:07.980 11645-11702/fr.uncanny W/System.err:     at com.gamesparks.sdk.GSConnection.<init>(GSConnection.java:38)
08-12 07:21:07.980 11645-11702/fr.uncanny W/System.err:     at com.gamesparks.sdk.GS.NewConnection(GS.java:208)
08-12 07:21:07.980 11645-11702/fr.uncanny W/System.err:     at com.gamesparks.sdk.GS.ConnectIfRequired(GS.java:196)
08-12 07:21:07.980 11645-11702/fr.uncanny W/System.err:     at com.gamesparks.sdk.GS.processQueues(GS.java:174)
08-12 07:21:07.981 11645-11702/fr.uncanny W/System.err:     at com.gamesparks.sdk.GS$GSWorker.run(GS.java:559)
08-12 07:21:07.981 11645-11702/fr.uncanny W/System.err:     at java.lang.Thread.run(Thread.java:818)
08-12 07:21:07.981 11645-11702/fr.uncanny W/System.err: Caused by: java.net.UnknownHostException: Host is unresolved: preview-b314713vRYh3.ws.gamesparks.net
08-12 07:21:07.981 11645-11702/fr.uncanny W/System.err:     at java.net.Socket.connect(Socket.java:867)
08-12 07:21:07.982 11645-11702/fr.uncanny W/System.err:     at com.neovisionaries.ws.client.SocketConnector.doConnect(SocketConnector.java:111)
08-12 07:21:07.982 11645-11702/fr.uncanny W/System.err: 	... 8 more

 

And so on and so on, every few milliseconds. Is that normal ? Does that impact performance ? Is there a way to avoid any reconnection spam like that, which most likely impacts performance ? Ideally, I would just check if GS is connected every time I call requests for GS, and try reconnecting it before sending the request if it's not already connected.

Login to post a comment