Support multiple connections in the client mode.#2320
Conversation
Signed-off-by: ChenYing Kuo <evshary@gmail.com>
|
PR missing one of the required labels: {'dependencies', 'breaking-change', 'enhancement', 'api-sync', 'bug', 'internal', 'ci', 'new feature', 'documentation'} |
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #2320 +/- ##
==========================================
- Coverage 74.01% 74.01% -0.01%
==========================================
Files 400 400
Lines 60846 60991 +145
==========================================
+ Hits 45034 45140 +106
- Misses 15812 15851 +39 ☔ View full report in Codecov by Sentry. |
Signed-off-by: ChenYing Kuo <evshary@gmail.com>
Signed-off-by: ChenYing Kuo <evshary@gmail.com>
Signed-off-by: ChenYing Kuo <evshary@gmail.com>
Signed-off-by: ChenYing Kuo <evshary@gmail.com>
Signed-off-by: ChenYing Kuo <evshary@gmail.com>
| } | ||
|
|
||
| if !args.connect.is_empty() { | ||
| // Able to parse multiple endpoints, e.g. "tcp/127.0.0.1:7447?rel=0,tcp/127.0.0.1:7447?rel=1" |
There was a problem hiding this comment.
This is a change in behavior.
Coma separated values were already accepted here and were the equivalent of passing multiple -e arguments.
Let's decide if:
- we assume this behavior change and add this in a minor release
- find another separator for this case
There was a problem hiding this comment.
I personally prefer the first one, while the second one will make usage complicated.
However, it's still fine with me if we decide on the second one.
|
I also realize that we had plans to create locator groups for peers, where peer connect to a single endpoint of each group. We need to decide if this is still something we consider and how to articulate that with the multilink thing here. |
|
Another point, I don't see any changes in |
Signed-off-by: ChenYing Kuo <evshary@gmail.com>
I thought it would make the description too complicated, so I just skipped that. |
Signed-off-by: ChenYing Kuo <evshary@gmail.com>
7f4dc41 to
43854bc
Compare
Signed-off-by: ChenYing Kuo <evshary@gmail.com>
Signed-off-by: ChenYing Kuo <evshary@gmail.com>
Signed-off-by: ChenYing Kuo <evshary@gmail.com>
a70b060 to
589d911
Compare
Signed-off-by: ChenYing Kuo <evshary@gmail.com>
4de772f to
1b03d5a
Compare
Signed-off-by: ChenYing Kuo <evshary@gmail.com>
1b03d5a to
2405e55
Compare
|
@OlivierHecart I also added some tests for the feature. |
Signed-off-by: ChenYing Kuo <evshary@gmail.com>
Signed-off-by: ChenYing Kuo <evshary@gmail.com>
Solve #2142
We added the
EndPointsto accept a singleEndPointorEndPointvector.To test the multiple connections:
RUST_LOG=zenoh_transport::unicast::establishment=debug cargo run --bin zenohd -- --cfg=transport/unicast/max_links:2 RUST_LOG=zenoh_transport::unicast::establishment=debug cargo run --example z_sub -- --cfg=transport/unicast/max_links:2 --cfg="connect/endpoints:[{strategy:'allOf',locators:['tcp/127.0.0.1:7447?rel=0','tcp/127.0.0.1:7447?rel=1']}]" -m clientNote that only 'allOf' is implemented in the PR. We leave 'oneOf' for the future.
🏷️ Label-Based Checklist
Based on the labels applied to this PR, please complete these additional requirements:
Labels:
bug🐛 Bug Fix Requirements
Since this PR is labeled as a bug fix, please ensure:
Why this matters: Bugs without tests often reoccur.
Instructions:
- [ ]to- [x])This checklist updates automatically when labels change, but preserves your checked boxes.