Remove TODOs from RootTabletMutatorImpl.java - #6494
Draft
Amemeda wants to merge 4 commits into
Draft
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Removed the following TODOs:
RootTabletMutatorImpl.java:// TODO examine implementation of getZooReaderWriter().mutate(): This TODO may be outdated, current version of code does not usecontext.getZooReaderWriter(), usescontext.getZooSession()insteadRootTabletMutatorImpl.java:// TODO for efficiency this should maybe call mutateExisting: Updated line 103 to usemutateExisting()instead ofmutateOrCreate()RootTabletMutatorImpl.java:// TODO this is racy.... AddedThread.sleep()after the first call to clear() as a makeshift wait to check that the ZROOT_TABLET is empty before calling clear() again a few lines later to avoid race condition.RootConditionalWriter.java:// TODO this is racy.... Same as aboveThis pr resolves 4 TODOs from #2699
Need more information on what is going on here / what an alternative would be. Both occurrences of this TODO are preceded by the exact same clear() a few lines beforehand, could this be why it is racy?