Go to file
Lucio Lelii cc820554ac Close shared MCP sessions when their execution is cancelled
ExecutionContext.cancel() cleared executionVariableDescriptors before
transitioning to CANCELLED, so ExecutionsService.cleanupManagedResourcesIfFinal
(triggered from the same state-change notification) always found an empty
map and closed nothing. The CLOSE_RESOURCE mechanism already worked
correctly on SUCCESS and ERROR - only cancel/stop silently leaked any
shared MCP bridge session still open at that point, until the bridge's
own idle timeout, eventually hitting its session cap ("Reached the
maximum limit of 5 sessions").

Defer clearing executionVariableDescriptors until after the state-change
notification runs, so the cleanup sees the still-registered CLOSE_RESOURCE
session descriptor and closes it before the map is scrubbed. Added a
regression test that reproduces the leak (confirmed red without this
change) and asserts closeSessionQuietly runs on cancel.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-14 11:39:01 +02:00
.mvn/wrapper upgrade to springboot 4 2026-05-05 19:22:53 +02:00
src Close shared MCP sessions when their execution is cancelled 2026-09-14 11:39:01 +02:00
.gitattributes first commit 2025-03-27 11:38:06 +01:00
.gitignore Improve assistant model routing and diagnostics 2026-05-20 12:27:09 +02:00
Dockerfile Harden Maven downloads in Docker build 2026-09-10 11:34:39 +02:00
README.md Note how to run the service locally and build its image 2026-09-09 12:24:51 +02:00
mvnw first commit 2025-03-27 11:38:06 +01:00
mvnw.cmd first commit 2025-03-27 11:38:06 +01:00
ollama-preloaded-docker image for test with ollama added 2025-09-29 17:00:57 +02:00
pom.xml Replace Flyway schema setup with JPA mappings 2026-09-09 12:20:36 +02:00
run_service.sh Replace Flyway schema setup with JPA mappings 2026-09-09 12:20:36 +02:00

README.md

RUN LOCAL SERVICE

./run_service.sh

BUILD DOCKER IMAGE

docker buildx build –platform linux/amd64,linux/arm64 -t luciolelii/humainflow:latest . –push

HOST

lelii@build-host.internal