Skip to content

Commit

Permalink
fix(ingest/nifi): remove duplicate upstream jobs
Browse files Browse the repository at this point in the history
  • Loading branch information
mayurinehate committed Jul 4, 2024
1 parent 8d5f0f3 commit 3892966
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions metadata-ingestion/src/datahub/ingestion/source/nifi.py
Original file line number Diff line number Diff line change
Expand Up @@ -826,7 +826,7 @@ def construct_workunits(self) -> Iterable[MetadataWorkUnit]: # noqa: C901
outgoing = list(
filter(lambda x: x[0] == component.id, self.nifi_flow.connections)
)
inputJobs = []
inputJobs = set()
jobProperties = None

if component.nifi_type is NifiType.PROCESSOR:
Expand Down Expand Up @@ -877,7 +877,7 @@ def construct_workunits(self) -> Iterable[MetadataWorkUnit]: # noqa: C901
dataset_urn,
)
else:
inputJobs.append(
inputJobs.add(
builder.make_data_job_urn_with_flow(flow_urn, incoming_from)
)

Expand Down Expand Up @@ -957,7 +957,7 @@ def construct_workunits(self) -> Iterable[MetadataWorkUnit]: # noqa: C901
job_properties=jobProperties,
inlets=list(component.inlets.keys()),
outlets=list(component.outlets.keys()),
inputJobs=inputJobs,
inputJobs=list(inputJobs),
status=component.status,
)

Expand Down

0 comments on commit 3892966

Please sign in to comment.