Skip to content

Commit

Permalink
Correct TreeTableImpl.maybeWaitForStructuralSatisfaction(): we were m…
Browse files Browse the repository at this point in the history
…istakenly not waiting for the sourceRowLookup in unfiltered cases
  • Loading branch information
rcaudy committed Nov 19, 2024
1 parent 8ddafe6 commit 6a189ee
Showing 1 changed file with 6 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -414,7 +414,7 @@ boolean nodeIdExpandable(@NotNull final SnapshotStateImpl snapshotState, final l

@Override
NotificationStepSource[] getSourceDependencies() {
// NB: The reverse lookup may be derived from an unfiltered parent of our source, hence we need to treat it as a
// The reverse lookup may be derived from an unfiltered parent of our source, hence we need to treat it as a
// separate dependency if we're filtered.
return filtered
? new NotificationStepSource[] {source, sourceRowLookup}
Expand All @@ -423,9 +423,12 @@ NotificationStepSource[] getSourceDependencies() {

@Override
void maybeWaitForStructuralSatisfaction() {
// NB: Our root is just a node in the tree (which is a partitioned table of constituent nodes), so waiting for
// Our root is just a node in the tree (which is a partitioned table of constituent nodes), so waiting for
// satisfaction of the root would be insufficient (and unnecessary if we're waiting for the tree).
maybeWaitForSatisfaction(tree);
if (!filtered) {
// The row lookup aggregation must also be satisfied if we aren't using it as a source dependency.
maybeWaitForSatisfaction(sourceRowLookup);
}
}

}

0 comments on commit 6a189ee

Please sign in to comment.