Skip to content

Commit

Permalink
fixes #142 get callerId from the header and put it into the auditInfo…
Browse files Browse the repository at this point in the history
… for metrics (#143)
  • Loading branch information
stevehu authored Oct 18, 2020
1 parent 7d372dd commit 8d7ef09
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,8 @@ public void handleRequest(final HttpServerExchange exchange) throws Exception {
auditInfo.put(Constants.CLIENT_ID_STRING, claims.getStringClaimValue(Constants.CLIENT_ID_STRING));
auditInfo.put(Constants.USER_ID_STRING, claims.getStringClaimValue(Constants.USER_ID_STRING));
auditInfo.put(Constants.SUBJECT_CLAIMS, claims);
String callerId = headerMap.getFirst(HttpStringConstants.CALLER_ID);
if(callerId != null) auditInfo.put(Constants.CALLER_ID_STRING, callerId);
if(config != null && (Boolean)config.get(ENABLE_VERIFY_JWT_SCOPE_TOKEN) && OpenApiHelper.openApi3 != null) {
Operation operation = null;
OpenApiOperation openApiOperation = (OpenApiOperation)auditInfo.get(Constants.OPENAPI_OPERATION_STRING);
Expand Down

0 comments on commit 8d7ef09

Please sign in to comment.