meraj_enigma
Elixir/Phoenix Channel based chat application
Hello,
I am currently investigating into writing a real time chat application in Elixir/Phoenix. I have a few queries before I jump into choosing a particular technology. Please see and answer my below queries -
-
Is WebSocket the standard for writing real time chat applications or can I use gRPC or is there any better transport mechanism?
-
How does Elixir/Phoenix Channel compares to other technologies or services like
- Firestore
- Pusher
- Anycable
- Action Cable
-
If I decide to go with Elixir/Phoenix Channel, how can I run multiple instances of chat application on Kubernetes pods? Can someone points me to any document/article on this deployment part?
-
Is there any hidden problem using WebSocket with multiple instances of chat applications that I should know about - like security/stability/scalability/performance?
Awaiting some response.
Thanks,
-Meraj
Most Liked Responses
kokolegorille
Websocket is one of the reason why I started Phoenix, coming from Rails…
1 If You use Phoenix, it might… but You can use other protocol
2. Firestore. Pusher. Anycable are all external services. Actioncable… Phoenix channel, hmmm, cannot be compared
3. Distribution is one aspect of the BEAM, but it’s not easy to setup
4. Websocket is just the transport
Sorry to tell, but a chat app is just the hello world application in Phoenix. If Rails promotion video is about building a blog in 15 minutes, Phoenix one could be how to build a chat in 15 minutes.
Websocket is just the transport, but Elixir has building blocks for chat application.
You should really try to build one. And You will see it’s easy because of the tools the BEAM provides.
There was a lecture about building a chat in Erlang before Phoenix even existed, unfortunately it is outdated now.
https://pragprog.com/screencast/v-kserl/erlang-in-practice
The article You posted is about Ruby…
Update: I guess You can make it in less than 15 minutes… ![]()
meraj_enigma
Hi @kokolegorille, thanks for your reply.
Regarding point 3 - I have come across the below articles -
Looks like using Redis Pub/Sub it’s not that complicated to setup. However, using PG2 adapter can be a bit complicated.
Thanks.
Popular in Questions
Other popular topics
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #javascript
- #podcasts
- #code-sync
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #phoenix_html
- #iex
- #blog-post
- #graphql
- #genstage
- #ai
- #websockets
- #supervisor
- #advent-of-code
- #elixirconf-us
- #distillery
- #processes
- #forms
- #api
- #metaprogramming
- #security
- #performance








