embulk-output-mailchimp 0.2.3 → 0.3.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (49) hide show
  1. checksums.yaml +4 -4
  2. data/.coveralls.yml +1 -1
  3. data/.gitignore +10 -3
  4. data/.travis.yml +4 -7
  5. data/CHANGELOG.md +18 -0
  6. data/README.md +18 -17
  7. data/build.gradle +124 -0
  8. data/ci/travis_mailchimp.yml +8 -0
  9. data/circle.yml +16 -0
  10. data/classpath/embulk-base-restclient-0.5.0.jar +0 -0
  11. data/classpath/embulk-output-mailchimp-0.3.2.jar +0 -0
  12. data/classpath/embulk-util-retryhelper-jetty92-0.5.0.jar +0 -0
  13. data/classpath/jetty-client-9.2.14.v20151106.jar +0 -0
  14. data/classpath/jetty-http-9.2.14.v20151106.jar +0 -0
  15. data/classpath/jetty-io-9.2.14.v20151106.jar +0 -0
  16. data/classpath/jetty-util-9.2.14.v20151106.jar +0 -0
  17. data/config/checkstyle/checkstyle.xml +128 -0
  18. data/config/checkstyle/default.xml +108 -0
  19. data/gradle/wrapper/gradle-wrapper.jar +0 -0
  20. data/gradle/wrapper/gradle-wrapper.properties +6 -0
  21. data/gradlew +160 -0
  22. data/gradlew.bat +90 -0
  23. data/lib/embulk/output/mailchimp.rb +3 -172
  24. data/src/main/java/org/embulk/output/mailchimp/MailChimpAbstractRecordBuffer.java +320 -0
  25. data/src/main/java/org/embulk/output/mailchimp/MailChimpHttpClient.java +151 -0
  26. data/src/main/java/org/embulk/output/mailchimp/MailChimpOutputPlugin.java +18 -0
  27. data/src/main/java/org/embulk/output/mailchimp/MailChimpOutputPluginDelegate.java +164 -0
  28. data/src/main/java/org/embulk/output/mailchimp/MailChimpRecordBuffer.java +174 -0
  29. data/src/main/java/org/embulk/output/mailchimp/helper/MailChimpHelper.java +70 -0
  30. data/src/main/java/org/embulk/output/mailchimp/model/AuthMethod.java +58 -0
  31. data/src/main/java/org/embulk/output/mailchimp/model/CategoriesResponse.java +30 -0
  32. data/src/main/java/org/embulk/output/mailchimp/model/ErrorResponse.java +56 -0
  33. data/src/main/java/org/embulk/output/mailchimp/model/InterestCategoriesResponse.java +24 -0
  34. data/src/main/java/org/embulk/output/mailchimp/model/InterestResponse.java +30 -0
  35. data/src/main/java/org/embulk/output/mailchimp/model/InterestsResponse.java +24 -0
  36. data/src/main/java/org/embulk/output/mailchimp/model/MemberStatus.java +64 -0
  37. data/src/main/java/org/embulk/output/mailchimp/model/MetaDataResponse.java +36 -0
  38. data/src/main/java/org/embulk/output/mailchimp/model/ReportResponse.java +105 -0
  39. data/src/main/java/org/embulk/output/mailchimp/validation/ColumnDataValidator.java +40 -0
  40. data/src/test/java/org/embulk/output/mailchimp/CircleCICredentials.java +22 -0
  41. data/src/test/java/org/embulk/output/mailchimp/TestColumnDataValidator.java +43 -0
  42. data/src/test/java/org/embulk/output/mailchimp/TestMailChimpHelper.java +54 -0
  43. data/src/test/java/org/embulk/output/mailchimp/TestMailChimpOutputPlugin.java +158 -0
  44. data/src/test/resources/csv/email.csv +2 -0
  45. metadata +55 -122
  46. data/.ruby-version +0 -1
  47. data/Gemfile +0 -2
  48. data/Rakefile +0 -29
  49. data/embulk-output-mailchimp.gemspec +0 -27
@@ -0,0 +1,40 @@
1
+ package org.embulk.output.mailchimp.validation;
2
+
3
+ import org.embulk.spi.Column;
4
+ import org.embulk.spi.Schema;
5
+
6
+ import java.util.Arrays;
7
+
8
+ /**
9
+ * An Util class to validate data based on @{@link Schema} to build data payload
10
+ * <p>
11
+ * Created by thangnc on 4/18/17.
12
+ */
13
+ public final class ColumnDataValidator
14
+ {
15
+ private ColumnDataValidator()
16
+ {
17
+ }
18
+
19
+ /**
20
+ * Check required columns. Should require `email` and `status` columns
21
+ *
22
+ * @param schema the schema
23
+ * @param allowColumns the columns
24
+ * @return the boolean
25
+ */
26
+ public static boolean checkExistColumns(final Schema schema, final String... allowColumns)
27
+ {
28
+ int found = 0;
29
+
30
+ for (Column column : schema.getColumns()) {
31
+ if (!Arrays.asList(allowColumns).contains(column.getName())) {
32
+ continue;
33
+ }
34
+
35
+ found++;
36
+ }
37
+
38
+ return found == allowColumns.length;
39
+ }
40
+ }
@@ -0,0 +1,22 @@
1
+ package org.embulk.output.mailchimp;
2
+
3
+ import org.embulk.EmbulkEmbed;
4
+ import org.embulk.config.ConfigSource;
5
+
6
+ /**
7
+ * Created by thangnc on 3/6/17.
8
+ */
9
+ public class CircleCICredentials
10
+ {
11
+ private CircleCICredentials()
12
+ {
13
+ }
14
+
15
+ public static ConfigSource credentials()
16
+ {
17
+ return EmbulkEmbed.newSystemConfigLoader().newConfigSource()
18
+ .set("apikey", System.getenv("MAILCHIMP_APIKEY"))
19
+ .set("access_token", System.getenv("MAILCHIMP_ACCESS_TOKEN"))
20
+ .set("list_id", System.getenv("MAILCHIMP_LIST_ID"));
21
+ }
22
+ }
@@ -0,0 +1,43 @@
1
+ package org.embulk.output.mailchimp;
2
+
3
+ import org.embulk.output.mailchimp.validation.ColumnDataValidator;
4
+ import org.embulk.spi.Schema;
5
+ import org.junit.Assert;
6
+ import org.junit.Test;
7
+
8
+ import static org.embulk.spi.type.Types.STRING;
9
+
10
+ /**
11
+ * Created by thangnc on 5/12/17.
12
+ */
13
+ public class TestColumnDataValidator
14
+ {
15
+ @Test
16
+ public void test_checkExistColumns_valid()
17
+ {
18
+ Schema schema = Schema.builder()
19
+ .add("email", STRING)
20
+ .add("fname", STRING)
21
+ .add("lname", STRING)
22
+ .add("status", STRING)
23
+ .build();
24
+
25
+ Assert.assertEquals("Column should be exists",
26
+ true,
27
+ ColumnDataValidator.checkExistColumns(schema, "status", "email"));
28
+ }
29
+
30
+ @Test
31
+ public void test_checkExistColumns_invalid()
32
+ {
33
+ Schema schema = Schema.builder()
34
+ .add("email", STRING)
35
+ .add("fname", STRING)
36
+ .add("lname", STRING)
37
+ .build();
38
+
39
+ Assert.assertEquals("Column should be not exist",
40
+ false,
41
+ ColumnDataValidator.checkExistColumns(schema, "status", "email"));
42
+ }
43
+ }
@@ -0,0 +1,54 @@
1
+ package org.embulk.output.mailchimp;
2
+
3
+ import com.fasterxml.jackson.databind.JsonNode;
4
+ import com.fasterxml.jackson.databind.node.JsonNodeFactory;
5
+ import com.google.common.collect.Multimap;
6
+ import org.junit.Test;
7
+
8
+ import java.util.ArrayList;
9
+ import java.util.Arrays;
10
+ import java.util.List;
11
+
12
+ import static org.embulk.output.mailchimp.helper.MailChimpHelper.containsCaseInsensitive;
13
+ import static org.embulk.output.mailchimp.helper.MailChimpHelper.extractMemberStatus;
14
+ import static org.embulk.output.mailchimp.helper.MailChimpHelper.maskEmail;
15
+ import static org.junit.Assert.assertEquals;
16
+
17
+ /**
18
+ * Created by thangnc on 4/26/17.
19
+ */
20
+ public class TestMailChimpHelper
21
+ {
22
+ @Test
23
+ public void test_maskEmail_validInErrorResponse()
24
+ {
25
+ String given = "thang0001@example.com looks fake or invalid, please enter a real email address.";
26
+ String expect = "t******01@example.com looks fake or invalid, please enter a real email address.";
27
+ assertEquals("Email should match", expect, maskEmail(given));
28
+ }
29
+
30
+ @Test
31
+ public void test_containsCaseInsensitive_validMergeFields()
32
+ {
33
+ String expect = "United State";
34
+ assertEquals("Interest category should match", expect, containsCaseInsensitive("united state",
35
+ Arrays.asList("Donating", "United State")));
36
+ }
37
+
38
+ @Test
39
+ public void test_extractMemberStatus()
40
+ {
41
+ List<JsonNode> given = new ArrayList<>();
42
+ given.add(JsonNodeFactory.instance.objectNode().put("status", "subcribed").put("email", "thang@gmail.com"));
43
+ given.add(JsonNodeFactory.instance.objectNode().put("status", "pending").put("email", "thang123@gmail.com"));
44
+ given.add(JsonNodeFactory.instance.objectNode().put("status", "abc").put("email", "thang456@gmail.com"));
45
+ given.add(JsonNodeFactory.instance.objectNode().put("status", "pending").put("email", "thang789@gmail.com"));
46
+ given.add(JsonNodeFactory.instance.objectNode().put("status", "subcribed").put("email", "thang000@gmail.com"));
47
+
48
+ Multimap<String, JsonNode> statusMap = extractMemberStatus(given);
49
+ assertEquals("Status should match", 3, statusMap.keySet().size());
50
+ assertEquals("Status should contain keys", true, statusMap.containsKey("pending"));
51
+ assertEquals("Status should contain keys", true, statusMap.containsKey("subcribed"));
52
+ assertEquals("Status should contain keys", true, statusMap.containsKey("abc"));
53
+ }
54
+ }
@@ -0,0 +1,158 @@
1
+ package org.embulk.output.mailchimp;
2
+
3
+ import com.fasterxml.jackson.databind.ObjectMapper;
4
+ import com.fasterxml.jackson.datatype.guava.GuavaModule;
5
+ import com.fasterxml.jackson.datatype.joda.JodaModule;
6
+ import com.google.common.base.Throwables;
7
+ import com.google.common.collect.Lists;
8
+ import org.embulk.EmbulkTestRuntime;
9
+ import org.embulk.config.ConfigException;
10
+ import org.embulk.config.ConfigLoader;
11
+ import org.embulk.config.ConfigSource;
12
+ import org.embulk.config.ModelManager;
13
+ import org.embulk.config.TaskReport;
14
+ import org.embulk.config.TaskSource;
15
+ import org.embulk.spi.Exec;
16
+ import org.embulk.spi.OutputPlugin;
17
+ import org.embulk.spi.Schema;
18
+ import org.embulk.spi.TransactionalPageOutput;
19
+ import org.junit.After;
20
+ import org.junit.Before;
21
+ import org.junit.Rule;
22
+ import org.junit.Test;
23
+
24
+ import java.io.File;
25
+ import java.io.IOException;
26
+ import java.util.List;
27
+
28
+ import static com.google.common.base.Strings.isNullOrEmpty;
29
+ import static org.embulk.spi.type.Types.STRING;
30
+ import static org.hamcrest.Matchers.is;
31
+ import static org.junit.Assume.assumeThat;
32
+
33
+ /**
34
+ * Created by thangnc on 4/14/17.
35
+ */
36
+ public class TestMailChimpOutputPlugin
37
+ {
38
+ @Rule
39
+ public EmbulkTestRuntime runtime = new EmbulkTestRuntime();
40
+
41
+ private ConfigSource baseConfig;
42
+ private MailChimpOutputPluginDelegate.PluginTask task;
43
+ private MailChimpOutputPlugin plugin;
44
+
45
+ @Before
46
+ public void setup()
47
+ {
48
+ plugin = new MailChimpOutputPlugin();
49
+ baseConfig = config();
50
+ task = baseConfig.loadConfig(MailChimpOutputPluginDelegate.PluginTask.class);
51
+ }
52
+
53
+ @After
54
+ public void teardown()
55
+ {
56
+ }
57
+
58
+ @Test(expected = ConfigException.class)
59
+ public void test_config_invalidWithEmptyApiKey()
60
+ {
61
+ ConfigSource config = baseConfig.set("apikey", "");
62
+ doSetUpSchemaAndRun(config, plugin);
63
+ }
64
+
65
+ @Test(expected = ConfigException.class)
66
+ public void test_config_invalidWithNullApiKey()
67
+ {
68
+ ConfigSource config = baseConfig.set("apikey", null);
69
+ doSetUpSchemaAndRun(config, plugin);
70
+ }
71
+
72
+ @Test(expected = ConfigException.class)
73
+ public void test_config_invalidWithEmptyAccessToken()
74
+ {
75
+ ConfigSource config = baseConfig.set("auth_method", "oauth")
76
+ .set("access_token", "");
77
+ doSetUpSchemaAndRun(config, plugin);
78
+ }
79
+
80
+ @Test(expected = ConfigException.class)
81
+ public void test_config_invalidWithNullAccessToken()
82
+ {
83
+ ConfigSource config = baseConfig.set("auth_method", "oauth")
84
+ .set("access_token", null);
85
+ doSetUpSchemaAndRun(config, plugin);
86
+ }
87
+
88
+ @Test(expected = ConfigException.class)
89
+ public void test_config_invalidWithNullListId()
90
+ {
91
+ ConfigSource config = baseConfig.set("list_id", null);
92
+ doSetUpSchemaAndRun(config, plugin);
93
+ }
94
+
95
+ @Test(expected = ConfigException.class)
96
+ public void test_config_invalidWithEmptyListId()
97
+ {
98
+ ConfigSource config = baseConfig.set("list_id", "");
99
+ doSetUpSchemaAndRun(config, plugin);
100
+ }
101
+
102
+ @Test(expected = ConfigException.class)
103
+ public void test_config_invalidWithColumnEmailRequires()
104
+ {
105
+ ConfigSource config = baseConfig;
106
+ Schema schema = Schema.builder()
107
+ .add("fname", STRING)
108
+ .add("lname", STRING)
109
+ .build();
110
+
111
+ final TransactionalPageOutput output = plugin.open(task.dump(), schema, 0);
112
+ output.finish();
113
+
114
+ plugin.transaction(config, schema, 0, new OutputControl());
115
+ }
116
+
117
+ /**
118
+ * Load plugin config with Guava & Joda support
119
+ */
120
+ private static ConfigSource config()
121
+ {
122
+ String path = System.getenv("EMBULK_OUTPUT_MAILCHIMP_TEST_CONFIG");
123
+ assumeThat(isNullOrEmpty(path), is(false));
124
+ try {
125
+ ObjectMapper mapper = new ObjectMapper()
126
+ .registerModule(new GuavaModule())
127
+ .registerModule(new JodaModule());
128
+ ConfigLoader configLoader = new ConfigLoader(new ModelManager(null, mapper));
129
+ return configLoader.fromYamlFile(new File(path));
130
+ }
131
+ catch (IOException ex) {
132
+ throw Throwables.propagate(ex);
133
+ }
134
+ }
135
+
136
+ private class OutputControl implements OutputPlugin.Control
137
+ {
138
+ @Override
139
+ public List<TaskReport> run(TaskSource taskSource)
140
+ {
141
+ return Lists.newArrayList(Exec.newTaskReport());
142
+ }
143
+ }
144
+
145
+ private void doSetUpSchemaAndRun(final ConfigSource config, final MailChimpOutputPlugin plugin)
146
+ {
147
+ Schema schema = Schema.builder()
148
+ .add("email", STRING)
149
+ .add("fname", STRING)
150
+ .add("lname", STRING)
151
+ .build();
152
+
153
+ final TransactionalPageOutput output = plugin.open(task.dump(), schema, 0);
154
+ output.finish();
155
+
156
+ plugin.transaction(config, schema, 0, new OutputControl());
157
+ }
158
+ }
@@ -0,0 +1,2 @@
1
+ email;fistname;lastname;favorite;type
2
+ hi@example.com;first_name;last_name;music,book;middle
metadata CHANGED
@@ -1,76 +1,33 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: embulk-output-mailchimp
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.3
4
+ version: 0.3.2
5
5
  platform: ruby
