Disabled async stacktraces temporarily
This commit is contained in:
parent
a6b9037507
commit
816e9db448
@ -5,8 +5,15 @@ import org.jetbrains.annotations.NotNull;
|
||||
|
||||
public class AsyncStackTraceExecutorServiceDecorator extends SimplerExecutorServiceDecorator {
|
||||
|
||||
// todo: Fix async stacktrace performance and memory problems
|
||||
private static final boolean DISABLE_ASYNC_STACKTRACES_GLOBALLY = true;
|
||||
|
||||
public AsyncStackTraceExecutorServiceDecorator(ExecutorService executorService) {
|
||||
super(executorService, (executor) -> {
|
||||
if (DISABLE_ASYNC_STACKTRACES_GLOBALLY) {
|
||||
return executor;
|
||||
}
|
||||
|
||||
// Do nothing if it has already the asyncstacktrace executor service decorator
|
||||
if (executorService instanceof ExecutorServiceDecorator) {
|
||||
var decorators = ((ExecutorServiceDecorator) executorService).getExecutorServiceDecorators();
|
||||
|
@ -14,10 +14,10 @@ import org.jetbrains.annotations.NotNull;
|
||||
|
||||
public abstract class SimplerExecutorServiceDecorator extends ExecutorServiceDecorator {
|
||||
|
||||
private final ExecutorDecorator executorDecorator;
|
||||
private final Executor executorDecorator;
|
||||
|
||||
public SimplerExecutorServiceDecorator(ExecutorService executorService,
|
||||
Function<Executor, ExecutorDecorator> executorDecoratorInitializer) {
|
||||
Function<Executor, Executor> executorDecoratorInitializer) {
|
||||
super(executorService);
|
||||
this.executorDecorator = executorDecoratorInitializer.apply(executorService);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user