OpenLineage Event Listener¶
The OpenLineage event listener plugin emits query events in the OpenLineage format, enabling integration with lineage tracking systems such as Marquez, Atlan, and DataHub.
The plugin captures:
Query start events (
START)Query completion events (
COMPLETEorFAIL)Input and output dataset information including column-level lineage
Installation¶
The OpenLineage event listener plugin is bundled with Presto and requires no additional installation.
Configuration¶
Create an etc/event-listener.properties file on the coordinator with the
following required properties:
event-listener.name=openlineage-event-listener
openlineage-event-listener.presto.uri=http://presto-coordinator:8080
openlineage-event-listener.transport.type=CONSOLE
Transport Types¶
The plugin supports two transport types for emitting OpenLineage events:
Console Transport
Writes OpenLineage events as JSON to stdout. Useful for debugging and development.
event-listener.name=openlineage-event-listener
openlineage-event-listener.presto.uri=http://presto-coordinator:8080
openlineage-event-listener.transport.type=CONSOLE
HTTP Transport
Sends OpenLineage events to an HTTP endpoint such as the Marquez API.
event-listener.name=openlineage-event-listener
openlineage-event-listener.presto.uri=http://presto-coordinator:8080
openlineage-event-listener.transport.type=HTTP
openlineage-event-listener.transport.url=http://marquez:5000
openlineage-event-listener.transport.endpoint=/api/v1/lineage
Configuration Properties¶
Property |
Required |
Default |
Description |
|---|---|---|---|
|
Yes |
URI of the Presto server. Used for namespace rendering in OpenLineage events. |
|
|
No |
|
Transport type for emitting events. Supported values: |
|
No |
Override the default namespace for OpenLineage jobs. Defaults to the Presto URI with |
|
|
No |
|
Format string for the OpenLineage job name. Supported placeholders: |
|
No |
|
Comma-separated list of query types that generate OpenLineage events. Other query types are filtered out on completion. |
|
No |
Comma-separated list of facets to exclude from events. Supported values: |
HTTP Transport Properties¶
These properties apply when openlineage-event-listener.transport.type is set to HTTP.
Property |
Required |
Default |
Description |
|---|---|---|---|
|
Yes |
URL of the OpenLineage API server. |
|
|
No |
Custom API path for receiving events. |
|
|
No |
API key for authentication. Sent as a |
|
|
No |
|
HTTP request timeout. Accepts duration strings. For example: |
|
No |
Custom HTTP headers as comma-separated |
|
|
No |
Custom URL query parameters as comma-separated |
|
|
No |
|
HTTP body compression. Supported values: |
Event Details¶
The plugin emits the following OpenLineage facets:
Run Facets
processing_engine- Presto server version informationpresto_metadata- Query ID, transaction ID, and query planpresto_query_context- User, server address, environment, source, client infopresto_query_statistics- Detailed query execution statistics (on completion only)nominalTime- Query start and end times (on completion only)errorMessage- Failure message (on failure only)
Job Facets
jobType-BATCH/PRESTO/QUERYsql- The SQL query text with dialectpresto
Dataset Facets
schema- Column names and types for input and output datasetsdataSource- Catalog and schema informationcolumnLineage- Column-level lineage mapping from input to output columns