On Mon, Aug 26, 2013 at 8:32 PM,  <chrisg...@gmail.com> wrote:
> Thanks for taking the time to read/reply.
>
> GetHeartbeat2 is my original version which I included as well and the
> way I had thought it should probably work. This code is serializing to
> string
> on the inner buffer and then again on the outer.
>
>    response.response_proto = heartbeatResult.SerializeToString()
>     self.sendMessage(response.SerializeToString())
>
>
> The GetHeartbeat2 generates this error on the server ( I included more of
> the stack trace this time)
>
> Message: [org.java_websocket.exceptions.InvalidDataException:
> java.nio.charset.MalformedInputException: Input length = 1
>     at
> org.java_websocket.util.Charsetfunctions.stringUtf8(Charsetfunctions.java:80)
>     at
> org.java_websocket.WebSocketImpl.deliverMessage(WebSocketImpl.java:561)
>     at org.java_websocket.WebSocketImpl.decodeFrames(WebSocketImpl.java:328)
>     at org.java_websocket.WebSocketImpl.decode(WebSocketImpl.java:149)
>     at
> org.java_websocket.server.WebSocketServer$WebSocketWorker.run(WebSocketServer.java:593)
> Caused by: java.nio.charset.MalformedInputException: Input length = 1
>     at java.nio.charset.CoderResult.throwException(CoderResult.java:277)
>     at java.nio.charset.CharsetDecoder.decode(CharsetDecoder.java:798)
>     at
> org.java_websocket.util.Charsetfunctions.stringUtf8(Charsetfunctions.java:77)

I would assume that the error is in the sendMessage / receiving logic.
Try dumping out what you're sending and what you're receiving and make
sure they match up.

-- 
You received this message because you are subscribed to the Google Groups 
"Protocol Buffers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to protobuf+unsubscr...@googlegroups.com.
To post to this group, send email to protobuf@googlegroups.com.
Visit this group at http://groups.google.com/group/protobuf.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to