diff --git a/croud/__main__.py b/croud/__main__.py index a3d4c331..6e71ce84 100644 --- a/croud/__main__.py +++ b/croud/__main__.py @@ -901,16 +901,16 @@ Argument( "--ingestion-type", type=str, choices=[ - "IMPORT_ONLY", - "IMPORT_AND_CDC", - "CDC_ONLY" + "import-only", + "import-and-cdc", + "cdc-only" ], required=True, help="Determines how to ingest the data. " - "IMPORT_ONLY will just ingest the data " - "and finish. CDC_ONLY will continuously " + "import-only will just ingest the data " + "and finish. cdc-only will continuously " "read CDC (Change Data Capture) events. " - "IMPORT_AND_CDC will first import the " + "import-and-cdc will first import the " "data and then start listening for CDC " "events." ), diff --git a/croud/clusters/commands.py b/croud/clusters/commands.py index 50301341..9faeb16e 100644 --- a/croud/clusters/commands.py +++ b/croud/clusters/commands.py @@ -217,7 +217,7 @@ def import_jobs_create_from_dynamodb(args: Namespace) -> None: extra_body["dynamodb"]["endpoint"] = args.endpoint if args.ingestion_type: extra_body["ingestion_type"] = args.ingestion_type - if "CDC" in extra_body.get("ingestion_type", ""): + if "cdc" in extra_body.get("ingestion_type", ""): if args.kinesis_stream_name: extra_body["dynamodb"]["kinesis_stream_name"] = args.kinesis_stream_name else: diff --git a/tests/commands/test_clusters.py b/tests/commands/test_clusters.py index 48332823..511f4776 100644 --- a/tests/commands/test_clusters.py +++ b/tests/commands/test_clusters.py @@ -1620,7 +1620,7 @@ def test_import_job_create_from_dynamodb(mock_request): kinesis_stream_name = "my_kinesis_stream_name" secret_id = gen_uuid() endpoint = "https://my-dynamodb-compatible-endpoint" - ingestion_type = "IMPORT_AND_CDC" + ingestion_type = "import-and-cdc" call_command( "croud", "clusters",