-
Notifications
You must be signed in to change notification settings - Fork 40
Deprecate include-metadata option for data loader export
#3159
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
Deprecate include-metadata option for data loader export
#3159
Conversation
… config # Conflicts: # data-loader/cli/src/main/java/com/scalar/db/dataloader/cli/command/dataexport/ExportCommand.java # data-loader/core/src/test/java/com/scalar/db/dataloader/core/dataexport/CsvExportManagerTest.java
Summary of ChangesHello @ypeckstadt, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request refactors the Data Loader export mechanism by deprecating the Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
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.
Code Review
This pull request effectively deprecates the --include-metadata command-line option in favor of a centralized configuration property. The changes are well-structured, removing the now-obsolete logic from the core data loader and producer tasks, and replacing it with a clear warning for users who still use the deprecated flag. The accompanying unit tests are thorough and validate the new warning mechanism. My review includes a few suggestions for minor refactoring to improve code clarity and maintainability, as well as recommendations to clean up some redundant tests that resulted from this change.
...-loader/cli/src/main/java/com/scalar/db/dataloader/cli/command/dataexport/ExportCommand.java
Outdated
Show resolved
Hide resolved
.../cli/src/main/java/com/scalar/db/dataloader/cli/command/dataexport/ExportCommandOptions.java
Outdated
Show resolved
Hide resolved
...der/cli/src/test/java/com/scalar/db/dataloader/cli/command/dataexport/ExportCommandTest.java
Outdated
Show resolved
Hide resolved
data-loader/core/src/main/java/com/scalar/db/dataloader/core/dataexport/CsvExportManager.java
Outdated
Show resolved
Hide resolved
komamitsu
left a comment
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.
LGTM! 👍
brfrn169
left a comment
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.
LGTM! Thank you!
Torch3333
left a comment
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.
LGTM, thank you!
thongdk8
left a comment
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.
LGTM! Thank you!
feeblefakie
left a comment
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.
LGTM! Thank you!
96ba8f0
into
feat/data-loader/import-replace-storage
Description
This PR deprecates the include-metadata argument in the Data Loader export command. Previously, this flag controlled whether before_ metadata fields were emitted in the export output. This behavior is no longer appropriate because metadata inclusion should be determined solely by the
scalar.db.consensus_commit.include_metadata.enabledconfiguration.Instead of manually toggling metadata output at the CLI level, the Data Loader should simply export the data exactly as returned by the underlying scan operation. This ensures consistent behavior with how ScalarDB is configured and avoids divergent or confusing export logic.
I kept the argument as mentioned in the code comments, but of course, it is also possible to just remove it altogether.
Related issues and/or PRs
This PR is currently targeting the
feat/data-loader/import-replace-storagebranch, as many PRs are open that this one is built on. I will update this PR to target master branch when the others are reviewed.Changes made
include-metadataargumentChecklist
Additional notes (optional)
NA
Release notes
Deprecated
include-metadataoption for Data Loader export