Copilot commented on code in PR #2569:
URL: https://github.com/apache/phoenix/pull/2569#discussion_r3789333190
##########
phoenix-core-client/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java:
##########
@@ -1991,6 +1992,11 @@ private TableDescriptor ensureTableCreated(byte[]
physicalTableName,
}
return null;
} else {
+ if (createIfNotExists && doesPhoenixTableAlreadyExist(existingDesc)) {
Review Comment:
`doesPhoenixTableAlreadyExist` is not a reliable test for this no-op. In
particular, transactional Phoenix tables install
`PHOENIX_TRANSACTIONAL_INDEXER_CLASSNAME`, while that helper only accepts
`INDEXER`, `INDEX_REGION_OBSERVER`, or `GLOBAL_INDEX_CHECKER` (lines
1688-1703). The predicate is therefore false for an existing transactional
table, and this method still applies the new TTL/VERSIONS despite `IF NOT
EXISTS`. Please base this decision on logical Phoenix-table existence or extend
the detection to every supported Phoenix table form, with a transactional
regression test.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]