[ 
https://issues.apache.org/jira/browse/WW-3720?focusedWorklogId=1048008&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-1048008
 ]

ASF GitHub Bot logged work on WW-3720:
--------------------------------------

                Author: ASF GitHub Bot
            Created on: 17/Oct/26 09:03
            Start Date: 17/Oct/26 09:03
    Worklog Time Spent: 10m 
      Work Description: lukaszlenart opened a new pull request, #2040:
URL: https://github.com/apache/struts/pull/2040

   Relates to [WW-3720](https://issues.apache.org/jira/browse/WW-3720)
   
   ## Summary
   
   WW-3720 asks for a `<list><element>…</element></list>` form for 
collection-valued params such as `excludeMethods`. The readability need behind 
it is already met: a comma-delimited value can be split across lines inside one 
`<param>`, because both `XmlHelper.getContent` and 
`TextParseUtil.commaDelimitedStringToSet` trim whitespace.
   
   ```xml
   <param name="excludeMethods">
       input,
       back,
       cancel
   </param>
   ```
   
   This PR is test-only. It pins that behaviour end to end (XML file → 
configuration → built `DefaultWorkflowInterceptor`), both on the interceptor 
definition and on an `interceptor-ref` override, so the multi-line form stays 
supported.
   
   A real `<list>` element isn't proposed: params are `Map<String, String>` 
throughout the config model (XML, `InterceptorConfig`/`ActionConfig`, 
`DefaultInterceptorFactory`, lazy params, Convention's `@InterceptorRef(params 
= …)`), and the comma-string convention is shared by many interceptors across 
core and plugins.
   
   ## Verification
   
   - `XmlConfigurationProviderInterceptorsTest`: 5/5 pass on current code.
   - With `.map(String::trim)` removed from `commaDelimitedStringToSet`, the 
new test fails with `expected:<[cancel, back, input]> but was:<[input,\n 
back,\n cancel]>`, so it covers the trimming path.
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)




Issue Time Tracking
-------------------

            Worklog Id:     (was: 1048008)
    Remaining Estimate: 0h
            Time Spent: 10m

> Support collection-based properties in .xml
> -------------------------------------------
>
>                 Key: WW-3720
>                 URL: https://issues.apache.org/jira/browse/WW-3720
>             Project: Struts 2
>          Issue Type: New Feature
>            Reporter: Ilya
>            Priority: Minor
>             Fix For: 7.5.0
>
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> MethodFilterInterceptor.setExcludeMethods accepts coma-separated list of 
> methods and it should be typed in such way in XML too.
> It would be much better to support collections:
> <param name="workflow.excludeMethods">
>   <list>
>    <element>input</element>
>    <element>back</element>
>    <element>cancel</element>
>   </list>
> </param>
> and 
> MethodFilterInterceptor.setExcludeMethods(String... methods)
> or
> MethodFilterInterceptor.setExcludeMethods(Collection<String> methods)



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

Reply via email to