Skip to content
Merged
Changes from all commits
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
28 changes: 28 additions & 0 deletions content/en/data_observability/jobs_monitoring/glue.md
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,34 @@
Enable the [Glue Integration][4] tile for Glue metrics collection.
Metrics should be available under the {{< ui >}}Glue{{< /ui >}} job tab in **Data Observability: Jobs Monitoring**.

## (Optional) Enable dataset lineage

Check warning on line 111 in content/en/data_observability/jobs_monitoring/glue.md

View workflow job for this annotation

GitHub Actions / vale

Datadog.headings

'(Optional) Enable dataset lineage' should use sentence-style capitalization.

Glue jobs that run with the Spark engine can emit OpenLineage events directly to Datadog. This provides dataset-level lineage, showing which datasets your job reads and writes.

**Note**: AWS Glue includes the Spark OpenLineage connector in its default class path. To use a more recent version, add the connector JAR manually through the `--extra-jars` Glue job parameter and set `--user-jars-first=true` to override the bundled version. For example: `--extra-jars s3://<YOUR_BUCKET>/openlineage-spark-<VERSION>.jar` and `--user-jars-first true`.

### Configure the SparkSession

Check warning on line 117 in content/en/data_observability/jobs_monitoring/glue.md

View workflow job for this annotation

GitHub Actions / vale

Datadog.headings

'Configure the SparkSession' should use sentence-style capitalization.

In your Glue job script, configure the `SparkSession` with the following settings:

```python
spark = SparkSession.builder \
.config("spark.extraListeners", "io.openlineage.spark.agent.OpenLineageSparkListener") \
.config("spark.openlineage.transport.type", "http") \
.config("spark.openlineage.transport.url", "<DD_DATA_OBSERVABILITY_INTAKE>") \
.config("spark.openlineage.transport.auth.type", "api_key") \
.config("spark.openlineage.transport.auth.apiKey", "<DATADOG_API_KEY>") \
.config("spark.redaction.regex", "(?i)secret|password|token|access[.]key|apikey") \
.config("spark.openlineage.capturedProperties", "spark.glue.JOB_RUN_ID") \
.getOrCreate()
```

Replace `<DD_DATA_OBSERVABILITY_INTAKE>` with `https://data-obs-intake.`{{< region-param key="dd_site" code="true" >}}. Replace `<DATADOG_API_KEY>` with your Datadog API key. `spark.glue.JOB_RUN_ID` is the Spark configuration property automatically set by AWS Glue with the current job run ID — use it verbatim.

Check warning on line 133 in content/en/data_observability/jobs_monitoring/glue.md

View workflow job for this annotation

GitHub Actions / vale

Datadog.dashes

Don't put a space before or after a dash.

### Validate

After enabling OpenLineage, open a job run in [Data Observability: Jobs Monitoring][6]. In the flame graph, additional spans such as `spark.application` or `spark.sql_job` should appear. The payloads of these spans should be helpful when debugging dataset extraction.

## Next steps

The crawler runs every few minutes.
Expand Down
Loading