Uploaded image for project: 'IMPALA'
  1. IMPALA
  2. IMPALA-6900

Invalidate metadata operation is ignored at a coordinator if catalog is empty

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Blocker
    • Resolution: Fixed
    • Impala 3.0, Impala 2.12.0
    • Impala 3.2.0
    • Catalog
    • None

    Description

      The following workflow may cause an impalad that issued an invalidate metadata to falsely consider that the effect of that operation has taken effect, thus causing subsequent queries to fail due to unresolved references to tables or databases. 

      Steps to reproduce:

      1. Start an impala cluster connecting to an empty HMS (no databases).
      2. Create a database "db" in HMS outside of Impala (e.g. using Hive).
      3. Run INVALIDATE METADATA through Impala.
      4. Run "use db" statement in Impala.

       

      The while condition in the code snippet below is cause the WaitForMinCatalogUpdate function to prematurely return even though INVALIDATE METADATA has not taken effect: 

      void ImpalaServer::WaitForMinCatalogUpdate(..) {
      ...
      VLOG_QUERY << "Waiting for minimum catalog object version: "
                 << min_req_catalog_object_version << " current version: "
                 << min_catalog_object_version;
      while (catalog_update_info_.min_catalog_object_version <  min_req_catalog_object_version && catalog_update_info_.catalog_service_id ==  catalog_service_id) {
         catalog_version_update_cv_.Wait(unique_lock);
      }
      

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              dtsirogiannis Dimitris Tsirogiannis
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: