Skip to content

Conversation

@adinauer
Copy link
Member

@adinauer adinauer commented Jun 25, 2024

#skip-changelog

📜 Description

Using SentrySpanFactoryHolder which is loaded into the bootstrap classloader and is used by the agent to assign a OtelSpanFactory instance created in the agent class loader which references SentryWeakSpanStorage also from the agent classloader. Without this workaround the application would be referring to SentryWeakSpanStorage (via OtelSpanFactory) in the bootstrap classloader which has no data in it (since the span processor writes to the one in the agent class loader).

💡 Motivation and Context

Due to a bug around using the wrong classloader for sentry-opentelemetry-bootstrap (currently loaded via agent classloader; should be bootstrap classloader), we need a workaround when the agent is used without auto init (SENTRY_AUTO_INIT=false).

💚 How did you test it?

📝 Checklist

  • I reviewed the submitted code.
  • I added tests to verify the changes.
  • No new PII added or SDK only sends newly added PII if sendDefaultPII is enabled.
  • I updated the docs if needed.
  • Review from the native team if needed.
  • No breaking change or entry added to the changelog.
  • No breaking change for hybrid SDKs or communicated to hybrid SDKs.

🔮 Next steps

@github-actions
Copy link
Contributor

github-actions bot commented Jun 25, 2024

Messages
📖 Do not forget to update Sentry-docs with your feature once the pull request gets approved.

Generated by 🚫 dangerJS against 4ffe8ea

Base automatically changed from feat/potel-24-merge-fix-pr-comments to 8.x.x June 25, 2024 14:15
@adinauer adinauer merged commit 1a4c9e8 into 8.x.x Jun 25, 2024
@adinauer adinauer deleted the feat/potel-25-workaround-for-agent-non-auto-init branch June 25, 2024 14:15
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.

3 participants