Skip to main content
1-Visitor
December 9, 2016
Question

Suddenly the AzureIoThubConnector has stopped working!!!!

  • December 9, 2016
  • 1 reply
  • 6011 views

The azureiothub connector was working corectlty, but now has stopped working!!!!

It seems not to be able to open WS in thingworx...

Here is the log of the cx-server:

18:51:55.255 [Thread-10] ERROR c.t.s.i.t.netty.NettyBytesChannel - Error while establishing websocket connection on channel com.thingworx.sdk.impl.transport.netty.NettyBytesChannel$2@795a2ee4.

java.util.concurrent.TimeoutException: Timed out waiting for response

  at com.thingworx.sdk.impl.concurrent.DeadlineFuture.notifyOfTimeout(DeadlineFuture.java:81) ~[tw-sdk-core-1.2.0.5.jar:na]

  at com.thingworx.sdk.impl.concurrent.DeadlineManager.notifyOfTimeout(DeadlineManager.java:132) [tw-sdk-core-1.2.0.5.jar:na]

  at com.thingworx.sdk.impl.concurrent.DeadlineManager.processDeadlines(DeadlineManager.java:78) [tw-sdk-core-1.2.0.5.jar:na]

  at com.thingworx.sdk.impl.concurrent.DeadlineManager.run(DeadlineManager.java:47) [tw-sdk-core-1.2.0.5.jar:na]

  at java.lang.Thread.run(Thread.java:745) [na:1.8.0_92]

18:51:55.260 [Thread-10] ERROR c.t.f.i.AbstractManyPlatformWebSocketFabric - Failure while connecting to platform: endpoint=ws://localhost:8080/Thingworx/WS

java.util.concurrent.TimeoutException: Timed out waiting for response

  at com.thingworx.sdk.impl.concurrent.DeadlineFuture.notifyOfTimeout(DeadlineFuture.java:81) ~[tw-sdk-core-1.2.0.5.jar:na]

  at com.thingworx.sdk.impl.concurrent.DeadlineManager.notifyOfTimeout(DeadlineManager.java:132) ~[tw-sdk-core-1.2.0.5.jar:na]

  at com.thingworx.sdk.impl.concurrent.DeadlineManager.processDeadlines(DeadlineManager.java:78) ~[tw-sdk-core-1.2.0.5.jar:na]

  at com.thingworx.sdk.impl.concurrent.DeadlineManager.run(DeadlineManager.java:47) ~[tw-sdk-core-1.2.0.5.jar:na]

  at java.lang.Thread.run(Thread.java:745) ~[na:1.8.0_92]

18:51:55.361 [Thread-10] ERROR c.t.s.i.t.netty.NettyBytesChannel - Error while establishing websocket connection on channel com.thingworx.sdk.impl.transport.netty.NettyBytesChannel$2@156f3d21.

java.util.concurrent.TimeoutException: Timed out waiting for response

  at com.thingworx.sdk.impl.concurrent.DeadlineFuture.notifyOfTimeout(DeadlineFuture.java:81) ~[tw-sdk-core-1.2.0.5.jar:na]

  at com.thingworx.sdk.impl.concurrent.DeadlineManager.notifyOfTimeout(DeadlineManager.java:132) [tw-sdk-core-1.2.0.5.jar:na]

  at com.thingworx.sdk.impl.concurrent.DeadlineManager.processDeadlines(DeadlineManager.java:78) [tw-sdk-core-1.2.0.5.jar:na]

  at com.thingworx.sdk.impl.concurrent.DeadlineManager.run(DeadlineManager.java:47) [tw-sdk-core-1.2.0.5.jar:na]

  at java.lang.Thread.run(Thread.java:745) [na:1.8.0_92]

I tried to:

-Reboot

-Stop the firewall

but nothing..

Can you help me Please????

1 reply

14-Alexandrite
December 9, 2016

Can you make a connection to http://localhost:8080/Thingworx/Composer?

mvolanti1-VisitorAuthor
1-Visitor
December 10, 2016

Yes!

14-Alexandrite
December 10, 2016

Well, we know your local instance is up, then. We're getting a timeout, so maybe the URI in the config file has a slight error. I feel like we would get an authentication error if the API key had been wiped out by an upgrade (or something like that), but it's worth making sure the appKey you're using is still in your ThingWorx instance, too. We should look at the URI configured in your azure-iot.conf file. Mine's in the /conf dir of my Azure IoT Connector app. Here's the ThingWorx section:

  transport.websockets {

        // ThingWorx platform application key

        app-key = "xxxxxxxx-005e-49ed-8d7a-xxaxxxxxxxa"

        // One or more platforms can be specified here, comma separated

        platforms = "wss://twxazuredemo.cloudapp.net:443/Thingworx/WS"

    }

Your error trace makes me think you're not using ssl, so your platform's entry should probably look more like ws://localhost:8080/Thingworx/WS .

Let's check all that, and continue, if we don't find an issue.