[
http://jira.jboss.com/jira/browse/JBSEAM-1246?page=all ]
Christian Bauer updated JBSEAM-1246:
------------------------------------
Summary: Make ServletContext available during startup (was: Make pages.xml available
during application startup)
I renamed this issue because what we really need is a way to access the ServletContext
when the SeamListener starts up. Only at that time can you use getResourcePaths() and
getResourceAsStream() to look for and process files in your deployment (which the Seam
scanner does not cover). This is required to build internal registries in applications,
e.g. "all names of directories in my view folder in /templates/".
The Initialization.java class currently has a private reference to that ServletContext we
need, during startup. We need to expose this with an API, also without conflicting with
the request-based ServletContexts.instance() API already present.
Make ServletContext available during startup
--------------------------------------------
Key: JBSEAM-1246
URL:
http://jira.jboss.com/jira/browse/JBSEAM-1246
Project: Seam
Issue Type: Feature Request
Components: Core
Affects Versions: 1.2.1.GA
Environment: Any
Reporter: Mike Quilleash
pages.xml will not be found by the resource loader when the Pages component is @Created
during startup ie outside a JSF request. One of my components that queries the Pages
component is causing the component to be created and look for its pages outside a JSF
request.
The only resource lookup that can succeed for something in WEB-INF is the
ExternalContext.getResource() but this is not available outside a JSF request.
Using ServletContext.getResource() will work instead however this is not portable to
Portlets etc.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira