Github user d2r commented on a diff in the pull request: https://github.com/apache/storm/pull/838#discussion_r45513199 --- Diff: storm-core/src/jvm/backtype/storm/messaging/netty/SaslMessageToken.java --- @@ -74,20 +84,32 @@ int encodeLength() { * * @throws Exception */ - ChannelBuffer buffer() throws Exception { + public ChannelBuffer buffer() throws IOException { ChannelBufferOutputStream bout = new ChannelBufferOutputStream( ChannelBuffers.directBuffer(encodeLength())); - short identifier = -500; int payload_len = 0; if (token != null) payload_len = token.length; - bout.writeShort(identifier); - bout.writeInt(payload_len); + bout.writeShort(IDENTIFIER); + bout.writeInt((int) payload_len); --- End diff -- `(int)` cast not needed.
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---