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

Do not resolve names before ZMQ connect calls. #86

Merged
merged 3 commits into from
Jun 8, 2023

Conversation

eflumerf
Copy link
Member

@eflumerf eflumerf commented May 3, 2023

Have publishers bind to * (all addresses)

@eflumerf
Copy link
Member Author

eflumerf commented May 3, 2023

@plasorak
Copy link
Contributor

Ok so looking at the connectivity service I see entries like:

timesync_fake_hsi: Connection(uri='tcp://np04-srv-004:37685', data_type='TimeSync', connection_type=1, time=datetime.datetime(2023, 5, 30, 11, 23, 51, 655020))
fragments_to_dataflow0: Connection(uri='tcp://np04-srv-004:33837', data_type='Fragment', connection_type=0, time=datetime.datetime(2023, 5, 30, 11, 23, 51, 652151))

which is what I expect.

Looking at the logs (grep -B 2 "Connection String" *txt), I see:
Push: ZmqSenderImpl.hpp:81] Connection String is tcp://np04-srv-004:33837 -> sends to 004.
Pull: ZmqReceiver.cpp:88] Connection String is tcp://10.73.136.77:* -> receives (this IP is localhost?)
Publish: ZmqSenderImpl.hpp:81] Connection String is tcp://*:* -> sends to whoever wants it, hence the * in the hostname?
Subscribe: ZmqSubscriber.cpp:73] Connecting to publisher at tcp://np04-srv-004:37685 (with grep "Subscriber" *txt). -> subscribes to the publisher's address.

Also, can you remind me what it means for a port number to be *? Is this because the connectivity service is in charge of providing the port number?

@eflumerf
Copy link
Member Author

For bind endpoints (Receive, Publish), a * in the port number means "use any available port". daqconf will only put * in the port number when we're not in Kubernetes mode. A * in the hostname means "bind to all interfaces".

@plasorak
Copy link
Contributor

Also, this line https://github.com/DUNE-DAQ/ipm/blob/eflumerf/DontResolveConnect/plugins/ZmqSubscriber.cpp#LL73C1-L73C1 seems to be appearing in the log way too much (for every receive?). I don't think we can have that.

@eflumerf
Copy link
Member Author

Moved that log message (and another one which was logging at the info level) to debug

…de from ZmqReceiver to ZmqPublisher. Have ZmqSubscriber keep track of connected URIs, don't reconnect to already-connected ones.
Copy link
Contributor

@plasorak plasorak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works on APA1 and 2

plugins/ZmqSenderImpl.hpp Outdated Show resolved Hide resolved
plugins/ZmqSenderImpl.hpp Outdated Show resolved Hide resolved
@plasorak plasorak merged commit 7f06624 into develop Jun 8, 2023
@plasorak plasorak deleted the eflumerf/DontResolveConnect branch June 8, 2023 11:13
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

Successfully merging this pull request may close these issues.

2 participants