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

using multi=True on ZeroMQSubscriber #265

Open
AvishaiW opened this issue Jun 21, 2018 · 4 comments
Open

using multi=True on ZeroMQSubscriber #265

AvishaiW opened this issue Jun 21, 2018 · 4 comments

Comments

@AvishaiW
Copy link

Hi,
I'm running my project on Aws instance using the zeroMQhandler to send logs to the client. When running on the local computer everything works fine and I'm able to receive the logs, however once I change to to the instance address subscriber = ZeroMQSubscriber(uri="tcp://20.20.20.20:5000", multi=True) I get the following error zmq.error.ZMQError: Can't assign requested address. I opened all Inbound/ outbound connections in AWS and was able to run a pure zeromq code (using PUSH/PULL) and there was a connection, so I presume that the issue is on your side.

@vmalloc
Copy link
Collaborator

vmalloc commented Jun 24, 2018

Hi! thanks for reporting.

Can you provide a minimal (as isolated as possible) example that reproduces this? It would make it much easier to pin-point and investigate.

Thanks!

@AvishaiW
Copy link
Author

AvishaiW commented Jun 24, 2018

Client:

`from logbook.queues import ZeroMQSubscriber
from logbook import StderrHandler

my_handler = StderrHandler()
subscriber = ZeroMQSubscriber("tcp://20.20.20.20:5050", multi=True)
#subscriber = ZeroMQSubscriber('tcp://127.0.0.1:5050', multi=True)
controller = subscriber.dispatch_in_background(my_handler)
a = True
while a:
if not a:
a = False

controller.stop()
subscriber.close()`

Server:

`from logbook import Logger
from logbook.queues import ZeroMQHandler

log = Logger('cloud_server')
handler = ZeroMQHandler(uri='tcp://0.0.0.0:5050', multi=True)
handler.push_application()
while True:
log.info("test me")
handler.pop_application()`

@AvishaiW
Copy link
Author

AvishaiW commented Jul 8, 2018

any progress?

@vmalloc
Copy link
Collaborator

vmalloc commented Jul 8, 2018

Sorry, I've been a bit swamped lately so didn't get to investigate it. Any help would be greatly appreciated.

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

2 participants