aboutsummaryrefslogtreecommitdiff
path: root/content/posts/2020-03-22-simple-sse-based-pubsub-server.md
diff options
context:
space:
mode:
authorMitja Felicijan <m@mitjafelicijan.com>2023-08-05 12:09:37 +0200
committerMitja Felicijan <m@mitjafelicijan.com>2023-08-05 12:09:37 +0200
commit2f5ea5f4982d6276881c9a3342ed8847ebc7d326 (patch)
treec405cf24bce11c00d7d453bdd18995cf8cda97aa /content/posts/2020-03-22-simple-sse-based-pubsub-server.md
parentc181dc5c37435029a0f5f2c51d6f36da4d32afd5 (diff)
downloadmitjafelicijan.com-2f5ea5f4982d6276881c9a3342ed8847ebc7d326.tar.gz
Moved assets to posts
Diffstat (limited to 'content/posts/2020-03-22-simple-sse-based-pubsub-server.md')
-rw-r--r--content/posts/2020-03-22-simple-sse-based-pubsub-server.md8
1 files changed, 4 insertions, 4 deletions
diff --git a/content/posts/2020-03-22-simple-sse-based-pubsub-server.md b/content/posts/2020-03-22-simple-sse-based-pubsub-server.md
index 8e46138..cf5a5d9 100644
--- a/content/posts/2020-03-22-simple-sse-based-pubsub-server.md
+++ b/content/posts/2020-03-22-simple-sse-based-pubsub-server.md
@@ -38,7 +38,7 @@ simple. We have subscribers that receive messages, and we have publishers that
38create and post messages. Similar model is also well know pattern that works on 38create and post messages. Similar model is also well know pattern that works on
39a premise of consumers and producers, and they take similar roles. 39a premise of consumers and producers, and they take similar roles.
40 40
41![How PubSub works](/assets/simple-pubsub-server/pubsub-overview.png) 41![How PubSub works](/posts/simple-pubsub-server/pubsub-overview.png)
42 42
43**These are some naive characteristics we want to achieve:** 43**These are some naive characteristics we want to achieve:**
44 44
@@ -74,7 +74,7 @@ page](https://html.spec.whatwg.org/multipage/server-sent-events.html).
74 74
75### Current browser support 75### Current browser support
76 76
77![Browser support](/assets/simple-pubsub-server/caniuse.png) 77![Browser support](/posts/simple-pubsub-server/caniuse.png)
78 78
79Check 79Check
80[https://caniuse.com/#feat=eventsource](https://caniuse.com/#feat=eventsource) 80[https://caniuse.com/#feat=eventsource](https://caniuse.com/#feat=eventsource)
@@ -142,7 +142,7 @@ which is quite nice and available from Developer Tools under Network tab.
142> ones. For debugging server events add `console.log` to `server.js` code and 142> ones. For debugging server events add `console.log` to `server.js` code and
143> print out events. 143> print out events.
144 144
145![Google Chrome Developer Tools EventStream](/assets/simple-pubsub-server/chrome-debugging.png) 145![Google Chrome Developer Tools EventStream](/posts/simple-pubsub-server/chrome-debugging.png)
146 146
147## Server implementation 147## Server implementation
148 148
@@ -281,7 +281,7 @@ nicer and maintanable.
281 281
282### Publisher and subscriber in action 282### Publisher and subscriber in action
283 283
284<video src="/assets/simple-pubsub-server/clients.m4v" controls></video> 284<video src="/posts/simple-pubsub-server/clients.m4v" controls></video>
285 285
286You can download [the code](../simple-pubsub-server/sse-pubsub-server.zip) and 286You can download [the code](../simple-pubsub-server/sse-pubsub-server.zip) and
287follow along. 287follow along.