6
6
  authors:
7
- - uu59
8
- - takkanm
7
+ - Thang Nguyen
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2016-03-24 00:00:00.000000000 Z
11
+ date: 2017-05-30 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  requirement: !ruby/object:Gem::Requirement
16
15
  requirements:
17
- - - "~>"
16
+ - - ~>
18
17
  - !ruby/object:Gem::Version
19
- version: 2.0.6
20
- name: mailchimp-api
21
- prerelease: false
22
- type: :runtime
23
- version_requirements: !ruby/object:Gem::Requirement
24
- requirements:
25
- - - "~>"
26
- - !ruby/object:Gem::Version
27
- version: 2.0.6
28
- - !ruby/object:Gem::Dependency
29
- requirement: !ruby/object:Gem::Requirement
30
- requirements:
31
- - - "~>"
32
- - !ruby/object:Gem::Version
33
- version: '0.3'
34
- name: perfect_retry
35
- prerelease: false
36
- type: :runtime
37
- version_requirements: !ruby/object:Gem::Requirement
38
- requirements:
39
- - - "~>"
40
- - !ruby/object:Gem::Version
41
- version: '0.3'
42
- - !ruby/object:Gem::Dependency
43
- requirement: !ruby/object:Gem::Requirement
44
- requirements:
45
- - - "~>"
46
- - !ruby/object:Gem::Version
47
- version: 0.7.9
48
- name: embulk
49
- prerelease: false
50
- type: :development
51
- version_requirements: !ruby/object:Gem::Requirement
52
- requirements:
53
- - - "~>"
54
- - !ruby/object:Gem::Version
55
- version: 0.7.9
56
- - !ruby/object:Gem::Dependency
57
- requirement: !ruby/object:Gem::Requirement
58
- requirements:
59
- - - "~>"
60
- - !ruby/object:Gem::Version
61
- version: 1.10.6
18
+ version: '1.0'
62
19
  name: bundler
