Are key words "TOPIC" and "QUEUE" case-sensitive in CURL?
Hello Exports,
Greetings.
Are key words "TOPIC" and "QUEUE" case-sensitive in CURL?
Thank you.
https://docs.solace.com/API/RESTMessagingPrtl/Solace-REST-Example.htm
Felix,
BR
Best Answer
-
Hello All,
many thanks for your kind answers.
I did a rough test on our Solace test system and found it's not case sensitive.
Posting payload to the following URLs has the same result. Subscribers can all receive payload.
https://host:port/TOPIC/flight/boarding/fl1234/yow/ewr
https://host:port/topic/flight/boarding/fl1234/yow/ewr
https://host:port/toPic/flight/boarding/fl1234/yow/ewr
https://host:port/ToPic/flight/boarding/fl1234/yow/ewr
https://host:port/ToPiC/flight/boarding/fl1234/yow/ewr
https://host:port/flight/boarding/fl1234/yow/ewrThank you.
Felix,
BR
2
Answers
-
Hey @felix0315,
Great question! I'm actually not sure and don't see it specified in the docs. But note that both queues and topics are case sensitive so you don't want to be converting everything to one case in the URL ;)
Also all the examples I see have that level in all caps I would recommend using all caps unless we learn otherwise. Did you happen to try lowercase just to see if it works?
1 -
No it's not case sensitive.
Also, if the very first level isn't (case insensitive) "topic" or "queue", the whole this is treated as a topic. That is:
curl -u foo:bar http://localhost:9000/q1 -d 'this is my payload'
Will be a message published with a topic of
q1
. EDIT: oh, that was already mentioned in the first post! hahaBut yeah, always a topic, unless the first level is the word "queue".
2 -
Hello All,
many thanks for your kind answers.
I did a rough test on our Solace test system and found it's not case sensitive.
Posting payload to the following URLs has the same result. Subscribers can all receive payload.
https://host:port/TOPIC/flight/boarding/fl1234/yow/ewr
https://host:port/topic/flight/boarding/fl1234/yow/ewr
https://host:port/toPic/flight/boarding/fl1234/yow/ewr
https://host:port/ToPic/flight/boarding/fl1234/yow/ewr
https://host:port/ToPiC/flight/boarding/fl1234/yow/ewr
https://host:port/flight/boarding/fl1234/yow/ewrThank you.
Felix,
BR
2 -
Thanks for confirming @felix0315!
If you fly to YOW this time of year don't forget your jacket ;)
2