I keep seeing the following warning and stack trace in the server log and would like to know what is going wrong and how to fix it. I checked the designation PUSH-000183, but it only says "A communication error has occurred on a message channel."
2016-04-20 13:37:42.452|WARN|Diffusion: InboundThreadPool Thread_1|PUSH-000183|Message channel error: 'NIOBufferedChannel@571714020[connected local=/10.96.130.21:8070 remote=/10.96.1.36:24832] : Closed(UNEXPECTED_ERROR) ServerInboundTask@542477fd HTTPConnectionHandler@2641ae33[partial request - more expected]: handler left no space in buffer ' caused by 'ServerInboundTask@542477fd HTTPConnectionHandler@2641ae33[partial request - more expected]: handler left no space in buffer'.|com.pushtechnology.diffusion.io.message.MessageChannelException
com.pushtechnology.diffusion.io.message.MessageChannelException: ServerInboundTask@542477fd HTTPConnectionHandler@2641ae33[partial request - more expected]: handler left no space in buffer
at com.pushtechnology.diffusion.io.nio.NIOBufferedChannel.logClosingException(NIOBufferedChannel.java:647)
at com.pushtechnology.diffusion.io.nio.NIOBufferedChannel.logAndClose(NIOBufferedChannel.java:613)
at com.pushtechnology.diffusion.io.nio.AbstractReadSelector$InboundTask.close(AbstractReadSelector.java:410)
at com.pushtechnology.diffusion.io.nio.AbstractReadSelector$InboundTask.run(AbstractReadSelector.java:351)
at com.pushtechnology.diffusion.threads.FastThreadPool$PoolWorker.run(FastThreadPool.java:783)
at java.lang.Thread.run(Thread.java:744)
Caused by: java.lang.IllegalStateException: ServerInboundTask@542477fd HTTPConnectionHandler@2641ae33[partial request - more expected]: handler left no space in buffer
at com.pushtechnology.diffusion.io.nio.AbstractReadSelector$InboundTask.run(AbstractReadSelector.java:324)
Is this only limited to clients connecting using XHR or would websockets also be affected?
This happens when a client sends a message to the server that is bigger than the configured input-buffer-size in Connectors.xml.
It will disconnect the client which may then reconnect if it has been configured to do so. This can happen to any client regardless of the transport (XHR, Websockets, etc).
You will need to increase the input-buffer-size in Connectors.xml to match the biggest message that you expect. For example if you are sending messages up to 256K in size you could use the following configuration:
<socket-conditioning>
<!-- If this value is less than max-message-size defined in
Server.xml, it will be
overwritten by the latter. -->
<input-buffer-size>256k</input-buffer-size>
<!-- Other config... -->
</socket-conditioning>