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

TajoClient is blocked while main thread finished.

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 0.8.0, 0.9.0
    • Fix Version/s: 0.8.0
    • Component/s: RPC
    • Labels:
      None

      Description

      I tested Tajo JDBC Driver like bellow. After closing connection the TestCase still running.

      public static void main(String[] args) throws Exception {
      	Class.forName("org.apache.tajo.jdbc.TajoDriver").newInstance();
      	Connection conn = DriverManager
      			.getConnection("jdbc:tajo://127.0.0.1:26002");
      
      	Statement stmt = null;
      	ResultSet rs = null;
      	try {
      		stmt = conn.createStatement();
      		rs = stmt.executeQuery("select * from table1");
      		while (rs.next()) {
      			System.out.println(rs.getString(1) + "," + rs.getString(3));
      		}
      	} finally {
      		if (rs != null) rs.close();
      		if (stmt != null) stmt.close();
      		if (conn != null) conn.close();
      	}
      }
      

        Attachments

        1. TAJO-646_2.patch
          28 kB
          Jinho Kim
        2. TAJO-646.patch
          26 kB
          Hyoungjun Kim

          Activity

            People

            • Assignee:
              hjkim Hyoungjun Kim
              Reporter:
              hjkim Hyoungjun Kim
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: