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

sentry: allow passing base tags #67

Merged
merged 8 commits into from
Mar 20, 2024
Merged

sentry: allow passing base tags #67

merged 8 commits into from
Mar 20, 2024

Conversation

mping-exo
Copy link
Contributor

@mping-exo mping-exo commented Mar 20, 2024

The java sdk seems to set isEnableExternalConfiguration by default (reading from env vars), or at the very least allows setting that option, while the clj sdk does not. The sentry-clj library is initiated without this option; it's also not possible to set it to true, hence we need a way to forwared some options to the sentry library.

This PR forwards the tags; environment and release could already be passed down

https://docs.sentry.io/platforms/java/configuration/#configuration-methods
https://github.com/getsentry/sentry-clj/?tab=readme-ov-file#additional-initialisation-options

Copy link

@arnaudgeiser arnaudgeiser left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How is it behaving when you do set both the environment variables and the keys? What takes precedence?

src/spootnik/reporter/impl.clj Show resolved Hide resolved
src/spootnik/reporter/sentry.clj Outdated Show resolved Hide resolved
src/spootnik/reporter/sentry.clj Outdated Show resolved Hide resolved
Co-authored-by: Arnaud Geiser <arnaudgeiser@gmail.com>
@mping-exo
Copy link
Contributor Author

mping-exo commented Mar 20, 2024

How is it behaving when you do set both the environment variables and the keys? What takes precedence?

@arnaudgeiser the issue is that while the java sdk seems to set isEnableExternalConfiguration by default (reading from env vars), the clj sdk does not, and the sentry library is initiated without this option, so we have to set the tags manually.

src/spootnik/reporter/sentry.clj Outdated Show resolved Hide resolved
@mping-exo mping-exo merged commit 26003a9 into master Mar 20, 2024
1 check passed
@mping-exo mping-exo deleted the sentry/base-tags branch March 20, 2024 16:20
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.

None yet

3 participants