androidasync-koush

Android Studio Gradle Error:Execution failed for task ':app:dexDebug' using Ion koush lib

蹲街弑〆低调 提交于 2019-12-25 06:35:18
问题 I want to use the Ion Lib from koush in Android Studio. But after I synchronize the libraries in my gradle file and try to run the application a strange error occurs. My thought is that the Ion Lib does not accept the other libraries in my gradle file. Gradle tasks [:app:assembleDebug] :app:preBuild UP-TO-DATE :app:preDebugBuild UP-TO-DATE :app:checkDebugManifest :app:preReleaseBuild UP-TO-DATE :app:prepareComAndroidSupportAppcompatV72311Library UP-TO-DATE :app

How to close/retry/manage a WebSocket using Koush AndroidAsync?

南楼画角 提交于 2019-12-19 06:16:10
问题 I'm using Koush's AndroidAsync for a WebSocket client. My code follows the example at https://github.com/koush/AndroidAsync and works. (Example copied below.) I need my app to open a websocket when it starts, however, I need to handle a few issues: A) I need to allow the user to change the address of the websocket server. In this case, I need to close the existing websocket (which may have failed) and open a websocket to the new server. B) The Server may be down or unavailable. In this case I

How are timeouts set for AndroidAsync websockets?

假如想象 提交于 2019-12-13 02:31:49
问题 I am trying to change the default AndroidAsync websocket initial connection timeout of 30 seconds. This is the working version with the default timeout: AsyncHttpClient.getDefaultInstance().websocket(connectionURI.toString(), null, this); I would like to change the timeout. This is what I expected to work: int timeout_ms = 20000; AsyncHttpGet request = new AsyncHttpGet(connectionURI.toString()); request.setTimeout(timeout_ms); AsyncHttpClient.getDefaultInstance().websocket(request, null, this

Why is AndroidAsync disconnect time so long?

我的梦境 提交于 2019-12-12 13:24:07
问题 I'm using the AndroidAsync koush low level network protocol library. I am connecting to a server with WebSocket. I am able to connect, send/receive messages, and disconnect. My disconnect time is very long. Server does not detect the disconnect for on average 59 seconds. In order to reproduce the problem, I connect WebSocket, authorize, and start pinging every 10 seconds. Then I turn on Airplane Mode and my network connection drops. At this time the setClosedCallback method is called. Here is

Socket.io client on Google Glass

淺唱寂寞╮ 提交于 2019-12-08 03:29:53
问题 Im trying to let my Google Glass and my android phone connect to a NodeJs server that Im running on my computer, so that I can send messages from my android phone to my Google Glass. For this Im using koush's AndroidAsync library, which works great on my android phone and I have absolutely no trouble connecting my phone to the NodeJS server with this library. However, the same code doesnt seem to work on my Google Glass. My Google Glass DOES connect, because the on connection eventhandler of

How to close/retry/manage a WebSocket using Koush AndroidAsync?

a 夏天 提交于 2019-12-01 03:59:57
I'm using Koush's AndroidAsync for a WebSocket client. My code follows the example at https://github.com/koush/AndroidAsync and works. (Example copied below.) I need my app to open a websocket when it starts, however, I need to handle a few issues: A) I need to allow the user to change the address of the websocket server. In this case, I need to close the existing websocket (which may have failed) and open a websocket to the new server. B) The Server may be down or unavailable. In this case I'd like to report that back to the activity. Currently it simply silently fails. So in order of