Support Telnet clients in STOMP 1.2

139 views
Skip to first unread message

Hiram Chirino

unread,
Sep 11, 2012, 11:02:42 AM9/11/12
to stomp-spec
I propose that STOMP 1.2 also support being access via telnet on systems where hitting Enter generates a \r\n pair (like windows).
Right now the way the 1.1 spec is written, telnet access is supported but only on systems where hitting enter generates a \n.

I think we can support this by updating the grammer so that: 

LF                  = [<US-ASCII carriage return (octet 13)>] <US-ASCII new line (line feed) (octet 10)>

And adding the escape \r to the value encoding section.

What do you guys think?

--

Hiram Chirino

Software Fellow | FuseSource Corp.

chi...@fusesource.com | fusesource.com

skype: hiramchirino | twitter: @hiramchirino

blog: Hiram Chirino's Bit Mojo




Lionel Cons

unread,
Sep 12, 2012, 2:19:43 AM9/12/12
to stomp...@googlegroups.com
Hiram Chirino <hi...@hiramchirino.com> writes:
> I propose that STOMP 1.2 also support being access via telnet on
> systems where hitting Enter generates a \r\n pair (like windows).

This would also make STOMP a bit closer to other "text protocols" such
as HTTP or SMTP that require CR LF to terminate lines.

> LF = [<US-ASCII carriage return (octet 13)>] <US-ASCII new line (line feed) (octet 10)>

I would prefer to keep the usual meaning of LF in BNF and use:

LF = <US-ASCII new line (line feed) (octet 10)>
CR = <US-ASCII carriage return (octet 13)>
EOL = [CR] LF

And then use EOL instead of LF for the rest.

> And adding the escape \r to the value encoding section.

Indeed, this would be needed.

> What do you guys think?

Looks good to me.

Cheers,

Lionel

Hiram Chirino

unread,
Sep 12, 2012, 8:14:37 AM9/12/12
to stomp...@googlegroups.com
On Wed, Sep 12, 2012 at 2:19 AM, Lionel Cons <lione...@cern.ch> wrote:
I would prefer to keep the usual meaning of LF in BNF and use:

LF  = <US-ASCII new line (line feed) (octet 10)>
CR  = <US-ASCII carriage return (octet 13)>
EOL = [CR] LF

And then use EOL instead of LF for the rest.


Yep that looks better.  I'll make the updates today. 

gmallard

unread,
Sep 15, 2012, 12:36:52 PM9/15/12
to stomp...@googlegroups.com, hi...@hiramchirino.com
Macs/OSX ??

That is environment uses CR only doesn't it?

Juts thinking ..........

Hiram Chirino

unread,
Sep 15, 2012, 7:44:52 PM9/15/12
to stomp...@googlegroups.com
Think my OS X does NL on enter.
--

Hiram Chirino

Engineering | Red Hat, Inc.

hchi...@redhat.com | fusesource.com | redhat.com

Reply all
Reply to author
Forward
0 new messages