From 778138aac41269f987559299c5a00b7a5f430185 Mon Sep 17 00:00:00 2001 From: Alex Hultman <3397140+alexhultman@users.noreply.github.com> Date: Tue, 14 Aug 2018 19:27:39 +0200 Subject: [PATCH] Update README.md --- README.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/README.md b/README.md index bf8f319..ccf9056 100644 --- a/README.md +++ b/README.md @@ -4,6 +4,16 @@ µWS v0.15 is about 20% faster than v0.14 for small sends, 260% faster for large sends (50 MB). +#### Pub/sub +One of the most popular usages of WebSockets is to deliver a message sent under a topic to all subscribers of said topic. This functionality is easy to implement and even easier to completely mess up, resulting in a very inefficient solution. + +With v0.15 we now have built-in protocol independent pub/sub support delivering top notch broadcast performance. + +```c++ +ws->sub("some/topic/*"); +ws->pub("another/topic/here", message); +``` + #### Build optimized WebSocket & HTTP servers & clients in no time. ```c++ uWS::App a; // or uWS::SSLApp(options) for SSL