When would you use Spark.publish() vs. Server-Sent Events (SSE)?

Both Spark.publish and Server-Sent Events (SSE) seem to provide a mechanism whereby the caller can block to get a notification from the Spark Core.

Just wondering about the use case scenarios for either. Are they both the same thing?

Thanks

They are indeed the same thing. A Spark.publish() is what you use to trigger a Server Sent Event.

2 Likes

OK, thanks.

1 Like