Advertisement
Guest User

Untitled

a guest
Apr 12th, 2012
55
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.40 KB | None | 0 0
  1. Glassfish Spring
  2. <context-param>
  3. <param-name>contextConfigLocation</param-name>
  4. <param-value>
  5. /WEB-INF/applicationContext.xml
  6. etc etc
  7. </param-value>
  8. </context-param>
  9.  
  10. <listener>
  11. <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
  12. </listener>
  13.  
  14. <servlet>
  15. <servlet-name>dispatcher</servlet-name>
  16. <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
  17. <load-on-startup>1</load-on-startup>
  18. </servlet>
  19.  
  20. <servlet-mapping>
  21. <servlet-name>dispatcher</servlet-name>
  22. <url-pattern>/myApp/*</url-pattern>
  23. </servlet-mapping>
  24.  
  25. <context-param>
  26. <param-name>contextConfigLocation</param-name>
  27. <!-- All file ends with Context.xml under web-inf folder -->
  28. <param-value>WEB-INF/*Context.xml</param-value>
  29. </context-param>
  30.  
  31.  
  32. <listener>
  33. <display-name>Spring context loader</display-name>
  34. <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
  35. <!-- use following if you want to use request scope -->
  36. <!-- org.springframework.web.context.request.RequestContextListener -->
  37. </listener>
  38.  
  39. <servlet>
  40. <servlet-name>servlet name</servlet-name>
  41. <servlet-class>org.springframework.web.context.support.HttpRequestHandlerServlet</servlet-class>
  42. </servlet>
  43.  
  44. <servlet-mapping>
  45. <servlet-name>name</servlet-name>
  46. <url-pattern>/URLName</url-pattern>
  47. </servlet-mapping>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement