|
14 | 14 | import org.slf4j.LoggerFactory; |
15 | 15 | import org.springframework.boot.CommandLineRunner; |
16 | 16 | import org.springframework.boot.WebApplicationType; |
17 | | -import org.springframework.boot.autoconfigure.EnableAutoConfiguration; |
| 17 | +import org.springframework.boot.autoconfigure.SpringBootApplication; |
18 | 18 | import org.springframework.boot.builder.SpringApplicationBuilder; |
19 | | -import org.springframework.context.annotation.ComponentScan; |
20 | | -import org.springframework.context.annotation.Configuration; |
21 | 19 | import org.springframework.context.annotation.EnableAspectJAutoProxy; |
22 | | -import org.springframework.core.Ordered; |
23 | 20 | import org.springframework.data.jpa.repository.config.EnableJpaRepositories; |
24 | | -import org.springframework.data.web.config.EnableSpringDataWebSupport; |
25 | 21 | import org.springframework.hateoas.Link; |
26 | 22 | import org.springframework.hateoas.config.EnableHypermediaSupport; |
27 | 23 | import org.springframework.http.HttpEntity; |
|
30 | 26 | import org.springframework.web.client.HttpClientErrorException; |
31 | 27 | import org.springframework.web.client.RestTemplate; |
32 | 28 |
|
33 | | -@EnableAutoConfiguration |
34 | 29 | @EnableHypermediaSupport(type = EnableHypermediaSupport.HypermediaType.HAL) |
35 | 30 | @EnableJpaRepositories |
36 | 31 | @EnableAspectJAutoProxy(proxyTargetClass = true) |
37 | | -@EnableSpringDataWebSupport |
38 | | -@EnableTransactionManagement(order = Ordered.LOWEST_PRECEDENCE - 1) |
39 | | -@Configuration |
40 | | -@ComponentScan |
| 32 | +@EnableTransactionManagement |
| 33 | +@SpringBootApplication |
41 | 34 | public class JpaApplication implements CommandLineRunner { |
42 | 35 | protected static final Logger logger = LoggerFactory.getLogger(JpaApplication.class); |
43 | 36 |
|
|
0 commit comments