Hi All,

I am having a little problem with my messaging.  I have modeled my app similar 
to the way the SumUp example application works.  Things work fine as long as my 
messages are delimited by using \r\n at the end of the message.  I would like 
to use a different single byte delimiter (0x03) (if possible? for compatiblity 
with the current client base) to end my messages, but I can't seem to get this 
to work (actually I don't know how to get this to work).  I decided to try 
using my test client against both the echo example and the reverser example, to 
see if it behaves in the same manner in this regard.  Both work fine as long as 
I use something like this to write my message:

            out = new PrintWriter(socket.getOutputStream(), true);
            out.println(payload); // contains /r/n ending to msg

But if I leave off the \r\n, e.g.,

            out = new PrintWriter(socket.getOutputStream(), true);
            out.print(payload); // no /r/n on the print

Then both echo and reverser servers neglect to forward the message on to the 
rest of the framework -- which is the same behavior I get from my server.

I am using SimpleServiceRegistry to initiate the framework.  I am new to NIO 
and I am not sure what I am missing.  Could somebody point me in the right 
direction?

Thanks
Colin

Reply via email to