-
Notifications
You must be signed in to change notification settings - Fork 765
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
[21612] Data sharing performance improvement #5209
Open
paxifaer
wants to merge
35
commits into
eProsima:master
Choose a base branch
from
paxifaer:data_sharing
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
35 commits
Select commit
Hold shift + click to select a range
00df4b9
Hotfix: Secure simple participants with `initialpeers` over `TCP` mat…
Mario-DL e02a52d
Fix the problem that gcc-9 cannot compile
paxifaer 9c8bb04
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.cpp
paxifaer eeb1381
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.cpp
paxifaer d12a810
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.cpp
paxifaer d2eacdb
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.hpp
paxifaer b446cd4
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.cpp
paxifaer 242456a
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.hpp
paxifaer 3f179ac
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.hpp
paxifaer 291fa89
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.hpp
paxifaer 3dfdb20
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.hpp
paxifaer 75b7480
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.cpp
paxifaer 549d97a
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.cpp
paxifaer 91ed3a6
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.hpp
paxifaer 1e6d9aa
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.cpp
paxifaer 2ec01b6
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.cpp
paxifaer ca455e2
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.hpp
paxifaer f9153ef
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.hpp
paxifaer 8122e05
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.hpp
paxifaer 64e4230
Update src/cpp/fastdds/xtypes/dynamic_types/AnnotationDescriptorImpl.hpp
paxifaer 7a19061
Revert missing noexcept suggested by JesusPoderoso.
paxifaer 30328eb
Set string arguments as const references (#5179)
JesusPoderoso 28a3371
Improve resilience against clock adjustments (#5018)
ma30002000 2b80fa7
TypeLookupService: also register the minimal created from the receive…
richiware 8063e60
Use eProsima-CI action to install Qt (#5186)
JesusPoderoso a2098d6
Compared with the traditional separate locking method, Acquire-Releas…
paxifaer b62bc1b
Merge branch 'master' into data_sharing
paxifaer 6de8155
Merge branch 'eProsima:master' into data_sharing
paxifaer 34ba4c6
Compared with the traditional separate locking method, Acquire-Releas…
paxifaer 9eaae61
Fix uncrustify
paxifaer 860d8dd
Merge branch 'data_sharing' of https://github.com/paxifaer/Fast-DDS i…
paxifaer 1e95b84
fix uncrustify 2
paxifaer 0bc9d2e
fix duplicate code
paxifaer 4ce305e
For thread safety, add locks. Mark the usage restrictions of zero cop…
paxifaer fa752fa
Mark the usage restrictions of zero copy in test.
paxifaer File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am a bit worried about the validity of this iterator changing during the next few lines (until we get to
std::shared_ptr<ReaderPool> pool = it->pool;
)There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If there was a problem with effectiveness here, it would have been exposed before. I'll keep an eye on this later, and if there's a problem I'll fix it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The places where
writer_pools_
is modified are protected by takingmutex_
.Your PR is removing the guard on the
mutex_
during the traversal ofwriter_pools_
here.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't worry about this, I use the lock_free mechanism here. It is thread safe.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
writer_pools_
is astd::vector<WriterInfo>
which is not thread-safe. IfDataSharingListener::remove_datasharing_writer()
is called on one thread while another thread is insideDataSharingListener::process_new_data()
, an invalidated iterator on the vector could be dereferencedThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you are right. But I tested it many times under multi-thread conditions and there was no problem.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I re-locked