[JBoss JIRA] Created: (JBSEAM-4623) ServletContext is application scoped even though several can exist in one .ear
by Kasper Sørensen (JIRA)
ServletContext is application scoped even though several can exist in one .ear
------------------------------------------------------------------------------
Key: JBSEAM-4623
URL: https://jira.jboss.org/jira/browse/JBSEAM-4623
Project: Seam
Issue Type: Bug
Components: Core
Affects Versions: 2.2.1.CR1
Reporter: Kasper Sørensen
When creating an .ear project with multiple .war files, several servlet contexts will exist, but Seam registers only a single servlet context in the application scope. This application scoped servlet context is used a lot of places through the ServletLifecycle class.
To reproduce, try the following:
ServletContext servletLifecycleServletContext = ServletLifecycle.getCurrentServletContext();
ServletContext facesContextServletContext = (ServletContext) FacesContext.getCurrentInstance().getExternalContext().getContext();
This will return two different servlet contexts if called from the webapp that was not registered in application scope.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 7 months
[JBoss JIRA] Created: (JBSEAM-4622) Event org.jboss.seam.noConversation no caught for long running natural conversation where conversation id is missing
by Tomas Cerny (JIRA)
Event org.jboss.seam.noConversation no caught for long running natural conversation where conversation id is missing
--------------------------------------------------------------------------------------------------------------------
Key: JBSEAM-4622
URL: https://jira.jboss.org/jira/browse/JBSEAM-4622
Project: Seam
Issue Type: Bug
Components: Core
Affects Versions: 2.2.0.GA
Reporter: Tomas Cerny
Event org.jboss.seam.noConversation no caught for long running natural conversation where conversation id is missing
if I have a conversation that has a name - lets say "CCC"
and I go to a page "URL/page.seam?CCC=1 " with no active conversation I get the event org.jboss.seam.noConversation
but if I go to a page "URL/page.seam?XXX=1 " with no active conversation I DO NOT get the event org.jboss.seam.noConversation
all the redirects will not come then an I end up with java.lang.IllegalStateException
19:50:09,175 WARN [Component] Cannot create Seam component, scope is not active: myActionManager(CONVERSATION)
19:50:09,175 WARN [SeamPhaseListener] uncaught exception, passing to exception handler
java.lang.IllegalStateException: conversation id evaluated to null: CCC
at org.jboss.seam.navigation.NaturalConversationIdParameter.getParameterValue(NaturalConversationIdParameter.java:70)
at org.jboss.seam.navigation.NaturalConversationIdParameter.getConversationId(NaturalConversationIdParameter.java:62)
at org.jboss.seam.navigation.NaturalConversationIdParameter.getInitialConversationId(NaturalConversationIdParameter.java:44)
at org.jboss.seam.faces.FacesManager.generateInitialConversationId(FacesManager.java:116)
at org.jboss.seam.core.Manager.initializeTemporaryConversation(Manager.java:651)
at org.jboss.seam.core.Manager.restoreAndLockConversation(Manager.java:613)
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 7 months
[JBoss JIRA] Created: (JBSEAM-4620) back port fix from JBSEAM-4316-Classloader cannot find XML files in multiple WARs
by Marek Novotny (JIRA)
back port fix from JBSEAM-4316-Classloader cannot find XML files in multiple WARs
---------------------------------------------------------------------------------
Key: JBSEAM-4620
URL: https://jira.jboss.org/jira/browse/JBSEAM-4620
Project: Seam
Issue Type: Bug
Components: Core
Affects Versions: 2.2.0.CR1
Environment: JBoss AS 5.0.0.GA. Seam 2.2 r11299
Reporter: Reind D
Assignee: Marek Novotny
Fix For: 2.2.1.CR1
I have an EAR that contains multiple WAR files. The first webapp to be accessed works fine. Any web request to the 2nd WAR to be accessed causes the following error:
WARN [VFSScanner] Error handling item 'login/index.page.xml': java.lang.NullPointerException: Cannot find URL from classLoader for login/index.page.xml, loading from org.jboss.web.tomcat.service.WebCtxLoader$ENCLoader@1ed964f
FileDescriptor.java calls:
Resources.getResource(name, ServletLifecycle.getServletContext());
Which returns a static reference to the ServletContext which is overwritten by the last webapp to be initialized.
private static ServletContext servletContext;
public static ServletContext getServletContext()
{
//don't throw an exception if null, because of unit tests
return servletContext;
}
The 2nd webapp to be initialized will have a reference to the first webapp's ServletContext.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 7 months
[JBoss JIRA] Created: (JBSEAM-4619) back port fix from JBSEAM-2292-Resources from resource servlet can't be re-rendered
by Marek Novotny (JIRA)
back port fix from JBSEAM-2292-Resources from resource servlet can't be re-rendered
-----------------------------------------------------------------------------------
Key: JBSEAM-4619
URL: https://jira.jboss.org/jira/browse/JBSEAM-4619
Project: Seam
Issue Type: Bug
Components: JSF Integration
Reporter: Christian Bauer
Assignee: Shane Bryzak
Fix For: 2.2.1.CR1
Found this after using the captcha:
<div class="input">
<a:region>
<s:validateAll>
<h:graphicImage value="/seam/resource/captcha" style="vertical-align:text-bottom;"/>
<h:inputText tabindex="1" size="6" maxlength="6" required="true" id="verifyCaptcha" value="#{captcha.response}">
<a:support status="#{statusId}" event="onblur" reRender="verifyCaptchaEntry"/>
</h:inputText>
</s:validateAll>
</a:region>
</div>
This is a re-rendered s:decorate form field, so that onblur we get a new challenge (if the captcha repsonse was wrong). However, the graphicImage is not reloaded from the server, the browser caches it. To prevent browser caching, this is a quick hack:
<div class="input">
<a:region>
<s:validateAll>
<h:graphicImage value="/seam/resource/captcha?nocache=#{wiki:generateRandomNumber()}" style="vertical-align:text-bottom;"/>
<h:inputText tabindex="1" size="6" maxlength="6" required="true" id="verifyCaptcha" value="#{captcha.response}">
<a:support status="#{statusId}" event="onblur" reRender="verifyCaptchaEntry"/>
</h:inputText>
</s:validateAll>
</a:region>
</div>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 7 months
[JBoss JIRA] Created: (JBSEAM-4616) back port fix from JBSEAM-4203-Interpolator swallows all exceptions
by Marek Novotny (JIRA)
back port fix from JBSEAM-4203-Interpolator swallows all exceptions
-------------------------------------------------------------------
Key: JBSEAM-4616
URL: https://jira.jboss.org/jira/browse/JBSEAM-4616
Project: Seam
Issue Type: Bug
Components: Core
Affects Versions: 2.1.2.CR1
Environment: Any
Reporter: Yuriy Lazarev
Assignee: Marek Novotny
Fix For: 2.2.1.CR1
org.jboss.seam.core.Interpolator swallows all exceptions, so if I have #{entityHome.instance.name} somewere in the page, and entityHome has id which is missed from database - I expect that org.jboss.seam.framework.EntityNotFoundException will be handled by this block in pages.xml
<exception class = "org.jboss.seam.framework.EntityNotFoundException">
<redirect view-id = "/error.xhtml">
<message severity = "warn">#{messages['org.jboss.seam.framework.EntityNotFoundException']}</message>
</redirect>
</exception>
but, instead I got
[WARN] exception interpolating string: #{entityHome.instance.name}
This is due
Interpolator.java:131
} catch (Exception e) {
log.warn("exception interpolating string: " + string, e);
}
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 7 months