Repository navigation
MCP errors, audit and cleanup: generic upstream errors, three-state audit, central tool validation (0.14.0) - #32
Merged
Conversation
Widen the constraint to ^0.5.0 || ^0.6.0. The suite is green with 0.5.0 and with 0.6.0. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Processor, command and MCP schema factory each built the path of an operation input file themselves. Schema\InputSchemaPath is now the one place that knows where these files live; behaviour and the schema snapshot are unchanged. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
page, itemsPerPage, sort and order of the three list tools are now $defs in api-configuration.json; sort keeps its description per tool. The resolved schemas and the snapshot are unchanged. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
The single upload and the bundle decoded and size-checked inline content with the same logic. UploadRule::decodeInlineContent() does it once; each caller keeps its own error messages. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
The selector-to-id rule now lives in the trait that processors and providers share, so the read providers can use it. No behaviour change. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Service\FlowableAuditLogger knows the shape of an audit entry and takes the actor from its caller, so processors, commands and the external worker can share it. The processors' output is unchanged. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…owable logger [*] TestFlowableEngine can answer with an HTTP error or a transport error, TestKernel takes options for the MCP switches, extra parameters and use_symfony_listeners (one cache directory per configuration), and the flowable channel is recorded instead of discarded. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
A 502 or 504 no longer carries the engine body, the engine URL or the transport error text. The caller gets a generic message with a correlation id, over HTTP also as X-Correlation-Id; the details are logged once as flowable.upstream_error with the same id. A 422 keeps the first line of the engine message, at most 200 characters, and the fallback to the raw response body is gone. getHealthInfo() returns the generic text as well. The logger argument of FlowableClient and FlowableClientLocator is optional. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…y write [*] Every write now leaves an attempt entry and then a success or a failure entry, with via=mcp|http|cli|worker, the MCP tool name, and on failure the status and the correlation id of the upstream error. The write CLI commands audit with via=cli, ExternalWorkerRunner with via=worker and the worker id as actor. Deployments carry the sha256 of each file and of the archive that is sent. The worker's outcome and shutdown unacquire lines are replaced by the audit entries of the same message; flowable.external_worker.bpmnError becomes .bpmn_error. Also fixes flowable:external-worker:bpmn-error, which looked for a schema file that does not exist and failed on every call. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…ows mcp.read [*] The switches filter resource metadata inside API Platform's metadata cache, so an env placeholder would be frozen there. A compiler pass now fails the container build when mcp.read, mcp.write or mcp.deploy is not a literal boolean, also when the application overrides the parameter or the decorator's arguments. McpResource entries of the bundle are kept only with mcp.read on. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
A provider decorator in front of the read step of the MCP provider chain validates the arguments of every tool call of the bundle's resources against the published input schema, also when an application replaced the tool's provider. Tools of other bundles pass through. A compiler pass hooks it into api_platform.mcp.state_provider.read or, without use_symfony_listeners, api_platform.state_provider.read, and fails the build when MCP is on and neither exists. URI variables of write tools are now validated as well. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…e covers it [*] The six read providers and the DMN upload processor no longer validate MCP arguments themselves; McpToolInputValidationProvider does it for every bundle tool in front of the provider. Results over the MCP transport are unchanged. Removed for subclasses: the $mcpInput constructor argument and property of AbstractFlowableProvider, FlowTaskFormProvider and AbstractFlowableProcessor, and AbstractFlowableProvider::validateMcpInput(). The tests of the removed calls moved to the MCP transport or are covered by the decorator's unit tests. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…le of a write tool [*] A processor names its input file once, in INPUT_SCHEMA; validatedBody() enforces it over HTTP and MCP, and the tool attribute publishes the same constant. A test discovers every write tool from the metadata and proves that both sides resolve to the same file. AbstractFlowableProcessor::schemaPath() is replaced by INPUT_SCHEMA, inputSchemaPath() and validatedBody(). Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
… as {uuid} [*]
The six read tools and flowable_dmn_deploy now publish the selector as
a string or {uuid}, like the write tools. The read providers resolve it
with configurationId(), so a value that is neither is rejected with a
400 instead of falling back to the default connection. The unused
definition apiConfigurationString is removed. The schema snapshot
changes only in the apiConfiguration property of these seven inputs.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…ule on the CLI [*] A name ending in .dmn.xml or .cmmn.xml passed as .xml where DMN or CMMN is not accepted: in flowable_deploy_bundle, and .cmmn.xml in the process deployment upload. UploadRule now checks the full suffix. The three CLI upload commands apply the same file name rule and the same extension list as their HTTP and MCP counterparts; the lists live on the processors. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…utions [*] flowable_history_get asked for the first 200 rows in ascending order, so a long-running instance lost its newest activities. The rows are now fetched newest first and returned oldest first, as before. Tests pin how failedDecisionExecutionsTotal comes about when the engine ignores the failed filter. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…ur with tests [*] Tool failures are JSON-RPC errors, not tool errors; flowable_dmn_evaluate returns the engine's rows of result variables and adds a history row; the timer tool only moves the job and needs an active async executor; executions have no total. The README gains sections on errors and the correlation id, the audit entries and rate limiting, and is corrected on oneOf, structuredContent, the selector forms and the upload rules. New tests pin the timer call, the DMN result shape, the DMN and event uploads and the input schema endpoints. No runtime change. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
The descriptions said "full or partial UUID", but the selector is the first 8 characters of the UUID or the full UUID, lowercase. The 21 attribute descriptions now share FlowableClientLocator::SELECTOR_DESCRIPTION, and the files[].name description of flowable_deploy_bundle names the accepted extensions. The schema snapshot changes in descriptions only. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
30 of 35 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Completes #18 after part A in 0.13.0 and prepares release
0.14.0. The full list for consumers, separated by HTTP, MCP, CLI and Worker, is inCHANGELOG.md.What changes
X-Correlation-Id; the details are logged once asflowable.upstream_error. A 422 keeps the first line of the engine message, at most 200 characters.getHealthInfo()returns the generic text as well.via=http|mcp|cli|worker, the MCP tool name, and on failure the status and the correlation id. The write CLI commands andExternalWorkerRunnerare audited. Deployments carry the sha256 of each file and of the archive.McpResourceentries followmcp.read.apiConfiguration: the read tools andflowable_dmn_deployaccept the{uuid}form; descriptions name the accepted selector forms..dmn.xml,.cmmn.xml); the CLI upload commands apply the file name rule.dmstr/openapi-json-schema-bundle^0.5.0 || ^0.6.0.Commits
One commit per step. The refactor commits come before the behaviour changes and leave the suite and the schema snapshot unchanged; the snapshot changes deliberately in two commits (
{uuid}on the read tools, description texts).Verification
dmstr/openapi-json-schema-bundle0.5.0 and 0.6.0.Split out of #18
outputSchemaofflowable_dmn_evaluate)Closes #18
🤖 Generated with Claude Code