[ https://issues.apache.org/jira/browse/PHOENIX-4278?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16356725#comment-16356725 ]
ASF GitHub Bot commented on PHOENIX-4278: ----------------------------------------- Github user ohadshacham commented on a diff in the pull request: https://github.com/apache/phoenix/pull/291#discussion_r166875958 --- Diff: phoenix-core/src/main/java/org/apache/phoenix/query/ConnectionQueryServicesImpl.java --- @@ -850,19 +849,12 @@ private void addCoprocessors(byte[] tableName, HTableDescriptor descriptor, PTab && !SchemaUtil.isMetaTable(tableName) && !SchemaUtil.isStatsTable(tableName)) { if (isTransactional) { - if (!descriptor.hasCoprocessor(PhoenixTransactionalIndexer.class.getName())) { - descriptor.addCoprocessor(PhoenixTransactionalIndexer.class.getName(), null, priority, null); - } --- End diff -- Maybe I am missing something, but I don't understand why if we upgrade server and client together, we still need an empty PhoenixTransactionalIndexer. Can't we just remove the addCoprocessor from the code and remove PhoenixTransactionalIndexer? Regarding the case of supporting server upgrade with old clients. Can't we just add a new attribute to each mutation denotes that the index maintenance performed on the client slide and modify PhoenixTransactionalIndexer to ignore mutations (call the super function) for mutations that contains this attribute? > Implement pure client side transactional index maintenance > ---------------------------------------------------------- > > Key: PHOENIX-4278 > URL: https://issues.apache.org/jira/browse/PHOENIX-4278 > Project: Phoenix > Issue Type: Improvement > Reporter: James Taylor > Assignee: Ohad Shacham > Priority: Major > > The index maintenance for transactions follows the same model as non > transactional tables - coprocessor based on data table updates that looks up > previous row value to perform maintenance. This is necessary for non > transactional tables to ensure the rows are locked so that a consistent view > may be obtained. However, for transactional tables, the time stamp oracle > ensures uniqueness of time stamps (via transaction IDs) and the filtering > handles a scan seeing the "true" last committed value for a row. Thus, > there's no hard dependency to perform this on the server side. > Moving the index maintenance to the client side would prevent any RS->RS RPC > calls (which have proved to be troublesome for HBase). It would require > returning more data to the client (i.e. the prior row value), but this seems > like a reasonable tradeoff. -- This message was sent by Atlassian JIRA (v7.6.3#76005)