The content-length header on the other hand does affect STOMP framing.
If it's missing, the frame ends at the first null byte. This means
the if your sending a message payload that contains an embedded null
byte, then it MUST set the content length to be properly framed.
This is why as of STOMP 1.1, we recommend that frame always specify
the content-length. It's the safer, and simpler. But technically its
not required if your not sending messages with null bytes. This comes
in handy if your manually doing a telnet session with your STOMP
server and typing out stomp frames by hand.
Regards,
Hiram
FuseSource
Web: http://fusesource.com/
The SEND, MESSAGE and ERROR frames SHOULD include a content-typeheader if a frame body is present. It SHOULD be set to a mime typewhich describes the format of the body to help the receiver of theframe interpret it's contents.
Great suggestion. I've opened issue
https://github.com/stomp/stomp-spec/issues/36
so we can update the next revision of the spec.
Regards,
Hiram
FuseSource
Web: http://fusesource.com/