Palash Chauhan created PHOENIX-7460:
---------------------------------------

             Summary: Update stream metadata when a data table region splits
                 Key: PHOENIX-7460
                 URL: https://issues.apache.org/jira/browse/PHOENIX-7460
             Project: Phoenix
          Issue Type: Sub-task
            Reporter: Palash Chauhan


PHOENIX-7456 introduces the concept of a Stream to consume records from Phoenix 
CDC. Stream records are grouped into partitions which are nothing but data 
table regions. Since data table regions can split, we need to track the lineage 
of regions to share it with consumers of CDC. This enables them to consume the 
change records for a given rowkey in the order of their arrival. 

In HBase, when a split operation is successful, master invokes this master 
coproc hook:
{code:java}
/**
   * Called after the region is split.
   * @param c           the environment to interact with the framework and 
master
   * @param regionInfoA the left daughter region
   * @param regionInfoB the right daughter region
   */
  default void postCompletedSplitRegionAction(final 
ObserverContext<MasterCoprocessorEnvironment> c,
    final RegionInfo regionInfoA, final RegionInfo regionInfoB) throws 
IOException {
  } {code}
Phoenix can introduce a new MasterCoprocessor that implements the above action 
to update the partition metadata (child -> parent links) in the 
SYSTEM.CDC_STREAM table. 



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

Reply via email to