pdi 2.0.0.pre.alpha → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +1 -1
- data/README.md +1 -1
- data/lib/pdi/spoon.rb +2 -2
- data/lib/pdi/version.rb +1 -1
- data/spec/pdi/executor_spec.rb +1 -1
- data/spec/pdi/spoon_spec.rb +3 -8
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f99b35960e8b34b16146e824e1970fc9e9d39e0f7b982f850f62c6ff67e1e2cf
|
4
|
+
data.tar.gz: b81e3b25c302c3505f23d60d15872ea2497245601bd69a7252d3f6e5fa5d9704
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3b0994605738f6643ad5ef0320529a8b6d87964e4690322c75de42fac8711c2f53b579cab759d7ff3c21eb97ba93c645058a365ef3d6f9f625cec739c5e04e74
|
7
|
+
data.tar.gz: b843cc9261b0997b23a241f89f327f208d9e7ef11e9728c854155ef5921940fea69e1ca84108e4f7733d4fb1a8457493f556999b30576ec2ca146a625a5f8981
|
data/CHANGELOG.md
CHANGED
data/README.md
CHANGED
@@ -50,7 +50,7 @@ Notes:
|
|
50
50
|
|
51
51
|
* You can also override the names of the scripts using the `kitchen` and `pan` constructor keyword arguments. The defaults are `kitchen.sh` and `pan.sh`, respectively.
|
52
52
|
* For other command line arguments that are not supported first-class in the Options objects below you can utilize the `args` argument when instantiating a `Spoon` instance.
|
53
|
-
* Another optional argument is `timeout_in_seconds`. If set it will ensure the sub-process runs within a given window. If it times out the sub-process will be terminated and a Timeout::Error will be raised.
|
53
|
+
* Another optional argument is `timeout_in_seconds`. It is set to `nil` by default which means there is no timeout. If set it will ensure the sub-process runs within a given window. If it times out the sub-process will be terminated and a Timeout::Error will be raised.
|
54
54
|
|
55
55
|
### Executing a Job/Transformation
|
56
56
|
|
data/lib/pdi/spoon.rb
CHANGED
@@ -24,7 +24,7 @@ module Pdi
|
|
24
24
|
Options::Type::TRANSFORMATION => PanError
|
25
25
|
}.freeze
|
26
26
|
|
27
|
-
attr_reader :args, :dir, :kitchen, :pan
|
27
|
+
attr_reader :args, :dir, :executor, :kitchen, :pan
|
28
28
|
|
29
29
|
def initialize(
|
30
30
|
args: [],
|
@@ -73,7 +73,7 @@ module Pdi
|
|
73
73
|
|
74
74
|
private
|
75
75
|
|
76
|
-
attr_reader :
|
76
|
+
attr_reader :parser
|
77
77
|
|
78
78
|
def error_constant(options)
|
79
79
|
TYPES_TO_ERRORS.fetch(options.type)
|
data/lib/pdi/version.rb
CHANGED
data/spec/pdi/executor_spec.rb
CHANGED
@@ -24,7 +24,7 @@ describe Pdi::Executor do
|
|
24
24
|
|
25
25
|
# This will run a script that will take 30 seconds to process, but by limiting the
|
26
26
|
# timeout using the #run argument, it should raise an error after one second.
|
27
|
-
it 'times out and kills process after
|
27
|
+
it 'times out and kills process after 1 second' do
|
28
28
|
args = [script, thirty_seconds]
|
29
29
|
|
30
30
|
expect { subject.run(args) }.to raise_error(Timeout::Error)
|
data/spec/pdi/spoon_spec.rb
CHANGED
@@ -15,15 +15,10 @@ describe Pdi::Spoon do
|
|
15
15
|
let(:dir) { File.join(*mocks_dir) }
|
16
16
|
|
17
17
|
describe '#initialize' do
|
18
|
-
it 'sets
|
18
|
+
it 'sets Executor#timeout_in_seconds' do
|
19
19
|
timeout_in_seconds = 987
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
# Private/internal testing is not recommended, but I really wanted to ensure
|
24
|
-
# this class is properly configuring the Executor instance, that way I can rely
|
25
|
-
# mainly on the Executor unit tests instead of integration tests at this level.
|
26
|
-
executor = subject.send('executor')
|
20
|
+
subject = described_class.new(dir: dir, timeout_in_seconds: timeout_in_seconds)
|
21
|
+
executor = subject.executor
|
27
22
|
|
28
23
|
expect(executor.timeout_in_seconds).to eq(timeout_in_seconds)
|
29
24
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pdi
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.0
|
4
|
+
version: 2.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Matthew Ruggio
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-05-
|
11
|
+
date: 2020-05-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: acts_as_hashable
|
@@ -185,9 +185,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
185
185
|
version: 2.3.8
|
186
186
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
187
187
|
requirements:
|
188
|
-
- - "
|
188
|
+
- - ">="
|
189
189
|
- !ruby/object:Gem::Version
|
190
|
-
version:
|
190
|
+
version: '0'
|
191
191
|
requirements: []
|
192
192
|
rubygems_version: 3.0.3
|
193
193
|
signing_key:
|