Skip to content

Commit

Permalink
Added entity size loggings and conditional payload logging
Browse files Browse the repository at this point in the history
  • Loading branch information
hr2904 committed Nov 27, 2024
1 parent 297acc0 commit c1ae147
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ public List<AtlasEvaluatePolicyResponse> evaluatePolicies(List<AtlasEvaluatePoli
if (AtlasPerfTracer.isPerfTraceEnabled(PERF_LOG)) {
perf = AtlasPerfTracer.getPerfTracer(PERF_LOG, "EntityREST.evaluatePolicies()");
}

LOG.info("Number of evaluations : " + entities.size());
for (int i = 0; i < entities.size(); i++) {

String action = entities.get(i).getAction();
Expand Down Expand Up @@ -244,6 +244,9 @@ else if (RELATIONSHIP_ADD.name().equals(action) || RELATIONSHIP_REMOVE.name().eq

}
} finally {
if(perf.getElapsedTime() > 1000){
LOG.info("Slow perf response payload : " + entities.toString());
}
AtlasPerfTracer.log(perf);
}

Expand Down

0 comments on commit c1ae147

Please sign in to comment.