Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ public class ExportCommandOptions {
protected Integer maxThreads;

/**
* @deprecated As of release 3.6.2. Will be removed in release 4.0.0. Use --max-threads instead
* @deprecated As of release 3.17.0. Will be removed in release 4.0.0. Use --max-threads instead
*/
@Deprecated
@CommandLine.Option(
Expand All @@ -118,7 +118,10 @@ public class ExportCommandOptions {
// TODO: test that -si false, works
protected boolean scanStartInclusive;

// Deprecated option - kept for backward compatibility
/**
* @deprecated As of release 3.17.0. Will be removed in release 4.0.0. Use --start-inclusive
* instead (inverted logic).
*/
@CommandLine.Option(
names = {DEPRECATED_START_EXCLUSIVE_OPTION},
description = "Deprecated: Use --start-inclusive instead (inverted logic)",
Expand All @@ -139,7 +142,10 @@ public class ExportCommandOptions {
defaultValue = "true")
protected boolean scanEndInclusive;

// Deprecated option - kept for backward compatibility
/**
* @deprecated As of release 3.17.0. Will be removed in release 4.0.0. Use --end-inclusive instead
* (inverted logic).
*/
@CommandLine.Option(
names = {DEPRECATED_END_EXCLUSIVE_OPTION},
description = "Deprecated: Use --end-inclusive instead (inverted logic)",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public class ImportCommandOptions {
protected Integer maxThreads;

/**
* @deprecated As of release 3.6.2. Will be removed in release 4.0.0. Use --max-threads instead
* @deprecated As of release 3.17.0. Will be removed in release 4.0.0. Use --max-threads instead
*/
@Deprecated
@CommandLine.Option(
Expand Down Expand Up @@ -75,7 +75,7 @@ public class ImportCommandOptions {
protected String controlFilePath;

/**
* @deprecated As of release 3.6.2. Will be removed in release 4.0.0. Use --enable-log-success
* @deprecated As of release 3.17.0. Will be removed in release 4.0.0. Use --enable-log-success
* instead
*/
@Deprecated
Expand Down Expand Up @@ -125,8 +125,8 @@ public class ImportCommandOptions {

@CommandLine.Option(
names = {"--log-raw-record", "-lr"},
description = "Include the original source record in the log file output (default: false)",
defaultValue = "false")
description = "Include the original source record in the log file output (default: true)",
defaultValue = "true")
Comment on lines +128 to +129
Copy link
Contributor

Choose a reason for hiding this comment

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

high

I have a couple of points regarding this change:

  • Inconsistency with Core Options: While changing the default value here to true aligns with the PR's goal, it creates an inconsistency with the core ImportOptions class, where logRawRecord still defaults to false. This means the default behavior will differ depending on whether the tool is used via the CLI or programmatically. For consistency, please consider also updating the default in data-loader/core/src/main/java/com/scalar/db/dataloader/core/dataimport/ImportOptions.java.

  • Missing Test Coverage: Changing a default value is a behavioral change that should be covered by tests. ImportCommandTest.java appears to be missing tests for the --log-raw-record option. Please add a test case to verify that logRawRecord defaults to true when the option is not specified in the command arguments.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I have updated changes based on suggestion in 58c5051

protected boolean logRawRecord;

@CommandLine.Option(
Expand Down