embulk-output-redshift 0.3.0 → 0.4.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f739710245a2663409cf49beb31c8e18cb148684
4
- data.tar.gz: fe5268568d22eed5d8fc40e9117684ba5989a715
3
+ metadata.gz: d9ca4eb2942aae5f463bf611914d8cf76393ab7d
4
+ data.tar.gz: f65aa7a7ee215d13437567609be6233ed538f2dd
5
5
  SHA512:
6
- metadata.gz: 9d8808f711394ed62b840faa26d1472f871e7c7e71b069b9279a5342b1580b9d496c8d1103984f97e942a715d16f91bd402a2baed03c3dc68625d0727761064b
7
- data.tar.gz: a65ba3a389a4f3e80cc179c18d5ed0d8e0e62a550776dd73b0888ae4b2832ccd96f9b3e680d202723ab667d4104aaa62af25dc7e9e51699634dc767d0f578701
6
+ metadata.gz: c0f0fc9b9270cff6e50456594bd41ea87b4e5f89f55faf0709dbc40263ebdf63497528174e759b901dfab7ad6e5bf024a84abf91472274cddbe691cbfe5bdba5
7
+ data.tar.gz: 136189a5e9b844cc5c9a8bb87a39e176a69db3544ee717735bbfd7e1190bba03bc4aa5c1df5cd7841457f7a07728b3f101af807cc196b93374b6bcaed27bfdbb
data/README.md CHANGED
@@ -20,12 +20,12 @@ Redshift output plugins for Embulk loads records to Redshift.
20
20
  - **options**: extra connection properties (hash, default: {})
21
21
  - **mode**: "replace" or "insert" (string, required)
22
22
  - **batch_size**: size of a single batch insert (integer, default: 16777216)
23
- - **default_timezone**: If input column type (embulk type) is timestamp and destination column type is `string` or `nstring`, this plugin needs to format the timestamp into a string. This default_timezone option is used to control the timezone. You can overwrite timezone for each columns using column_options option. (string, default: `UTC`)
23
+ - **default_timezone**: If input column type (embulk type) is timestamp, this plugin needs to format the timestamp into a SQL string. This default_timezone option is used to control the timezone. You can overwrite timezone for each columns using column_options option. (string, default: `UTC`)
24
24
  - **column_options**: advanced: a key-value pairs where key is a column name and value is options for the column.
25
25
  - **type**: type of a column when this plugin creates new tables (e.g. `VARCHAR(255)`, `INTEGER NOT NULL UNIQUE`). This used when this plugin creates intermediate tables (insert, truncate_insert and merge modes), when it creates the target table (insert_direct and replace modes), and when it creates nonexistent target table automatically. (string, default: depends on input column type. `BIGINT` if input column type is long, `BOOLEAN` if boolean, `DOUBLE PRECISION` if double, `CLOB` if string, `TIMESTAMP` if timestamp)
26
26
  - **value_type**: This plugin converts input column type (embulk type) into a database type to build a INSERT statement. This value_type option controls the type of the value in a INSERT statement. (string, default: depends on input column type. Available values options are: `byte`, `short`, `int`, `long`, `double`, `float`, `boolean`, `string`, `nstring`, `date`, `time`, `timestamp`, `decimal`, `null`, `pass`)
27
27
  - **timestamp_format**: If input column type (embulk type) is timestamp and value_type is `string` or `nstring`, this plugin needs to format the timestamp value into a string. This timestamp_format option is used to control the format of the timestamp. (string, default: `%Y-%m-%d %H:%M:%S.%6N`)
28
- - **timezone**: If input column type (embulk type) is timestamp and value_type is `string` or `nstring`, this plugin needs to format the timestamp value into a string. And if the input column type is timestamp and value_type is `date`, this plugin needs to consider timezone. In those cases, this timezone option is used to control the timezone. (string, value of default_timezone option is used by default)
28
+ - **timezone**: If input column type (embulk type) is timestamp, this plugin needs to format the timestamp value into a SQL string. In this cases, this timezone option is used to control the timezone. (string, value of default_timezone option is used by default)
29
29
 
30
30
  ### Modes
31
31
 
@@ -42,7 +42,7 @@ Redshift output plugins for Embulk loads records to Redshift.
42
42
  * Transactional: Yes.
43
43
  * Resumable: Yes.
44
44
  * **merge**:
45
- * Behavior: This mode writes rows to some intermediate tables first. If all those tasks run correctly, runs `INSERT INTO <target_table> SELECT * FROM <intermediate_table_1> UNION ALL SELECT * FROM <intermediate_table_2> UNION ALL ... ON DUPLICATE KEY UPDATE ...` query.
45
+ * Behavior: This mode writes rows to some intermediate tables first. If all those tasks run correctly, runs `with updated AS (UPDATE .... RETURNING ...) INSERT INTO ....` query.
46
46
  * Transactional: Yes.
47
47
  * Resumable: Yes.
48
48
  * **replace**:
@@ -44,7 +44,7 @@ public class RedshiftCopyBatchInsert
44
44
  private long totalRows;
45
45
  private int fileCount;
46
46
 
47
- public static final String COPY_AFTER_FROM = "GZIP DELIMITER '\\t' NULL '\\N' ESCAPE TRUNCATECOLUMNS ACCEPTINVCHARS STATUPDATE OFF COMPUPDATE OFF";
47
+ public static final String COPY_AFTER_FROM = "GZIP DELIMITER '\\t' NULL '\\\\N' ESCAPE TRUNCATECOLUMNS ACCEPTINVCHARS STATUPDATE OFF COMPUPDATE OFF";
48
48
 
49
49
  public RedshiftCopyBatchInsert(RedshiftOutputConnector connector,
50
50
  AWSCredentialsProvider credentialsProvider, String s3BucketName,
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: embulk-output-redshift
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.4.0
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-05-19 00:00:00.000000000 Z
11
+ date: 2015-06-11 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Inserts or updates records to a table.
14
14
  email:
@@ -30,13 +30,14 @@ files:
30
30
  - classpath/aws-java-sdk-sts-1.9.17.jar
31
31
  - classpath/commons-codec-1.6.jar
32
32
  - classpath/commons-logging-1.1.3.jar
33
- - classpath/embulk-output-jdbc-0.3.0.jar
34
- - classpath/embulk-output-postgresql-0.3.0.jar
35
- - classpath/embulk-output-redshift-0.3.0.jar
33
+ - classpath/embulk-output-jdbc-0.4.0.jar
34
+ - classpath/embulk-output-postgresql-0.4.0.jar
35
+ - classpath/embulk-output-redshift-0.4.0.jar
36
36
  - classpath/httpclient-4.3.4.jar
37
37
  - classpath/httpcore-4.3.2.jar
38
38
  - classpath/jna-4.1.0.jar
39
39
  - classpath/jna-platform-4.1.0.jar
40
+ - classpath/joda-time-2.8.jar
40
41
  - classpath/postgresql-9.4-1200-jdbc41.jar
41
42
  - classpath/slf4j-simple-1.7.7.jar
42
43
  - classpath/waffle-jna-1.7.jar