You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@phoenix.apache.org by "Palash Chauhan (Jira)" <ji...@apache.org> on 2024/02/23 01:20:00 UTC

[jira] [Commented] (PHOENIX-7230) Optimize rpc call to master if all indexes are migrated to new coprocs

    [ https://issues.apache.org/jira/browse/PHOENIX-7230?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17819863#comment-17819863 ] 

Palash Chauhan commented on PHOENIX-7230:
-----------------------------------------

[~vjasani] What is the best way to access the new config within MutationState? Will we have to pick it from the connection's CQSI properties? 

> Optimize rpc call to master if all indexes are migrated to new coprocs
> ----------------------------------------------------------------------
>
>                 Key: PHOENIX-7230
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-7230
>             Project: Phoenix
>          Issue Type: Improvement
>    Affects Versions: 5.1.3
>            Reporter: Viraj Jasani
>            Assignee: Palash Chauhan
>            Priority: Major
>
> If all the tables of the cluster have been migrated to the new index coprocs (GlobalIndexChecker, IndexRegionObserver), for every mutation, we should avoid making additional rpc call to master to retrieve TableDescriptor to determine if the table descriptor has GlobalIndexChecker coproc enabled:
> {code:java}
> at org.apache.phoenix.query.ConnectionQueryServicesImpl.getTableDescriptor(ConnectionQueryServicesImpl.java:605)
> at org.apache.phoenix.util.IndexUtil.isGlobalIndexCheckerEnabled(IndexUtil.java:311)
> at org.apache.phoenix.execute.MutationState.filterIndexCheckerMutations(MutationState.java:1680)
> at org.apache.phoenix.execute.MutationState.sendBatch(MutationState.java:1255)
> at org.apache.phoenix.execute.MutationState.send(MutationState.java:1186)
> at org.apache.phoenix.execute.MutationState.send(MutationState.java:2028)
> at org.apache.phoenix.execute.MutationState.commit(MutationState.java:1840)
> at org.apache.phoenix.jdbc.PhoenixConnection$2.call(PhoenixConnection.java:841)
> at org.apache.phoenix.jdbc.PhoenixConnection$2.call(PhoenixConnection.java:836)
> at org.apache.phoenix.call.CallRunner.run(CallRunner.java:53)
> at org.apache.phoenix.jdbc.PhoenixConnection.commit(PhoenixConnection.java:836) {code}
> We already use config "phoenix.index.region.observer.enabled" to disable/enable new index coproc during upgrade. The primary purpose of this config is to add/remove new or old index coprocs during upgrade process.
> We can introduce new config "phoenix.index.region.observer.enabled.alltables" with default value true. Unless the config is disabled, we should avoid call to "IndexUtil#isGlobalIndexCheckerEnabled" within filterIndexCheckerMutations().



--
This message was sent by Atlassian Jira
(v8.20.10#820010)