You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Gary Yao (Jira)" <ji...@apache.org> on 2020/01/16 16:10:00 UTC
[jira] [Reopened] (FLINK-14075) Remove unnecessary resource close
in JDBCOutputFormatTest.java
[ https://issues.apache.org/jira/browse/FLINK-14075?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Gary Yao reopened FLINK-14075:
------------------------------
No commits were added under this ticket but resolution is 'fixed' with fixVersion = 1.10. I am reopening this ticket so that I can close it again with a different resolution.
> 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
> Priority: Minor
> 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.4#803005)