Reputation: 507
I've been recently learning about vertx and websocket. What I understood that you can have real-time application using them, but I didn't understand the difference between them A websocket lets you push messages from server to client and vice-versa, encouraging the publish-subscribe methodology. Then what is vertx doing? It acts as an event bus and also encourages publish-subscribe model.
I can be completely wrong in my analysis, hence please correct me and I'll be glad. thanks.
Upvotes: 0
Views: 671
Reputation: 17731
WebSockets is a stateful protocol, usually used to communicate between clients and servers.
Vert.x is a server-side framework, which has a very good support for WebSockets.
You don't have to use WebSockets with Vert.x. But if you do want to use WebSockets, Vert.x is a great option.
Here's an article I wrote a few months ago about both:
https://medium.com/@alexey.soshin/playing-ping-pong-over-websockets-with-vert-x-447c634c6c87
Upvotes: 2