
asibbald
Programming Phoenix LiveView B3.0 P237: More explanation needed
The text here could do with more explanation. It assumes a considerable amount of knowledge outside that covered so far in the book. If a reader doesn’t have this additional knowledge, they will not be able to understand what is being said here - which is pretty key to what we’re about to do.
an example of what I’m referring to:
“…The configuration sets the default adapter, PubSub.PG2. This adapter runs on Distributed Erlang––clients across distributed nodes of our app can subscribe to a shared topic and broadcast to that shared topic, because PubSub can directly exchange notifications between servers when configured to use the Phoenix.PubSub.PG2 adapter…”
First Post!

SophieDeBenedetto
Hey @asibbald! Which part of this explanation felt unclear to you? The intended take-away here is: By using the PG2 adapter, your code will work even if you deploy your application in a distributed manner". This is what we mean by:
clients across distributed nodes of our app can subscribe to a shared topic and broadcast to that shared topic, because
PubSub
can directly exchange notifications between servers when configured to use thePhoenix.PubSub.PG2
adapter
It’s not important to understand the mechanics of the PG2 adapter or Distributed Erlang beyond that, and I don’t feel that a lack of that deeper understanding will prevent the reader from building out the feature in this section.
Popular Pragmatic topics










Other popular topics









Latest in PragProg
Latest (all)
Categories:
Popular Portals
- /elixir
- /rust
- /wasm
- /ruby
- /erlang
- /phoenix
- /keyboards
- /js
- /rails
- /python
- /security
- /go
- /swift
- /vim
- /clojure
- /java
- /haskell
- /emacs
- /svelte
- /onivim
- /typescript
- /crystal
- /c-plus-plus
- /tailwind
- /kotlin
- /gleam
- /react
- /flutter
- /elm
- /ocaml
- /vscode
- /opensuse
- /ash
- /centos
- /php
- /deepseek
- /zig
- /scala
- /html
- /debian
- /nixos
- /lisp
- /agda
- /textmate
- /react-native
- /sublime-text
- /kubuntu
- /arch-linux
- /ubuntu
- /revery
- /manjaro
- /django
- /spring
- /diversity
- /nodejs
- /lua
- /julia
- /c
- /slackware
- /neovim