-
Notifications
You must be signed in to change notification settings - Fork 35
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
Disable logging to DataDog for local invocation #97
Comments
Hey @dtothefp . It looks like the error is because of some environment variables we usually read from the AWS sandbox that the serverless plugin's invoke environment doesn't provide. I think we might be able to address this at the serverless plugin level by disabling instrumentation when the invoke occurs. DataDog/serverless-plugin-datadog#63 We might be able to address both issues at once. |
@DarcyRaynerDD your fix for serverless plugin fixed the problem references in that issue but I'm still seeing this on local invoke
Do I need to update this lib as well? |
Hi @dtothefp, that error message comes from this function, and is You should be able to enable writing the metrics to logs by setting the |
@sfirrin sorry for the late reply, for some reason I'm not receiving notifications for this issue 🤷♂️ This solution seems difficult to do because in my mind I would have to toggle the custom custom:
datadog:
flushMetricsToLogs: # ternary for IS_LOCAL |
Expected Behavior
I'd like to be able to locally invoke my function using the Serverless framework and just see DEBUG logs without sending to data dog. Maybe this is possible with existing env variables for configuration but I didn't see these options.
I'm using this library in combination with serverless-plugin-datadog to supply the Forwarder ARN.
Actual Behavior
See error below
Steps to Reproduce the Problem
Specifications
Stacktrace
The text was updated successfully, but these errors were encountered: