java - Spring Maven - context configuration in resources folder -
as found in other question @ stackoverflow, better keep configuration of spring in src/main/resources folder. when use mvn jetty:run tries load context configuration web-inf whatever i'm typing web.xml. following error:
javax.servlet.servletexception: org.springframework.beans.factory.beandefinitionstoreexception: ioexception parsing xml document servletcontext resource [/web-inf/easyscrum-servlet.xml]; nested exception java.io.filenotfoundexception: not open servletcontext resource [/web-inf/easyscrum-servlet.xml]
what should force servlet load config classpath instead of web-inf?
to load spring config context files classpath have prefix path classpath:
<context-param> <param-name>contextconfiglocation</param-name> <param-value> classpath:context.xml </param-value> </context-param>
Comments
Post a Comment