bugsnag / bugsnag-go

Automatic panic monitoring for Go and Go web frameworks, like negroni, gin, and revel
https://docs.bugsnag.com/platforms/go
MIT License
203 stars 69 forks source link

Allow creating own session, with OpenTelemetry trace_id as the uuid #202

Closed veqryn closed 9 months ago

veqryn commented 9 months ago

Description

Right now, StartSession is the only way to add new sessions, and it calls the private method newSession which creates a new session with a new uuid.

Describe the solution you'd like I would like the ability to add a new session that I have created, so that I can put the OpenTelemetry trace_id as the session uuid (they are both [16]byte). This way the session uuid's in bugsnag line up with our trace id's.

gareththackeray commented 9 months ago

Hi Chris. Thanks for the feature request. Could you elaborate on what your use case is for wanting a matching session id? I don't believe that session ids are accessible externally, but please correct me if I'm wrong!

We are currently looking at extending our OpenTelemetry support so it would be good to hear what you have in mind.

veqryn commented 9 months ago

I made this while mistakenly thinking the trace id's were accessible in bugsnags.