embulk 0.8.22 → 0.8.23
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 +4 -4
- data/build.gradle +1 -1
- data/embulk-core/src/main/java/org/embulk/spi/PageReader.java +9 -0
- data/embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-oneline-tr.png +0 -0
- data/embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-oneline-wt.png +0 -0
- data/embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-oneline.ai +395 -1
- data/embulk-docs/src/_static/{embulk-logo.png → embulk-logo-v2/embulk-logo-v2-sq-tr-small.png} +0 -0
- data/embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-sq-tr.png +0 -0
- data/embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-sq-wt.png +0 -0
- data/embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-sq.ai +417 -0
- data/embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-sq.svg +1 -0
- data/embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-symbol-tr.png +0 -0
- data/embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-symbol-wt.png +0 -0
- data/embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-symbol.ai +394 -1
- data/embulk-docs/src/built-in.rst +1 -1
- data/embulk-docs/src/index.rst +3 -1
- data/embulk-docs/src/logo.rst +27 -0
- data/embulk-docs/src/release.rst +1 -1
- data/embulk-docs/src/release/release-0.8.23.rst +14 -0
- data/embulk-standards/src/main/java/org/embulk/standards/JsonParserPlugin.java +8 -0
- data/lib/embulk/guess/json.rb +13 -3
- data/lib/embulk/version.rb +1 -1
- metadata +18 -6
|
@@ -949,7 +949,7 @@ Example
|
|
|
949
949
|
...
|
|
950
950
|
|
|
951
951
|
Preview executor
|
|
952
|
-
|
|
952
|
+
----------------
|
|
953
953
|
|
|
954
954
|
The preview executor is called by ``preview`` command. It tries to read sample buffer from a specified input source and writes them to Page objects. ``preview`` outputs the Page objects to console.
|
|
955
955
|
|
data/embulk-docs/src/index.rst
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
Embulk
|
|
7
7
|
==================================
|
|
8
8
|
|
|
9
|
-
.. image:: _static/embulk-logo.png
|
|
9
|
+
.. image:: _static/embulk-logo-v2/embulk-logo-v2-sq-tr-small.png
|
|
10
10
|
:width: 512px
|
|
11
11
|
:target: https://github.com/embulk/embulk
|
|
12
12
|
|
|
@@ -75,6 +75,8 @@ Documents
|
|
|
75
75
|
|
|
76
76
|
release
|
|
77
77
|
|
|
78
|
+
logo
|
|
79
|
+
|
|
78
80
|
For developers
|
|
79
81
|
---------------
|
|
80
82
|
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
Logo
|
|
2
|
+
===========================
|
|
3
|
+
|
|
4
|
+
Feel free to use these logos on your slides, blog posts, etc!
|
|
5
|
+
|
|
6
|
+
Square
|
|
7
|
+
------------------
|
|
8
|
+
|
|
9
|
+
.. image:: _static/embulk-logo-v2/embulk-logo-v2-sq-tr.png
|
|
10
|
+
:scale: 30 %
|
|
11
|
+
|
|
12
|
+
Horizontal
|
|
13
|
+
------------------
|
|
14
|
+
|
|
15
|
+
.. image:: _static/embulk-logo-v2/embulk-logo-v2-oneline-tr.png
|
|
16
|
+
:scale: 30 %
|
|
17
|
+
|
|
18
|
+
Icon
|
|
19
|
+
------------------
|
|
20
|
+
|
|
21
|
+
.. image:: _static/embulk-logo-v2/embulk-logo-v2-symbol-tr.png
|
|
22
|
+
:scale: 30 %
|
|
23
|
+
|
|
24
|
+
Links
|
|
25
|
+
------------------
|
|
26
|
+
|
|
27
|
+
* `Full list of files <https://github.com/embulk/embulk/tree/master/embulk-docs/src/_static/embulk-logo-v2/>`_
|
data/embulk-docs/src/release.rst
CHANGED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
Release 0.8.23
|
|
2
|
+
==================================
|
|
3
|
+
|
|
4
|
+
General Changes
|
|
5
|
+
------------------
|
|
6
|
+
|
|
7
|
+
* PageReader#get{String,Timestamp,Json} calls #isNull to return null. [#654]
|
|
8
|
+
* Ignore JsonParseException in JSON guess if JsonGuessPlugin could parse at least one JSON. [#659]
|
|
9
|
+
* Ignore JsonParseException in JSON preview if at least one JSON is already parsed. [#661]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
Release Date
|
|
13
|
+
------------------
|
|
14
|
+
2017-06-06
|
|
@@ -65,6 +65,7 @@ public class JsonParserPlugin
|
|
|
65
65
|
try (PageBuilder pageBuilder = newPageBuilder(schema, output);
|
|
66
66
|
FileInputInputStream in = new FileInputInputStream(input)) {
|
|
67
67
|
while (in.nextFile()) {
|
|
68
|
+
boolean evenOneJsonParsed = false;
|
|
68
69
|
try (JsonParser.Stream stream = newJsonStream(in)) {
|
|
69
70
|
Value value;
|
|
70
71
|
while ((value = stream.next()) != null) {
|
|
@@ -76,6 +77,7 @@ public class JsonParserPlugin
|
|
|
76
77
|
|
|
77
78
|
pageBuilder.setJson(column, value);
|
|
78
79
|
pageBuilder.addRecord();
|
|
80
|
+
evenOneJsonParsed = true;
|
|
79
81
|
}
|
|
80
82
|
catch (JsonRecordValidateException e) {
|
|
81
83
|
if (stopOnInvalidRecord) {
|
|
@@ -86,6 +88,12 @@ public class JsonParserPlugin
|
|
|
86
88
|
}
|
|
87
89
|
}
|
|
88
90
|
catch (IOException | JsonParseException e) {
|
|
91
|
+
if (Exec.isPreview() && evenOneJsonParsed) {
|
|
92
|
+
// JsonParseException occurs when it cannot parse the last part of sampling buffer. Because
|
|
93
|
+
// the last part is sometimes invalid as JSON data. Therefore JsonParseException can be
|
|
94
|
+
// ignore in preview if at least one JSON is already parsed.
|
|
95
|
+
break;
|
|
96
|
+
}
|
|
89
97
|
throw new DataException(e);
|
|
90
98
|
}
|
|
91
99
|
}
|
data/lib/embulk/guess/json.rb
CHANGED
|
@@ -16,14 +16,24 @@ module Embulk
|
|
|
16
16
|
|
|
17
17
|
# Use org.embulk.spi.json.JsonParser to respond to multi-line Json
|
|
18
18
|
json_parser = new_json_parser(sample_buffer)
|
|
19
|
+
one_json_parsed = false
|
|
19
20
|
begin
|
|
20
|
-
while json_parser.next
|
|
21
|
+
while (v = json_parser.next)
|
|
22
|
+
# "v" needs to be JSON object type (isMapValue) because:
|
|
23
|
+
# 1) Single-column CSV can be mis-guessed as JSON if JSON non-objects are accepted.
|
|
24
|
+
# 2) JsonParserPlugin accepts only the JSON object type.
|
|
25
|
+
raise JsonParseException.new("v must be JSON object type") unless v.isMapValue
|
|
26
|
+
one_json_parsed = true
|
|
21
27
|
end
|
|
22
28
|
rescue JsonParseException
|
|
23
|
-
|
|
29
|
+
# the exception is ignored
|
|
24
30
|
end
|
|
25
31
|
|
|
26
|
-
|
|
32
|
+
if one_json_parsed
|
|
33
|
+
return {"parser" => {"type" => "json"}} # if JsonParser can parse even one JSON data
|
|
34
|
+
else
|
|
35
|
+
return {}
|
|
36
|
+
end
|
|
27
37
|
end
|
|
28
38
|
|
|
29
39
|
private
|
data/lib/embulk/version.rb
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
module Embulk
|
|
4
4
|
@@warned = false
|
|
5
5
|
|
|
6
|
-
VERSION_INTERNAL = '0.8.
|
|
6
|
+
VERSION_INTERNAL = '0.8.23'
|
|
7
7
|
|
|
8
8
|
DEPRECATED_MESSAGE = 'Embulk::VERSION in (J)Ruby is deprecated. Use org.embulk.EmbulkVersion::VERSION instead. If this message is from a plugin, please tell this to the author of the plugin!'
|
|
9
9
|
def self.const_missing(name)
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: embulk
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.8.
|
|
4
|
+
version: 0.8.23
|
|
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-06 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: jruby-jars
|
|
@@ -110,9 +110,9 @@ files:
|
|
|
110
110
|
- classpath/commons-compress-1.10.jar
|
|
111
111
|
- classpath/commons-lang-2.4.jar
|
|
112
112
|
- classpath/commons-lang3-3.4.jar
|
|
113
|
-
- classpath/embulk-cli-0.8.
|
|
114
|
-
- classpath/embulk-core-0.8.
|
|
115
|
-
- classpath/embulk-standards-0.8.
|
|
113
|
+
- classpath/embulk-cli-0.8.23.jar
|
|
114
|
+
- classpath/embulk-core-0.8.23.jar
|
|
115
|
+
- classpath/embulk-standards-0.8.23.jar
|
|
116
116
|
- classpath/guava-18.0.jar
|
|
117
117
|
- classpath/guice-4.0.jar
|
|
118
118
|
- classpath/guice-bootstrap-0.1.1.jar
|
|
@@ -361,13 +361,24 @@ files:
|
|
|
361
361
|
- embulk-docs/make.bat
|
|
362
362
|
- embulk-docs/push-gh-pages.sh
|
|
363
363
|
- embulk-docs/src/_static/embulk-architecture.png
|
|
364
|
-
- embulk-docs/src/_static/embulk-logo.png
|
|
364
|
+
- embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-oneline-tr.png
|
|
365
|
+
- embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-oneline-wt.png
|
|
366
|
+
- embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-oneline.ai
|
|
367
|
+
- embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-sq-tr-small.png
|
|
368
|
+
- embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-sq-tr.png
|
|
369
|
+
- embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-sq-wt.png
|
|
370
|
+
- embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-sq.ai
|
|
371
|
+
- embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-sq.svg
|
|
372
|
+
- embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-symbol-tr.png
|
|
373
|
+
- embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-symbol-wt.png
|
|
374
|
+
- embulk-docs/src/_static/embulk-logo-v2/embulk-logo-v2-symbol.ai
|
|
365
375
|
- embulk-docs/src/_static/embulk-logo.svg
|
|
366
376
|
- embulk-docs/src/built-in.rst
|
|
367
377
|
- embulk-docs/src/conf.py
|
|
368
378
|
- embulk-docs/src/customization.rst
|
|
369
379
|
- embulk-docs/src/developers/index.rst
|
|
370
380
|
- embulk-docs/src/index.rst
|
|
381
|
+
- embulk-docs/src/logo.rst
|
|
371
382
|
- embulk-docs/src/recipe.rst
|
|
372
383
|
- embulk-docs/src/recipe/scheduled-csv-load-to-elasticsearch-kibana5.rst
|
|
373
384
|
- embulk-docs/src/release.rst
|
|
@@ -450,6 +461,7 @@ files:
|
|
|
450
461
|
- embulk-docs/src/release/release-0.8.20.rst
|
|
451
462
|
- embulk-docs/src/release/release-0.8.21.rst
|
|
452
463
|
- embulk-docs/src/release/release-0.8.22.rst
|
|
464
|
+
- embulk-docs/src/release/release-0.8.23.rst
|
|
453
465
|
- embulk-docs/src/release/release-0.8.3.rst
|
|
454
466
|
- embulk-docs/src/release/release-0.8.4.rst
|
|
455
467
|
- embulk-docs/src/release/release-0.8.5.rst
|