| Line 17... |
Line 17... |
| 17 |
public class SpringWebAppInitializer implements WebApplicationInitializer{
|
17 |
public class SpringWebAppInitializer implements WebApplicationInitializer{
|
| 18 |
|
18 |
|
| 19 |
private static final Logger LOGGER=LoggerFactory.getLogger(SpringWebAppInitializer.class);
|
19 |
private static final Logger LOGGER=LoggerFactory.getLogger(SpringWebAppInitializer.class);
|
| 20 |
|
20 |
|
| 21 |
private static final String DISPATCHER_SERVLET_NAME="DispatcherServlet";
|
21 |
private static final String DISPATCHER_SERVLET_NAME="DispatcherServlet";
|
| 22 |
private static final String SPRING_CONFIG_PACKAGE_LOCATION="com.spice.profitmandi.config";
|
22 |
private static final String SPRING_CONFIG_PACKAGE_LOCATION="com.spice.profitmandi.web.config";
|
| 23 |
|
23 |
|
| 24 |
public void onStartup(ServletContext servletContext) throws ServletException {
|
24 |
public void onStartup(ServletContext servletContext) throws ServletException {
|
| 25 |
WebApplicationContext context = getContext();
|
25 |
WebApplicationContext context = getContext();
|
| 26 |
servletContext.addListener(new ContextLoaderListener(context));
|
26 |
servletContext.addListener(new ContextLoaderListener(context));
|
| 27 |
ServletRegistration.Dynamic dispatcher = servletContext.addServlet(DISPATCHER_SERVLET_NAME, new DispatcherServlet(context));
|
27 |
ServletRegistration.Dynamic dispatcher = servletContext.addServlet(DISPATCHER_SERVLET_NAME, new DispatcherServlet(context));
|