63
20
  prerelease: false
64
21
  type: :development
65
22
  version_requirements: !ruby/object:Gem::Requirement
66
23
  requirements:
67
- - - "~>"
24
+ - - ~>
68
25
  - !ruby/object:Gem::Version
69
- version: 1.10.6
26
+ version: '1.0'
70
27
  - !ruby/object:Gem::Dependency
71
28
  requirement: !ruby/object:Gem::Requirement
72
29
  requirements:
73
- - - ">="
30
+ - - '>='
74
31
  - !ruby/object:Gem::Version
75
32
  version: '10.0'
76
33
  name: rake
@@ -78,88 +35,64 @@ dependencies:
78
35
  type: :development
79
36
  version_requirements: !ruby/object:Gem::Requirement
80
37
  requirements:
81
- - - ">="
38
+ - - '>='
82
39
  - !ruby/object:Gem::Version
83
40
  version: '10.0'
84
- - !ruby/object:Gem::Dependency
85
- requirement: !ruby/object:Gem::Requirement
86
- requirements:
87
- - - ">="
88
- - !ruby/object:Gem::Version
89
- version: '0'
90
- name: test-unit
91
- prerelease: false
92
- type: :development
93
- version_requirements: !ruby/object:Gem::Requirement
94
- requirements:
95
- - - ">="
96
- - !ruby/object:Gem::Version
97
- version: '0'
98
- - !ruby/object:Gem::Dependency
99
- requirement: !ruby/object:Gem::Requirement
100
- requirements:
101
- - - ">="
102
- - !ruby/object:Gem::Version
103
- version: '0'
104
- name: test-unit-rr
105
- prerelease: false
106
- type: :development
107
- version_requirements: !ruby/object:Gem::Requirement
108
- requirements:
109
- - - ">="
110
- - !ruby/object:Gem::Version
111
- version: '0'
112
- - !ruby/object:Gem::Dependency
113
- requirement: !ruby/object:Gem::Requirement
114
- requirements:
115
- - - ">="
116
- - !ruby/object:Gem::Version
117
- version: '0.9'
118
- name: simplecov
119
- prerelease: false
120
- type: :development
121
- version_requirements: !ruby/object:Gem::Requirement
122
- requirements:
123
- - - ">="
124
- - !ruby/object:Gem::Version
125
- version: '0.9'
126
- - !ruby/object:Gem::Dependency
127
- requirement: !ruby/object:Gem::Requirement
128
- requirements:
129
- - - ">="
130
- - !ruby/object:Gem::Version
131
- version: '0'
132
- name: coveralls
133
- prerelease: false
134
- type: :development
135
- version_requirements: !ruby/object:Gem::Requirement
136
- requirements:
137
- - - ">="
138
- - !ruby/object:Gem::Version
139
- version: '0'
140
- description: Dumps records to Mailchimp.
41
+ description: Dumps records to MailChimp.
141
42
  email:
