Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiple brokers? #46

Open
DenisGorbachev opened this issue Jul 13, 2015 · 6 comments
Open

Multiple brokers? #46

DenisGorbachev opened this issue Jul 13, 2015 · 6 comments

Comments

@DenisGorbachev
Copy link
Contributor

Does PIGATO.Client really support connecting to multiple brokers? The code says this.socket.connect(this.broker) (single connect call), and original ZMQ guide says A subscriber can connect to more than one publisher, using one connect call each time (multiple connect calls). So, what's right? :)

Or am I missing the point of connect?

@prdn
Copy link
Owner

prdn commented Jul 13, 2015

The multiple broker support as described in the zmq official guide was part of pigato and removed after some time because it was useful only as a ventilator but was very hard to control.

I'm currently working on a new client class that can wrap multiple clients and used as a single client so we maintain the overall structure simple but at the same time we allow to track correctly requests states and handle network issues.

Does this sound good for you?

@DenisGorbachev
Copy link
Contributor Author

Sounds great. Currently my client sends requests for various services. Would be great if each "subclient" were attached to a single service.

By the way, I'm planning to launch N clients, K brokers, M workers — all connecting/binding to the same addr. Is that a correct setup? (particularly worried about "K brokers" part)

@maxired
Copy link

maxired commented Jul 16, 2015

@DenisGorbachev , from what I know, ou can't have K brokers connected to the same addr.
In order to solve this kind of problems, I am working on a special kind of worker, that one can call proxy, which will transfert requests from a broker to another.

@prdn
Copy link
Owner

prdn commented Jul 21, 2015

@maxired that is amazing

@maxired
Copy link

maxired commented Jul 21, 2015

@prdn , you might be interested in giving it a look -> https://github.com/maxired/pigato-proxy

For information, I also published https://github.com/maxired/pigato-cli , but this is not relevant to this issue.

@prdn
Copy link
Owner

prdn commented Jul 22, 2015

@maxired I'm looking to use pigato-proxy in some project 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants