-
Notifications
You must be signed in to change notification settings - Fork 103
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
Set slogger on rungroup after logshipping is set up, so that rungroup logs will be shipped #1869
Set slogger on rungroup after logshipping is set up, so that rungroup logs will be shipped #1869
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hrm. Not sure I love the changed signature. It feels error prone.
We could maybe move NewRunGroup
to after the logshipper is setup? Though it would mean moving runGroup.Add
till later too
… logs will be shipped
8b2bcb8
to
0da0f76
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
great find! this looks good to me I think you just have to fix up the watchdog_service_windows NewRunGroup
call - those are only written to sqlite so I don't think order/timing should matter at all
I considered that, but felt like moving all the runGroup.Add calls later was more error prone 😅 -- we'd have one or two runGroup.Add calls to move, given that we don't add the trace exporter if we can't init it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice
I wanted to understand why this was happening, and figured it out. When we set the new log shipping handler, we initialize a new slogger, so the previous reference to the slogger never gets that new handler.
|
Despite the changes in #1822, I wasn't seeing rungroup shutdown logs being shipped. When looking through the shipped logs, I noticed that the only rungroup logs available were either from very old versions of launcher, or from the desktop process.
This PR updates when we set the slogger on the rungroup so that we set it after the shipping handler has been added.