Skip to content

Commit

Permalink
fix: expose Spring executor for Vaadin dev mode (#692)
Browse files Browse the repository at this point in the history
Part of #691

# Conflicts:
#	vaadin-spring/src/test/java/com/vaadin/flow/spring/VaadinServletContextInitializerTest.java
  • Loading branch information
Denis committed Dec 3, 2020
1 parent e8d959f commit 4c5cd18
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
import java.util.Map;
import java.util.Objects;
import java.util.Set;
import java.util.concurrent.Executor;
import java.util.concurrent.locks.ReentrantLock;
import java.util.stream.Collectors;
import java.util.stream.Stream;
Expand All @@ -56,6 +57,7 @@
import org.springframework.core.io.Resource;
import org.springframework.core.io.ResourceLoader;
import org.springframework.core.io.support.PathMatchingResourcePatternResolver;
import org.springframework.core.task.TaskExecutor;
import org.springframework.core.type.filter.AnnotationTypeFilter;
import org.springframework.core.type.filter.AssignableTypeFilter;

Expand Down Expand Up @@ -343,6 +345,8 @@ public void contextInitialized(ServletContextEvent event) {
|| !config.enableDevServer()) {
return;
}
config.getInitParameters().put(Executor.class,
appContext.getBean(TaskExecutor.class));

Set<String> basePackages;
if (isScanOnlySet()) {
Expand Down

0 comments on commit 4c5cd18

Please sign in to comment.