I have a simple Spring Boot application that gets messages from a JMS queue and saves some data to a log file, but does not need a web server. Is there any way of starting S
You can create something like this:
@SpringBootApplication
public class Application {
public static void main(String[] args) {
new SpringApplicationBuilder(Application.class).web(false).run(args);
}
}
And
@Component
public class CommandLiner implements CommandLineRunner {
@Override
public void run(String... args) throws Exception {
// Put your logic here
}
}
The dependency is still there though but not used.