[
https://issues.apache.org/jira/browse/CAMEL-25254?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18121821#comment-18121821
]
Claus Ibsen commented on CAMEL-25254:
-------------------------------------
PR: https://github.com/apache/camel/pull/27251
_Claude Code on behalf of davsclaus_
> camel-jbang - convert a route file between YAML, XML and Java DSL without
> running it
> ------------------------------------------------------------------------------------
>
> Key: CAMEL-25254
> URL: https://issues.apache.org/jira/browse/CAMEL-25254
> Project: Camel
> Issue Type: Improvement
> Components: camel-jbang
> Reporter: Claus Ibsen
> Assignee: Claus Ibsen
> Priority: Minor
>
> Convert a route file from one DSL to another, without running it.
> Today the source editor of camel-jbang shows a route in YAML, Java or XML
> (Space) only for a running integration (it asks the application for a route
> dump), read-only and one route at a time; the camel transform route command
> converts files without running them, but only to XML or YAML.
> Add:
> * in the source editor, a Convert to YAML / XML / Java... file action (F12)
> on a route file: the file is read into the model without running it (Java
> with the Java DSL parser, XML with the XML parser, YAML with the YAML DSL
> reader), written with the model writers (ModelToYAMLDumper, ModelToXMLDumper,
> ModelToJavaDumper) into a new file next to it, which opens; the original
> stays as it is;
> * what does not survive is said: comments, and Java code the parser cannot
> read (lambdas, processors) which makes the conversion refuse rather than drop
> it;
> * the same converter for camel transform route --format java, and as an MCP
> tool for AI agents.
> Fidelity checked with the YAML/XML/Java round-trip corpora of CAMEL-25206 and
> CAMEL-25182.
> _Claude Code on behalf of davsclaus_
--
This message was sent by Atlassian Jira
(v8.20.10#820010)