0

I'm using wildfly 18 with java 11. undertow is configured to serve http/2. push is disabled and i'm also using gzipFilter.

Response sent to the client does not content the content-length header field.

i'm using jsf_2.3

How can I setup my wildfly so that response header content-length is set?

Selaron
  • 6,105
  • 4
  • 31
  • 39
Yan'son
  • 1
  • 1
  • JSF views are rendered dynamically, the length of this response cannot be predicted. You would need to make sure that the complete rendered content fits into the response buffer. Only then you are able to determine and set the correct value for the Content-Length header before anything is started to be transmitted. Also relevant: https://stackoverflow.com/questions/14381825/java-servlet-httpresponse-contentlenght-header – Selaron Feb 03 '20 at 12:22
  • Does it work in older WildFly versions and in other servers? Your question is implying that the "problem" is only happening in WildFly 18. Nonetheless, why exactly do you want the content-length header to be set? Probably you're just having a XY-problem. – BalusC Feb 03 '20 at 12:26
  • @BalusC i want the content lenght to be set to implement a better user experience in the view showing download bar where resources are loaded – Yan'son Feb 03 '20 at 13:31

0 Answers0