Devtools Restarter is incompatible with Java 25 main method
Closed this issue · 2 comments
tompson commented
when you create a main method in the style of Java 25 like:
@SpringBootApplication
public class DemoApplication {
void main(String[] args) {
SpringApplication.run(DemoApplication.class, args);
}
}
and add devtools you get the following exception:
java.lang.IllegalStateException: Unable to find the main class to restart
at org.springframework.util.Assert.state(Assert.java:79)
at org.springframework.boot.devtools.restart.Restarter.doStart(Restarter.java:275)
at org.springframework.boot.devtools.restart.Restarter.start(Restarter.java:263)
at org.springframework.boot.devtools.restart.Restarter.lambda$immediateRestart$0(Restarter.java:171)
at org.springframework.boot.devtools.restart.Restarter$LeakSafeThread.run(Restarter.java:612)
wilkinsona commented