Uploaded image for project: 'Phoenix'
  1. Phoenix
  2. PHOENIX-3534

Support multi region SYSTEM.CATALOG table

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 4.15.0, 5.1.0
    • None
    • None

    Description

      Currently Phoenix requires that the SYSTEM.CATALOG table is single region based on the server-side row locks being held for operations that impact a table and all of it's views. For example, adding/removing a column from a base table pushes this change to all views.

      As an alternative to making the SYSTEM.CATALOG transactional (PHOENIX-2431), when a new table is created we can do a lazy cleanup of any rows that may be left over from a failed DDL call (kudos to lhofhansl for coming up with this idea). To implement this efficiently, we'd need to also do PHOENIX-2051 so that we can efficiently find derived views.

      The implementation would rely on an optimistic concurrency model based on checking our sequence numbers for each table/view before/after updating. Each table/view row would be individually locked for their change (metadata for a view or table cannot span regions due to our split policy), with the sequence number being incremented under lock and then returned to the client.

      Attachments

        1. PHOENIX-3534.patch
          869 kB
          Thomas D'Silva
        2. PHOENIX-3534-v2.patch
          881 kB
          Hadoop QA
        3. PHOENIX-3534-v3.patch
          886 kB
          Thomas D'Silva

        Issue Links

          Activity

            People

              tdsilva Thomas D'Silva
              jamestaylor James R. Taylor
              Votes:
              0 Vote for this issue
              Watchers:
              13 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 4h 10m
                  4h 10m