ammachado opened a new pull request, #23432:
URL: https://github.com/apache/camel/pull/23432

   # Description
   
   Extracts 16 collection-related functions from the monolithic 
`SimpleFunctionExpression` into a dedicated `CollectionFunctionFactory` 
implementing `SimpleLanguageFunctionFactory`.
   
   Functions moved: `setHeader`, `setVariable`, `range`, `distinct`, `reverse`, 
`shuffle`, `split`, `sort`, `forEach`, `filter`, `listAdd`, `listRemove`, 
`mapAdd`, `mapRemove`, `list`, `map`.
   
   This is a follow-up to the previous PR that extracted math and string 
functions. The refactoring continues reducing `SimpleFunctionExpression` by 
removing approximately 600 lines.
   
   **Cleanup included:** removes a duplicate `distinct` block in 
`createCodeExpressionMisc` that was dead code (unreachable because `distinct` 
was already matched earlier in the same method).
   
   **Known pre-existing inconsistency preserved (not fixed here):** the `range` 
function behaves differently between the expression and code-gen paths — the 
expression path defaults `min` to `"1"` while the code-gen path defaults `min` 
to `0`. Both behaviors are preserved unchanged to avoid introducing regressions.
   
   # Target
   
   - [x] I checked that the commit is targeting the correct branch (Camel 4 
uses the `main` branch)
   
   # Tracking
   - [x] If this is a large change, bug fix, or code improvement, I checked 
there is a [JIRA issue](https://issues.apache.org/jira/browse/CAMEL) filed for 
the change (usually before you start working on it).
   
   # Apache Camel coding standards and style
   
   - [x] I checked that each commit in the pull request has a meaningful 
subject line and body.
   
   - [ ] I have run `mvn clean install -DskipTests` locally from root folder 
and I have committed all auto-generated changes.
   
   _Claude Code on behalf of Adriano Machado_


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to