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

Setting experimental metricsAggregator: true does not respect enabled setting and hangs on connecting #10837

Closed
3 tasks done
Jimmy89 opened this issue Feb 28, 2024 · 5 comments

Comments

@Jimmy89
Copy link

Jimmy89 commented Feb 28, 2024

Is there an existing issue for this?

How do you use Sentry?

Sentry Saas (sentry.io)

Which SDK are you using?

@sentry/serverless

SDK Version

7.103.0

Framework Version

NodeJS 20.10

Link to Sentry event

No response

SDK Setup

Index.mjs

import Sentry from "@sentry/serverless";
// Important: no DSN is inserted, no Sentry environment variables are set, these are all values given to Sentry
Sentry.AWSLambda.init({
    enabled: false,
    _experiments: {
        metricsAggregator: true,
    },
});

console.log("I keep running");

Steps to Reproduce

  1. Run code with node index.mjs
  2. The node process will never stop, it 'hangs' on the metricsAggregator to 'finish' or something, which never happens.

Expected Result

Sentry not doing anything as it is disabled.

Actual Result

Need to kill the node process the hard way.

@AbhiPrasad
Copy link
Member

If you add debug: true, to your Sentry.init, what shows up in the logs?

@Jimmy89
Copy link
Author

Jimmy89 commented Feb 29, 2024

Only the basic Sentry Logger [warn]: No DSN provided, client will not send events. message (which is expected as I also disable Sentry), whether the plugin is added or not.
No other messages. Were you able to reproduce the issue as well?

@AbhiPrasad
Copy link
Member

I was able to reproduce this issue. It seems something is being problematic and not letting the node process exit.

For now you can resolve this by only setting the metricsAggregator experiment if the dsn is defined. We currently don't have the bandwidth to dig deeper for now, but PRs are welcome if you would like to help us out! Thanks.

@AbhiPrasad
Copy link
Member

Fixed with #11483, will be released end of this week.

@AbhiPrasad
Copy link
Member

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

No branches or pull requests

2 participants