-
Notifications
You must be signed in to change notification settings - Fork 72
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
Expand gateway request logging in AWS, GCP, and airnode-client #1526
Conversation
express.json available since 4.16.0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm a bit skeptical about how much will this help with the debugging process. I'm not saying it's bad, it will definitely help but I don't know if it's enough. But it's a start 🙂
// Unlike GCP, AWS automatically generates a unique request ID so no need to use one here | ||
logger.info(`Received HTTP gateway request`); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this actually necessary? I think every request (lambda invocation) is logged in the AWS (and I think also in GCP) anyway. I don't think this adds anything. I would at least set it to debug
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Edit: I've kept it for all, but changed it to debug
. I think keeping it aids in visualizing the beginning of the block of logs pertaining to the request.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would use the log options with the meta
field everywhere where you want to add some data to the log message. Similar to how it's done in Airseeker. Or do you feel like it's better this way?
Ah sorry it wasn't ready for re-review just yet 😅 I pushed that commit in order for CI to build the images that I could then test. But I think the meta option will be the better route 👍 |
Also adds back debug request received log for AWS
Agreed, but it's a start and provides a lot more than what the user / Airnode operator gets access to currently. I actually found it useful in debugging encoded parameters for a signed gateway request 😅
For the local client, a |
Closes #1351.
User story for the motivation and context of this PR:
As a [developer], I want to [access request processing logs on any of GCP, AWS, or the airnode-client without needing knowledge of Airnode request handling], so jthat [I can debug failing requests].