Andrus Adamchik created CAY-2949:
------------------------------------
Summary: CayenneModeler MCP: dbimport_run tool
Key: CAY-2949
URL: https://issues.apache.org/jira/browse/CAY-2949
Project: Cayenne
Issue Type: Task
Reporter: Andrus Adamchik
Assignee: Andrus Adamchik
Fix For: 5.0-M2
Add a new {{dbimport_run}} tool to the CayenneModeler MCP server that runs
Cayenne reverse engineering for a single DataMap, using the
{{<reverse-engineering>}} config already stored in the DataMap XML.
Inputs are an absolute {{projectPath}} to the top-level {{cayenne-*.xml}} and a
{{dataMap}} symbolic name — no JDBC URL, credentials, or filters as parameters.
All connection state is sourced from CayenneModeler preferences: the named
{{DBConnector}} bound to the DataMap supplies URL/driver/user/password/adapter,
and the JDBC driver jars come from Preferences → Classpath.
Validation runs in fixed order and short-circuits:
* project readable
* parses
* DataMap present
* {{<reverse-engineering>}} config present
* connector binding present in prefs
* named connector exists in the registry
* driver class loadable from the Modeler-classpath {{URLClassLoader}}
* JDBC connection openable.
The response envelope is always the same shape: {{{}status{}}}, {{summary,
}}{{{}resolved{}}}, captured warnings, a per-step {{validation}} block, and an
{{error}} object with a lowercase-snake_case code enum. The response
deliberately omits a per-token changes list since the agent can diff the
rewritten DataMap XML directly off disk.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)