embulk-output-postgresql 0.4.1 → 0.4.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,40 +1,39 @@
1
- package org.embulk.output.postgresql;
2
-
3
- import java.util.Properties;
4
- import java.sql.Driver;
5
- import java.sql.Connection;
6
- import java.sql.SQLException;
7
- import org.embulk.output.jdbc.JdbcOutputConnector;
8
- import org.embulk.output.jdbc.JdbcOutputConnection;
9
-
10
- public class PostgreSQLOutputConnector
11
- implements JdbcOutputConnector
12
- {
13
- private static final Driver driver = new org.postgresql.Driver();
14
-
15
- private final String url;
16
- private final Properties properties;
17
- private final String schemaName;
18
-
19
- public PostgreSQLOutputConnector(String url, Properties properties, String schemaName)
20
- {
21
- this.url = url;
22
- this.properties = properties;
23
- this.schemaName = schemaName;
24
- }
25
-
26
- @Override
27
- public PostgreSQLOutputConnection connect(boolean autoCommit) throws SQLException
28
- {
29
- Connection c = driver.connect(url, properties);
30
- try {
31
- PostgreSQLOutputConnection con = new PostgreSQLOutputConnection(c, schemaName, autoCommit);
32
- c = null;
33
- return con;
34
- } finally {
35
- if (c != null) {
36
- c.close();
37
- }
38
- }
39
- }
40
- }
1
+ package org.embulk.output.postgresql;
2
+
3
+ import java.util.Properties;
4
+ import java.sql.Driver;
5
+ import java.sql.Connection;
6
+ import java.sql.SQLException;
7
+ import org.embulk.output.jdbc.JdbcOutputConnector;
8
+
9
+ public class PostgreSQLOutputConnector
10
+ implements JdbcOutputConnector
11
+ {
12
+ private static final Driver driver = new org.postgresql.Driver();
13
+
14
+ private final String url;
15
+ private final Properties properties;
16
+ private final String schemaName;
17
+
18
+ public PostgreSQLOutputConnector(String url, Properties properties, String schemaName)
19
+ {
20
+ this.url = url;
21
+ this.properties = properties;
22
+ this.schemaName = schemaName;
23
+ }
24
+
25
+ @Override
26
+ public PostgreSQLOutputConnection connect(boolean autoCommit) throws SQLException
27
+ {
28
+ Connection c = driver.connect(url, properties);
29
+ try {
30
+ PostgreSQLOutputConnection con = new PostgreSQLOutputConnection(c, schemaName, autoCommit);
31
+ c = null;
32
+ return con;
33
+ } finally {
34
+ if (c != null) {
35
+ c.close();
36
+ }
37
+ }
38
+ }
39
+ }
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: embulk-output-postgresql
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.1
4
+ version: 0.4.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sadayuki Furuhashi
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-07-06 00:00:00.000000000 Z
11
+ date: 2015-12-08 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Inserts or updates records to a table.
14
14
  email:
@@ -25,13 +25,9 @@ files:
25
25
  - src/main/java/org/embulk/output/postgresql/PostgreSQLCopyBatchInsert.java
26
26
  - src/main/java/org/embulk/output/postgresql/PostgreSQLOutputConnection.java
27
27
  - src/main/java/org/embulk/output/postgresql/PostgreSQLOutputConnector.java
28
- - classpath/embulk-output-jdbc-0.4.1.jar
29
- - classpath/embulk-output-postgresql-0.4.1.jar
30
- - classpath/jna-4.1.0.jar
31
- - classpath/jna-platform-4.1.0.jar
32
- - classpath/postgresql-9.4-1200-jdbc41.jar
33
- - classpath/slf4j-simple-1.7.7.jar
34
- - classpath/waffle-jna-1.7.jar
28
+ - classpath/embulk-output-jdbc-0.4.2.jar
29
+ - classpath/embulk-output-postgresql-0.4.2.jar
30
+ - classpath/postgresql-9.4-1205-jdbc41.jar
35
31
  homepage: https://github.com/embulk/embulk-output-jdbc
36
32
  licenses:
37
33
  - Apache 2.0
Binary file
Binary file
Binary file
Binary file
Binary file