Sho SHIMIZU
Committed by Thomas Vachuska

Refactor: Inline method

Change-Id: Iafa70a7a728a3e701a2f62c4b9c015504bdcfabd
...@@ -293,11 +293,6 @@ public class IntentManager ...@@ -293,11 +293,6 @@ public class IntentManager
293 } 293 }
294 } 294 }
295 295
296 - private CompletableFuture<FinalIntentProcessPhase> submitIntentData(IntentData data) {
297 - IntentProcessPhase initial = createInitialPhase(data);
298 - return CompletableFuture.supplyAsync(() -> process(initial), workerExecutor);
299 - }
300 -
301 private IntentProcessPhase createInitialPhase(IntentData data) { 296 private IntentProcessPhase createInitialPhase(IntentData data) {
302 IntentData current = store.getIntentData(data.key()); 297 IntentData current = store.getIntentData(data.key());
303 return newInitialPhase(processor, data, current); 298 return newInitialPhase(processor, data, current);
...@@ -330,7 +325,8 @@ public class IntentManager ...@@ -330,7 +325,8 @@ public class IntentManager
330 (we can also try to update these individually) 325 (we can also try to update these individually)
331 */ 326 */
332 List<CompletableFuture<IntentData>> futures = operations.stream() 327 List<CompletableFuture<IntentData>> futures = operations.stream()
333 - .map(IntentManager.this::submitIntentData) 328 + .map(x -> createInitialPhase(x))
329 + .map(x -> CompletableFuture.supplyAsync(() -> process(x), workerExecutor))
334 .map(x -> x.thenApply(FinalIntentProcessPhase::data)) 330 .map(x -> x.thenApply(FinalIntentProcessPhase::data))
335 .map(x -> x.exceptionally(e -> { 331 .map(x -> x.exceptionally(e -> {
336 //FIXME 332 //FIXME
......