Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GraphQL Request Logging #35

Merged
merged 2 commits into from
May 30, 2024
Merged

GraphQL Request Logging #35

merged 2 commits into from
May 30, 2024

Conversation

joshgarde
Copy link
Member

@joshgarde joshgarde commented May 30, 2024

GraphQL logging for SWODLR APIs based on the java-graphql instrumentation APIs

https://www.graphql-java.com/documentation/instrumentation/

Example logs:

2024-05-30 00:15:56.783  INFO 16430 --- [r-http-kqueue-2] g.n.p.s.metrics.GraphQlRequestLogger     : {"operation":"QUERY","path":"/currentUser","executionId":"ca95ea89-1","arguments":{},"user":"joshgarde"}
2024-05-30 00:15:56.796  INFO 16430 --- [r-http-kqueue-2] g.n.p.s.metrics.GraphQlRequestLogger     : {"operation":"QUERY","path":"/currentUser/id","executionId":"ca95ea89-1","arguments":{},"user":"joshgarde"}
2024-05-30 00:15:56.800  INFO 16430 --- [r-http-kqueue-2] g.n.p.s.metrics.GraphQlRequestLogger     : {"operation":"QUERY","path":"/currentUser/firstName","executionId":"ca95ea89-1","arguments":{},"user":"joshgarde"}
2024-05-30 00:15:56.802  INFO 16430 --- [r-http-kqueue-2] g.n.p.s.metrics.GraphQlRequestLogger     : {"operation":"QUERY","path":"/currentUser/lastName","executionId":"ca95ea89-1","arguments":{},"user":"joshgarde"}
2024-05-30 00:15:56.804  INFO 16430 --- [r-http-kqueue-2] g.n.p.s.metrics.GraphQlRequestLogger     : {"operation":"QUERY","path":"/currentUser/email","executionId":"ca95ea89-1","arguments":{},"user":"joshgarde"}

Closes podaac/swodlr#134

@joshgarde joshgarde self-assigned this May 30, 2024
@joshgarde joshgarde merged commit 5545169 into develop May 30, 2024
2 checks passed
@joshgarde joshgarde deleted the graphql-logging branch May 30, 2024 23:21
@frankinspace frankinspace mentioned this pull request Jun 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Generate logging on SWODLR-API's GraphQL calls (mutations/query)
2 participants