test_class.file: blog-code/src/test/java/pl/ciruk/blog/fanout/CompletableFuturesTest.java
test_class.identifier: CompletableFuturesTest
test_case.body: @Test
  	public void shouldExecuteAllFunctionsAtTheSameTime() throws Exception {
  		// Given
  		CompletableFuture<String> future = CompletableFuture.supplyAsync(() -> "SampleText");
  
  		// When
  		ExecutorService pool = Executors.newFixedThreadPool(4);
  		CompletableFuture<Stream<Integer>> actualFuture = future.thenComposeAsync(
  				fanOut(ImmutableList.of(
  						text -> {
  							waitThreeSecond();
  							return 1;
  						},
  						text -> {
  							waitThreeSecond();
  							return 2;
  						},
  						text -> {
  							waitThreeSecond();
  							return 4;
  						})
  				)
  		);
  
  		// Then
  		try {
  			actualFuture.get(4, TimeUnit.SECONDS);
  		} catch (TimeoutException e) {
  			fail("Should have finished in less than four seconds");
  		}
  	}
test_case.class_method_signature: CompletableFuturesTest.shouldExecuteAllFunctionsAtTheSameTime()
test_case.full_signature: @Test public void shouldExecuteAllFunctionsAtTheSameTime()
test_case.identifier: shouldExecuteAllFunctionsAtTheSameTime
test_case.invocations: supplyAsync newFixedThreadPool thenComposeAsync fanOut of waitThreeSecond waitThreeSecond waitThreeSecond get fail
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void shouldExecuteAllFunctionsAtTheSameTime()
focal_class.file: blog-code/src/main/java/pl/ciruk/blog/fanout/CompletableFutures.java
focal_class.identifier: CompletableFutures
focal_class.class_method_signature: CompletableFutures.fanOut(Collection<Function<F, T>> mappings)
focal_class.full_signature: static Function<F, CompletableFuture<Stream<T>>> fanOut(Collection<Function<F, T>> mappings)
focal_class.identifier: fanOut
focal_class.modifiers: static
focal_class.parameters: (Collection<Function<F, T>> mappings)
focal_class.return: Function<F, CompletableFuture<Stream<T>>>
focal_class.signature: Function<F, CompletableFuture<Stream<T>>> fanOut(Collection<Function<F, T>> mappings)
focal_class.class_method_signature: CompletableFutures.fanOut(Collection<Function<F, T>> mappings, ExecutorService executorService)
focal_class.full_signature: static Function<F, CompletableFuture<Stream<T>>> fanOut(Collection<Function<F, T>> mappings, ExecutorService executorService)
focal_class.identifier: fanOut
focal_class.modifiers: static
focal_class.parameters: (Collection<Function<F, T>> mappings, ExecutorService executorService)
focal_class.return: Function<F, CompletableFuture<Stream<T>>>
focal_class.signature: Function<F, CompletableFuture<Stream<T>>> fanOut(Collection<Function<F, T>> mappings, ExecutorService executorService)
focal_class.class_method_signature: CompletableFutures.combineUsing(BiFunction<T, T, T> combiningFunction)
focal_class.full_signature: public static BinaryOperator<CompletableFuture<T>> combineUsing(BiFunction<T, T, T> combiningFunction)
focal_class.identifier: combineUsing
focal_class.modifiers: public static
focal_class.parameters: (BiFunction<T, T, T> combiningFunction)
focal_class.return: BinaryOperator<CompletableFuture<T>>
focal_class.signature: BinaryOperator<CompletableFuture<T>> combineUsing(BiFunction<T, T, T> combiningFunction)
focal_class.class_method_signature: CompletableFutures.combineUsing(BiFunction<T, T, T> combiningFunction, ExecutorService executorService)
focal_class.full_signature: public static BinaryOperator<CompletableFuture<T>> combineUsing(BiFunction<T, T, T> combiningFunction, ExecutorService executorService)
focal_class.identifier: combineUsing
focal_class.modifiers: public static
focal_class.parameters: (BiFunction<T, T, T> combiningFunction, ExecutorService executorService)
focal_class.return: BinaryOperator<CompletableFuture<T>>
focal_class.signature: BinaryOperator<CompletableFuture<T>> combineUsing(BiFunction<T, T, T> combiningFunction, ExecutorService executorService)
focal_class.class_method_signature: CompletableFutures.CompletableFutures()
focal_class.full_signature: private  CompletableFutures()
focal_class.identifier: CompletableFutures
focal_class.modifiers: private
focal_class.parameters: ()
focal_class.signature:  CompletableFutures()
focal_method.body: static <F, T> Function<F, CompletableFuture<Stream<T>>> fanOut(Collection<Function<F, T>> mappings) {
  		return fanOut(mappings, ForkJoinPool.commonPool());
  	}
focal_method.class_method_signature: CompletableFutures.fanOut(Collection<Function<F, T>> mappings)
focal_method.full_signature: static Function<F, CompletableFuture<Stream<T>>> fanOut(Collection<Function<F, T>> mappings)
focal_method.identifier: fanOut
focal_method.invocations: fanOut commonPool
focal_method.modifiers: static
focal_method.parameters: (Collection<Function<F, T>> mappings)
focal_method.return: Function<F, CompletableFuture<Stream<T>>>
focal_method.signature: Function<F, CompletableFuture<Stream<T>>> fanOut(Collection<Function<F, T>> mappings)