feat(ingest/dynamodb): add S3 export lineage and Glue DynamoDB job URNs - #19381
feat(ingest/dynamodb): add S3 export lineage and Glue DynamoDB job URNs#19381acrylJonny wants to merge 7 commits into
Conversation
Discover existing DynamoDB Export to S3 destinations for COPY lineage, and resolve Glue job DynamoDB DataSource/DataSink nodes so ETL to catalog/Iceberg joins. Co-authored-by: Cursor <cursoragent@cursor.com>
❌ 1 Tests Failed:
View the top 1 failed test(s) by shortest run time
To view more test analytics, go to the Test Analytics Dashboard |
Identity-map inferred DynamoDB field paths onto the S3 export dataset when include_s3_export_lineage is on, and commit the regenerated connector registry so CI stops failing on the new LINEAGE capabilities. Co-authored-by: Cursor <cursoragent@cursor.com>
Connector Tests ResultsAll connector tests passed for commit To skip connector tests, add the Autogenerated by the connector-tests CI pipeline. |
PR SummaryOverview The DynamoDB connector can set Glue now resolves Reviewed by Cursor Bugbot for commit a7e013b. Bugbot is set up for automated code reviews on this repo. Configure here. |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 75bfd5d. Configure here.
There was a problem hiding this comment.
1 issue found across 9 files
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="metadata-ingestion/tests/unit/glue/test_glue_source.py">
<violation number="1" location="metadata-ingestion/tests/unit/glue/test_glue_source.py:3003">
P2: The expected URN in this assertion bakes the account id into the dataset name ("123456789012.us-east-1.customers"), but _process_dynamodb_node passes it as a separate platform_instance argument (account_id) to make_dataset_urn_with_platform_instance with name="us-east-1.customers". That serializes the account id as its own tuple field, so the emitted URN is urn:li:dataset:(urn:li:dataPlatform:dynamodb,us-east-1.customers,123456789012,PROD). Update the assertion to the 4-field form (or fix the source if the intended convention really is to prepend the account), or the test fails against the current implementation.</violation>
</file>
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
ETL connector nodes often omit tableArn, so fall back from catalog_id to STS GetCallerIdentity so Glue job lineage joins DynamoDB tables. Co-authored-by: Cursor <cursoragent@cursor.com>
|
Linked to ING-3362. |
There was a problem hiding this comment.
All reported issues were addressed across 2 files (changes from recent commits).
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
… parsing Default column lineage off for native DynamoDB JSON/Ion exports, end-anchor table ARN matching, and strengthen unit coverage around failed exports. Co-authored-by: Cursor <cursoragent@cursor.com>
There was a problem hiding this comment.
1 issue found across 5 files (changes from recent commits).
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="metadata-ingestion/src/datahub/ingestion/source/dynamodb/dynamodb.py">
<violation number="1" location="metadata-ingestion/src/datahub/ingestion/source/dynamodb/dynamodb.py:150">
P2: Custom agent: **Enforce Pragmatic Test Coverage**
When `include_s3_export_column_lineage` is omitted, the new `default=False` changes emitted lineage, but no successful export test verifies that default. Add a test that omits the option and asserts table-level COPY lineage without fine-grained lineage.</violation>
</file>
Tip: Review your code locally with the cubic CLI to iterate faster.
Re-trigger cubic
| ), | ||
| ) | ||
| include_s3_export_column_lineage: bool = Field( | ||
| default=False, |
There was a problem hiding this comment.
P2: Custom agent: Enforce Pragmatic Test Coverage
When include_s3_export_column_lineage is omitted, the new default=False changes emitted lineage, but no successful export test verifies that default. Add a test that omits the option and asserts table-level COPY lineage without fine-grained lineage.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At metadata-ingestion/src/datahub/ingestion/source/dynamodb/dynamodb.py, line 150:
<comment>When `include_s3_export_column_lineage` is omitted, the new `default=False` changes emitted lineage, but no successful export test verifies that default. Add a test that omits the option and asserts table-level COPY lineage without fine-grained lineage.</comment>
<file context>
@@ -147,11 +147,12 @@ class DynamoDBConfig(
)
include_s3_export_column_lineage: bool = Field(
- default=True,
+ default=False,
description=(
"When `include_s3_export_lineage` is enabled, also emit column-level COPY lineage "
</file context>
There was a problem hiding this comment.
Added test_column_lineage_off_by_default: omits include_s3_export_column_lineage, asserts the default is False and that emit produces a table-level COPY upstream with no fineGrainedLineages.
Route the DynamoDB ETL account-id resolution through a new get_sts_client() helper so the STS call honors the recipe's proxy, retry, and advanced client settings instead of a bare boto3 client. Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
…mn lineage Add a test for the DescribeExport failure path (warning emitted, no lineage edge/location, emit still runs) and one asserting the omitted include_s3_export_column_lineage default emits table-level COPY only. Co-authored-by: Cursor <cursoragent@cursor.com>

Summary
include_s3_export_lineageon the DynamoDB source to discover existing Export to S3 jobs (ListExports/DescribeExport) and emit COPY lineage tos3://bucket/prefixwithout starting exports.connection_type: dynamodbjob DAG nodes to DynamoDB dataset URNs so ETL jobs into Glue catalog / Iceberg / Parquet join correctly.target_platform_configs.dynamodbalignment.Fixes ING-3362
Test plan