Lukasz Lenart created WW-5641:
---------------------------------

             Summary: JSON plugin ignores struts.json.writer / 
struts.json.reader override (regression since 7.2.x)
                 Key: WW-5641
                 URL: https://issues.apache.org/jira/browse/WW-5641
             Project: Struts 2
          Issue Type: Bug
          Components: Plugin - JSON
    Affects Versions: 7.2.1
            Reporter: Lukasz Lenart
             Fix For: 7.3.0



  * Change is localized to {{JSONUtil}}; {{JSONUtil}} is the only consumer of 
{{JSONWriter}} /
    {{JSONReader}}.
  * Preserves the 7.2.x hardening: {{StrutsJSONWriter}} / {{StrutsJSONReader}} 
remain the shipped
    defaults, and the DoS limits ({{struts.json.maxDepth}}, {{maxElements}}, 
{{maxLength}},
    {{maxStringLength}}, {{maxKeyLength}}) are unchanged.
  * Preserves {{prototype}} scope and per-instance resolution — no 
thread-safety regression for
    the stateful bean-info caching.

  h2. Regression test

  Add a test exercising the full bootstrap ({{struts-default.xml}} + the JSON 
plugin's
  {{struts-plugin.xml}} + a user override config, in that order) and assert the 
*effective*
  writer and reader used by {{JSONUtil}} are the overrides — covering both 
{{struts.json.writer}}
  and {{struts.json.reader}}.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to