[
https://issues.apache.org/jira/browse/CAMEL-18516?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17605469#comment-17605469
]
Tomohisa Igarashi commented on CAMEL-18516:
-------------------------------------------
We're looking at the possibility to leverage this plugin to generate a subset
of Camel YAML DSL schema, in order to make a system with some restriction on
available definitions on DSL. And I found that this bannedDefinitions could be
used for that purpose, but is not working as expected. It seems like there's
some background on having FromDefinition in ban list, I'll talk with
[~lburgazzoli] about this in more details next week.
> camel-yaml-dsl - bannedDefinitions doesn't work for generate-yaml-schema
> ------------------------------------------------------------------------
>
> Key: CAMEL-18516
> URL: https://issues.apache.org/jira/browse/CAMEL-18516
> Project: Camel
> Issue Type: Bug
> Components: camel-yaml-dsl
> Reporter: Tomohisa Igarashi
> Assignee: Tomohisa Igarashi
> Priority: Minor
> Fix For: 3.19.0
>
>
> GenerateYamlSchemaMojo here retrieves deserializers and extract the
> corresponding definitions from it, causes to bypass the bannedDefinitions
> check
> [https://github.com/apache/camel/blob/f7d1282261013f0172e90a3ddaa4fd0f1b1d6a94/dsl/camel-yaml-dsl/camel-yaml-dsl-maven-plugin/src/main/java/org/apache/camel/maven/dsl/yaml/GenerateYamlSchemaMojo.java#L87]
>
> It would need a separate check with `isBanned()` against extracted
> *Definition.
> Due to this issue, the current generated schema has `FromDefinition` while
> it's listed as banned in POM
> [https://github.com/apache/camel/blob/f7d1282261013f0172e90a3ddaa4fd0f1b1d6a94/dsl/camel-yaml-dsl/camel-yaml-dsl/src/generated/resources/schema/camel-yaml-dsl.json#L1013]
--
This message was sent by Atlassian Jira
(v8.20.10#820010)