Why the connection server running error!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Why the connection server running error!
The connection server run ERROR code:
[NettyClient-NIO-2] ERROR c.t.s.i.transport.MuxingBytesChannel - Error refilling connections on [channel: null, endpoint ws://localhost:8080/Thingworx/WS, uri: ws://localhost:8080/Thingworx/WS] failed : Connection authentication/registration FAILED [channel: NettyBytesChannel [id=ws://localhost:8080/Thingworx/WS-2, closed=true], code: STATUS_UNAUTHORIZED, reason: Error [context: authenticating connection][cause: Application Key not found]]
com.thingworx.sdk.api.exception.AuthenticationException: Connection authentication/registration FAILED [channel: NettyBytesChannel [id=ws://localhost:8080/Thingworx/WS-2, closed=true], code: STATUS_UNAUTHORIZED, reason: Error [context: authenticating connection][cause: Application Key not found]]
at com.thingworx.sdk.impl.protocol.common.AbstractProtocolContext$AuthChannelListenerAdapter.messageReceived(AbstractProtocolContext.java:225) [tw-sdk-core-1.1.0.4.jar:na]
at com.thingworx.sdk.impl.protocol.common.AbstractProtocolContext$AuthChannelListenerAdapter.messageReceived(AbstractProtocolContext.java:174) [tw-sdk-core-1.1.0.4.jar:na]
at com.thingworx.sdk.impl.transport.netty.NettyBytesChannel.messageReceived(NettyBytesChannel.java:112) [tw-sdk-netty-websockets-1.1.0.4.jar:na]
at com.thingworx.sdk.impl.transport.netty.NettyChannelHandler.channelRead0(NettyChannelHandler.java:125) [tw-sdk-netty-websockets-1.1.0.4.jar:na]
at com.thingworx.sdk.impl.transport.netty.NettyChannelHandler.channelRead0(NettyChannelHandler.java:26) [tw-sdk-netty-websockets-1.1.0.4.jar:na]
at io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:105) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:318) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:304) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.handler.timeout.IdleStateHandler.channelRead(IdleStateHandler.java:266) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:318) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:304) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:103) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:318) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:304) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:103) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:318) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:304) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:276) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:263) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:318) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:304) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:846) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:131) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:511) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:468) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:382) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:354) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at io.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:112) [netty-all-4.0.33.Final.jar:4.0.33.Final]
at java.lang.Thread.run(Thread.java:748) [na:1.8.0_131]
- Labels:
-
Connectivity
-
Install-Upgrade
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi Zhou,
How did you configure in Connection Server config file(cxserver.conf)?
Did you set proper appKey to connect to ThingWorx platform?
Like in my config file, I set as:
transport.websockets {
// Thingworx platform application key
app-key = "YOU_APP_KEY_HERE"
// One or more platforms can be specified here, comma separated
platforms = "ws://localhost:8080/Thingworx/WS"
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
This is my configuration file content:
cx-server {
protocol {
port=8090
http-server {
ssl {
enabled = false
}
}
health-check {
port = 9009
}
transport.websockets {
app-key = "44b3eac5-63e5-469d-8f4b-acf91d051ccc"
platforms = "ws://host:port/Thingworx/WS"
}
}
}
