payara / Payara

Payara Server is an open source middleware platform that supports reliable and secure deployments of Java EE (Jakarta EE) and MicroProfile applications in any environment: on premise, in the cloud or hybrid.
http://www.payara.fish
Other
879 stars 301 forks source link

Bug Report: net::ERR_CONTENT_LENGTH_MISMATCH when serving up angular page with hsts enabled #6155

Closed baldpope closed 1 year ago

baldpope commented 1 year ago

Brief Summary

We currently operate payara 5.2020.2 with our application. In order to enable HSTS, we are upgrading to 5.2022.5 . Once HSTS is enabled, the angular site fails to load with the ERR_CONTENT_LENGTH_MISMATCH status.

Expected Outcome

angular page is rendered

Current Outcome

angular page does not render

Reproducer

I don't have a sample app to compare it against.

Operating System

Linux

JDK Version

1.8u220

Payara Distribution

Payara Server Full Profile

Elifzeynepedman commented 1 year ago

Greetings @baldpope , Payara Platform 5 Community support has ended as of last year, please make sure to migrate your applications to Payara Platform 6 and convert them to Jakarta EE 10 and then confirm if this issue affects your environment,

If you encounter any issues or have trouble transforming your applications and migrating them to Payara Platform 6 and if you want to remain on Payara Platform 5, you may consider acquiring a Payara Enterprise subscription.

baldpope commented 1 year ago

Thanks @Elifzeynepedman for the suggestion, I missed that Payara 5 was set for EOL.

I did try upgrading to Payara 6, made some needed tweaks to our deployment (not the application) and ran into the following error on loading

{ "Timestamp": "2023-01-17T11:08:09.664-0600", "Level": "SEVERE", "Version": "Payara 6.2022.2", "LoggerName": "javax.enterprise.system.core", "ThreadID": "157", "ThreadName": "payara-executor-service-scheduled-task", "TimeMillis": "1673975289664", "LevelValue": "1000", "LogMessage": "Exception while loading the app : java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: java.lang.IllegalArgumentException: java.lang.IllegalArgumentException: Unable to add listener of type: com.tc.fw.SessionCounter, because it does not implement any of the required ServletContextListener, ServletContextAttributeListener, ServletRequestListener, ServletRequestAttributeListener, HttpSessionListener, or HttpSessionAttributeListener interfaces" }

that's just one of the output logs - I've discussed the same with our internal engineering team, looks like we'd need to upgrade our war as part of the upgrade, outside the scope of the payara upgrade. Since I can't yet recreate the problem in Payara 6, should we just close this issue until I have a clean example?

Elifzeynepedman commented 1 year ago

Hi @baldpope,

I will proceed to close this issue. Feel free to open a new issue when you are able to recreate the problem in Payara 6.

Thank you, Elif