JSF-Primefaces App: Memory not releasing & Performance impact issue
I have created Web application using JSF & Primefaces. It is consuming more memory & also not releasing memory.
Also, there is a Performance impact on the application.
Web Server: Apache Tomcat 7.0.32
Please guide me in resolving the issue.
JSF-Primefaces App:Memory not releasing & Performance impact
-
- Posts: 30
- Joined: 04 Jul 2012, 17:37
PrimeFaces 6.0 | Apache Tomcat 7.0.53, 7.0.x | Mojarra 2.2.8
Windows 7, Ubuntu | Firefox 50
Windows 7, Ubuntu | Firefox 50
-
- PrimeFaces Core Developer
- Posts: 3979
- Joined: 03 Dec 2010, 14:11
- Location: Bavaria, DE
- Contact:
use a profiler
Thomas Andraschko
PrimeFaces | PrimeFaces Extensions
Apache Member | OpenWebBeans, DeltaSpike, MyFaces, BVal, TomEE
Sponsor me: https://github.com/sponsors/tandraschko
Blog: http://tandraschko.blogspot.de/
Twitter: https://twitter.com/TAndraschko
PrimeFaces | PrimeFaces Extensions
Apache Member | OpenWebBeans, DeltaSpike, MyFaces, BVal, TomEE
Sponsor me: https://github.com/sponsors/tandraschko
Blog: http://tandraschko.blogspot.de/
Twitter: https://twitter.com/TAndraschko
-
- Posts: 6144
- Joined: 10 Sep 2011, 21:10
Please click on ALL of the following, read ALL of them, and then proceed with the memory and performance of your app.
Increase your JSF application performance (Part 1 - Environment & Configuration)
Increase your JSF application performance (Part 2 - Design Patterns)
Improve the Performance of Java EE Applications
JSF Performance: Mojarra improves dramatically with latest release
JSF-Comparison: MyFaces vs. Mojarra
Understanding JSF 2.0 Performance - Part 1
Understanding JSF 2.0 Performance - Part 2
Understanding JSF 2.0 Performance - Part 3
search google for: java memory leak, and read as many of those articles as possible until you understand how to fix memory leaks in your app
Increase your JSF application performance (Part 1 - Environment & Configuration)
Increase your JSF application performance (Part 2 - Design Patterns)
Improve the Performance of Java EE Applications
JSF Performance: Mojarra improves dramatically with latest release
JSF-Comparison: MyFaces vs. Mojarra
Understanding JSF 2.0 Performance - Part 1
Understanding JSF 2.0 Performance - Part 2
Understanding JSF 2.0 Performance - Part 3
search google for: java memory leak, and read as many of those articles as possible until you understand how to fix memory leaks in your app
Howard
PrimeFaces 6.0, Extensions 6.0.0, Push (Atmosphere 2.4.0)
TomEE+ 1.7.4 (Tomcat 7.0.68), MyFaces Core 2.2.9, JDK8
JUEL 2.2.7 | OmniFaces | EclipseLink-JPA/Derby | Chrome
Java EE 6 Tutorial|NetBeans|Google|Stackoverflow|PrimeFaces|Apache
PrimeFaces 6.0, Extensions 6.0.0, Push (Atmosphere 2.4.0)
TomEE+ 1.7.4 (Tomcat 7.0.68), MyFaces Core 2.2.9, JDK8
JUEL 2.2.7 | OmniFaces | EclipseLink-JPA/Derby | Chrome
Java EE 6 Tutorial|NetBeans|Google|Stackoverflow|PrimeFaces|Apache
@Howard: nice summary, maybe BalusC should create a tab for this on http://jsf.zeef.com.
But the referecence to the 'old' Mojarra vs MyFaces (the one with the hockeystick curve) should not be in there I think.
But the referecence to the 'old' Mojarra vs MyFaces (the one with the hockeystick curve) should not be in there I think.
-
- PrimeFaces Core Developer
- Posts: 3979
- Joined: 03 Dec 2010, 14:11
- Location: Bavaria, DE
- Contact:
I think/believe there is still a big difference or did they more performance improvements? I'm only aware about the issue with a big view with many components.kukeltje wrote:But the referecence to the 'old' Mojarra vs MyFaces (the one with the hockeystick curve) should not be in there I think.
But maybe someone should run the benchmark again
Thomas Andraschko
PrimeFaces | PrimeFaces Extensions
Apache Member | OpenWebBeans, DeltaSpike, MyFaces, BVal, TomEE
Sponsor me: https://github.com/sponsors/tandraschko
Blog: http://tandraschko.blogspot.de/
Twitter: https://twitter.com/TAndraschko
PrimeFaces | PrimeFaces Extensions
Apache Member | OpenWebBeans, DeltaSpike, MyFaces, BVal, TomEE
Sponsor me: https://github.com/sponsors/tandraschko
Blog: http://tandraschko.blogspot.de/
Twitter: https://twitter.com/TAndraschko
-
- Prime
- Posts: 18616
- Joined: 05 Jan 2009, 00:21
- Location: Cybertron
- Contact:
Avoid component binding to a session, view scoped bean.
@Oleg: they did. The link above the one with the hockeystick curve: https://blog.oio.de/2013/05/16/jsf-perf ... t-release/
-
- PrimeFaces Core Developer
- Posts: 3979
- Joined: 03 Dec 2010, 14:11
- Location: Bavaria, DE
- Contact:
Thomas, not Olegkukeltje wrote:@Oleg: they did. The link above the one with the hockeystick curve: https://blog.oio.de/2013/05/16/jsf-perf ... t-release/
Ahh i see, that would be the better link of course!
Thomas Andraschko
PrimeFaces | PrimeFaces Extensions
Apache Member | OpenWebBeans, DeltaSpike, MyFaces, BVal, TomEE
Sponsor me: https://github.com/sponsors/tandraschko
Blog: http://tandraschko.blogspot.de/
Twitter: https://twitter.com/TAndraschko
PrimeFaces | PrimeFaces Extensions
Apache Member | OpenWebBeans, DeltaSpike, MyFaces, BVal, TomEE
Sponsor me: https://github.com/sponsors/tandraschko
Blog: http://tandraschko.blogspot.de/
Twitter: https://twitter.com/TAndraschko
-
- Posts: 30
- Joined: 04 Jul 2012, 17:37
Thanks for all posts.
I have read them and shared consolidated issues list below:
1. I am using Mojarra 2.2.6. Would you recommend migrating to MyFaces for better performance.
2. I am using ViewScoped Beans for my page.
I am not binding components to ViewScope Beans, instead I am mapping Component Value to beans objects.
I have noticed that while navigating from one page to other page, Beans objects are not removed from SessionScope.
(ViewScope objects are stored in SessionScope)
Would this be causing memory leaks.? Is there any alternative to this or any code that would remove Beans objects from SessionScope on page navigation.
Please share your views..!
I have read them and shared consolidated issues list below:
1. I am using Mojarra 2.2.6. Would you recommend migrating to MyFaces for better performance.
2. I am using ViewScoped Beans for my page.
I am not binding components to ViewScope Beans, instead I am mapping Component Value to beans objects.
I have noticed that while navigating from one page to other page, Beans objects are not removed from SessionScope.
(ViewScope objects are stored in SessionScope)
Would this be causing memory leaks.? Is there any alternative to this or any code that would remove Beans objects from SessionScope on page navigation.
Please share your views..!
PrimeFaces 6.0 | Apache Tomcat 7.0.53, 7.0.x | Mojarra 2.2.8
Windows 7, Ubuntu | Firefox 50
Windows 7, Ubuntu | Firefox 50
-
- PrimeFaces Core Developer
- Posts: 3979
- Joined: 03 Dec 2010, 14:11
- Location: Bavaria, DE
- Contact:
1) yep...
3) ViewScoped beans will be released but not eagerly. I would reduce the max views in session (com.sun.faces.numberOfViewsInSession / org.apache.myfaces.NUMBER_OF_VIEWS_IN_SESSION).
If you have real memory leaks, they will of course never be released.
We can't help if you have real memory leaks. This can only be checked via a profiler.
3) ViewScoped beans will be released but not eagerly. I would reduce the max views in session (com.sun.faces.numberOfViewsInSession / org.apache.myfaces.NUMBER_OF_VIEWS_IN_SESSION).
If you have real memory leaks, they will of course never be released.
We can't help if you have real memory leaks. This can only be checked via a profiler.
Thomas Andraschko
PrimeFaces | PrimeFaces Extensions
Apache Member | OpenWebBeans, DeltaSpike, MyFaces, BVal, TomEE
Sponsor me: https://github.com/sponsors/tandraschko
Blog: http://tandraschko.blogspot.de/
Twitter: https://twitter.com/TAndraschko
PrimeFaces | PrimeFaces Extensions
Apache Member | OpenWebBeans, DeltaSpike, MyFaces, BVal, TomEE
Sponsor me: https://github.com/sponsors/tandraschko
Blog: http://tandraschko.blogspot.de/
Twitter: https://twitter.com/TAndraschko
-
- Information
-
Who is online
Users browsing this forum: No registered users and 12 guests