Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-17481 LLAP workload management
  3. HIVE-18457

improve show plan output (triggers, mappings)

Log workAgile BoardRank to TopRank to BottomBulk Copy AttachmentsBulk Move AttachmentsVotersWatch issueWatchersConvert to IssueMoveLinkCloneLabelsUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 3.0.0
    • 3.0.0
    • None
    • None

    Description

      Did the following sequence to add triggers to UNMANAGED. I can see the triggers added to metastore by IS_IN_UNAMANGED flag is not set in metastore. Also show resource plans does not show triggers in unmanaged pool.

      0: jdbc:hive2://localhost:10000> show resource plans;
      +----------+----------+--------------------+
      | rp_name  |  status  | query_parallelism  |
      +----------+----------+--------------------+
      | global   | ACTIVE   | NULL               |
      | llap     | ENABLED  | NULL               |
      +----------+----------+--------------------+
      
      0: jdbc:hive2://localhost:10000>ALTER RESOURCE PLAN llap ACTIVATE;
      0: jdbc:hive2://localhost:10000>ALTER RESOURCE PLAN global DISABLE;
      0: jdbc:hive2://localhost:10000>CREATE TRIGGER global.highly_parallel WHEN TOTAL_TASKS > 40 DO KILL;
      0: jdbc:hive2://localhost:10000>ALTER TRIGGER global.highly_parallel ADD TO UNMANAGED;
      
      0: jdbc:hive2://localhost:10000>CREATE TRIGGER global.big_hdfs_read WHEN HDFS_BYTES_READ > 3000000000 DO KILL;
      0: jdbc:hive2://localhost:10000>ALTER TRIGGER global.big_hdfs_read ADD TO UNMANAGED;
      
      0: jdbc:hive2://localhost:10000>CREATE TRIGGER global.slow_query WHEN EXECUTION_TIME > 100000 DO KILL;
      0: jdbc:hive2://localhost:10000>ALTER TRIGGER global.slow_query ADD TO UNMANAGED;
      
      0: jdbc:hive2://localhost:10000>CREATE TRIGGER global.some_spills WHEN SPILLED_RECORDS > 10 DO KILL;
      0: jdbc:hive2://localhost:10000>ALTER TRIGGER global.some_spills ADD TO UNMANAGED;
      
      0: jdbc:hive2://localhost:10000>ALTER RESOURCE PLAN global ENABLE;
      0: jdbc:hive2://localhost:10000>ALTER RESOURCE PLAN global ACTIVATE;
      
      0: jdbc:hive2://localhost:10000> show resource plan global;
      +----------------------------------------------------+
      |                        line                        |
      +----------------------------------------------------+
      | global[status=ACTIVE,parallelism=null,defaultPool=default] |
      |     default[allocFraction=1.0,schedulingPolicy=null,parallelism=4] |
      +----------------------------------------------------+
      
      mysql
      mysql> select * from wm_trigger;
      +------------+-------+-----------------+------------------------------+-------------------+-----------------+
      | TRIGGER_ID | RP_ID | NAME            | TRIGGER_EXPRESSION           | ACTION_EXPRESSION | IS_IN_UNMANAGED |
      +------------+-------+-----------------+------------------------------+-------------------+-----------------+
      |         29 |     1 | highly_parallel | TOTAL_TASKS > 40             | KILL              |                |
      |         33 |     1 | big_hdfs_read   | HDFS_BYTES_READ > 3000000000 | KILL              |                |
      |         34 |     1 | slow_query      | EXECUTION_TIME > 100000      | KILL              |                |
      |         35 |     1 | some_spills     | SPILLED_RECORDS > 10         | KILL              |                |
      +------------+-------+-----------------+------------------------------+-------------------+-----------------+
      

      From the above mysql table, IS_IN_UNMANAGED is not set and 'show resource plan global' is not showing triggers defined in unmanaged pool.

      Attachments

        1. HIVE-18457.01.patch
          30 kB
          Sergey Shelukhin
        2. HIVE-18457.patch
          27 kB
          Sergey Shelukhin

        Issue Links

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            sershe Sergey Shelukhin Assign to me
            prasanth_j Prasanth Jayachandran
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment