[ 
https://issues.apache.org/jira/browse/CAMEL-17094?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17429660#comment-17429660
 ] 

Luca Burgazzoli commented on CAMEL-17094:
-----------------------------------------

{code:yaml}
when: 
    - when: 
{code}

This is not possible as it is ambiguous for the resolution and to be honest it 
seems ambiguous also for the developer point of view as you have the same key 
for two different purposes.

> camel-yaml-dsl - Unification of DSL (Choice When clause)
> --------------------------------------------------------
>
>                 Key: CAMEL-17094
>                 URL: https://issues.apache.org/jira/browse/CAMEL-17094
>             Project: Camel
>          Issue Type: Improvement
>          Components: camel-yaml-dsl
>            Reporter: Marat Gubaidullin
>            Priority: Major
>
> All DSLs in *steps* array start with DSL name field, ex: *filter* and *to*
> {code:yaml}
> steps:    
>     - filter:  
>          simple: "${body}"
>          steps: 
>             - to: "mock:filter"
>     - to: "mock:result"
> {code}
> but in *when* array WhenDefinition steps: *simple* and *expression*
> {code:yaml}
> when: 
>     - simple: "${body.size()} == 1"
>       steps: 
>           - to: "log:when-a"
>     - expression: 
>         simple: "${body.size()} == 2"
>       steps: 
>           - to: "log:when-b"
> {code}
> Could we unified YAML DSL for arrays of Definitions? Ex.:
> {code:yaml}
> when: 
>     - when: 
>           expression: 
>               simple: "${body.size()} == 2"
>           steps: 
>               - to: "log:when-a"
>     - when: 
>           expression: 
>               simple: "${body.size()} == 2"
>           steps: 
>               - to: "log:when-b"
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to