1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57 | package io.dorbae.springboot.tutorial;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
/*****************************************************************
*
* TutorialSpringbootApplication.java
*
*****************************************************************
*
* @version 0.1.0 2019-01-15 18:18:07 dorbae WAR 배포로 수정
* @version 0.0.0 2019-01-14 18:18:07 dorbae 최초생성
* @since 1.0
* @author dorbae(dorbae.io@gmail.com)
*
*/
/*
* @SpringBootApplication Annotation
* 실행될 Spring Boot 어플리케이션의 시작 포인트
* @EnableAutoConfiguration, @ComponentScan, @SpringBootConfiguration Annotation을 포함
* @EnableAutoConfiguration Annotation
* JAR dependencies 기반으로 자동으로 application을 설정
* @ComponentScan Annotation
* 프로젝트에서 추가된 스캔될 컴포넌트를 지정
*/
/*
*
* JAR 형태로 배포
*
*
@SpringBootApplication
public class TutorialSpringbootApplication {
public static void main( String[] args) {
SpringApplication.run( TutorialSpringbootApplication.class, args);
}
}
*/
/*
* WAR 형태로 배포
*/
@SpringBootApplication
public class TutorialSpringbootApplication extends SpringBootServletInitializer {
@Override
protected SpringApplicationBuilder configure( SpringApplicationBuilder application) {
return application.sources( TutorialSpringbootApplication.class);
}
public static void main( String[] args) {
SpringApplication.run( TutorialSpringbootApplication.class, args);
}
}
|
댓글남기기