I want to intercept a request in a filter/servlet and add a few parameters to it. However, the request does not expose a ‘setParameter’ method and the parameter map when manipulated throws an error saying it is locked. Is there an alternative I can try?
Share
Subclass
HttpServletRequestWrapperand override thegetParametermethods. The description of this class reads:In the filter, wrap the request in an instance of your subclass.