Closed skanct closed 9 years ago
This is definitely an issue, and one that has been around for a surprisingly long time. However, fixing it in the Client isn't the right place to tackle it, but the connection code is so convoluted that I don't blame you for applying a fix there.
See issue #28 for more on this issue and its resolution.
In the current implementation, if the user does not define a login and passcode, then the library sets their values to '' and the headers that are sent to the STOMP server are the following:
When this is tested against ActiveMQ (version 5.8.0), the connection fails with the following error:
According to the STOMP protocol specification, the clients MAY set the login and passcode headers. It seems that when the user does not define a login and passcode, then the CONNECT frame must not include these headers.
This commit changes the existing behaviour and when the user does not define a login and a passcode, then the library does not include these headers in the CONNECT frame.