Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-14799

Query operation are not thread safe during its cancellation

Log workAgile BoardRank to TopRank to BottomBulk Copy AttachmentsBulk Move AttachmentsVotersWatch issueWatchersCreate sub-taskConvert to sub-taskMoveLinkCloneLabelsUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 2.1.1, 2.2.0
    • HiveServer2
    • None

    Description

      When a query is cancelled either via Beeline (Ctrl-C) or API call TCLIService.Client.CancelOperation, SQLOperation.cancel is invoked in a different thread from that running the query to close/destroy its encapsulated Driver object. Both SQLOperation and Driver are not thread-safe which could sometimes result in Runtime exceptions like NPE. The errors from the running query are not handled properly therefore probably causing some stuffs (files, locks etc) not being cleaned after the query termination.

      Attachments

        1. HIVE-14799.1.patch
          34 kB
          Chaoyu Tang
        2. HIVE-14799.2.patch
          36 kB
          Chaoyu Tang
        3. HIVE-14799.3.patch
          36 kB
          Chaoyu Tang
        4. HIVE-14799.4.patch
          35 kB
          Chaoyu Tang
        5. HIVE-14799.5.patch
          35 kB
          Chaoyu Tang
        6. HIVE-14799.5.patch
          35 kB
          Chaoyu Tang
        7. HIVE-14799.6.patch
          36 kB
          Chaoyu Tang
        8. HIVE-14799.6.patch
          36 kB
          Chaoyu Tang
        9. HIVE-14799.7.patch
          36 kB
          Chaoyu Tang
        10. HIVE-14799.patch
          33 kB
          Chaoyu Tang
        11. HIVE-14799-branch-2.1.patch
          34 kB
          Chaoyu Tang

        Issue Links

        Activity

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

          People

            ctang Chaoyu Tang Assign to me
            ctang Chaoyu Tang
            Votes:
            0 Vote for this issue
            Watchers:
            9 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment