https://issues.apache.org/bugzilla/show_bug.cgi?id=46727
Summary: DefaultServlet - serving multiple encodings
Product: Tomcat 6
Version: unspecified
Platform: All
OS/Version: All
Status: NEW
Severity: enhancement
Priority: P2
Component: Catalina
AssignedTo: [email protected]
ReportedBy: [email protected]
CC: [email protected]
Created an attachment (id=23272)
--> (https://issues.apache.org/bugzilla/attachment.cgi?id=23272)
Minor refactor of DefaultServlet
Hi,
It had to happen sooner or later. In one of my tomcat applications I now have
to serve multiple collections of static content which may have various
encodings. We depend heavily on DefaultServlet, but in its current state it is
not possible to control encoding on a resource-by-resource basis. One can set
the "fileEncoding" parameter, but this controls all static resources.
The structure of the current code makes this impossible to solve by extending
the class, since fileEncoding is a global instance variable.
The attached refactoring mitigates this primarily by changing the method
signature of serveResource() to contain an encoding argument. The extending
class may override this method on every call if necessary.
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]