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

IndexScrutinyTool should use empty catalog instead of null

    XMLWordPrintableJSON

Details

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

    Description

      Before executing, the index scrutiny tool does a sanity check to make sure that the given data table and index are valid and related to each other. This check uses the JDBC metadata API, and passes in null for the catalog name. 

      Unfortunately, a null entry for catalog causes Phoenix to omit tenant_id from the query against System.Catalog, causing a table scan, which can be lengthy or time out if the server has too many views. 

      It should pass in the empty string for catalog, which will make Phoenix filter on "WHERE tenant_id is NULL", which will avoid the table scan. 

      Attachments

        1. PHOENIX-4907.patch
          1 kB
          Geoffrey Jacoby

        Activity

          People

            gjacoby Geoffrey Jacoby
            gjacoby Geoffrey Jacoby
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: