-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Arc - Make it possible to inspect shutdown reason from ShutdownEvent #26752
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.
That's what I had in mind!
Makes sense to me, but I'd rather not expose the enum publicly, as it's hard to extend. Really the only thing the user can figure out is a boolean value, so in my opinion, we should expose a single |
Yea, we could do that.
From the code I don't think we can do this apart from native mode where we use I'll adjust the PR in a while |
@Ladicek updated. User can now only get to a I should also note that I tested these changes with quickstarts as there is no way to add automated test for 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.
LGTM.
SHUTDOWN_REASON
shouldn't really be upper-case, as it's not a constant, but that's just nit-picking :-)
Damn, can't get that past you even on Friday :-D |
Fixes #16976
A simple way to expand
ShutdownEvent
so that users can inspect the cause of shutdown and differentiate between standard and non-standard.@geoand is this at least close to what you meant? :)