[
https://issues.jboss.org/browse/RF-10998?page=com.atlassian.jira.plugin.s...
]
Shah EM commented on RF-10998:
------------------------------
This issue happens because of concurrent access of same request object in some weird
cases. To avoid this we have implemented the queue.
We have defined Global queue in the web.xml. Please note that the Global queue can have a
bit performance hit. If you know which page is causing the issue then in that case you can
define queue at page level.
Global queue :
A global queue is used by all the pages in the application. A global queue is defined in
the web.xml file:
<context-param>
<param-name>org.richfaces.queue.global.enabled</param-name>
<param-value>true</param-value>
</context-param>
The above is equivalent to adding the following to every page in your application:
<a4j:queue name="org.richfaces.queue.global"/>
The global queue name is org.richfaces.queue.global. To set attributes on the queue, we
use the queue name like this:
<a4j:queue name="org.richfaces.queue.global"
requestDelay="3000"/>
Request delay will be set for the current page only.
If you need to disable the global on any particular page, then the disabled attribute can
be used:
<a4j:queue disabled="true" name="org.richfaces.queue.global"/>
High CPU Utilization in Richfaces application
---------------------------------------------
Key: RF-10998
URL:
https://issues.jboss.org/browse/RF-10998
Project: RichFaces
Issue Type: Bug
Security Level: Public(Everyone can see)
Affects Versions: 3.3.2.SR1
Environment: Jboss 4.3.0.GA_CP03, jdk 1.6.0_05,jsf 1.2,facelets 1.1.14
Reporter: Shah EM
Labels: richfaces
Fix For: 3.Future
We have an application running on 3 node
cluster.After running normally for some time one node CPU spikes to 80% from
the normal usage of 6% and stays like that. meanwhile other nodes are working
fine.
We had contacted Redhat and they had advised to downgrad richfaces version to 3.3.1 sp2
to fix the issue.
We have a doubt if the solution provided by Redhat to downgrade the rich faces version to
3.3.1-SP2 will solve the issue or not.
The 3.3.1-SP2 release note says that the following issue is fixed - [RF-7248] - a4j
creates infinite HashMap.get loop
When we looked into more details of this issue that they fixed in the JBoss JIRA for this
defect, the logs say that the issue is with a specific component in the a4j. Please have a
look at the following trace from the issue logs.
Stack trace:
java.util.HashMap.get(HashMap.java:303)
org.ajax4jsf.component.UIDataAdaptor.restoreChildState(UIDataAdaptor.java:965)
org.ajax4jsf.component.UIDataAdaptor.restoreChildState(UIDataAdaptor.java:984)
org.ajax4jsf.component.UIDataAdaptor.restoreChildState(UIDataAdaptor.java:943)
In our case even though the issue is with the HashMap infinite loop, the cause of the
issue does not seem to be this particular component. Our stack traces point to a different
place where the infinite loop is happening.
Thread: http-10.20.81.200-17180-31 : priority:5, demon:true, threadId:337,
threadState:RUNNABLE, lockName:null
java.util.HashMap.get(HashMap.java:305)
org.apache.catalina.connector.Request.getAttribute(Request.java:878)
org.apache.catalina.connector.RequestFacade.getAttribute(RequestFacade.java:263)
com.sun.faces.application.WebappLifecycleListener.attributeReplaced(WebappLifecycleListener.java:168)
com.sun.faces.config.ConfigureListener.attributeReplaced(ConfigureListener.java:318)
org.apache.catalina.connector.Request.setAttribute(Request.java:1435)
org.apache.catalina.connector.RequestFacade.setAttribute(RequestFacade.java:503)
javax.servlet.ServletRequestWrapper.setAttribute(ServletRequestWrapper.java:284)
com.sun.faces.context.RequestMap.put(ExternalContextImpl.java:1087)
org.ajax4jsf.event.AjaxPhaseListener.afterPhase(AjaxPhaseListener.java:81)
com.sun.faces.lifecycle.Phase.handleAfterPhase(Phase.java:175)
com.sun.faces.lifecycle.Phase.doPhase(Phase.java:114)
com.sun.faces.lifecycle.RestoreViewPhase.doPhase(RestoreViewPhase.java:104)
com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:
http://www.atlassian.com/software/jira