142
- - k@uu59.org
143
- - takkanm@gmail.com
43
+ - thang@treasure-data.com
144
44
  executables: []
145
45
  extensions: []
146
46
  extra_rdoc_files: []
147
47
  files:
148
- - ".coveralls.yml"
149
- - ".gitignore"
150
- - ".ruby-version"
151
- - ".travis.yml"
48
+ - .coveralls.yml
49
+ - .gitignore
50
+ - .travis.yml
152
51
  - CHANGELOG.md
153
- - Gemfile
154
52
  - LICENSE.txt
155
53
  - README.md
156
- - Rakefile
157
- - embulk-output-mailchimp.gemspec
54
+ - build.gradle
55
+ - ci/travis_mailchimp.yml
56
+ - circle.yml
57
+ - config/checkstyle/checkstyle.xml
58
+ - config/checkstyle/default.xml
59
+ - gradle/wrapper/gradle-wrapper.jar
60
+ - gradle/wrapper/gradle-wrapper.properties
61
+ - gradlew
62
+ - gradlew.bat
158
63
  - lib/embulk/output/mailchimp.rb
64
+ - src/main/java/org/embulk/output/mailchimp/MailChimpAbstractRecordBuffer.java
65
+ - src/main/java/org/embulk/output/mailchimp/MailChimpHttpClient.java
66
+ - src/main/java/org/embulk/output/mailchimp/MailChimpOutputPlugin.java
67
+ - src/main/java/org/embulk/output/mailchimp/MailChimpOutputPluginDelegate.java
68
+ - src/main/java/org/embulk/output/mailchimp/MailChimpRecordBuffer.java
69
+ - src/main/java/org/embulk/output/mailchimp/helper/MailChimpHelper.java
70
+ - src/main/java/org/embulk/output/mailchimp/model/AuthMethod.java
71
+ - src/main/java/org/embulk/output/mailchimp/model/CategoriesResponse.java
72
+ - src/main/java/org/embulk/output/mailchimp/model/ErrorResponse.java
73
+ - src/main/java/org/embulk/output/mailchimp/model/InterestCategoriesResponse.java
74
+ - src/main/java/org/embulk/output/mailchimp/model/InterestResponse.java
75
+ - src/main/java/org/embulk/output/mailchimp/model/InterestsResponse.java
76
+ - src/main/java/org/embulk/output/mailchimp/model/MemberStatus.java
77
+ - src/main/java/org/embulk/output/mailchimp/model/MetaDataResponse.java
78
+ - src/main/java/org/embulk/output/mailchimp/model/ReportResponse.java
79
+ - src/main/java/org/embulk/output/mailchimp/validation/ColumnDataValidator.java
80
+ - src/test/java/org/embulk/output/mailchimp/CircleCICredentials.java
81
+ - src/test/java/org/embulk/output/mailchimp/TestColumnDataValidator.java
82
+ - src/test/java/org/embulk/output/mailchimp/TestMailChimpHelper.java
83
+ - src/test/java/org/embulk/output/mailchimp/TestMailChimpOutputPlugin.java
84
+ - src/test/resources/csv/email.csv
159
85
  - test/embulk/output/test_mailchimp.rb
