|
|
@ -124,7 +124,7 @@ public final class DynamicThreadPoolPostProcessor implements BeanPostProcessor {
|
|
|
|
|
|
|
|
|
|
|
|
if (dynamicThreadPoolWrap.getExecutor() instanceof AbstractDynamicExecutorSupport) {
|
|
|
|
if (dynamicThreadPoolWrap.getExecutor() instanceof AbstractDynamicExecutorSupport) {
|
|
|
|
// 设置动态线程池增强参数
|
|
|
|
// 设置动态线程池增强参数
|
|
|
|
ThreadPoolNotifyAlarm notify = executorProperties.getNotify();
|
|
|
|
ThreadPoolNotifyAlarm notify = Optional.ofNullable(executorProperties).map(ExecutorProperties::getNotify).orElse(null);
|
|
|
|
boolean isAlarm = Optional.ofNullable(notify)
|
|
|
|
boolean isAlarm = Optional.ofNullable(notify)
|
|
|
|
.map(each -> each.getIsAlarm())
|
|
|
|
.map(each -> each.getIsAlarm())
|
|
|
|
.orElseGet(() -> bootstrapCoreProperties.getAlarm() != null ? bootstrapCoreProperties.getAlarm() : true);
|
|
|
|
.orElseGet(() -> bootstrapCoreProperties.getAlarm() != null ? bootstrapCoreProperties.getAlarm() : true);
|
|
|
@ -194,5 +194,4 @@ public final class DynamicThreadPoolPostProcessor implements BeanPostProcessor {
|
|
|
|
|
|
|
|
|
|
|
|
return executorProperties;
|
|
|
|
return executorProperties;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|