I would like to put two small constant objects (one TreeMap and one ArrayList) somewhere in the ServletContext of a Struts2 webapp (running under Tomcat 6), such that those objects may be accessible from any JSP, through the Application Scope.
Under Struts1, I would have used one of those startup "plug-ins" (defined in struts-config.xml). Is there an equivalent way of achieving the same result with Struts2?
Alternatively (and maybe even better), since my webapp uses Spring configured in Tomcat with Spring's ContextLoaderListener, can I rely on Spring instead? For instance by creating a bean that declares some appropriate "ApplicationAware" interface...