Skip to content
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

Add support for old db3 schema used on distros prior to Foxy #1090

Merged
merged 3 commits into from
Sep 20, 2022

Conversation

MichaelOrlov
Copy link
Contributor

Support SqliteStorage::get_metadata() for db3 files recorded on distros prior to the Foxy by checking whether offered_qos_profiles field exist or not in topics table and forming SQL request accordingly.

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>
- Added unit tests for db with old schema
- Added unit test for new `database.is_field_exist()` API

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>
@MichaelOrlov MichaelOrlov self-assigned this Sep 14, 2022
@MichaelOrlov MichaelOrlov marked this pull request as ready for review September 14, 2022 07:22
@MichaelOrlov MichaelOrlov requested a review from a team as a code owner September 14, 2022 07:22
@MichaelOrlov MichaelOrlov requested review from gbiggs, jhdcs and emersonknapp and removed request for a team September 14, 2022 07:22
@MichaelOrlov MichaelOrlov added the bug Something isn't working label Sep 15, 2022
Copy link
Contributor

@jhdcs jhdcs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks really well done! The only thing I'd change is a minor rename to have is_field_exist look more similar to other exists functions. But that's minor enough that I'm not comfortable holding things up for it.

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>
@MichaelOrlov
Copy link
Contributor Author

@jhdcs I renamed is_field_exist(..) to field_exists(..) as you advised. Please see new commit 3eaaf4d

@MichaelOrlov
Copy link
Contributor Author

Gist: https://gist.githubusercontent.com/MichaelOrlov/ab796029b394e54ca6b2fa2a56189374/raw/340d151e32db0a4912eee351dbf7fe86518ca0bb/ros2.repos
BUILD args: --packages-above-and-dependencies rosbag2_storage_default_plugins rosbag2_tests
TEST args: --packages-above rosbag2_storage_default_plugins rosbag2_tests
ROS Distro: rolling
Job: ci_launcher
ci_launcher ran: https://ci.ros2.org/job/ci_launcher/10829

  • Linux Build Status
  • Linux-aarch64 Build Status
  • Windows Build Status

@MichaelOrlov MichaelOrlov merged commit c5761ee into rolling Sep 20, 2022
@delete-merged-branch delete-merged-branch bot deleted the morlov/add_support_for_eloquent_db3_schema branch September 20, 2022 00:23
@MichaelOrlov
Copy link
Contributor Author

https://github.com/Mergifyio backport humble

@mergify
Copy link

mergify bot commented Sep 20, 2022

backport humble

✅ Backports have been created

mergify bot pushed a commit that referenced this pull request Sep 20, 2022
* Support `SqliteStorage::get_metadata()` for files from `eloquent`

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>

* Add unit tests

- Added unit tests for db with old schema
- Added unit test for new `database.is_field_exist()` API

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>

* Rename `is_filed_exist(..)` to `field_exists(..)`

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>
(cherry picked from commit c5761ee)
MichaelOrlov added a commit that referenced this pull request Sep 21, 2022
…1094)

* Support `SqliteStorage::get_metadata()` for files from `eloquent`

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>

* Add unit tests

- Added unit tests for db with old schema
- Added unit test for new `database.is_field_exist()` API

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>

* Rename `is_filed_exist(..)` to `field_exists(..)`

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>
(cherry picked from commit c5761ee)

Co-authored-by: Michael Orlov <michael.orlov@apex.ai>
@MichaelOrlov
Copy link
Contributor Author

https://github.com/Mergifyio backport galactic

@mergify
Copy link

mergify bot commented Sep 29, 2022

backport galactic

✅ Backports have been created

mergify bot pushed a commit that referenced this pull request Sep 29, 2022
* Support `SqliteStorage::get_metadata()` for files from `eloquent`

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>

* Add unit tests

- Added unit tests for db with old schema
- Added unit test for new `database.is_field_exist()` API

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>

* Rename `is_filed_exist(..)` to `field_exists(..)`

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>
(cherry picked from commit c5761ee)
MichaelOrlov added a commit that referenced this pull request Sep 29, 2022
…1105)

* Support `SqliteStorage::get_metadata()` for files from `eloquent`

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>

* Add unit tests

- Added unit tests for db with old schema
- Added unit test for new `database.is_field_exist()` API

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>

* Rename `is_filed_exist(..)` to `field_exists(..)`

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>

Signed-off-by: Michael Orlov <michael.orlov@apex.ai>
(cherry picked from commit c5761ee)

Co-authored-by: Michael Orlov <michael.orlov@apex.ai>
@ros-discourse
Copy link

This pull request has been mentioned on ROS Discourse. There might be relevant details there:

https://discourse.ros.org/t/ros-2-tsc-meeting-minutes-2022-10-13/28213/1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ros2 bag info and play are not able to open db3 bag files recorded on eloquent
3 participants