-
Notifications
You must be signed in to change notification settings - Fork 130
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
Bug 1682638 - Multiple fixes: Don't let the queue run, handle empty databases #1398
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.
Drive by comment pile.
This test as of this commit fails.
There's no point in waiting for it to finish initialization if we're shutting down. There might be multiple operations queued, which could block for a long time. We should not hold off shutdown in those cases. Note: If Glean was already fully initialized shutdown will wait for these operations to finish before it shuts down.
Invalid means: either empty or not bincode-deserializable.
`test_reset_glean` will already do the right thing: * Destroys the Glean object if any * Resets the dispatcher, but only if Glean was initialized.
a25ab44
to
c0abb67
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.
@badboy would you consider dropping the FOG prefix from the filenames and the references in the test files?
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.
Thank you :)
I identified 2 problems, that in combination cause the crashes in bug 1682638.
See document.
When init fails for some reason we never set a global Glean object. However on shutdown we try to unblock the dispatcher, which might have some recording tasks in there already. These should never be executed without a Glean.
The first 4 commits address that: we know when it is initialized, so we can avoid emptying the dispatcher if it hasn't.
For reasons unknown to me right now the database file was empty on at least the machine of one tester.
Rkv in safe-mode considers empty files as invalid files. I filed this upstream.
The solution (for now) is to remove that file and start over again.
For both cases I added new tests.