-
In Cluster model, when I pub a message to cluster addr, subscribe can receive message, but we got an ERR log
what’s the problem, what should i do ? config file as below
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
Hey!
Clients should connect to the listen URL of one of the nodes. In your example it's Docs are here: https://docs.nats.io/running-a-nats-service/configuration/clustering Keep in mind that your cluster should have at least 3 nodes. |
Beta Was this translation helpful? Give feedback.
Hey!
cluster
routes are meant to be used only for other nodes (servers) to connect and form a cluster.Clients should connect to the listen URL of one of the nodes. In your example it's
192.168.0.3:4222
.Docs are here: https://docs.nats.io/running-a-nats-service/configuration/clustering
Keep in mind that your cluster should have at least 3 nodes.
If you want master/slave hub/spoke architecture, leafnodes might be a better solution.