160
86
  - test/override_assert_raise.rb
161
87
  - test/run-test.rb
162
- homepage:
88
+ - classpath/embulk-base-restclient-0.5.0.jar
89
+ - classpath/embulk-output-mailchimp-0.3.2.jar
90
+ - classpath/embulk-util-retryhelper-jetty92-0.5.0.jar
91
+ - classpath/jetty-client-9.2.14.v20151106.jar
92
+ - classpath/jetty-http-9.2.14.v20151106.jar
93
+ - classpath/jetty-io-9.2.14.v20151106.jar
94
+ - classpath/jetty-util-9.2.14.v20151106.jar
95
+ homepage: https://github.com/treasure-data/embulk-output-mailchimp
163
96
  licenses:
164
97
  - MIT
165
98
  metadata: {}
@@ -169,17 +102,17 @@ require_paths:
169
102
  - lib
170
103
  required_ruby_version: !ruby/object:Gem::Requirement
171
104
  requirements:
172
- - - ">="
105
+ - - '>='
173
106
  - !ruby/object:Gem::Version
174
107
  version: '0'
175
108
  required_rubygems_version: !ruby/object:Gem::Requirement
176
109
  requirements:
177
- - - ">="
110
+ - - '>='
178
111
  - !ruby/object:Gem::Version
