Try PubSub+

Does Solace Support Server-sent Events

Rakesh JSRakesh JS Member Posts: 1

wanted to know if solace supports server sent events for creating a streaming API that pushes text messages from server to clients.

Tagged:

Comments

  • TomFTomF Member, Employee Posts: 225 Solace Employee

    Hi @Rakesh JS , I'm tempted to just say "yes" and leave it at that :)

    Solace uses a brokered publish/subscribe pattern. The broker is the server and your applications are clients in this model, but anyone can send to anyone. Your "server" application can send to any number of "client" applications.

    Regarding "text messages," we send any data you send us to wherever it needs to go. It can be text, binary, a cat video... anything. Essentially, the interpretation of what you're sending is decided by you. We have helper routines/classes that will, say interpret a message as text.

  • marcmarc Member, Administrator, Moderator, Employee Posts: 336 admin
    edited March 26 #3

    Hey @TomF I think @Rakesh JS is referring to the Server-Sent Events capabilities standardized as part of HTML5. Solace Event Brokers don't currently support SSE, but I'd love to hear more about your use case for using them @Rakesh JS. We usually direct folks towards using MQTT over websockets since it's still lightweight while also allowing for bi-directional communications which is a shortcoming of SSE.

    There is a short comparison of SSE & MQTT here: https://www.iotforall.com/mqtt-vs-sse

    *Note we also have a JavaScript SMF API which allows for more use of solace broker features.

  • TomFTomF Member, Employee Posts: 225 Solace Employee

    Lol! I read "server-side" events not "server sent" events. Apologies.

  • AaronAaron Member, Moderator, Employee Posts: 177 Solace Employee

    Also, we can do HTTP Webhooks out of the broker... every message that lands on a particular queue can get either POST or PUT to a defined URL.

Sign In or Register to comment.