Skip to content

Commit

Permalink
Merge pull request #2416 from atlanhq/nb/hasLineage
Browse files Browse the repository at this point in the history
Logging
  • Loading branch information
nikhilbonte21 authored Oct 23, 2023
2 parents d6d6714 + a7710b4 commit dee70fe
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2478,10 +2478,14 @@ public void repairHasLineage(AtlasHasLineageRequests requests) throws AtlasBaseE
private void repairHasLineageForAsset(AtlasHasLineageRequest request) {
//only supports repairing scenario mentioned here - https://atlanhq.atlassian.net/browse/DG-128?focusedCommentId=20652

AtlasPerfMetrics.MetricRecorder metricRecorder = RequestContext.get().startMetricRecord("repairHasLineageForAssetGetById");
AtlasVertex assetVertex = AtlasGraphUtilsV2.findByGuid(this.graph, request.getAssetGuid());
RequestContext.get().endMetricRecord(metricRecorder);

if (getEntityHasLineage(assetVertex)) {
metricRecorder = RequestContext.get().startMetricRecord("repairHasLineageForAssetGetRelations");
Iterator<AtlasEdge> lineageEdges = assetVertex.getEdges(AtlasEdgeDirection.BOTH, PROCESS_EDGE_LABELS).iterator();
RequestContext.get().endMetricRecord(metricRecorder);
boolean foundActiveRel = false;

while (lineageEdges.hasNext()) {
Expand Down

0 comments on commit dee70fe

Please sign in to comment.