Canbin Zheng created FLINK-14075:
------------------------------------
Summary: Remove unnecessary resource close in JDBCOutputFormatTest.java
Key: FLINK-14075
URL:
https://issues.apache.org/jira/browse/FLINK-14075 Project: Flink
Issue Type: Improvement
Components: Connectors / JDBC
Reporter: Canbin Zheng
Fix For: 1.10.0
{code:java}
public void clearOutputTable() throws Exception {
Class.forName(DRIVER_CLASS);
try (
Connection conn = DriverManager.getConnection(DB_URL);
Statement stat = conn.createStatement()) {
stat.execute("DELETE FROM " + OUTPUT_TABLE);
stat.close();
conn.close();
}
}{code}
Unnecessary close of stat and conn can be removed.
--
This message was sent by Atlassian Jira
(v8.3.2#803003)