Wicket 1.5 violates servlet standard, Glassfish spews warnings
--------------------------------------------------------------
Key: WICKET-3914
URL: https://issues.apache.org/jira/browse/WICKET-3914
Project: Wicket
Issue Type: Bug
Components: wicket-core
Affects Versions: 1.5-RC5.1
Environment: SVN Revision: 1147931
Reporter: Bertrand Guay-Paquet
This seems to be a re-occurance of WICKET-1816.
Deploying wicket-examples to Glassfish produces tens of warnings in the server
log with the following text:
WARNING: PWC4011: Unable to set request character encoding to UTF-8 from
context /wicket-examples, because request parameters have already been read, or
ServletRequest.getReader() has already been called
According to Glassfish faq
http://wikis.sun.com/display/glassfish/FaqWebAppUnableToSetRequestCharEncoding:
"""
This warning message means that the web container is complaining about the fact
that the web application deployed at /your_webapp is trying to set the request
encoding too late in the request's lifecycle, when it is impossible for the
container to honor it.
See the javadocs of javax.servlet.ServletRequest.setCharacterEncoding():
This method must be called prior to reading request parameters or reading
input using getReader(). Otherwise, it has no effect.
The container issues a warning to let you know that a call to
ServletRequest.setCharacterEncoding() by your_webapp has no effect and is being
ignored, because one of the above conditions is met.
To avoid this warning, your_webapp should move its invocation of
ServletRequest.setCharacterEncoding() to an earlier stage, before it acquires
any input reader from the request, or before it reads any request parameters.
In case your_webapp is not responsible for this warning, one if its
dependencies might be, in which case that library needs to be fixed.
"""
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira