Skip to content

Commit

Permalink
Skip diagnostic logs publish for myaccount app
Browse files Browse the repository at this point in the history
  • Loading branch information
sadilchamishka committed May 13, 2024
1 parent d1f68fd commit 2fbf164
Showing 1 changed file with 8 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -146,10 +146,14 @@ public static void triggerDiagnosticLogEvent(String componentId, Map<String, Obj
resultMessage, actionId, componentId, input, configurations);
/* As the console application is used to manage the identity server, the diagnostic logs are not required
to be emitted. */
if (diagnosticLog.getInput() != null &&
("CONSOLE".equals(diagnosticLog.getInput().get(LogConstants.InputKeys.CLIENT_ID)) ||
"CONSOLE".equals(diagnosticLog.getInput().get("client_id")))) {
return;
if (diagnosticLog.getInput() != null) {
String clientID = (String) diagnosticLog.getInput().get(LogConstants.InputKeys.CLIENT_ID);
if (clientID == null) {
clientID = (String) diagnosticLog.getInput().get("client_id");
}
if ("CONSOLE".equals(clientID) || "MY_ACCOUNT".equals(clientID)) {
return;
}
}
IdentityEventService eventMgtService =
CentralLogMgtServiceComponentHolder.getInstance().getIdentityEventService();
Expand Down

0 comments on commit 2fbf164

Please sign in to comment.