-
Notifications
You must be signed in to change notification settings - Fork 117
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
Example for using Zero Copy with Galactic #596
Comments
@k-gupta thanks for the issue. you could take a look at #579, especially this comment |
Hey @fujitatomoya Thanks for looking into this. I had tried the suggestion from the issue you mentioned but I am seeing an error when I run it. I am just running the demo node - This is the error
The command I ran, this is running on Galactic. Also I am using the docker container not sure if that matters -
My profile looks like this
|
Hi @k-gupta The error you are seeing is to be expected the way you are configuring things, let me explain. By default, Fast DDS sets the history memory policy to However, as explained here, when setting the environment variable |
probably you can try the following xml setting. (this works with rolling if the data is PoD.) <?xml version="1.0" encoding="UTF-8" ?>
<profiles xmlns="http://www.eprosima.com/XMLSchemas/fastRTPS_Profiles">
<!-- Default publisher profile -->
<data_writer profile_name="default publisher profile" is_default_profile="true">
<qos>
<publishMode>
<kind>SYNCHRONOUS</kind>
</publishMode>
<data_sharing>
<kind>AUTOMATIC</kind>
</data_sharing>
</qos>
<historyMemoryPolicy>DYNAMIC</historyMemoryPolicy>
</data_writer>
<data_reader profile_name="default subscription profile" is_default_profile="true">
<qos>
<data_sharing>
<kind>AUTOMATIC</kind>
</data_sharing>
</qos>
<historyMemoryPolicy>DYNAMIC</historyMemoryPolicy>
</data_reader>
</profiles>
nitpick, this means serialization since the problem is observed on publisher gdb stacktrace
|
@fujitatomoya thanks for your hints. this configuration with ASYNCHRONOUS publisherMode also enables the datasharing I am testing this in https://github.com/ZhenshengLee/performance_test |
Thanks a lot for the info. We were able to fix this by setting the historyMemoryPolicy to PREALLOCATED_WITH_REALLOC. But we will also try to the setting you gave. |
@k-gupta thanks. please close the issue once everything is confirmed and resolved. |
Since Galactic is already E.O.L https://docs.ros.org/en/rolling/Releases.html, i will go ahead to close this issue. |
We are trying to find an example on how to use zero copy with Fast RTPS. Is there a simple example somewhere that we can refer? We tried to use Galactic to do it but saw this error.
Currently used middleware can't loan messages. Local allocator will be used.
The text was updated successfully, but these errors were encountered: