Question: 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 Spring Boot without the web server?

Answer: 
Use this code.

```
SpringApplication application = new SpringApplication(DemoApplication.class);
application.setWebApplicationType(WebApplicationType.NONE);
application.run(args);

```
Spring boot has many starters, some starters have an embedded web server, some don't. The following have the embedded web server:

```
spring-boot-starter-web
spring-boot-starter-data-jpa
spring-boot-starter-jetty
spring-boot-starter-tomcat
spring-boot-starter-jdbc
spring-boot-starter-data-rest
...

```

Pick the one that meets your requirements and that does not have server support.

I only need to make restful json api request in my spring application, so the starter I need is

```
spring-boot-starter-json

```

which provide `RestTemplate` and `jackson` for me to use.