-
Notifications
You must be signed in to change notification settings - Fork 463
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
RTPS discovery slow #2787
Comments
Attached log files. |
What's the value of ResendPeriod in the rtps_discovery section? Try setting it to something small? |
I am not behind my PC right now but this is the DevGuide messenger example with all defaults, only tcp as data transport |
Yeah, I think the default is 30 seconds or something large like that, and the default "response" time is about 3 seconds, which sounds like it's what you're seeing. If you set it somewhere in the 1-10 seconds range I'm guessing it would feel more reasonable. |
I will test a little bit with these settings, but when I have a subscriber running and I start the publisher, I would expect that at the moment the publisher is created the RTPS discovery will run, waiting on a resend period doesn't feel optimal, shouldn't the discovery process be triggered at the moment the publisher is created? |
Debugged this a little bit further, it looks on Windows the order in which things are triggered is slightly different than on Linux. I start the subscriber on the console and the publisher in the debugger. At the moment now the datawriter is created in the publisher there is no associated participant at https://github.com/objectcomputing/OpenDDS/blob/045cde5cb9e4a01d8291917ba4a1527feb071e88/dds/DCPS/RTPS/Sedp.cpp#L5126 so the Sedp is not done at that point. Now, a little bit later the remote participant is discovered and at https://github.com/objectcomputing/OpenDDS/blob/045cde5cb9e4a01d8291917ba4a1527feb071e88/dds/DCPS/RTPS/Spdp.cpp#L701 there is a comment that our announcement is send now so that they have to wait, but this is only a shorten, with the default settings of a ResendPeriod=30 and QuickResendRatio=0.1 this still means that there is a 3 second delay on the first announcement. On a new participant, shouldn't we directly send out our announcement, the user can tune the settings to a shorter period, but that impacts also the resends, can image that a very short resend is also bad in some scenarios. |
Directly send sedp when we have a new discovered participant, the original shorten resulted in a 3 second delay with the default settings, see OpenDDS#2787
Created #2798 as first step, this improves the startup delay already a lot, looks it still can be more faster, but let us first discuss this solution before spending even more time on this |
I also see the same slow discovery on Linux, in our fedora opendds build the DevGuideExamples/DCPS/Messenger/run_test.pl takes 0 secons with InfoRepo discovery and 7 seconds with RTPS |
It's still in similar state, it seems? |
Yes, no changes made yet, this needs more time to analyze and test solutions, feel free to open a PR with a more intelligent solution or consider sponsoring someone to work more on this. |
Okay.. |
When running the `DevGuidExamples/DCPS/Messenger' with RTPS on Windows it takes mostly 4 to 5 seconds to run this example, on Linux it finished almost directly. Looks RTPS discovery is slow on Windows, looking at the logs it takes around 3 seconds to let the publisher/subscriber find each other.
The text was updated successfully, but these errors were encountered: