Why does rosbag_storage add "topic" to the connection header?

asked 2017-07-20 14:41:54 -0600

jtbandes gravatar image

updated 2017-07-20 14:46:41 -0600

rosbag_storage makes a copy of the connection header and adds the "topic" to it: https://github.com/ros/ros_comm/blob/...

This was apparently added to mitigate an issue introduced by https://github.com/ros/ros_comm/commi...

However, as far as I can tell the topic should already be in the header (and experimentally, when I subscribe with a MessageEvent callback, event.getConnectionHeader()["topic"] does have the topic name): https://github.com/ros/ros_comm/blame...

Am I missing something? Why was it necessary to add the topic separately?

Unfortunately, the old relevant trac issues #3727 (motivation for this change) / #3755 (issue arising as a result of that change) are gone:
http://lists.ros.org/pipermail/ros-us...
http://lists.ros.org/pipermail/ros-us...

edit retag flag offensive close merge delete

Comments

You might file a ticket on the repo in this situation.

allenh1 gravatar imageallenh1 ( 2017-07-20 16:50:25 -0600 )edit

@allenh1 Is a ticket appropriate for just a question? This isn't necessarily a bug, I just don't understand why it is written this way...

jtbandes gravatar imagejtbandes ( 2017-07-20 17:52:14 -0600 )edit

If you have a better solution, you should absolutely file a PR, and if it's just a question, you might just ask and then flag it as "question" in a tag. You might not get an answer immediately, but eventually the maintainer will get back to you.

allenh1 gravatar imageallenh1 ( 2017-07-20 18:11:21 -0600 )edit