Comments (3)
I recently upgraded the pubsub dependency in my project following the documentation, but I am getting this error whenever I run the server:
an exception was raised:
** (ArgumentError) unknown registry: Demo.PubSub
(elixir 1.10.2) lib/registry.ex:1239: Registry.info!/1
(elixir 1.10.2) lib/registry.ex:920: Registry.register/3
(phoenix_pubsub 2.0.0) lib/phoenix/pubsub.ex:117: Phoenix.PubSub.subscribe/3
(phoenix 1.5.8) lib/phoenix/channel/server.ex:420: Phoenix.Channel.Server.init_join/3
(phoenix 1.5.8) lib/phoenix/channel/server.ex:378: Phoenix.Channel.Server.channel_join/4
(phoenix 1.5.8) lib/phoenix/channel/server.ex:298: Phoenix.Channel.Server.handle_info/2
(stdlib 3.7) gen_server.erl:637: :gen_server.try_dispatch/4
(stdlib 3.7) gen_server.erl:711: :gen_server.handle_msg/6
Here is my application.ex
def start(_type, _args) do
children = [
{Phoenix.PubSub, name: Demo.PubSub},
Demo.Repo,
DemoWeb.Endpoint,
{Demo.ExpireCodesJob, []},
{Demo.DistributeCodesJob, []},
{Oban, oban_config()},
worker(PlugAttack.Storage.Ets, [Demo.PlugAttack.Storage, [clean_period: 60_000]])
]
opts = [strategy: :one_for_one, name: Demo.Supervisor]
Supervisor.start_link(children, opts)
end
It happens occasionally not all the time as other users reported.
from phoenix_pubsub.
Hi there, I am facing similar issues, I had updated to version 2 and now I am confused, the code documentation establish this as a valid example - name as an atom {Phoenix.PubSub, name: :my_pubsub},
but the notes on the readme says {Phoenix.PubSub, name: MyApp.PubSub})
What's the correct one? my test suite is failing since multiple errors like ** (FunctionClauseError) no function clause matching in Phoenix.PubSub.broadcast/4 Any help is very appreciated :D
from phoenix_pubsub.
@sashaafm What does the test look like that is causing the issue? I know it's silly, but since you've confirmed pubsub is starting first in the supervision tree, is it possible there is a typo in the name MyAppServer.PubSub when you call broadcast? Also, if there is or isn't an alias present in that file, that's tripped me up in the past.
But yeah, likely the devil is in the details, and seeing the actual test implementation (or place where you call broadcast) might help.
from phoenix_pubsub.
Related Issues (20)
- Network traffic up for 20 minutes after a server restart
- Release v1.1.3 suppressing warnings HOT 1
- Where is version 2.0? HOT 1
- It may be helpful for users, if parallel option can be provided when starting Registry. Without it partitions in registry executes sequentially. HOT 1
- unknown registry: XXX.PubSub HOT 4
- RFC: Provide a way to mass update presences HOT 1
- topic forced to be string HOT 1
- Race condition causing data inconsistency when nodes are coming up
- Does Phoenix.PubSub itself support subscribing to wildcard topics? HOT 1
- [Feature Request] Be able to transform a module into a Pub.Sub HOT 6
- Unsubscribe all HOT 2
- v2.1 and v2.0 are incompatible
- Odd Jason Encoding error after new release HOT 2
- Broken Build Status link
- Presence list keep growing when using Presence.update HOT 3
- Presence stops working after ~1 week HOT 5
- Politely request release of 2.1.4
- Tracker: join/leave within broadcast_period unclear in handle_diff/2 HOT 5
- RFC: expose erlang pg's scope ability for Phoenix.PubSub.PG2 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from phoenix_pubsub.