ripe 0.2.0 → 0.2.1
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/.travis.yml +0 -5
- data/Guardfile +2 -4
- data/README.md +1 -0
- data/bin/ripe +1 -59
- data/lib/ripe.rb +8 -1
- data/lib/ripe/blocks.rb +13 -0
- data/lib/ripe/blocks/block.rb +142 -0
- data/lib/ripe/blocks/liquid_block.rb +48 -0
- data/lib/ripe/blocks/multi_block.rb +71 -0
- data/lib/ripe/blocks/parallel_block.rb +29 -0
- data/lib/ripe/blocks/serial_block.rb +61 -0
- data/lib/ripe/blocks/working_block.rb +101 -0
- data/lib/ripe/cli.rb +121 -0
- data/lib/ripe/cli/helper.rb +31 -0
- data/lib/ripe/db.rb +7 -0
- data/lib/ripe/db/task.rb +42 -0
- data/lib/ripe/db/task_migration.rb +33 -0
- data/lib/ripe/db/worker.rb +64 -0
- data/lib/ripe/db/worker_migration.rb +41 -0
- data/lib/ripe/dsl.rb +2 -4
- data/lib/ripe/dsl/task_dsl.rb +4 -2
- data/lib/ripe/dsl/workflow_dsl.rb +5 -0
- data/lib/ripe/library.rb +34 -45
- data/lib/ripe/repo.rb +24 -23
- data/lib/ripe/version.rb +1 -1
- data/lib/ripe/worker_controller.rb +72 -144
- data/lib/ripe/worker_controller/preparer.rb +172 -0
- data/lib/ripe/worker_controller/syncer.rb +118 -0
- data/spec/cli_spec.rb +14 -0
- data/spec/library_spec.rb +18 -18
- data/spec/spec_helper.rb +2 -0
- data/spec/testpack.rb +16 -5
- data/spec/testpack/.ripe/meta.db +0 -0
- data/spec/testpack/.ripe/tasks/bar.sh +3 -0
- data/spec/testpack/{ripe → .ripe}/tasks/foo.sh +0 -0
- data/spec/testpack/.ripe/workers/1/1.sh +16 -0
- data/spec/testpack/.ripe/workers/1/2.sh +16 -0
- data/spec/testpack/.ripe/workers/1/job.sh +54 -0
- data/spec/testpack/.ripe/workers/2/3.sh +16 -0
- data/spec/testpack/.ripe/workers/2/4.sh +16 -0
- data/spec/testpack/.ripe/workers/2/job.sh +54 -0
- data/spec/testpack/.ripe/workers/3/5.sh +16 -0
- data/spec/testpack/.ripe/workers/3/6.sh +16 -0
- data/spec/testpack/.ripe/workers/3/job.sh +54 -0
- data/spec/testpack/.ripe/workflows/foobar.rb +23 -0
- data/spec/testpack/{case/Sample1 → Sample1}/bar_output.txt +0 -0
- data/spec/testpack/{case/Sample1 → Sample1}/foo_input.txt +0 -0
- data/spec/testpack/{case/Sample1 → Sample1}/foo_output.txt +0 -0
- data/spec/testpack/{case/Sample2 → Sample2}/bar_output.txt +0 -0
- data/spec/testpack/{case/Sample2 → Sample2}/foo_input.txt +0 -0
- data/spec/testpack/{case/Sample2 → Sample2}/foo_output.txt +0 -0
- data/spec/testpack/{case/Sample3 → Sample3}/bar_output.txt +0 -0
- data/spec/testpack/{case/Sample3 → Sample3}/foo_input.txt +0 -0
- data/spec/testpack/{case/Sample3 → Sample3}/foo_output.txt +0 -0
- data/spec/worker_controller_spec.rb +143 -0
- metadata +66 -40
- data/lib/ripe/block.rb +0 -41
- data/lib/ripe/liquid_block.rb +0 -17
- data/lib/ripe/multi_block.rb +0 -35
- data/lib/ripe/parallel_block.rb +0 -13
- data/lib/ripe/serial_block.rb +0 -37
- data/lib/ripe/task.rb +0 -21
- data/lib/ripe/task_migration.rb +0 -18
- data/lib/ripe/worker.rb +0 -44
- data/lib/ripe/worker_migration.rb +0 -26
- data/lib/ripe/working_block.rb +0 -41
- data/spec/block_spec.rb +0 -7
- data/spec/ripe_spec.rb +0 -7
- data/spec/testpack/ripe/tasks/bar.sh +0 -3
- data/spec/testpack/ripe/workflows/foobar.rb +0 -23
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
|
|
3
|
+
#PBS -N 1
|
|
4
|
+
#PBS -A abc-012-ab
|
|
5
|
+
#PBS -q debug
|
|
6
|
+
#PBS -l nodes=1:ppn=1
|
|
7
|
+
#PBS -l walltime=5:00
|
|
8
|
+
#PBS -o .ripe/workers/1/job.stdout
|
|
9
|
+
#PBS -e .ripe/workers/1/job.stderr
|
|
10
|
+
#PBS -V
|
|
11
|
+
|
|
12
|
+
cd "/Users/nicolas.dejay/Dropbox/Code/ripe/spec/testpack"
|
|
13
|
+
|
|
14
|
+
(
|
|
15
|
+
(
|
|
16
|
+
|
|
17
|
+
# <foo.sh>
|
|
18
|
+
|
|
19
|
+
INPUT_FOO="Sample1/foo_input.txt"
|
|
20
|
+
FOO_MESSAGE="For You"
|
|
21
|
+
OUTPUT_FOO="Sample1/foo_output.txt"
|
|
22
|
+
LOG=".ripe/workers/1/1.log"
|
|
23
|
+
|
|
24
|
+
exec 1>"$LOG" 2>&1
|
|
25
|
+
|
|
26
|
+
# Foo is certainly one of the most important prerequisites to Bar.
|
|
27
|
+
|
|
28
|
+
echo "$(cat "$INPUT_FOO") $FOO_MESSAGE" > "$OUTPUT_FOO"
|
|
29
|
+
|
|
30
|
+
echo "##.DONE.##"
|
|
31
|
+
|
|
32
|
+
# </foo.sh>
|
|
33
|
+
|
|
34
|
+
) ; (
|
|
35
|
+
|
|
36
|
+
# <bar.sh>
|
|
37
|
+
|
|
38
|
+
INPUT_BAR="Sample1/foo_input.txt"
|
|
39
|
+
BAR_MESSAGE="Bar"
|
|
40
|
+
OUTPUT_BAR="Sample1/bar_output.txt"
|
|
41
|
+
LOG=".ripe/workers/1/2.log"
|
|
42
|
+
|
|
43
|
+
exec 1>"$LOG" 2>&1
|
|
44
|
+
|
|
45
|
+
# Bar is the most important consequence of Foo.
|
|
46
|
+
|
|
47
|
+
echo "$(cut -d' ' -f1 "$INPUT_BAR") $BAR_MESSAGE" > "$OUTPUT_BAR"
|
|
48
|
+
|
|
49
|
+
echo "##.DONE.##"
|
|
50
|
+
|
|
51
|
+
# </bar.sh>
|
|
52
|
+
|
|
53
|
+
)
|
|
54
|
+
)
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
|
|
2
|
+
# <foo.sh>
|
|
3
|
+
|
|
4
|
+
INPUT_FOO="Sample2/foo_input.txt"
|
|
5
|
+
FOO_MESSAGE="For You"
|
|
6
|
+
OUTPUT_FOO="Sample2/foo_output.txt"
|
|
7
|
+
|
|
8
|
+
exec 1>"$LOG" 2>&1
|
|
9
|
+
|
|
10
|
+
# Foo is certainly one of the most important prerequisites to Bar.
|
|
11
|
+
|
|
12
|
+
echo "$(cat "$INPUT_FOO") $FOO_MESSAGE" > "$OUTPUT_FOO"
|
|
13
|
+
|
|
14
|
+
echo "##.DONE.##"
|
|
15
|
+
|
|
16
|
+
# </foo.sh>
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
|
|
2
|
+
# <bar.sh>
|
|
3
|
+
|
|
4
|
+
INPUT_BAR="Sample2/foo_input.txt"
|
|
5
|
+
BAR_MESSAGE="Bar"
|
|
6
|
+
OUTPUT_BAR="Sample2/bar_output.txt"
|
|
7
|
+
|
|
8
|
+
exec 1>"$LOG" 2>&1
|
|
9
|
+
|
|
10
|
+
# Bar is the most important consequence of Foo.
|
|
11
|
+
|
|
12
|
+
echo "$(cut -d' ' -f1 "$INPUT_BAR") $BAR_MESSAGE" > "$OUTPUT_BAR"
|
|
13
|
+
|
|
14
|
+
echo "##.DONE.##"
|
|
15
|
+
|
|
16
|
+
# </bar.sh>
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
|
|
3
|
+
#PBS -N 2
|
|
4
|
+
#PBS -A abc-012-ab
|
|
5
|
+
#PBS -q debug
|
|
6
|
+
#PBS -l nodes=1:ppn=1
|
|
7
|
+
#PBS -l walltime=5:00
|
|
8
|
+
#PBS -o .ripe/workers/2/job.stdout
|
|
9
|
+
#PBS -e .ripe/workers/2/job.stderr
|
|
10
|
+
#PBS -V
|
|
11
|
+
|
|
12
|
+
cd "/Users/nicolas.dejay/Dropbox/Code/ripe/spec/testpack"
|
|
13
|
+
|
|
14
|
+
(
|
|
15
|
+
(
|
|
16
|
+
|
|
17
|
+
# <foo.sh>
|
|
18
|
+
|
|
19
|
+
INPUT_FOO="Sample2/foo_input.txt"
|
|
20
|
+
FOO_MESSAGE="For You"
|
|
21
|
+
OUTPUT_FOO="Sample2/foo_output.txt"
|
|
22
|
+
LOG=".ripe/workers/2/3.log"
|
|
23
|
+
|
|
24
|
+
exec 1>"$LOG" 2>&1
|
|
25
|
+
|
|
26
|
+
# Foo is certainly one of the most important prerequisites to Bar.
|
|
27
|
+
|
|
28
|
+
echo "$(cat "$INPUT_FOO") $FOO_MESSAGE" > "$OUTPUT_FOO"
|
|
29
|
+
|
|
30
|
+
echo "##.DONE.##"
|
|
31
|
+
|
|
32
|
+
# </foo.sh>
|
|
33
|
+
|
|
34
|
+
) ; (
|
|
35
|
+
|
|
36
|
+
# <bar.sh>
|
|
37
|
+
|
|
38
|
+
INPUT_BAR="Sample2/foo_input.txt"
|
|
39
|
+
BAR_MESSAGE="Bar"
|
|
40
|
+
OUTPUT_BAR="Sample2/bar_output.txt"
|
|
41
|
+
LOG=".ripe/workers/2/4.log"
|
|
42
|
+
|
|
43
|
+
exec 1>"$LOG" 2>&1
|
|
44
|
+
|
|
45
|
+
# Bar is the most important consequence of Foo.
|
|
46
|
+
|
|
47
|
+
echo "$(cut -d' ' -f1 "$INPUT_BAR") $BAR_MESSAGE" > "$OUTPUT_BAR"
|
|
48
|
+
|
|
49
|
+
echo "##.DONE.##"
|
|
50
|
+
|
|
51
|
+
# </bar.sh>
|
|
52
|
+
|
|
53
|
+
)
|
|
54
|
+
)
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
|
|
2
|
+
# <foo.sh>
|
|
3
|
+
|
|
4
|
+
INPUT_FOO="Sample3/foo_input.txt"
|
|
5
|
+
FOO_MESSAGE="For You"
|
|
6
|
+
OUTPUT_FOO="Sample3/foo_output.txt"
|
|
7
|
+
|
|
8
|
+
exec 1>"$LOG" 2>&1
|
|
9
|
+
|
|
10
|
+
# Foo is certainly one of the most important prerequisites to Bar.
|
|
11
|
+
|
|
12
|
+
echo "$(cat "$INPUT_FOO") $FOO_MESSAGE" > "$OUTPUT_FOO"
|
|
13
|
+
|
|
14
|
+
echo "##.DONE.##"
|
|
15
|
+
|
|
16
|
+
# </foo.sh>
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
|
|
2
|
+
# <bar.sh>
|
|
3
|
+
|
|
4
|
+
INPUT_BAR="Sample3/foo_input.txt"
|
|
5
|
+
BAR_MESSAGE="Bar"
|
|
6
|
+
OUTPUT_BAR="Sample3/bar_output.txt"
|
|
7
|
+
|
|
8
|
+
exec 1>"$LOG" 2>&1
|
|
9
|
+
|
|
10
|
+
# Bar is the most important consequence of Foo.
|
|
11
|
+
|
|
12
|
+
echo "$(cut -d' ' -f1 "$INPUT_BAR") $BAR_MESSAGE" > "$OUTPUT_BAR"
|
|
13
|
+
|
|
14
|
+
echo "##.DONE.##"
|
|
15
|
+
|
|
16
|
+
# </bar.sh>
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
|
|
3
|
+
#PBS -N 3
|
|
4
|
+
#PBS -A abc-012-ab
|
|
5
|
+
#PBS -q debug
|
|
6
|
+
#PBS -l nodes=1:ppn=1
|
|
7
|
+
#PBS -l walltime=5:00
|
|
8
|
+
#PBS -o .ripe/workers/3/job.stdout
|
|
9
|
+
#PBS -e .ripe/workers/3/job.stderr
|
|
10
|
+
#PBS -V
|
|
11
|
+
|
|
12
|
+
cd "/Users/nicolas.dejay/Dropbox/Code/ripe/spec/testpack"
|
|
13
|
+
|
|
14
|
+
(
|
|
15
|
+
(
|
|
16
|
+
|
|
17
|
+
# <foo.sh>
|
|
18
|
+
|
|
19
|
+
INPUT_FOO="Sample3/foo_input.txt"
|
|
20
|
+
FOO_MESSAGE="For You"
|
|
21
|
+
OUTPUT_FOO="Sample3/foo_output.txt"
|
|
22
|
+
LOG=".ripe/workers/3/5.log"
|
|
23
|
+
|
|
24
|
+
exec 1>"$LOG" 2>&1
|
|
25
|
+
|
|
26
|
+
# Foo is certainly one of the most important prerequisites to Bar.
|
|
27
|
+
|
|
28
|
+
echo "$(cat "$INPUT_FOO") $FOO_MESSAGE" > "$OUTPUT_FOO"
|
|
29
|
+
|
|
30
|
+
echo "##.DONE.##"
|
|
31
|
+
|
|
32
|
+
# </foo.sh>
|
|
33
|
+
|
|
34
|
+
) ; (
|
|
35
|
+
|
|
36
|
+
# <bar.sh>
|
|
37
|
+
|
|
38
|
+
INPUT_BAR="Sample3/foo_input.txt"
|
|
39
|
+
BAR_MESSAGE="Bar"
|
|
40
|
+
OUTPUT_BAR="Sample3/bar_output.txt"
|
|
41
|
+
LOG=".ripe/workers/3/6.log"
|
|
42
|
+
|
|
43
|
+
exec 1>"$LOG" 2>&1
|
|
44
|
+
|
|
45
|
+
# Bar is the most important consequence of Foo.
|
|
46
|
+
|
|
47
|
+
echo "$(cut -d' ' -f1 "$INPUT_BAR") $BAR_MESSAGE" > "$OUTPUT_BAR"
|
|
48
|
+
|
|
49
|
+
echo "##.DONE.##"
|
|
50
|
+
|
|
51
|
+
# </bar.sh>
|
|
52
|
+
|
|
53
|
+
)
|
|
54
|
+
)
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
workflow 'foobar' do
|
|
2
|
+
param :node_count, 1
|
|
3
|
+
param :ppn, 1
|
|
4
|
+
param :project_name, 'abc-012-ab'
|
|
5
|
+
param :queue, 'debug'
|
|
6
|
+
param :walltime, '5:00'
|
|
7
|
+
|
|
8
|
+
describe do |sample, params|
|
|
9
|
+
foo = task 'foo' do
|
|
10
|
+
param :input_foo, "#{sample}/foo_input.txt"
|
|
11
|
+
param :foo_message, 'For You'
|
|
12
|
+
param :output_foo, "#{sample}/foo_output.txt"
|
|
13
|
+
end
|
|
14
|
+
|
|
15
|
+
bar = task 'bar' do
|
|
16
|
+
param :input_bar, "#{sample}/foo_input.txt"
|
|
17
|
+
param :bar_message, 'Bar'
|
|
18
|
+
param :output_bar, "#{sample}/bar_output.txt"
|
|
19
|
+
end
|
|
20
|
+
|
|
21
|
+
foo + bar
|
|
22
|
+
end
|
|
23
|
+
end
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
require 'spec_helper'
|
|
2
|
+
|
|
3
|
+
include Ripe::DSL # required by dirty hack +WorkerController#prepare+
|
|
4
|
+
|
|
5
|
+
require 'digest'
|
|
6
|
+
require 'fileutils'
|
|
7
|
+
|
|
8
|
+
def signature(file)
|
|
9
|
+
Digest::MD5.hexdigest(File.read(file))
|
|
10
|
+
end
|
|
11
|
+
|
|
12
|
+
describe WorkerController do
|
|
13
|
+
context 'when RIPELIB contains the test library' do
|
|
14
|
+
before :all do
|
|
15
|
+
@test = TestPack.new
|
|
16
|
+
|
|
17
|
+
@oldwd = Dir.pwd
|
|
18
|
+
@tmpdir = Dir.mktmpdir 'ripe'
|
|
19
|
+
Dir.chdir(@tmpdir)
|
|
20
|
+
|
|
21
|
+
ENV['RIPELIB'] = @test.lib_path
|
|
22
|
+
@repo = Repo.new
|
|
23
|
+
@repo.attach_or_create
|
|
24
|
+
@library = Library
|
|
25
|
+
@controller = @repo.controller
|
|
26
|
+
|
|
27
|
+
@test.samples.each do |sample|
|
|
28
|
+
FileUtils.mkdir_p(sample)
|
|
29
|
+
@test.steps.each do |step|
|
|
30
|
+
source = "#{@test.path}/#{sample}/#{step}"
|
|
31
|
+
dest = "#{sample}/#{step}"
|
|
32
|
+
FileUtils.cp(source, dest)
|
|
33
|
+
end
|
|
34
|
+
end
|
|
35
|
+
end
|
|
36
|
+
|
|
37
|
+
after :all do
|
|
38
|
+
FileUtils.rm_r("#{@tmpdir}")
|
|
39
|
+
Dir.chdir(@oldwd)
|
|
40
|
+
end
|
|
41
|
+
|
|
42
|
+
describe '#prepare' do
|
|
43
|
+
it 'prepares workers' do
|
|
44
|
+
workers = @controller.prepare 'foobar', @test.samples, pwd: @test.path, mode: :force
|
|
45
|
+
# Prepares workers 1-2-3
|
|
46
|
+
expect(DB::Worker.all.length).to eql 3
|
|
47
|
+
# Returns the workers from the call to prepare
|
|
48
|
+
expect(workers).to eql DB::Worker.all.to_a
|
|
49
|
+
end
|
|
50
|
+
|
|
51
|
+
it 'prepares workers with accurate task scripts' do
|
|
52
|
+
DB::Task.all.each do |task|
|
|
53
|
+
test_hash = signature(task.sh)
|
|
54
|
+
ref_hash = signature("#{@test.path}/#{task.sh}")
|
|
55
|
+
expect(test_hash).to eql ref_hash
|
|
56
|
+
end
|
|
57
|
+
end
|
|
58
|
+
|
|
59
|
+
it 'properly prepares workers in force mode' do
|
|
60
|
+
sample = @test.samples[0]
|
|
61
|
+
|
|
62
|
+
@controller.prepare 'foobar', [sample], pwd: @test.path, mode: :force
|
|
63
|
+
|
|
64
|
+
ref_tasks = DB::Worker.find(1).tasks
|
|
65
|
+
test_tasks = DB::Worker.find(4).tasks
|
|
66
|
+
|
|
67
|
+
expect(ref_tasks.length).to eql 2
|
|
68
|
+
expect(test_tasks.length).to eql 2
|
|
69
|
+
|
|
70
|
+
ref_tasks.zip(test_tasks).map do |ref, test|
|
|
71
|
+
ref_hash = signature(ref.sh)
|
|
72
|
+
test_hash = signature(test.sh)
|
|
73
|
+
expect(test_hash).to eql ref_hash
|
|
74
|
+
end
|
|
75
|
+
end
|
|
76
|
+
|
|
77
|
+
it 'properly prepares workers in patch mode' do
|
|
78
|
+
sample = @test.samples[0]
|
|
79
|
+
step = @test.steps[1]
|
|
80
|
+
|
|
81
|
+
# Delete the first output
|
|
82
|
+
FileUtils.rm_r("#{sample}/#{step}")
|
|
83
|
+
|
|
84
|
+
@controller.prepare 'foobar', [sample], pwd: @test.path, mode: :patch
|
|
85
|
+
|
|
86
|
+
ref_tasks = DB::Worker.find(1).tasks
|
|
87
|
+
test_tasks = DB::Worker.find(5).tasks
|
|
88
|
+
|
|
89
|
+
expect(ref_tasks.length).to eql 2
|
|
90
|
+
expect(test_tasks.length).to eql 1
|
|
91
|
+
|
|
92
|
+
ref_hash = signature(ref_tasks.first.sh)
|
|
93
|
+
test_hash = signature(test_tasks.first.sh)
|
|
94
|
+
|
|
95
|
+
expect(test_hash).to eql ref_hash
|
|
96
|
+
end
|
|
97
|
+
|
|
98
|
+
it 'properly prepares workers in depend mode' do
|
|
99
|
+
sample = @test.samples[1]
|
|
100
|
+
step = @test.steps[1]
|
|
101
|
+
|
|
102
|
+
# Delete the first output
|
|
103
|
+
FileUtils.rm_r("#{sample}/#{step}")
|
|
104
|
+
|
|
105
|
+
@controller.prepare 'foobar', [sample], pwd: @test.path, mode: :depend
|
|
106
|
+
|
|
107
|
+
ref_tasks = DB::Worker.find(2).tasks
|
|
108
|
+
test_tasks = DB::Worker.find(6).tasks
|
|
109
|
+
|
|
110
|
+
expect(ref_tasks.length).to eql 2
|
|
111
|
+
expect(test_tasks.length).to eql 2
|
|
112
|
+
|
|
113
|
+
ref_tasks.zip(test_tasks).map do |ref, test|
|
|
114
|
+
ref_hash = signature(ref.sh)
|
|
115
|
+
test_hash = signature(test.sh)
|
|
116
|
+
expect(test_hash).to eql ref_hash
|
|
117
|
+
end
|
|
118
|
+
end
|
|
119
|
+
|
|
120
|
+
describe '#local' do
|
|
121
|
+
it 'runs worker jobs locally' do
|
|
122
|
+
worker = DB::Worker.find(1)
|
|
123
|
+
@controller.local worker
|
|
124
|
+
@test.steps.map do |step|
|
|
125
|
+
test_hash = signature("#{@test.samples[0]}/#{step}")
|
|
126
|
+
ref_hash = signature("#{@test.path}/#{@test.samples[0]}/#{step}")
|
|
127
|
+
expect(test_hash).to eql ref_hash
|
|
128
|
+
end
|
|
129
|
+
end
|
|
130
|
+
end
|
|
131
|
+
|
|
132
|
+
describe '#sync' do
|
|
133
|
+
it 'does not affected unprepared workers' do
|
|
134
|
+
before_statuses = DB::Worker.where(status: :prepared).map(&:id)
|
|
135
|
+
@controller.sync
|
|
136
|
+
after_statuses = DB::Worker.where(status: :prepared).map(&:id)
|
|
137
|
+
|
|
138
|
+
expect(after_statuses).to eql before_statuses
|
|
139
|
+
end
|
|
140
|
+
end
|
|
141
|
+
end
|
|
142
|
+
end
|
|
143
|
+
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: ripe
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Nicolas De Jay
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2015-
|
|
11
|
+
date: 2015-06-22 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: bundler
|
|
@@ -224,42 +224,58 @@ files:
|
|
|
224
224
|
- Rakefile
|
|
225
225
|
- bin/ripe
|
|
226
226
|
- lib/ripe.rb
|
|
227
|
-
- lib/ripe/
|
|
227
|
+
- lib/ripe/blocks.rb
|
|
228
|
+
- lib/ripe/blocks/block.rb
|
|
229
|
+
- lib/ripe/blocks/liquid_block.rb
|
|
230
|
+
- lib/ripe/blocks/multi_block.rb
|
|
231
|
+
- lib/ripe/blocks/parallel_block.rb
|
|
232
|
+
- lib/ripe/blocks/serial_block.rb
|
|
233
|
+
- lib/ripe/blocks/working_block.rb
|
|
234
|
+
- lib/ripe/cli.rb
|
|
235
|
+
- lib/ripe/cli/helper.rb
|
|
236
|
+
- lib/ripe/db.rb
|
|
237
|
+
- lib/ripe/db/task.rb
|
|
238
|
+
- lib/ripe/db/task_migration.rb
|
|
239
|
+
- lib/ripe/db/worker.rb
|
|
240
|
+
- lib/ripe/db/worker_migration.rb
|
|
228
241
|
- lib/ripe/dsl.rb
|
|
229
242
|
- lib/ripe/dsl/task_dsl.rb
|
|
230
243
|
- lib/ripe/dsl/workflow_dsl.rb
|
|
231
244
|
- lib/ripe/library.rb
|
|
232
|
-
- lib/ripe/liquid_block.rb
|
|
233
|
-
- lib/ripe/multi_block.rb
|
|
234
|
-
- lib/ripe/parallel_block.rb
|
|
235
245
|
- lib/ripe/repo.rb
|
|
236
|
-
- lib/ripe/serial_block.rb
|
|
237
|
-
- lib/ripe/task.rb
|
|
238
|
-
- lib/ripe/task_migration.rb
|
|
239
246
|
- lib/ripe/version.rb
|
|
240
|
-
- lib/ripe/worker.rb
|
|
241
247
|
- lib/ripe/worker_controller.rb
|
|
242
|
-
- lib/ripe/
|
|
243
|
-
- lib/ripe/
|
|
248
|
+
- lib/ripe/worker_controller/preparer.rb
|
|
249
|
+
- lib/ripe/worker_controller/syncer.rb
|
|
244
250
|
- ripe.gemspec
|
|
245
251
|
- share/moab.sh
|
|
246
|
-
- spec/
|
|
252
|
+
- spec/cli_spec.rb
|
|
247
253
|
- spec/library_spec.rb
|
|
248
|
-
- spec/ripe_spec.rb
|
|
249
254
|
- spec/spec_helper.rb
|
|
250
255
|
- spec/testpack.rb
|
|
251
|
-
- spec/testpack/
|
|
252
|
-
- spec/testpack/
|
|
253
|
-
- spec/testpack/
|
|
254
|
-
- spec/testpack/
|
|
255
|
-
- spec/testpack/
|
|
256
|
-
- spec/testpack/
|
|
257
|
-
- spec/testpack/
|
|
258
|
-
- spec/testpack/
|
|
259
|
-
- spec/testpack/
|
|
260
|
-
- spec/testpack
|
|
261
|
-
- spec/testpack
|
|
262
|
-
- spec/testpack
|
|
256
|
+
- spec/testpack/.ripe/meta.db
|
|
257
|
+
- spec/testpack/.ripe/tasks/bar.sh
|
|
258
|
+
- spec/testpack/.ripe/tasks/foo.sh
|
|
259
|
+
- spec/testpack/.ripe/workers/1/1.sh
|
|
260
|
+
- spec/testpack/.ripe/workers/1/2.sh
|
|
261
|
+
- spec/testpack/.ripe/workers/1/job.sh
|
|
262
|
+
- spec/testpack/.ripe/workers/2/3.sh
|
|
263
|
+
- spec/testpack/.ripe/workers/2/4.sh
|
|
264
|
+
- spec/testpack/.ripe/workers/2/job.sh
|
|
265
|
+
- spec/testpack/.ripe/workers/3/5.sh
|
|
266
|
+
- spec/testpack/.ripe/workers/3/6.sh
|
|
267
|
+
- spec/testpack/.ripe/workers/3/job.sh
|
|
268
|
+
- spec/testpack/.ripe/workflows/foobar.rb
|
|
269
|
+
- spec/testpack/Sample1/bar_output.txt
|
|
270
|
+
- spec/testpack/Sample1/foo_input.txt
|
|
271
|
+
- spec/testpack/Sample1/foo_output.txt
|
|
272
|
+
- spec/testpack/Sample2/bar_output.txt
|
|
273
|
+
- spec/testpack/Sample2/foo_input.txt
|
|
274
|
+
- spec/testpack/Sample2/foo_output.txt
|
|
275
|
+
- spec/testpack/Sample3/bar_output.txt
|
|
276
|
+
- spec/testpack/Sample3/foo_input.txt
|
|
277
|
+
- spec/testpack/Sample3/foo_output.txt
|
|
278
|
+
- spec/worker_controller_spec.rb
|
|
263
279
|
homepage: https://github.com/ndejay/ripe
|
|
264
280
|
licenses:
|
|
265
281
|
- MIT
|
|
@@ -285,21 +301,31 @@ signing_key:
|
|
|
285
301
|
specification_version: 4
|
|
286
302
|
summary: Abstraction layer between the MOAB/Torque stack and your pipeline.
|
|
287
303
|
test_files:
|
|
288
|
-
- spec/
|
|
304
|
+
- spec/cli_spec.rb
|
|
289
305
|
- spec/library_spec.rb
|
|
290
|
-
- spec/ripe_spec.rb
|
|
291
306
|
- spec/spec_helper.rb
|
|
292
307
|
- spec/testpack.rb
|
|
293
|
-
- spec/testpack/
|
|
294
|
-
- spec/testpack/
|
|
295
|
-
- spec/testpack/
|
|
296
|
-
- spec/testpack/
|
|
297
|
-
- spec/testpack/
|
|
298
|
-
- spec/testpack/
|
|
299
|
-
- spec/testpack/
|
|
300
|
-
- spec/testpack/
|
|
301
|
-
- spec/testpack/
|
|
302
|
-
- spec/testpack
|
|
303
|
-
- spec/testpack
|
|
304
|
-
- spec/testpack
|
|
308
|
+
- spec/testpack/.ripe/meta.db
|
|
309
|
+
- spec/testpack/.ripe/tasks/bar.sh
|
|
310
|
+
- spec/testpack/.ripe/tasks/foo.sh
|
|
311
|
+
- spec/testpack/.ripe/workers/1/1.sh
|
|
312
|
+
- spec/testpack/.ripe/workers/1/2.sh
|
|
313
|
+
- spec/testpack/.ripe/workers/1/job.sh
|
|
314
|
+
- spec/testpack/.ripe/workers/2/3.sh
|
|
315
|
+
- spec/testpack/.ripe/workers/2/4.sh
|
|
316
|
+
- spec/testpack/.ripe/workers/2/job.sh
|
|
317
|
+
- spec/testpack/.ripe/workers/3/5.sh
|
|
318
|
+
- spec/testpack/.ripe/workers/3/6.sh
|
|
319
|
+
- spec/testpack/.ripe/workers/3/job.sh
|
|
320
|
+
- spec/testpack/.ripe/workflows/foobar.rb
|
|
321
|
+
- spec/testpack/Sample1/bar_output.txt
|
|
322
|
+
- spec/testpack/Sample1/foo_input.txt
|
|
323
|
+
- spec/testpack/Sample1/foo_output.txt
|
|
324
|
+
- spec/testpack/Sample2/bar_output.txt
|
|
325
|
+
- spec/testpack/Sample2/foo_input.txt
|
|
326
|
+
- spec/testpack/Sample2/foo_output.txt
|
|
327
|
+
- spec/testpack/Sample3/bar_output.txt
|
|
328
|
+
- spec/testpack/Sample3/foo_input.txt
|
|
329
|
+
- spec/testpack/Sample3/foo_output.txt
|
|
330
|
+
- spec/worker_controller_spec.rb
|
|
305
331
|
has_rdoc:
|