userA91
userA91

Reputation: 47

IBM Worklight - Android app crashes

When I launch the Android environment, the app crash and the worklight console show this message. The app works on browser environment

[2013-08-29 09:57:47 - ddmlib] An established connection was aborted by the software in your host machine
    java.io.IOException: An established connection was aborted by the software in your host machine
        at sun.nio.ch.SocketDispatcher.write0(Native Method)
        at sun.nio.ch.SocketDispatcher.write(Unknown Source)
        at sun.nio.ch.IOUtil.writeFromNativeBuffer(Unknown Source)
        at sun.nio.ch.IOUtil.write(Unknown Source)
        at sun.nio.ch.SocketChannelImpl.write(Unknown Source)
        at com.android.ddmlib.JdwpPacket.writeAndConsume(JdwpPacket.java:213)
        at com.android.ddmlib.Client.sendAndConsume(Client.java:605)
        at com.android.ddmlib.HandleHeap.sendREAQ(HandleHeap.java:348)
        at com.android.ddmlib.Client.requestAllocationStatus(Client.java:451)
        at com.android.ddmlib.DeviceMonitor.createClient(DeviceMonitor.java:837)
        at com.android.ddmlib.DeviceMonitor.openClient(DeviceMonitor.java:805)
        at com.android.ddmlib.DeviceMonitor.processIncomingJdwpData(DeviceMonitor.java:765)
        at com.android.ddmlib.DeviceMonitor.deviceClientMonitorLoop(DeviceMonitor.java:652)
        at com.android.ddmlib.DeviceMonitor.access$100(DeviceMonitor.java:44)
        at com.android.ddmlib.DeviceMonitor$3.run(DeviceMonitor.java:580)

and logcat:

[2013-08-29 09:57:47 - ddmlib] An established connection was aborted by the software in your host machine
java.io.IOException: An established connection was aborted by the software in your host machine
    at sun.nio.ch.SocketDispatcher.write0(Native Method)
    at sun.nio.ch.SocketDispatcher.write(Unknown Source)
    at sun.nio.ch.IOUtil.writeFromNativeBuffer(Unknown Source)
    at sun.nio.ch.IOUtil.write(Unknown Source)
    at sun.nio.ch.SocketChannelImpl.write(Unknown Source)
    at com.android.ddmlib.JdwpPacket.writeAndConsume(JdwpPacket.java:213)
    at com.android.ddmlib.Client.sendAndConsume(Client.java:605)
    at com.android.ddmlib.HandleHeap.sendREAQ(HandleHeap.java:348)
    at com.android.ddmlib.Client.requestAllocationStatus(Client.java:451)
    at com.android.ddmlib.DeviceMonitor.createClient(DeviceMonitor.java:837)
    at com.android.ddmlib.DeviceMonitor.openClient(DeviceMonitor.java:805)
    at com.android.ddmlib.DeviceMonitor.processIncomingJdwpData(DeviceMonitor.java:765)
    at com.android.ddmlib.DeviceMonitor.deviceClientMonitorLoop(DeviceMonitor.java:652)
    at com.android.ddmlib.DeviceMonitor.access$100(DeviceMonitor.java:44)
    at com.android.ddmlib.DeviceMonitor$3.run(DeviceMonitor.java:580)

Upvotes: 0

Views: 259

Answers (2)

Gaurav Bhattacharjee
Gaurav Bhattacharjee

Reputation: 61

In addition to the above answer,

1) Are you sure you're not getting a timeout error? Check in the Android Logcat view in eclipse. 2) Are you using something like a localhost in the application?

Upvotes: 0

cnandreu
cnandreu

Reputation: 5111

"These problem can be simply solved by closing Eclipse and restarting it again. Eclipse sometimes fails to establish a connection with the Emulator, so this can happen in some cases." - source

Upvotes: 1

Related Questions