반응형
1. 개발환경
- JDK 1.8
- eclipse
- apache+tomcat 7.0
- Spring
- mybatis 3.2.1
- Oracle Database 11g
2. 과정
1. 프로젝트 생성: New > Dynamic Web Proejct
1. Project name, Target runtime 등 설정
2. Java(configure project for building a Java application) + 수정
- Remove: src
- Add Folder(3개)
src/main/java: 개발되는 코드의 경로
src/main/resources: 서비스가 실행될 떄 필요한 파일의 경로
src/test/java: 테스트 코드
3. Web Module(Configure web module settings) + [체크]Generate web.xml deployment descriptor
2. 설정 변경
- Build path 에 Spring 5, mybatis, oracle 관련 jar 추가
- [Libraies] add Library: user Library + User Libraries... 아래 library만들어서 .jar추가
- Spring5
- JSTL1.2
- Utils
- [Libraies] add Library: user Library + User Libraries... 아래 library만들어서 .jar추가
- [Source] src/main/resources > next > Exclusion patters + add... + 추가
- Properties + Deployment Assembly
- Source | Deploy Path
- ———————————————————
- /src/main/java | WEB+INF/classes
- /src/main/resource | WEB+INF/classes
- /WebContent | /
- Add.. + Java build path Entries > Spring5, JSTL1.2, Utils추가 | WEB+INF/lib
3. Xml 파일 생성
- Web.xml
- src/main/resources/config/mappers/oracle: 사용할mapper.xml들
- src/main/resources/config/mybatis: mybatis 설정파일(Mybatis+config.xml)
- src/main/resources/config/spring: spring 설정파일(spring+web+config.xml)
3. 필요파일
[Spring5] ${version: 5.1.2}
- spring+aop+${version}.RELEASE.jar
- spring+beans+${version}.RELEASE.jar
- spring+context+${version}.RELEASE.jar
- spring+context+support+${version}.RELEASE.jar
- spring+core+${version}.RELEASE.jar
- spring+expression+${version}.RELEASE.jar
- spring+jcl+${version}.RELEASE.jar
- spring+jdbc+${version}.RELEASE.jar
- spring+orm+${version}.RELEASE.jar
- spring+test+${version}.RELEASE.jar
- spring+tx+${version}.RELEASE.jar
- spring+web+${version}.RELEASE.jar
- spring+webmvc+${version}.RELEASE.jar
- spring+websocket+${version}.RELEASE.jar
[JSTL1.2]
- jstl+1.2.jar
- standard+1.1.2.jar
[UTILS]
- aspectjrt+1.5.4.jar
- aspectjweaver+1.5.4.jar
- commons+fileupload+1.3.3.jar
- commons+io+2.6.jar
- commons+lang+2.6.jar
- commons+logging+1.2.jar
- commons+net+3.6.jar
- commons+validator+1.6.jar
- activation+1.1.jar
- axis+1.4.jar
- axis+jaxrpc+1.4.jar
- axis+wsdl4j+1.5.1.jar
- cglib+nodep+2.2.2.jar
- commons+codec+1.11.jar
- commons+collections+3.2.2.jar
- commons+collections4+4.2.jar
- commons+dbcp+1.4.jar: db연결
- commons+digester+1.8.1.jar
- commons+discovery+0.2.jar
- commons+pool+1.5.5.jar
- curvesapi+1.0.3.jar
- ehcahce+core+2.6.11.jar
- httpclient+4.5.6.jar
- httpcore+4.4.10.jar
- ibatis+sqlmap+2.3.4.726.jar
- ibatis+sqlmap+2.3.4.726+sources.jar
- icu4j+4.8.1.1.jar
- jdom2+2.0.6.jar
- jsch +0.1.54.jar
- log4j +1.2.17.jar
- mail+1.4.jar
- mybatis+3.2.1.jar
- mybatis+spring+1.2.0.jar
- ojdbc6.jar
- ojdbc14.jar
- poi+3.14.jar
- poi+ooxml+3.14.jar
- poi+ooxml+schemas+3.14.jar
- scpdb.jar
- slf4j+api+1.7.25.jar
- slf4j+log4j12+1.7.25.jar
- stax+api+1.0.1.jar
- velocity+1.7.jar
- xalan+2.6.0.jar
- xml+apis+1.0.b2.jar
- xmlbeans+2.6.0.jar
https://gaeng-stroy.tistory.com/4