embulk-input-mysql 0.8.3 → 0.8.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/classpath/{embulk-input-jdbc-0.8.3.jar → embulk-input-jdbc-0.8.4.jar} +0 -0
- data/classpath/embulk-input-mysql-0.8.4.jar +0 -0
- data/src/main/java/org/embulk/input/MySQLInputPlugin.java +20 -15
- data/src/main/java/org/embulk/input/mysql/MySQLInputConnection.java +15 -0
- metadata +4 -4
- data/classpath/embulk-input-mysql-0.8.3.jar +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e95b049dedfd17520d5aec37672353c4c79b1e0f
|
4
|
+
data.tar.gz: cc6e270fae22085306a866f4fb614f77f7f30d88
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 97f583757f6ec44fba8f2eb4103bffdb09aef579e4745c1121c09a8194c98503a49d31d33e7e7fbe34af3629f8b2f427d09af020e5afcce98c060937c7ab7ba7
|
7
|
+
data.tar.gz: 282b89a3573cc9145fddd2ff7bc181a212ed516c769a7df4d9f84a84349bd3eeddaa8275547b35dab47e4c607960ad8fce1f75c0525325e55342772bdac66254
|
Binary file
|
Binary file
|
@@ -12,6 +12,7 @@ import com.mysql.jdbc.TimeUtil;
|
|
12
12
|
import org.embulk.config.Config;
|
13
13
|
import org.embulk.config.ConfigDefault;
|
14
14
|
import org.embulk.input.jdbc.AbstractJdbcInputPlugin;
|
15
|
+
import org.embulk.input.jdbc.Ssl;
|
15
16
|
import org.embulk.input.jdbc.JdbcInputConnection;
|
16
17
|
import org.embulk.input.jdbc.getter.ColumnGetterFactory;
|
17
18
|
import org.embulk.input.mysql.MySQLInputConnection;
|
@@ -42,6 +43,10 @@ public class MySQLInputPlugin
|
|
42
43
|
|
43
44
|
@Config("database")
|
44
45
|
public String getDatabase();
|
46
|
+
|
47
|
+
@Config("ssl")
|
48
|
+
@ConfigDefault("\"disable\"") // backward compatibility
|
49
|
+
public Ssl getSsl();
|
45
50
|
}
|
46
51
|
|
47
52
|
@Override
|
@@ -75,21 +80,21 @@ public class MySQLInputPlugin
|
|
75
80
|
// Socket options TCP_KEEPCNT, TCP_KEEPIDLE, and TCP_KEEPINTVL are not configurable.
|
76
81
|
props.setProperty("tcpKeepAlive", "true");
|
77
82
|
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
83
|
+
switch (t.getSsl()) {
|
84
|
+
case DISABLE:
|
85
|
+
props.setProperty("useSSL", "false");
|
86
|
+
break;
|
87
|
+
case ENABLE:
|
88
|
+
props.setProperty("useSSL", "true");
|
89
|
+
props.setProperty("requireSSL", "true");
|
90
|
+
props.setProperty("verifyServerCertificate", "false");
|
91
|
+
break;
|
92
|
+
case VERIFY:
|
93
|
+
props.setProperty("useSSL", "true");
|
94
|
+
props.setProperty("requireSSL", "true");
|
95
|
+
props.setProperty("verifyServerCertificate", "true");
|
96
|
+
break;
|
97
|
+
}
|
93
98
|
|
94
99
|
if (t.getFetchRows() == 1) {
|
95
100
|
logger.info("Fetch size is 1. Fetching rows one by one.");
|
@@ -67,4 +67,19 @@ public class MySQLInputConnection
|
|
67
67
|
timeZoneComparison.compareTimeZone();
|
68
68
|
}
|
69
69
|
|
70
|
+
//
|
71
|
+
//
|
72
|
+
// The MySQL Connector/J 5.1.35 introduce new option `Current MySQL Connect`.
|
73
|
+
// It has incompatibility behavior current version and 5.1.35.
|
74
|
+
//
|
75
|
+
// This method announces users about this change before the update driver version.
|
76
|
+
//
|
77
|
+
@Override
|
78
|
+
public void showDriverVersion() throws SQLException {
|
79
|
+
super.showDriverVersion();
|
80
|
+
logger.warn("This plugin will update MySQL Connector/J version in the near future release.");
|
81
|
+
logger.warn("It has some incompatibility changes.");
|
82
|
+
logger.warn("For example, the 5.1.35 introduced `noTimezoneConversionForDateType` and `cacheDefaultTimezone` options.");
|
83
|
+
logger.warn("Please read a document and make sure configuration carefully before updating the plugin.");
|
84
|
+
}
|
70
85
|
}
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: embulk-input-mysql
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.8.
|
4
|
+
version: 0.8.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sadayuki Furuhashi
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-06-23 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: Selects records from a table.
|
14
14
|
email:
|
@@ -19,8 +19,8 @@ extra_rdoc_files: []
|
|
19
19
|
files:
|
20
20
|
- README.md
|
21
21
|
- build.gradle
|
22
|
-
- classpath/embulk-input-jdbc-0.8.
|
23
|
-
- classpath/embulk-input-mysql-0.8.
|
22
|
+
- classpath/embulk-input-jdbc-0.8.4.jar
|
23
|
+
- classpath/embulk-input-mysql-0.8.4.jar
|
24
24
|
- classpath/mysql-connector-java-5.1.34.jar
|
25
25
|
- lib/embulk/input/mysql.rb
|
26
26
|
- src/main/java/org/embulk/input/MySQLInputPlugin.java
|
Binary file
|