embulk-input-mongodb 0.3.1 → 0.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: b2a60bb559e33bfa9fb7e8f9f0b6453e070d995e
4
- data.tar.gz: b6da249c33d89b3a84d070f48e18a97243061bf5
3
+ metadata.gz: 9e8662a212da54dab9c41190514709db11ee5db3
4
+ data.tar.gz: e914845e6bdbf89e1bdf4f8c23f968f316cbd130
5
5
  SHA512:
6
- metadata.gz: 1c3a1f2a3ae383587c548d5e7fcae302eeb17275e784498958e04436fc3e86fc49f2aa4197d2fae3436c009425c9414d4ee1bb358fd9bd2811241b4484c5f644
7
- data.tar.gz: 89d72c6f271dfbfed98fbf5ffbbb72851cc4d48aaa4af202a1fb09fe07caaefd2f835b2a94ee7c3ac733992b5a3ec1233ace1ac45221fb50284263f20452387c
6
+ metadata.gz: 6031e390a789b9feefb3918eefdd051ac23ad7e95594d56d65dfbf6af034b9611437979cbc30f9bfb9fe9fe49d16323171a455b4ac4d7903c4b361353099182f
7
+ data.tar.gz: 2a2bd692dd0506b46036ebb10e50af514d1a251f72fc74d853995e7a1d28cb3ca68036fb26faab045862cc85ed25ec75344b761f60251b9220fb10aa5f37ad53
data/build.gradle CHANGED
@@ -17,7 +17,7 @@ configurations {
17
17
  provided
18
18
  }
19
19
 
20
- version = "0.3.1"
20
+ version = "0.3.2"
21
21
 
22
22
  sourceCompatibility = 1.7
23
23
  targetCompatibility = 1.7
@@ -119,7 +119,9 @@ public class ValueCodec implements Codec<Value>
119
119
  return newInteger(reader.readInt64());
120
120
  case DOCUMENT:
121
121
  return decode(reader, decoderContext);
122
- default: // e.g. MIN_KEY, MAX_KEY, SYMBOL, DB_POINTER, UNDEFINED
122
+ case SYMBOL:
123
+ return newString(reader.readSymbol());
124
+ default: // e.g. MIN_KEY, MAX_KEY, DB_POINTER, UNDEFINED
123
125
  throw new UnknownTypeFoundException(String.format("Unsupported type %s of '%s' field. Please exclude the field from 'projection:' option",
124
126
  reader.getCurrentBsonType(), reader.getCurrentName()));
125
127
  }
@@ -13,6 +13,7 @@ import org.bson.BsonMaxKey;
13
13
  import org.bson.BsonRegularExpression;
14
14
  import org.bson.BsonTimestamp;
15
15
  import org.bson.Document;
16
+ import org.bson.types.Symbol;
16
17
  import org.embulk.EmbulkTestRuntime;
17
18
  import org.embulk.config.ConfigException;
18
19
  import org.embulk.config.ConfigSource;
@@ -39,7 +40,6 @@ import java.text.SimpleDateFormat;
39
40
  import java.util.ArrayList;
40
41
  import java.util.Arrays;
41
42
  import java.util.List;
42
- import java.util.Locale;
43
43
  import java.util.TimeZone;
44
44
 
45
45
  import static org.hamcrest.CoreMatchers.is;
@@ -278,6 +278,7 @@ public class TestMongodbInputPlugin
278
278
  .append("timestamp_field", new BsonTimestamp(1463991177, 4))
279
279
  .append("int64_field", new BsonInt64(314159265))
280
280
  .append("document_field", new Document("k", true))
281
+ .append("symbol_field", new Symbol("symbol"))
281
282
  );
282
283
 
283
284
  documents.add(
@@ -324,6 +325,7 @@ public class TestMongodbInputPlugin
324
325
  assertEquals("1463991177", node.get("timestamp_field").asText());
325
326
  assertEquals(314159265L, node.get("int64_field").asLong());
326
327
  assertEquals("{\"k\":true}", node.get("document_field").toString());
328
+ assertEquals("symbol", node.get("symbol_field").asText());
327
329
  }
328
330
 
329
331
  {
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: embulk-input-mongodb
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.1
4
+ version: 0.3.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kazuyuki Honda
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-06-21 00:00:00.000000000 Z
11
+ date: 2016-06-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  requirement: !ruby/object:Gem::Requirement
@@ -67,7 +67,7 @@ files:
67
67
  - src/test/resources/id_field_name.yml
68
68
  - src/test/resources/id_field_name_expected.csv
69
69
  - src/test/resources/my_collection.jsonl
70
- - classpath/embulk-input-mongodb-0.3.1.jar
70
+ - classpath/embulk-input-mongodb-0.3.2.jar
71
71
  - classpath/mongo-java-driver-3.2.2.jar
72
72
  homepage: https://github.com/hakobera/embulk-input-mongodb
73
73
  licenses: