-
STS 3버전 4로 마이그레이션최종프로젝트 관련 정리 2020. 8. 19. 20:55
sts 3 버전 -> 4버전으로 마이그레이션 하기
기본 환경
- Spring Framework 3.1.1
- java version 1.6
- Maven compiler
source 1.6
target 1.6
- servlet-api 2.5
- jsp-api 2.1변경 될 환경
- Spring Framework 4.3.4
- java version 1.8
- Maven compiler
source 1.8
target 1.8
- servlet-api 3.0
- jsp-api 2.2
설정 변경
pom.xml 수정
1. java version 1.6 -> 1.8 / springfamework version 3.1.1 -> 4.3.4
<properties> <java-version>1.8</java-version> <org.springframework-version>4.3.4.RELEASE</org.springframework-version> <org.aspectj-version>1.6.10</org.aspectj-version> <org.slf4j-version>1.6.6</org.slf4j-version> </properties>
2. Servlet api 버전 2.5 -> 3.0.1 // artifactId : servelt-api -> javax.servlet-api
<dependency> <groupId>javax.servlet</groupId> <artifactId>javax.servlet-api</artifactId> <version>3.0.1</version> <scope>provided</scope> </dependency>
3. jsp api 버전 2.1 -> 2.2로 변경
<dependency> <groupId>javax.servlet.jsp</groupId> <artifactId>jsp-api</artifactId> <version>2.2</version> <scope>provided</scope> </dependency>
4. maven complier 설정 소스, 타겟을 1.8로 변경
<plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <version>2.5.1</version> <configuration> <source>1.8</source> <target>1.8</target> <compilerArgument>-Xlint:all</compilerArgument> <showWarnings>true</showWarnings> <showDeprecation>true</showDeprecation> </configuration> </plugin>
출처: https://offbyone.tistory.com/16 [쉬고 싶은 개발자]'최종프로젝트 관련 정리' 카테고리의 다른 글