Merge branch '6.1.x'
This commit is contained in:
commit
ad2e95be4b
|
@ -192,7 +192,7 @@ public class SimpleAsyncTaskScheduler extends SimpleAsyncTaskExecutor implements
|
|||
}
|
||||
|
||||
private Runnable scheduledTask(Runnable task) {
|
||||
return () -> execute(task);
|
||||
return () -> execute(new DelegatingErrorHandlingRunnable(task, TaskUtils.LOG_AND_PROPAGATE_ERROR_HANDLER));
|
||||
}
|
||||
|
||||
private Runnable taskOnSchedulerThread(Runnable task) {
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright 2002-2023 the original author or authors.
|
||||
* Copyright 2002-2024 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
@ -59,8 +59,8 @@ class ApplicationContextAotGeneratorRuntimeHintsTests {
|
|||
void generateApplicationContextWithAutowiring() {
|
||||
GenericApplicationContext context = new AnnotationConfigApplicationContext();
|
||||
context.registerBeanDefinition("autowiredComponent", new RootBeanDefinition(AutowiredComponent.class));
|
||||
context.registerBeanDefinition("number", BeanDefinitionBuilder.rootBeanDefinition(Integer.class, "valueOf")
|
||||
.addConstructorArgValue("42").getBeanDefinition());
|
||||
context.registerBeanDefinition("number", BeanDefinitionBuilder.rootBeanDefinition(
|
||||
Integer.class, "valueOf").addConstructorArgValue("42").getBeanDefinition());
|
||||
compile(context, (hints, invocations) -> assertThat(invocations).match(hints));
|
||||
}
|
||||
|
||||
|
@ -89,8 +89,10 @@ class ApplicationContextAotGeneratorRuntimeHintsTests {
|
|||
compile(context, (hints, invocations) -> assertThat(invocations).match(hints));
|
||||
}
|
||||
|
||||
@SuppressWarnings({ "rawtypes", "unchecked" })
|
||||
private void compile(GenericApplicationContext applicationContext, BiConsumer<RuntimeHints, RuntimeHintsInvocations> initializationResult) {
|
||||
@SuppressWarnings({"rawtypes", "unchecked"})
|
||||
private void compile(GenericApplicationContext applicationContext,
|
||||
BiConsumer<RuntimeHints, RuntimeHintsInvocations> initializationResult) {
|
||||
|
||||
ApplicationContextAotGenerator generator = new ApplicationContextAotGenerator();
|
||||
TestGenerationContext generationContext = new TestGenerationContext();
|
||||
generator.processAheadOfTime(applicationContext, generationContext);
|
||||
|
@ -107,17 +109,15 @@ class ApplicationContextAotGeneratorRuntimeHintsTests {
|
|||
});
|
||||
}
|
||||
|
||||
|
||||
public interface Destroyable {
|
||||
|
||||
@PreDestroy
|
||||
default void destroy() {
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public static class InheritedDestroy implements Destroyable {
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue