Martin A. created TOMEE-4571:
--------------------------------

             Summary: TomEE 10.1.x -  Decrease in performance (Factor 2 or 
more).
                 Key: TOMEE-4571
                 URL: https://issues.apache.org/jira/browse/TOMEE-4571
             Project: TomEE
          Issue Type: Bug
          Components: TomEE Core Server
    Affects Versions: 10.1.2
            Reporter: Martin A.


We recently migrated our PrimeFaces 13 application from TomEE9 to TomEE10 and 
found a massive decrease in performance (Factor 2 or more).

Our Environment:
Primefaces 13.0.8, ojdbc11:21 , Oracle 19c database, gradle 8.7 build system. 
PLUME edition of TomEE because we need eclipselink due to native queries and DB 
package calls.
TomEE 9.1.3 PLUME as-is (Mojarra Faces 3, Eclipselink 3) on OpenJDK17
TomEE 10.1.2 PLUME as-is (Mojarra Faces 4, Eclipselink 4) on OpenJDK21

*Measurement 1* : open dedicated page, then track its 3 XHR requests in browser 
console
TomEE10 + JDK21 : 4900 ms - 6800 ms - 2100 ms
TomEE10 + JDK17 : 9200 ms - 8400 ms - 5700 ms
TomEE 9 + JDK17 : 2700 ms - 3000 ms - 0800 ms
TomEE 9 was > 2x faster, JDK might have a small impact, 21 is faster (as 
expected)

As suggested by BalusC, i did a comparison with MyFaces 4.03 from TomEE Plus by 
replacing it in TomEE Plume and ran the same testcases 3x to have reliable 
results:
Measured times in ms, using p:lifecycle component (skipped phases < 10 ms).The 
big differences are in RESTORE_VIEW phase = 10x faster and RENDER_RESPONSE 
phase = 2-3x faster

TomEE 9 / mojarra 3.0.5
"search": RESTORE_VIEW 130 | INVOKE_APPLICATION 630 | RENDER_RESPONSE 850 | 
"open dialog": RESTORE_VIEW 180 | INVOKE_APPLICATION 1200 | RENDER_RESPONSE 400 
|

TomEE 10 mojarra: 4.0.11
"search": RESTORE_VIEW *650* | INVOKE_APPLICATION 650 | RENDER_RESPONSE *1100* |
"open dialog": RESTORE_VIEW 750 | INVOKE_APPLICATION 1200 | RENDER_RESPONSE 400 
|

TomEE 10 myfaces: 4.0.3
"search" : RESTORE_VIEW 65 | INVOKE_APPLICATION 600 | RENDER_RESPONSE 650 |
"open dialog": RESTORE_VIEW 60 | INVOKE_APPLICATION 1200 | RENDER_RESPONSE 150 |

MyFaces 4.0.3 is factor 2-10 faster than Mojarra 4.0.11, depending on action. 

I also  did a freaky try: run TomEE 10 with mojarra 3.0.5 (like TomEE 9) by 
reverting namespace and related changed only, same tests as before (3x,same pc, 
same db)
"Search": RESTORE_VIEW 700 | INVOKE_APPLICATION 650 | RENDER_RESPONSE 1200
"Open Dialog": RESTORE_VIEW 700 | INVOKE_APPLICATION 1400 | RENDER_RESPONSE 700

The idea that eclipselink / DB level is slower which turned out false. I 
checked all server.xml, tomee.xml changes, as well as the required application 
changes in dependencies, namespaces, faces-config.xml, 
beans.xml persistence.xml and found no hint yet what could cause such decrease 
in performance. I can confirm the idead that faces 3 and faces 4 are equal in 
performance, 
in fact "Restore view" phase is slower in 4.  On the other hand, this now 
means: There must be some other things in TomEE 10 that make it slower, e.g. 
libraries, config changes, undocumented parameters, no-longer-in-use caches ... 
So further Ideas are highly welcome. 
 
web.xml parameters overview
listener-class = com.sun.faces.config.ConfigureListener
servlet-class = jakarta.faces.webapp.FacesServlet
jakarta.faces.FACELETS_VIEW_MAPPINGS = .jsf;.xhtml
jakarta.faces.STATE_SAVING_METHOD = server
jakarta.faces.FACELETS_REFRESH_PERIOD  = -1
jakarta.faces.PARTIAL_STATE_SAVING = true
jakarta.faces.FACELETS_BUFFER_SIZE = 1024000 (for fileuploads)
jakarta.faces.FACELETS_SKIP_COMMENTS = true
primefaces.CLIENT_SIDE_LOCALISATION = true



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to