-
Notifications
You must be signed in to change notification settings - Fork 30
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
No-op in case ELASTIC_APM_ACTIVE
is not set or set to false
#289
Comments
@aspacca apologies for the late reply on this one. There are a couple of things to unpack in this request, please let me know if I correctly understood what you are asking for: (1) You are looking for a way to install, but disable the lambda extension and the suggestion is that the extension should listen to |
then we are aligned on this :)
Checking the
No, sorry, I was not clear: I want to be able to disable the APM lambda extension (through the Basically what I look for is either I opt-in in the APM lambda extension setting explicitly |
Thanks for the explanation. Allowing to disable the lambda extension sounds reasonable. Checking I cannot make any promises on delivery and timelines, but we'll keep this enhancement topic in mind. |
@simitt great, thanks! |
@simitt could you confirm I can expect this feature on 8.7? thanks! |
@aspacca it is not planned for the |
@simitt @elastic/apm-pm : is this planned for any release? |
It currently isn't, as it is not aligned with our major priorities. |
The Elastic Serverless Forwarder currently uses the Python Agent.
The characteristic of the Forwarder is that it's an Application available on the AWS Serverless Application Repository that different users can deploy. Enabling APM tracing and instrumentation is optional: according to the users requirement they may opt-in into it, but by default the feature is not enabled.
We achieve this with our own
capture_serverless
decorator: checking forELASTIC_APM_ACTIVE
being set as ENV variable, and adding a no-op wrapper in case it's not.(Additionally we check for
AWS_LAMBDA_FUNCTION_NAME
being set as well, in order to easy local running and integration tests)I run a test deploying the Forwarder with the AWS Lambda extension layer, and I realised that without setting
ELASTIC_APM_LAMBDA_APM_SERVER
ENV variable the Forwarder lambda execution fails.Contrary to the Python Agent
capture_serverless
decorator, there is no workaround for this in the AWS Lambda extension.This prevents the Forwarder to adopt the AWS Lambda extension, that should be the way to go for the future, especially given the planned support for collecting logs.
In general, Applications available on the AWS Serverless Application Repository, should be the more flexible they can in providing their own users to optionally enable accessory features like APM, and with the current behaviour there is no way to use AWS Lambda extension without enabling it.
The additional check for
AWS_LAMBDA_FUNCTION_NAME
ENV variable would be optimal, since it will lower the effort required on running the lambda code outside of a real lambda environment, but there might be space for any alternative solution.The text was updated successfully, but these errors were encountered: