Uploaded image for project: 'Oozie'
  1. Oozie
  2. OOZIE-2541

Possible resource leak in Hive2Credentials

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Trivial
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.3.0
    • Component/s: core
    • Labels:
      None

      Description

      Connection to Hive is not closed in case of an SQLException:

      Connection con = DriverManager.getConnection(url);
      XLog.getLog(getClass()).debug("Connected successfully to " + url);
      // get delegation token for the given proxy user
      String tokenStr = ((HiveConnection)con).getDelegationToken(jobconf.get(USER_NAME), principal);
      XLog.getLog(getClass()).debug("Got token");
      

      Close the Connection in a finally block.

        Attachments

        1. OOZIE-2541-003.patch
          2 kB
          Peter Bacsko
        2. OOZIE-2541-002.patch
          2 kB
          Peter Bacsko
        3. OOZIE-2541-001.patch
          2 kB
          Peter Bacsko

          Activity

            People

            • Assignee:
              pbacsko Peter Bacsko
              Reporter:
              pbacsko Peter Bacsko
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: