How does a Spring Boot console based application work?

You should have a standard loader:

@SpringBootApplication
public class MyDemoApplication {
    public static void main(String[] args) {
        SpringApplication.run(MyDemoApplication.class, args);
    }
}

and implement a CommandLineRunner interface with @Component annotation

    @Component
    public class MyRunner implements CommandLineRunner {

       @Override    
       public void run(String... args) throws Exception {

      }
   }

@EnableAutoConfiguration will do the usual SpringBoot magic.

UPDATE:

As @jeton suggests the latest Springboot implements a straight:

spring.main.web-application-type=none
spring.main.banner-mode=off

See docs at 72.2

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)