Skip to content

Commit

Permalink
解决栈溢出问题
Browse files Browse the repository at this point in the history
  • Loading branch information
huhaosumail committed Jun 26, 2024
1 parent a68fb69 commit e8ce48b
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions cffu-core/src/main/java/io/foldright/cffu/Cffu.java
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ public Cffu<Void> thenRunAsync(Runnable action, Executor executor) {
*/
public <T, U> Cffu<List<U>> thenMApplyFastFailAsync(
CompletionStage<? extends T> cf, Function<? super T, ? extends U>... fns) {
return thenMApplyFastFailAsync(cf, fns);
return thenMApplyFastFailAsync(cf,fac.defaultExecutor(),fns);
}

/**
Expand Down Expand Up @@ -270,7 +270,7 @@ public <T, U> Cffu<List<U>> thenMApplyFastFailAsync(
public <T, U> Cffu<List<U>> thenMApplyMostSuccessAsync(
CompletionStage<? extends T> cf, @Nullable U valueIfNotSuccess,
long timeout, TimeUnit unit, Function<? super T, ? extends U>... fns) {
return thenMApplyMostSuccessAsync(cf, valueIfNotSuccess, timeout, unit, fns);
return thenMApplyMostSuccessAsync(cf, valueIfNotSuccess, fac.defaultExecutor(),timeout, unit, fns);
}

/**
Expand Down Expand Up @@ -310,7 +310,7 @@ public <T, U> Cffu<List<U>> thenMApplyMostSuccessAsync(
*/
public <T, U> Cffu<List<U>> thenMApplyAsync(
CompletionStage<? extends T> cf, Function<? super T, ? extends U>... fns) {
return thenMApplyAsync(cf, fns);
return thenMApplyAsync(cf,fac.defaultExecutor(), fns);
}

/**
Expand Down Expand Up @@ -339,7 +339,7 @@ public <T, U> Cffu<List<U>> thenMApplyAsync(
*/
public <T> Cffu<Void> thenMAcceptAsync(
CompletionStage<? extends T> cf, Consumer<? super T>... actions) {
return thenMAcceptAsync(cf, actions);
return thenMAcceptAsync(cf,fac.defaultExecutor(), actions);
}

/**
Expand Down Expand Up @@ -367,7 +367,7 @@ public <T> Cffu<Void> thenMAcceptAsync(
*/
public <T> Cffu<Void> thenMAcceptFastFailAsync(
CompletionStage<? extends T> cf, Consumer<? super T>... actions) {
return thenMAcceptFastFailAsync(cf, actions);
return thenMAcceptFastFailAsync(cf,fac.defaultExecutor(), actions);
}

/**
Expand Down Expand Up @@ -398,7 +398,7 @@ public <T> Cffu<Void> thenMAcceptFastFailAsync(
* @see CompletableFuture#thenRunAsync(Runnable)
*/
public Cffu<Void> thenMRunFastFailAsync(CompletionStage<?> cf, Runnable... actions) {
return thenMRunFastFailAsync(cf, actions);
return thenMRunFastFailAsync(cf,fac.defaultExecutor(), actions);
}

/**
Expand Down Expand Up @@ -426,7 +426,7 @@ public Cffu<Void> thenMRunFastFailAsync(
* @see CompletableFuture#thenRunAsync(Runnable)
*/
public Cffu<Void> thenMRunAsync(CompletionStage<?> cf, Runnable... actions) {
return thenMRunAsync(cf, actions);
return thenMRunAsync(cf,fac.defaultExecutor(), actions);
}

/**
Expand Down

0 comments on commit e8ce48b

Please sign in to comment.