c++ Stomp client

39 views
Skip to first unread message

Gerald

unread,
Oct 30, 2025, 3:10:58 AM (3 days ago) Oct 30
to A gathering place for the Open Rail Data community

Darwin Pushport V16

Is the SOAP requests for data being discontinued? does anyone have a c or c++ client for connecting to the stomp web stream? does anyone have a STOMP CONNECT message structure so I can see what header information I'm missing when I try telnet in.  

 

CONNECT
accept-version:1.0,1.1,2.0
client-id:<LOGIN_USERNAME>-1
login:<LOGIN_USERNAME>
passcode:<LOGIN_PASSCODE>

 

^@

 

Evelyn Snow

unread,
Oct 30, 2025, 4:55:23 AM (3 days ago) Oct 30
to openrail...@googlegroups.com

Gerald

unread,
Oct 30, 2025, 5:23:04 AM (3 days ago) Oct 30
to A gathering place for the Open Rail Data community
Thanks for your help. This is what I tried and what I get back 

CONNECT
accept-version:1.0,1.1,2.0
host:darwin-dist-44ae45.nationalrail.co.uk
client-id:<login_id>-1
login:<login_id>
passcode:<passcode>

 

^@
ERROR
     content-type:text/plain
                            message:Unknown STOMP action: ���� ����'������CONNECT

Evelyn Snow

unread,
Oct 30, 2025, 5:30:45 AM (3 days ago) Oct 30
to openrail...@googlegroups.com
Hi Gerald,

Issue here is that you're using a telnet client, which is sending control characters when the other
end picks up. You'll want to use something that's protocol-agnostic, or you could write a program to
test this.

Evelyn

Gerald

unread,
Oct 30, 2025, 6:47:40 AM (3 days ago) Oct 30
to A gathering place for the Open Rail Data community
Thanks, I have my first test working now using PuTTy with the Telnet option: "Telnet Negotiation mode:" set to passive. Now I  can see the connection and message response I can start writing a c++ application to connect and handle the messages    

Peter Hicks

unread,
Oct 30, 2025, 6:56:48 AM (3 days ago) Oct 30
to openrail...@googlegroups.com
Hi Gerald

On Thursday, 30 October 2025 at 10:47, Gerald <gehe...@gmail.com> wrote:

Thanks, I have my first test working now using PuTTy with the Telnet option: "Telnet Negotiation mode:" set to passive. Now I can see the connection and message response I can start writing a c++ application to connect and handle the messages

If you want to reinvent the wheel and write your own Stomp client for C++, nobody can stop you.  However, please test it thoroughly against a locally running copy of ActiveMQ (either Classic or Artemis) and don't use somebody else's server.  Make sure you also handle exception scenarios well, which will require a good level of knowledge of Stomp and protocol development.

ActiveMQ has a JMS-like API available for C++ - see https://activemq.apache.org/components/cms/ - which may well suit your needs.  This supports Stomp and OpenWire, and if you have free choice, I'd use OpenWire as it's a more compact format.


Peter

Gerald

unread,
Oct 30, 2025, 8:34:47 AM (3 days ago) Oct 30
to A gathering place for the Open Rail Data community
Thanks for the advice, yes we have a local test link for development.
Reply all
Reply to author
Forward
0 new messages