179
112
  version: '0'
180
113
  requirements: []
181
114
  rubyforge_project:
182
- rubygems_version: 2.4.8
115
+ rubygems_version: 2.1.9
183
116
  signing_key:
184
117
  specification_version: 4
185
118
  summary: Mailchimp output plugin for Embulk
data/.ruby-version DELETED
@@ -1 +0,0 @@
1
- jruby-9.0.0.0
data/Gemfile DELETED
@@ -1,2 +0,0 @@
1
- source 'https://rubygems.org/'
2
- gemspec
data/Rakefile DELETED
@@ -1,29 +0,0 @@
1
- require "bundler/gem_tasks"
2
-
3
- task default: :build
4
-
5
- task 'clean' do
6
- Dir.glob("pkg/*.gem").each do |name|
7
- sh "rm #{name}"
8
- end
9
- end
10
-
11
- task 'reload' do
12
- spec = Bundler::GemHelper.gemspec
13
-
14
- sh "embulk gem uninstall #{spec.name}"
15
- Rake::Task['clean'].execute
16
- Rake::Task['build'].execute
17
- sh "embulk gem install pkg/#{spec.name}-#{spec.version}.gem"
18
- end
19
-
20
- desc 'Run tests'
21
- task :test do
22
- ruby("test/run-test.rb", "--use-color=yes", "--collector=dir")
23
- end
24
-
25
- desc "Run tests with coverage"
26
- task :cov do
27
- ENV["COVERAGE"] = "1"
28
- ruby("--debug", "test/run-test.rb", "--use-color=yes", "--collector=dir")
29
- end
@@ -1,27 +0,0 @@
1
-
2
- Gem::Specification.new do |spec|
3
- spec.name = "embulk-output-mailchimp"
4
- spec.version = "0.2.3"
5
- spec.authors = ["uu59", "takkanm"]
6
- spec.summary = "Mailchimp output plugin for Embulk"
7
- spec.description = "Dumps records to Mailchimp."
8
- spec.email = ["k@uu59.org", "takkanm@gmail.com"]
9
- spec.licenses = ["MIT"]
10
- # TODO set this: spec.homepage = "https://github.com/takkanm/embulk-output-mailchimp"
11
-
12
- spec.files = `git ls-files`.split("\n") + Dir["classpath/*.jar"]
13
- spec.test_files = spec.files.grep(%r{^(test|spec)/})
14
- spec.require_paths = ["lib"]
15
-
16
- #spec.add_dependency 'YOUR_GEM_DEPENDENCY', ['~> YOUR_GEM_DEPENDENCY_VERSION']
17
- spec.add_dependency 'mailchimp-api', ['~> 2.0.6']
18
- spec.add_dependency 'perfect_retry', "~> 0.3"
19
-
20
- spec.add_development_dependency 'embulk', ['~> 0.7.9']
21
- spec.add_development_dependency 'bundler', ['~> 1.10.6']
22
- spec.add_development_dependency 'rake', ['>= 10.0']
23
- spec.add_development_dependency 'test-unit'
24
- spec.add_development_dependency 'test-unit-rr'
25
- spec.add_development_dependency 'simplecov', ['>= 0.9']
26
- spec.add_development_dependency 'coveralls'
27
- end