2017. 10. 17. 10:48ㆍ99. 정리전 - IT/11. Java
Eclipse STS + Spring Boot(1.5.8) + Gradle + Thymeleaf (Change Template Directory)
+ Embedded Tomcat + 외부 Tomcat
이클립스기동
마켓에서 등록할 목록
STS 프로젝트 생성
외부 tomcat 배포를 위해 War형태로 패키징 하길 바랍니다.
STS 프로젝트 생성된 프로젝트 구조
build.gradle 설정
buildscript { ext { buildVersion = "0.0.1-SNAPSHOT" springBootVersion = '1.5.7.RELEASE' } repositories { mavenCentral() } dependencies { classpath("org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}") } } apply plugin: 'java' apply plugin: 'eclipse-wtp' apply plugin: 'org.springframework.boot' apply plugin: 'war' war { baseName = "homepage-test" version = "${buildVersion}" } group = 'com.bluedigm' version = '0.0.1-SNAPSHOT' sourceCompatibility = 1.8 repositories { mavenCentral() } configurations { providedRuntime } dependencies { compile('net.sourceforge.nekohtml:nekohtml') compile('org.springframework.boot:spring-boot-starter-thymeleaf') compile('org.springframework.boot:spring-boot-starter-web') providedRuntime('org.springframework.boot:spring-boot-starter-tomcat') testCompile('org.springframework.boot:spring-boot-starter-test') }
주의 : 알아야 할 사항
compile('net.sourceforge.nekohtml:nekohtml') 는 닫는 tag를 쓰지 않아도 view단 컴파일 오류 발생하지 않음
또는 Embedded Tomcat인 bootRun으로는 정상 기동 되지만,
외부 Tomcat으로 기동시 Thymeleaf Compile 에러 발생시의 해결 대안 이기도 하다. (찾느라 3일 걸림 ㅠㅠ)
윈도우 환경에서는 에러가 나지 않지만, Mac 환경에서는 이하와 같이 Thymeleaf 코드 컴파일 에러가 터진다.
index.html의 <html> tag를 삭제하면 컴파일 오류가 나지 않고 th tag 컴파일이 잘된다. 완전 버그인듯.
환경 : Eclipse Oxygen / boot 1.5.7 / thymeleaf4 2.1.5
에러내용감상 : org.xml.sax.SAXParseException : 엔티티 참조에서는 '&' 바로 다음에 엔티티 이름이 와야 합니다.
10월 17, 2017 1:40:40 오후 org.apache.tomcat.util.digester.SetPropertiesRule begin
경고: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.j2ee.server:homepage-helper' did not find a matching property.
10월 17, 2017 1:40:40 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Server version: Apache Tomcat/9.0.0.M26
10월 17, 2017 1:40:40 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Server built: Aug 2 2017 20:29:05 UTC
10월 17, 2017 1:40:40 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Server number: 9.0.0.0
10월 17, 2017 1:40:40 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: OS Name: Mac OS X
10월 17, 2017 1:40:40 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: OS Version: 10.12.6
10월 17, 2017 1:40:40 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Architecture: x86_64
10월 17, 2017 1:40:40 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Java Home: /Library/Java/JavaVirtualMachines/jdk1.8.0_131.jdk/Contents/Home/jre
10월 17, 2017 1:40:40 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: JVM Version: 1.8.0_131-b11
10월 17, 2017 1:40:40 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: JVM Vendor: Oracle Corporation
10월 17, 2017 1:40:40 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: CATALINA_BASE: /Users/donz/Desktop/My_Data/project_e/workspace_bd/workspace_homepage/.metadata/.plugins/org.eclipse.wst.server.core/tmp0
10월 17, 2017 1:40:40 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: CATALINA_HOME: /Users/donz/Desktop/My_Data/project_e/tomcat/apache-tomcat-9.0.0.M26
10월 17, 2017 1:40:40 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Command line argument: -Dcatalina.base=/Users/donz/Desktop/My_Data/project_e/workspace_bd/workspace_homepage/.metadata/.plugins/org.eclipse.wst.server.core/tmp0
10월 17, 2017 1:40:40 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Command line argument: -Dcatalina.home=/Users/donz/Desktop/My_Data/project_e/tomcat/apache-tomcat-9.0.0.M26
10월 17, 2017 1:40:40 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Command line argument: -Dwtp.deploy=/Users/donz/Desktop/My_Data/project_e/workspace_bd/workspace_homepage/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps
10월 17, 2017 1:40:40 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Command line argument: -Djava.endorsed.dirs=/Users/donz/Desktop/My_Data/project_e/tomcat/apache-tomcat-9.0.0.M26/endorsed
10월 17, 2017 1:40:40 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Command line argument: -Dfile.encoding=UTF-8
10월 17, 2017 1:40:40 오후 org.apache.catalina.core.AprLifecycleListener lifecycleEvent
정보: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: [/Users/donz/Library/Java/Extensions:/Library/Java/Extensions:/Network/Library/Java/Extensions:/System/Library/Java/Extensions:/usr/lib/java:.]
10월 17, 2017 1:40:40 오후 org.apache.coyote.AbstractProtocol init
정보: Initializing ProtocolHandler ["http-nio-8080"]
10월 17, 2017 1:40:40 오후 org.apache.tomcat.util.net.NioSelectorPool getSharedSelector
정보: Using a shared selector for servlet write/read
10월 17, 2017 1:40:40 오후 org.apache.coyote.AbstractProtocol init
정보: Initializing ProtocolHandler ["ajp-nio-8009"]
10월 17, 2017 1:40:40 오후 org.apache.tomcat.util.net.NioSelectorPool getSharedSelector
정보: Using a shared selector for servlet write/read
10월 17, 2017 1:40:40 오후 org.apache.catalina.startup.Catalina load
정보: Initialization processed in 556 ms
10월 17, 2017 1:40:40 오후 org.apache.catalina.core.StandardService startInternal
정보: Starting service [Catalina]
10월 17, 2017 1:40:40 오후 org.apache.catalina.core.StandardEngine startInternal
정보: Starting Servlet Engine: Apache Tomcat/9.0.0.M26
10월 17, 2017 1:40:44 오후 org.apache.jasper.servlet.TldScanner scanJars
정보: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.
10월 17, 2017 1:40:44 오후 org.apache.catalina.core.ApplicationContext log
정보: 2 Spring WebApplicationInitializers detected on classpath
. ____ _ __ _ _
/\\ / ___'_ __ _ _(_)_ __ __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
\\/ ___)| |_)| | | | | || (_| | ) ) ) )
' |____| .__|_| |_|_| |_\__, | / / / /
=========|_|==============|___/=/_/_/_/
:: Spring Boot :: (v1.5.7.RELEASE)
2017-10-17 13:40:55.037 INFO 7776 --- [ main] com.bluedigm.ServletInitializer : Starting ServletInitializer on Donzui-MacBook-Pro.local with PID 7776 (/Users/donz/Desktop/My_Data/project_e/workspace_bd/workspace_homepage/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/homepage-helper/WEB-INF/classes started by donz in /Users/donz/Desktop/My_Data/project_e/ecipse/ecipse_bd_oxygen/Eclipse.app/Contents/MacOS)
2017-10-17 13:40:55.041 INFO 7776 --- [ main] com.bluedigm.ServletInitializer : No active profile set, falling back to default profiles: default
2017-10-17 13:40:55.254 INFO 7776 --- [ main] ationConfigEmbeddedWebApplicationContext : Refreshing org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext@1f9d6cb3: startup date [Tue Oct 17 13:40:55 KST 2017]; root of context hierarchy
2017-10-17 13:40:56.044 INFO 7776 --- [ main] o.a.c.c.C.[Catalina].[localhost].[/] : Initializing Spring embedded WebApplicationContext
2017-10-17 13:40:56.044 INFO 7776 --- [ main] o.s.web.context.ContextLoader : Root WebApplicationContext: initialization completed in 790 ms
2017-10-17 13:40:56.475 INFO 7776 --- [ main] o.s.b.w.servlet.ServletRegistrationBean : Mapping servlet: 'dispatcherServlet' to [/]
2017-10-17 13:40:56.476 INFO 7776 --- [ main] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'errorPageFilter' to: [/*]
2017-10-17 13:40:56.477 INFO 7776 --- [ main] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'characterEncodingFilter' to: [/*]
2017-10-17 13:40:56.477 INFO 7776 --- [ main] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'hiddenHttpMethodFilter' to: [/*]
2017-10-17 13:40:56.477 INFO 7776 --- [ main] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'httpPutFormContentFilter' to: [/*]
2017-10-17 13:40:56.477 INFO 7776 --- [ main] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'requestContextFilter' to: [/*]
2017-10-17 13:40:56.873 INFO 7776 --- [ main] s.w.s.m.m.a.RequestMappingHandlerAdapter : Looking for @ControllerAdvice: org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext@1f9d6cb3: startup date [Tue Oct 17 13:40:55 KST 2017]; root of context hierarchy
2017-10-17 13:40:56.996 INFO 7776 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/]}" onto public java.lang.String com.bluedigm.controller.CommonController.indexPage(java.lang.String,org.springframework.ui.Model)
2017-10-17 13:40:57.000 INFO 7776 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error]}" onto public org.springframework.http.ResponseEntity<java.util.Map<java.lang.String, java.lang.Object>> org.springframework.boot.autoconfigure.web.BasicErrorController.error(javax.servlet.http.HttpServletRequest)
2017-10-17 13:40:57.000 INFO 7776 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error],produces=[text/html]}" onto public org.springframework.web.servlet.ModelAndView org.springframework.boot.autoconfigure.web.BasicErrorController.errorHtml(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse)
2017-10-17 13:40:57.028 INFO 7776 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/webjars/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-10-17 13:40:57.028 INFO 7776 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-10-17 13:40:57.075 INFO 7776 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**/favicon.ico] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-10-17 13:40:57.142 WARN 7776 --- [ main] .t.AbstractTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
2017-10-17 13:40:57.642 INFO 7776 --- [ main] o.s.j.e.a.AnnotationMBeanExporter : Registering beans for JMX exposure on startup
2017-10-17 13:40:57.659 INFO 7776 --- [ main] com.bluedigm.ServletInitializer : Started ServletInitializer in 13.175 seconds (JVM running for 18.018)
2017-10-17 13:40:57.707 INFO 7776 --- [ main] org.apache.coyote.ajp.AjpNioProtocol : Starting ProtocolHandler ["ajp-nio-8009"]
2017-10-17 13:40:57.708 INFO 7776 --- [ main] org.apache.catalina.startup.Catalina : Server startup in 17381 ms
2017-10-17 13:40:57.775 INFO 7776 --- [nio-8080-exec-1] o.a.c.c.C.[Catalina].[localhost].[/] : Initializing Spring FrameworkServlet 'dispatcherServlet'
2017-10-17 13:40:57.775 INFO 7776 --- [nio-8080-exec-1] o.s.web.servlet.DispatcherServlet : FrameworkServlet 'dispatcherServlet': initialization started
2017-10-17 13:40:57.802 INFO 7776 --- [nio-8080-exec-1] o.s.web.servlet.DispatcherServlet : FrameworkServlet 'dispatcherServlet': initialization completed in 27 ms
2017-10-17 13:40:58.016 ERROR 7776 --- [nio-8080-exec-1] o.thymeleaf.templateparser.ErrorHandler : [THYMELEAF][http-nio-8080-exec-1] Fatal error during parsing
org.xml.sax.SAXParseException: 엔티티 참조에서는 '&' 바로 다음에 엔티티 이름이 와야 합니다.
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:203) ~[na:1.8.0_131]
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(ErrorHandlerWrapper.java:177) ~[na:1.8.0_131]
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:400) [na:1.8.0_131]
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:327) [na:1.8.0_131]
at com.sun.org.apache.xerces.internal.impl.XMLScanner.reportFatalError(XMLScanner.java:1472) [na:1.8.0_131]
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEntityReference(XMLDocumentFragmentScannerImpl.java:1846) [na:1.8.0_131]
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:3061) [na:1.8.0_131]
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:602) [na:1.8.0_131]
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:505) [na:1.8.0_131]
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:841) [na:1.8.0_131]
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:770) [na:1.8.0_131]
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141) [na:1.8.0_131]
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1213) [na:1.8.0_131]
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:643) [na:1.8.0_131]
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.parse(SAXParserImpl.java:327) [na:1.8.0_131]
at org.thymeleaf.templateparser.xmlsax.AbstractNonValidatingSAXTemplateParser.doParse(AbstractNonValidatingSAXTemplateParser.java:209) [thymeleaf-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.thymeleaf.templateparser.xmlsax.AbstractNonValidatingSAXTemplateParser.parseTemplateUsingPool(AbstractNonValidatingSAXTemplateParser.java:134) [thymeleaf-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.thymeleaf.templateparser.xmlsax.AbstractNonValidatingSAXTemplateParser.parseTemplate(AbstractNonValidatingSAXTemplateParser.java:116) [thymeleaf-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.thymeleaf.TemplateRepository.getTemplate(TemplateRepository.java:278) [thymeleaf-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.thymeleaf.TemplateEngine.process(TemplateEngine.java:1104) [thymeleaf-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.thymeleaf.TemplateEngine.process(TemplateEngine.java:1060) [thymeleaf-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.thymeleaf.TemplateEngine.process(TemplateEngine.java:1011) [thymeleaf-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.thymeleaf.spring4.view.ThymeleafView.renderFragment(ThymeleafView.java:335) [thymeleaf-spring4-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.thymeleaf.spring4.view.ThymeleafView.render(ThymeleafView.java:190) [thymeleaf-spring4-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:1286) [spring-webmvc-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.servlet.DispatcherServlet.processDispatchResult(DispatcherServlet.java:1041) [spring-webmvc-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:984) [spring-webmvc-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:901) [spring-webmvc-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:970) [spring-webmvc-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:861) [spring-webmvc-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:634) [servlet-api.jar:na]
at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:846) [spring-webmvc-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:741) [servlet-api.jar:na]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.0.M26]
at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53) [tomcat-websocket.jar:9.0.0.M26]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.0.M26]
at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:99) [spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) [spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.0.M26]
at org.springframework.web.filter.HttpPutFormContentFilter.doFilterInternal(HttpPutFormContentFilter.java:108) [spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) [spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.0.M26]
at org.springframework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:81) [spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) [spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.0.M26]
at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:197) [spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) [spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.0.M26]
at org.springframework.boot.web.support.ErrorPageFilter.doFilter(ErrorPageFilter.java:115) [spring-boot-1.5.7.RELEASE.jar:1.5.7.RELEASE]
at org.springframework.boot.web.support.ErrorPageFilter.access$000(ErrorPageFilter.java:59) [spring-boot-1.5.7.RELEASE.jar:1.5.7.RELEASE]
at org.springframework.boot.web.support.ErrorPageFilter$1.doFilterInternal(ErrorPageFilter.java:90) [spring-boot-1.5.7.RELEASE.jar:1.5.7.RELEASE]
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) [spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.boot.web.support.ErrorPageFilter.doFilter(ErrorPageFilter.java:108) [spring-boot-1.5.7.RELEASE.jar:1.5.7.RELEASE]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96) [catalina.jar:9.0.0.M26]
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:475) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140) [catalina.jar:9.0.0.M26]
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:80) [catalina.jar:9.0.0.M26]
at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:651) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87) [catalina.jar:9.0.0.M26]
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:342) [catalina.jar:9.0.0.M26]
at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:498) [tomcat-coyote.jar:9.0.0.M26]
at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66) [tomcat-coyote.jar:9.0.0.M26]
at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:796) [tomcat-coyote.jar:9.0.0.M26]
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1374) [tomcat-coyote.jar:9.0.0.M26]
at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) [tomcat-coyote.jar:9.0.0.M26]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [na:1.8.0_131]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [na:1.8.0_131]
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-util.jar:9.0.0.M26]
at java.lang.Thread.run(Thread.java:748) [na:1.8.0_131]
2017-10-17 13:40:58.020 ERROR 7776 --- [nio-8080-exec-1] org.thymeleaf.TemplateEngine : [THYMELEAF][http-nio-8080-exec-1] Exception processing template "index": Exception parsing document: template="index", line 7 - column 39
2017-10-17 13:40:58.023 ERROR 7776 --- [nio-8080-exec-1] o.s.boot.web.support.ErrorPageFilter : Forwarding to error page from request [/] due to exception [Exception parsing document: template="index", line 7 - column 39]
org.thymeleaf.exceptions.TemplateInputException: Exception parsing document: template="index", line 7 - column 39
at org.thymeleaf.templateparser.xmlsax.AbstractNonValidatingSAXTemplateParser.parseTemplateUsingPool(AbstractNonValidatingSAXTemplateParser.java:166) ~[thymeleaf-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.thymeleaf.templateparser.xmlsax.AbstractNonValidatingSAXTemplateParser.parseTemplate(AbstractNonValidatingSAXTemplateParser.java:116) ~[thymeleaf-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.thymeleaf.TemplateRepository.getTemplate(TemplateRepository.java:278) ~[thymeleaf-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.thymeleaf.TemplateEngine.process(TemplateEngine.java:1104) ~[thymeleaf-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.thymeleaf.TemplateEngine.process(TemplateEngine.java:1060) ~[thymeleaf-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.thymeleaf.TemplateEngine.process(TemplateEngine.java:1011) ~[thymeleaf-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.thymeleaf.spring4.view.ThymeleafView.renderFragment(ThymeleafView.java:335) ~[thymeleaf-spring4-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.thymeleaf.spring4.view.ThymeleafView.render(ThymeleafView.java:190) ~[thymeleaf-spring4-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:1286) ~[spring-webmvc-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.servlet.DispatcherServlet.processDispatchResult(DispatcherServlet.java:1041) ~[spring-webmvc-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:984) ~[spring-webmvc-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:901) ~[spring-webmvc-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:970) ~[spring-webmvc-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:861) ~[spring-webmvc-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:634) ~[servlet-api.jar:na]
at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:846) ~[spring-webmvc-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:741) ~[servlet-api.jar:na]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.0.M26]
at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53) ~[tomcat-websocket.jar:9.0.0.M26]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.0.M26]
at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:99) ~[spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) [spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.0.M26]
at org.springframework.web.filter.HttpPutFormContentFilter.doFilterInternal(HttpPutFormContentFilter.java:108) ~[spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) [spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.0.M26]
at org.springframework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:81) ~[spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) [spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.0.M26]
at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:197) ~[spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) [spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.0.M26]
at org.springframework.boot.web.support.ErrorPageFilter.doFilter(ErrorPageFilter.java:115) [spring-boot-1.5.7.RELEASE.jar:1.5.7.RELEASE]
at org.springframework.boot.web.support.ErrorPageFilter.access$000(ErrorPageFilter.java:59) [spring-boot-1.5.7.RELEASE.jar:1.5.7.RELEASE]
at org.springframework.boot.web.support.ErrorPageFilter$1.doFilterInternal(ErrorPageFilter.java:90) [spring-boot-1.5.7.RELEASE.jar:1.5.7.RELEASE]
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) [spring-web-4.3.11.RELEASE.jar:4.3.11.RELEASE]
at org.springframework.boot.web.support.ErrorPageFilter.doFilter(ErrorPageFilter.java:108) [spring-boot-1.5.7.RELEASE.jar:1.5.7.RELEASE]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96) [catalina.jar:9.0.0.M26]
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:475) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140) [catalina.jar:9.0.0.M26]
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:80) [catalina.jar:9.0.0.M26]
at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:651) [catalina.jar:9.0.0.M26]
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87) [catalina.jar:9.0.0.M26]
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:342) [catalina.jar:9.0.0.M26]
at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:498) [tomcat-coyote.jar:9.0.0.M26]
at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66) [tomcat-coyote.jar:9.0.0.M26]
at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:796) [tomcat-coyote.jar:9.0.0.M26]
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1374) [tomcat-coyote.jar:9.0.0.M26]
at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) [tomcat-coyote.jar:9.0.0.M26]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [na:1.8.0_131]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [na:1.8.0_131]
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-util.jar:9.0.0.M26]
at java.lang.Thread.run(Thread.java:748) [na:1.8.0_131]
Caused by: org.xml.sax.SAXParseException: 엔티티 참조에서는 '&' 바로 다음에 엔티티 이름이 와야 합니다.
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:203) ~[na:1.8.0_131]
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(ErrorHandlerWrapper.java:177) ~[na:1.8.0_131]
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:400) ~[na:1.8.0_131]
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:327) ~[na:1.8.0_131]
at com.sun.org.apache.xerces.internal.impl.XMLScanner.reportFatalError(XMLScanner.java:1472) ~[na:1.8.0_131]
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEntityReference(XMLDocumentFragmentScannerImpl.java:1846) ~[na:1.8.0_131]
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:3061) ~[na:1.8.0_131]
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:602) ~[na:1.8.0_131]
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:505) ~[na:1.8.0_131]
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:841) ~[na:1.8.0_131]
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:770) ~[na:1.8.0_131]
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141) ~[na:1.8.0_131]
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1213) ~[na:1.8.0_131]
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:643) ~[na:1.8.0_131]
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.parse(SAXParserImpl.java:327) ~[na:1.8.0_131]
at org.thymeleaf.templateparser.xmlsax.AbstractNonValidatingSAXTemplateParser.doParse(AbstractNonValidatingSAXTemplateParser.java:209) ~[thymeleaf-2.1.5.RELEASE.jar:2.1.5.RELEASE]
at org.thymeleaf.templateparser.xmlsax.AbstractNonValidatingSAXTemplateParser.parseTemplateUsingPool(AbstractNonValidatingSAXTemplateParser.java:134) ~[thymeleaf-2.1.5.RELEASE.jar:2.1.5.RELEASE]
... 61 common frames omitted
ThymeleafConfig.java
package com.bluedigm.config; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; import org.thymeleaf.spring4.templateresolver.SpringResourceTemplateResolver; import org.thymeleaf.templateresolver.ITemplateResolver; @Configuration public class ThymeleafConfig { @Bean public ITemplateResolver templateResolver() { SpringResourceTemplateResolver resolver = new SpringResourceTemplateResolver(); resolver.setPrefix("/views/"); resolver.setSuffix(".html"); resolver.setTemplateMode("LEGACYHTML5"); resolver.setCacheable(false); return resolver; } }
neko html 을 활성화 하려면 이하와 같이 선언해야 함
resolver.setTemplateMode("HTML5"); --> resolver.setTemplateMode("LEGACYHTML5");
CommonController.java
package com.bluedigm.controller; import org.springframework.stereotype.Controller; import org.springframework.ui.Model; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestParam; @Controller public class CommonController { @RequestMapping("/") public String indexPage(@RequestParam(value="name", required=false, defaultValue="Donz") String name, Model model) { model.addAttribute("name", name); return "index"; } }
index.html
<!DOCTYPE html> <html xmlns:th="http://www.thymeleaf.org"> <head> <title>Thymeleaf Test</title> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> </head> <body> <p th:text="${'Hello ' + name + '!'}"></p> </body>
gradle.build에 설정된 내용의 관련 jar 내려받기
[sts] -----------------------------------------------------
[sts] Starting Gradle build for the following tasks:
[sts] :homepage-helper:cleanEclipse
[sts] :homepage-helper:eclipse
[sts] -----------------------------------------------------
:homepage-helper:cleanEclipseClasspath
:homepage-helper:cleanEclipseJdt
:homepage-helper:cleanEclipseProject
:homepage-helper:cleanEclipseWtpComponent
:homepage-helper:cleanEclipseWtpFacet
:homepage-helper:cleanEclipseWtp
:homepage-helper:cleanEclipse
:homepage-helper:eclipseClasspath
:homepage-helper:eclipseJdt
:homepage-helper:eclipseProject
:homepage-helper:eclipseWtpComponent
:homepage-helper:eclipseWtpFacet
:homepage-helper:eclipseWtp
:homepage-helper:eclipse
BUILD SUCCESSFUL
Total time: 0.414 secs
[sts] -----------------------------------------------------
[sts] Build finished succesfully!
[sts] Time taken: 0 min, 0 sec
[sts] -----------------------------------------------------
compile 및 war파일 생성하고 embedded tomcat 으로 실행하기
[sts] -----------------------------------------------------
[sts] Starting Gradle build for the following tasks:
[sts] clean
[sts] assemble
[sts] bootRun
[sts] -----------------------------------------------------
:homepage-helper:clean
:homepage-helper:compileJava
:homepage-helper:processResources
:homepage-helper:classes
:homepage-helper:findMainClass
:homepage-helper:war
:homepage-helper:bootRepackage
:homepage-helper:assemble
:homepage-helper:bootRun
. ____ _ __ _ _
/\\ / ___'_ __ _ _(_)_ __ __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
\\/ ___)| |_)| | | | | || (_| | ) ) ) )
' |____| .__|_| |_|_| |_\__, | / / / /
=========|_|==============|___/=/_/_/_/
:: Spring Boot :: (v1.5.7.RELEASE)
2017-10-17 14:35:05.062 INFO 8087 --- [ main] com.bluedigm.HomepageHelperApplication : Starting HomepageHelperApplication on Donzui-MacBook-Pro.local with PID 8087 (/Users/donz/Desktop/My_Data/project_e/workspace_bd/workspace_homepage/homepage/homepage-helper/build/classes/main started by donz in /Users/donz/Desktop/My_Data/project_e/workspace_bd/workspace_homepage/homepage/homepage-helper)
2017-10-17 14:35:05.065 INFO 8087 --- [ main] com.bluedigm.HomepageHelperApplication : No active profile set, falling back to default profiles: default
2017-10-17 14:35:05.225 INFO 8087 --- [ main] ationConfigEmbeddedWebApplicationContext : Refreshing org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext@166fa74d: startup date [Tue Oct 17 14:35:05 KST 2017]; root of context hierarchy
2017-10-17 14:35:06.009 INFO 8087 --- [ main] s.b.c.e.t.TomcatEmbeddedServletContainer : Tomcat initialized with port(s): 8080 (http)
2017-10-17 14:35:06.019 INFO 8087 --- [ main] o.apache.catalina.core.StandardService : Starting service [Tomcat]
2017-10-17 14:35:06.020 INFO 8087 --- [ main] org.apache.catalina.core.StandardEngine : Starting Servlet Engine: Apache Tomcat/8.5.20
2017-10-17 14:35:06.090 INFO 8087 --- [ost-startStop-1] o.a.c.c.C.[Tomcat].[localhost].[/] : Initializing Spring embedded WebApplicationContext
2017-10-17 14:35:06.090 INFO 8087 --- [ost-startStop-1] o.s.web.context.ContextLoader : Root WebApplicationContext: initialization completed in 867 ms
2017-10-17 14:35:06.188 INFO 8087 --- [ost-startStop-1] o.s.b.w.servlet.ServletRegistrationBean : Mapping servlet: 'dispatcherServlet' to [/]
2017-10-17 14:35:06.190 INFO 8087 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'characterEncodingFilter' to: [/*]
2017-10-17 14:35:06.191 INFO 8087 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'hiddenHttpMethodFilter' to: [/*]
2017-10-17 14:35:06.191 INFO 8087 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'httpPutFormContentFilter' to: [/*]
2017-10-17 14:35:06.191 INFO 8087 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'requestContextFilter' to: [/*]
2017-10-17 14:35:06.419 INFO 8087 --- [ main] s.w.s.m.m.a.RequestMappingHandlerAdapter : Looking for @ControllerAdvice: org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext@166fa74d: startup date [Tue Oct 17 14:35:05 KST 2017]; root of context hierarchy
2017-10-17 14:35:06.467 INFO 8087 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/]}" onto public java.lang.String com.bluedigm.controller.CommonController.indexPage(java.lang.String,org.springframework.ui.Model)
2017-10-17 14:35:06.469 INFO 8087 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error]}" onto public org.springframework.http.ResponseEntity<java.util.Map<java.lang.String, java.lang.Object>> org.springframework.boot.autoconfigure.web.BasicErrorController.error(javax.servlet.http.HttpServletRequest)
2017-10-17 14:35:06.470 INFO 8087 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error],produces=[text/html]}" onto public org.springframework.web.servlet.ModelAndView org.springframework.boot.autoconfigure.web.BasicErrorController.errorHtml(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse)
2017-10-17 14:35:06.492 INFO 8087 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/webjars/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-10-17 14:35:06.493 INFO 8087 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-10-17 14:35:06.520 INFO 8087 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**/favicon.ico] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-10-17 14:35:06.543 WARN 8087 --- [ main] .t.AbstractTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
2017-10-17 14:35:06.834 INFO 8087 --- [ main] o.s.j.e.a.AnnotationMBeanExporter : Registering beans for JMX exposure on startup
2017-10-17 14:35:06.885 INFO 8087 --- [ main] s.b.c.e.t.TomcatEmbeddedServletContainer : Tomcat started on port(s): 8080 (http)
2017-10-17 14:35:06.889 INFO 8087 --- [ main] com.bluedigm.HomepageHelperApplication : Started HomepageHelperApplication in 12.071 seconds (JVM running for 12.346)
브라우저에서 확인
배포 환경처럼 구성하기 위해 "외부 Tomcat" 으로 실행하기
상기의 화면에서는 꼭 "save" 해 주세요.
그리고 기동하기!
bootRun과 동일한 환경으로 실행됨을 확인
10월 17, 2017 2:53:31 오후 org.apache.tomcat.util.digester.SetPropertiesRule begin
경고: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.j2ee.server:homepage-helper' did not find a matching property.
10월 17, 2017 2:53:31 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Server version: Apache Tomcat/9.0.0.M26
10월 17, 2017 2:53:31 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Server built: Aug 2 2017 20:29:05 UTC
10월 17, 2017 2:53:31 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Server number: 9.0.0.0
10월 17, 2017 2:53:31 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: OS Name: Mac OS X
10월 17, 2017 2:53:31 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: OS Version: 10.12.6
10월 17, 2017 2:53:31 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Architecture: x86_64
10월 17, 2017 2:53:31 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Java Home: /Library/Java/JavaVirtualMachines/jdk1.8.0_131.jdk/Contents/Home/jre
10월 17, 2017 2:53:31 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: JVM Version: 1.8.0_131-b11
10월 17, 2017 2:53:31 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: JVM Vendor: Oracle Corporation
10월 17, 2017 2:53:31 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: CATALINA_BASE: /Users/donz/Desktop/My_Data/project_e/workspace_bd/workspace_homepage/.metadata/.plugins/org.eclipse.wst.server.core/tmp0
10월 17, 2017 2:53:31 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: CATALINA_HOME: /Users/donz/Desktop/My_Data/project_e/tomcat/apache-tomcat-9.0.0.M26
10월 17, 2017 2:53:31 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Command line argument: -Dcatalina.base=/Users/donz/Desktop/My_Data/project_e/workspace_bd/workspace_homepage/.metadata/.plugins/org.eclipse.wst.server.core/tmp0
10월 17, 2017 2:53:31 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Command line argument: -Dcatalina.home=/Users/donz/Desktop/My_Data/project_e/tomcat/apache-tomcat-9.0.0.M26
10월 17, 2017 2:53:31 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Command line argument: -Dwtp.deploy=/Users/donz/Desktop/My_Data/project_e/workspace_bd/workspace_homepage/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps
10월 17, 2017 2:53:31 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Command line argument: -Djava.endorsed.dirs=/Users/donz/Desktop/My_Data/project_e/tomcat/apache-tomcat-9.0.0.M26/endorsed
10월 17, 2017 2:53:31 오후 org.apache.catalina.startup.VersionLoggerListener log
정보: Command line argument: -Dfile.encoding=UTF-8
10월 17, 2017 2:53:31 오후 org.apache.catalina.core.AprLifecycleListener lifecycleEvent
정보: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: [/Users/donz/Library/Java/Extensions:/Library/Java/Extensions:/Network/Library/Java/Extensions:/System/Library/Java/Extensions:/usr/lib/java:.]
10월 17, 2017 2:53:31 오후 org.apache.coyote.AbstractProtocol init
정보: Initializing ProtocolHandler ["http-nio-8080"]
10월 17, 2017 2:53:31 오후 org.apache.tomcat.util.net.NioSelectorPool getSharedSelector
정보: Using a shared selector for servlet write/read
10월 17, 2017 2:53:31 오후 org.apache.coyote.AbstractProtocol init
정보: Initializing ProtocolHandler ["ajp-nio-8009"]
10월 17, 2017 2:53:31 오후 org.apache.tomcat.util.net.NioSelectorPool getSharedSelector
정보: Using a shared selector for servlet write/read
10월 17, 2017 2:53:31 오후 org.apache.catalina.startup.Catalina load
정보: Initialization processed in 506 ms
10월 17, 2017 2:53:31 오후 org.apache.catalina.core.StandardService startInternal
정보: Starting service [Catalina]
10월 17, 2017 2:53:31 오후 org.apache.catalina.core.StandardEngine startInternal
정보: Starting Servlet Engine: Apache Tomcat/9.0.0.M26
10월 17, 2017 2:53:34 오후 org.apache.jasper.servlet.TldScanner scanJars
정보: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.
10월 17, 2017 2:53:34 오후 org.apache.catalina.core.ApplicationContext log
정보: 2 Spring WebApplicationInitializers detected on classpath
. ____ _ __ _ _
/\\ / ___'_ __ _ _(_)_ __ __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
\\/ ___)| |_)| | | | | || (_| | ) ) ) )
' |____| .__|_| |_|_| |_\__, | / / / /
=========|_|==============|___/=/_/_/_/
:: Spring Boot :: (v1.5.7.RELEASE)
2017-10-17 14:53:45.367 INFO 8163 --- [ main] com.bluedigm.ServletInitializer : Starting ServletInitializer on Donzui-MacBook-Pro.local with PID 8163 (/Users/donz/Desktop/My_Data/project_e/workspace_bd/workspace_homepage/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/homepage-helper/WEB-INF/classes started by donz in /Users/donz/Desktop/My_Data/project_e/ecipse/ecipse_bd_oxygen/Eclipse.app/Contents/MacOS)
2017-10-17 14:53:45.371 INFO 8163 --- [ main] com.bluedigm.ServletInitializer : No active profile set, falling back to default profiles: default
2017-10-17 14:53:45.579 INFO 8163 --- [ main] ationConfigEmbeddedWebApplicationContext : Refreshing org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext@5d978663: startup date [Tue Oct 17 14:53:45 KST 2017]; root of context hierarchy
2017-10-17 14:53:46.306 INFO 8163 --- [ main] o.a.c.c.C.[Catalina].[localhost].[/] : Initializing Spring embedded WebApplicationContext
2017-10-17 14:53:46.306 INFO 8163 --- [ main] o.s.web.context.ContextLoader : Root WebApplicationContext: initialization completed in 727 ms
2017-10-17 14:53:46.708 INFO 8163 --- [ main] o.s.b.w.servlet.ServletRegistrationBean : Mapping servlet: 'dispatcherServlet' to [/]
2017-10-17 14:53:46.709 INFO 8163 --- [ main] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'errorPageFilter' to: [/*]
2017-10-17 14:53:46.709 INFO 8163 --- [ main] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'characterEncodingFilter' to: [/*]
2017-10-17 14:53:46.709 INFO 8163 --- [ main] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'hiddenHttpMethodFilter' to: [/*]
2017-10-17 14:53:46.709 INFO 8163 --- [ main] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'httpPutFormContentFilter' to: [/*]
2017-10-17 14:53:46.709 INFO 8163 --- [ main] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'requestContextFilter' to: [/*]
2017-10-17 14:53:47.156 INFO 8163 --- [ main] s.w.s.m.m.a.RequestMappingHandlerAdapter : Looking for @ControllerAdvice: org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext@5d978663: startup date [Tue Oct 17 14:53:45 KST 2017]; root of context hierarchy
2017-10-17 14:53:47.240 INFO 8163 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/]}" onto public java.lang.String com.bluedigm.controller.CommonController.indexPage(java.lang.String,org.springframework.ui.Model)
2017-10-17 14:53:47.243 INFO 8163 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error]}" onto public org.springframework.http.ResponseEntity<java.util.Map<java.lang.String, java.lang.Object>> org.springframework.boot.autoconfigure.web.BasicErrorController.error(javax.servlet.http.HttpServletRequest)
2017-10-17 14:53:47.244 INFO 8163 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error],produces=[text/html]}" onto public org.springframework.web.servlet.ModelAndView org.springframework.boot.autoconfigure.web.BasicErrorController.errorHtml(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse)
2017-10-17 14:53:47.275 INFO 8163 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/webjars/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-10-17 14:53:47.275 INFO 8163 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-10-17 14:53:47.373 INFO 8163 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**/favicon.ico] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
2017-10-17 14:53:47.430 WARN 8163 --- [ main] .t.AbstractTemplateResolverConfiguration : Cannot find template location: classpath:/templates/ (please add some templates or check your Thymeleaf configuration)
2017-10-17 14:53:47.796 INFO 8163 --- [ main] o.s.j.e.a.AnnotationMBeanExporter : Registering beans for JMX exposure on startup
2017-10-17 14:53:47.809 INFO 8163 --- [ main] com.bluedigm.ServletInitializer : Started ServletInitializer in 12.948 seconds (JVM running for 17.211)
2017-10-17 14:53:47.851 INFO 8163 --- [ main] org.apache.coyote.ajp.AjpNioProtocol : Starting ProtocolHandler ["ajp-nio-8009"]
2017-10-17 14:53:47.852 INFO 8163 --- [ main] org.apache.catalina.startup.Catalina : Server startup in 16617 ms
2017-10-17 14:53:47.908 INFO 8163 --- [nio-8080-exec-1] o.a.c.c.C.[Catalina].[localhost].[/] : Initializing Spring FrameworkServlet 'dispatcherServlet'
2017-10-17 14:53:47.909 INFO 8163 --- [nio-8080-exec-1] o.s.web.servlet.DispatcherServlet : FrameworkServlet 'dispatcherServlet': initialization started
2017-10-17 14:53:47.932 INFO 8163 --- [nio-8080-exec-1] o.s.web.servlet.DispatcherServlet : FrameworkServlet 'dispatcherServlet': initialization completed in 23 ms