Repository navigation
Conversation
…r side for partial upserts (apache#2611) Co-authored-by: lokesh-khurana <lokesh.khurana@salesforce.com> Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com> (cherry picked from commit 96c05a4) Generated-by: Claude Code (Opus 5.5) Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Generated-by: Claude Code (Opus 5.5) Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
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.
JIRA: https://issues.apache.org/jira/browse/PHOENIX-7996
Backport of #2611 (master commit 96c05a4) to
5.3.What changes were proposed in this pull request?
Cherry-pick of the master change. It makes server-side maintenance of immutable, global, non-transactional indexes correct for partial upserts.
DEFAULT_SERVER_SIDE_IMMUTABLE_INDEXES_ENABLEDstaysfalseon5.3, as on master. Thus there is no change to the default behavior.IndexUtil.isServerSideImmutableIndexMaintenanceEnabled(...). Immutable tables with aROW_TIMESTAMPcolumn stay client-maintained.IndexRegionObserverreads back the current row for an immutable batch with a covered or uncovered global index when a mutation omits one of that index's on-disk columns.IndexUtil.isGlobalIndex, so uncovered global immutable indexes with a matching storage scheme are maintained.See #2611 for the full description.
Backport note: one conflict in
IndexRegionObserver.java. The newisPartialGlobalIndexMutationmethod is next togetPendingContext, which5.3has from PHOENIX-8053. Both methods are kept. Other files applied cleanly.Why are the changes needed?
Same as #2611. Without this change, when
phoenix.server.side.immutable.indexes.enabled=true, a partial upsert can drop a covered column from the index or write a null-keyed uncovered index entry, and an uncovered global immutable index can get no updates.Does this PR introduce any user-facing change?
No default behavior change. When the flag is enabled, the behavior is the same as on master after #2611.
How was this patch tested?
On
5.3(JDK 8), the change compiles and these ITs pass locally:ServerSideImmutableIndexIT: 95 run, 0 failures, 10 skippedClientSideImmutableIndexIT: 95 run, 0 failures, 10 skippedGlobalIndexCheckerIT: 116 run, 0 failures, 6 skippedDeleteIT: 74 run, 0 failuresThe skips come from
@IgnoreandAssumeguards that are already on5.3. This PR adds none.Was this patch authored or co-authored using generative AI tooling?
Generated-by: Claude Code (Opus 5.5)
🤖 Generated with Claude Code