tem_mr_search 0.3.4 → 0.3.5
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG +2 -0
- data/lib/tem_mr_search/map_reduce_executor.rb +3 -2
- data/tem_mr_search.gemspec +1 -1
- data/test/test_map_reduce_executor.rb +2 -1
- metadata +1 -1
data/CHANGELOG
CHANGED
@@ -48,7 +48,7 @@ class MapReduceExecutor
|
|
48
48
|
|
49
49
|
# Protected by @lock
|
50
50
|
tasks = { :map => 0.0, :reduce => 0.0, :finalize => 0.0,
|
51
|
-
:
|
51
|
+
:migrate_map => 0.0, :migrate_reduce => 0.0, :tem_ids => 0.0 }
|
52
52
|
@timings = { :tems => Array.new(@tems.length) { tasks.dup } }
|
53
53
|
|
54
54
|
# Thread-safe.
|
@@ -127,7 +127,8 @@ class MapReduceExecutor
|
|
127
127
|
|
128
128
|
@lock.synchronize do
|
129
129
|
@tem_parts[action[:secpack]][action[:to]] = out_part
|
130
|
-
|
130
|
+
task = action[:secpack] == :mapper ? :migrate_map : :migrate_reduce
|
131
|
+
@timings[:tems][tem_index][task] += time_delta
|
131
132
|
end
|
132
133
|
|
133
134
|
when :map
|
data/tem_mr_search.gemspec
CHANGED
@@ -37,7 +37,8 @@ class MapReduceExecutorTest < MrTestCase
|
|
37
37
|
assert_equal tems.length, data[:timings][:tems].length,
|
38
38
|
'No TEM data in the timings'
|
39
39
|
data[:timings][:tems].each do |tem_data|
|
40
|
-
[:tem_ids, :
|
40
|
+
[:tem_ids, :migrate_map, :migrate_reduce, :map, :reduce,
|
41
|
+
:finalize].each do |task|
|
41
42
|
assert tem_data[task], "No data on #{task} in the per-TEM timings"
|
42
43
|
end
|
43
44
|
end
|