From c1890bd78356fa5d3c9550311e3a9ea407d1f2ae Mon Sep 17 00:00:00 2001 From: Jonny Dixon <45681293+acrylJonny@users.noreply.github.com> Date: Wed, 11 Dec 2024 12:54:47 +0000 Subject: [PATCH] fix(ingest/abs): detect jsonl schema (#11775) --- metadata-ingestion/src/datahub/ingestion/source/abs/source.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/metadata-ingestion/src/datahub/ingestion/source/abs/source.py b/metadata-ingestion/src/datahub/ingestion/source/abs/source.py index 66f268799b2f1f..ad2bc36cf558b5 100644 --- a/metadata-ingestion/src/datahub/ingestion/source/abs/source.py +++ b/metadata-ingestion/src/datahub/ingestion/source/abs/source.py @@ -201,6 +201,10 @@ def get_fields(self, table_data: TableData, path_spec: PathSpec) -> List: ).infer_schema(file) elif extension == ".json": fields = json.JsonInferrer().infer_schema(file) + elif extension == ".jsonl": + fields = json.JsonInferrer( + max_rows=self.source_config.max_rows, format="jsonl" + ).infer_schema(file) elif extension == ".avro": fields = avro.AvroInferrer().infer_schema(file) else: