Uploaded image for project: 'Tajo'
  1. Tajo
  2. TAJO-1619

JDBC program is stuck after closing

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 0.10.0
    • Fix Version/s: 0.10.1
    • Component/s: JDBC Driver
    • Labels:
      None

      Description

      JdbcTest.java
      public class JdbcTest {
        public static void main(String [] args) throws ClassNotFoundException, SQLException {
          Class.forName("org.apache.tajo.jdbc.TajoDriver");
      
          Connection conn = DriverManager.getConnection("jdbc:tajo://127.0.0.1:26002/tpch");
      
          Statement stmt = null;
          ResultSet rs = null;
          try {
            stmt = conn.createStatement();
            rs = stmt.executeQuery("select count(*) from customer");
            System.out.println(rs.next());
            System.out.println(rs.getInt(1));
      
          } catch (SQLException e) {
            System.err.println(e.getMessage());
          } finally {
            System.out.println("close start");
            if (rs != null) rs.close();
            System.out.println("rs close end");
            if (stmt != null) stmt.close();
            System.out.println("stmt close end");
            if (conn != null) conn.close();
            System.out.println("conn close end");
          }
        }
      }
      

      When the code above is executed, it is stuck after printing 'conn close end'.

      I attache log and thread dump.

        Attachments

        1. tajo-eminency-worker-Jongyoungui-MBP.log
          1.22 MB
          Jongyoung Park
        2. tajo-eminency-master-Jongyoungui-MBP.log
          1.56 MB
          Jongyoung Park
        3. dump
          4 kB
          Jongyoung Park

          Activity

            People

            • Assignee:
              jihoonson Jihoon Son
              Reporter:
              eminency Jongyoung Park
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: