This is an automated email from the ASF dual-hosted git repository. davsclaus pushed a commit to branch feature/CAMEL-25208-code-assist in repository https://gitbox.apache.org/repos/asf/camel.git
commit 1096025aee61488c1b34987a2c07a7802d6974fc Author: Claus Ibsen <[email protected]> AuthorDate: Thu Oct 1 08:02:16 2026 +0200 CAMEL-25208: docs - MCP tool table, TUI agent section and upgrade guide for the Java and XML route checks Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]> Signed-off-by: Claus Ibsen <[email protected]> --- .../modules/ROOT/pages/camel-4x-upgrade-guide-4_23.adoc | 8 ++++++++ docs/user-manual/modules/ROOT/pages/camel-jbang-mcp.adoc | 7 +++++-- docs/user-manual/modules/ROOT/pages/camel-jbang-tui.adoc | 5 +++-- 3 files changed, 16 insertions(+), 4 deletions(-) diff --git a/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_23.adoc b/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_23.adoc index 0f7c35cf6615..2a0df93ffede 100644 --- a/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_23.adoc +++ b/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_23.adoc @@ -1589,6 +1589,14 @@ named as written. `--dep=camel-groovy`; before, the file was silently ignored unless the dependency was added. The dependency is also written to the run settings, so `camel export` includes it. +`camel validate source`, and the `camel_validate_source` and `camel_write_file` MCP tools, now check the routes of +Java and XML DSL files as they check YAML routes: the endpoint URIs against the catalog (also those built with the +endpoint DSL or from a constant), simple expressions, and a `to` whose URI holds `+${...}+` and should be a `toD`. +A Java file used to be checked only by the compiler and an XML file only for being well formed, so a file that +validated before can now report errors, and `camel_write_file` refuses to write it until they are fixed. In the +TUI Source tab an XML route file with such problems is not saved, as a YAML +file; a Java file is saved and its problems are shown. + === camel-jbang (MCP servers) The Camel authoring tools for AI agents are now defined once, in `camel-jbang-core`, and exposed under the diff --git a/docs/user-manual/modules/ROOT/pages/camel-jbang-mcp.adoc b/docs/user-manual/modules/ROOT/pages/camel-jbang-mcp.adoc index 5df892049106..e4f19d052b4c 100644 --- a/docs/user-manual/modules/ROOT/pages/camel-jbang-mcp.adoc +++ b/docs/user-manual/modules/ROOT/pages/camel-jbang-mcp.adoc @@ -317,8 +317,11 @@ project `directory` as an argument, the runtime tools take the integration `name `not defined in the schema` validation error. | `camel_validate_source` -| Validates Camel YAML DSL or `.properties` source without writing: the YAML DSL schema (a misspelled option - such as `logLevel` instead of `loggingLevel`), endpoint URIs, simple expressions, and `camel.*` options. +| Validates Camel YAML, Java or XML DSL or `.properties` source without writing: the YAML DSL schema (a + misspelled option such as `logLevel` instead of `loggingLevel`), endpoint URIs, simple expressions, and + `camel.*` options. The routes of a Java or XML file are read into the Camel model without compiling them and + get the same checks (the endpoint DSL and constants resolved, a `to` that needs `toD`); what the parser could + not read is listed under `notChecked`. Takes the content, or reads the file from the project directory. With `camelVersion` (or the version of the selected integration in the TUI) the catalog and the YAML DSL schema of that Camel version answer, the schema read from its `camel-yaml-dsl` jar; without it the CLI's own, with nothing to download. diff --git a/docs/user-manual/modules/ROOT/pages/camel-jbang-tui.adoc b/docs/user-manual/modules/ROOT/pages/camel-jbang-tui.adoc index c4a7c1de8179..4552e5cefb1e 100644 --- a/docs/user-manual/modules/ROOT/pages/camel-jbang-tui.adoc +++ b/docs/user-manual/modules/ROOT/pages/camel-jbang-tui.adoc @@ -1457,8 +1457,9 @@ worst case is a wrong route file in a folder you are watching. Before writing, an agent can check its content with `camel_validate_source`, which runs the same checks as the Source tab's save: YAML routes against the Camel YAML DSL schema (a misspelled option such as `logLevel` -instead of `loggingLevel` is reported) plus endpoint URIs and simple expressions, and `.properties` files -against the catalog of `camel.*` and Spring Boot options. `camel_write_file` runs that validation itself and +instead of `loggingLevel` is reported) plus endpoint URIs and simple expressions, Java and XML routes read into +the Camel model with the same endpoint and simple checks, and `.properties` files against the catalog of +`camel.*` and Spring Boot options. `camel_write_file` runs that validation itself and refuses to write an invalid file, returning the errors instead, so a model fixes them rather than the user finding them in the log after the reload. Both tools are part of the core tool set, so local models (Ollama) get them as well.
