* [Server][Tests] Serve the modern (SEP-2575) lifecycle The revision removed the initialize handshake: every request carries its own _meta - protocol version, client capabilities, client info - and answers server/discover for what initialize used to return. There is no session to keep, so there is nothing for the handshake-era dispatcher to do. Builder::buildStateless() produces StatelessProtocol, and StatelessHttpTransport serves it over one POST-only endpoint - GET and DELETE are 405, and no Mcp-Session-Id exists to hand out. Results go through a per-era wire codec rather than the handlers, so resultType and the caching hints are stamped for 2026-07-28 and left off the revisions that do not define them. Covered by the modern conformance suite (make conformance-draft-server) against its own baseline; unit coverage arrives with the fixes stacked on this. * Apply suggestions from code review Co-authored-by: Christopher Hertel <mail@christopher-hertel.de> * Fix critical stateless-lifecycle bugs from review - Don't leak internal exception messages to clients on uncaught \Throwable; use a generic message like the handshake-era protocol and every built-in handler already do. - Default a missing/invalid request id to null instead of "", and stop answering notifications and malformed messages as if they were "method not found" 404s. - Read the POST body in a loop instead of a single read() call, which PSR-7 allows to return short.
27 lines
655 B
YAML
27 lines
655 B
YAML
services:
|
|
nginx:
|
|
image: nginx:1.26-alpine
|
|
ports:
|
|
# Overridable so the fixture can coexist with whatever else a developer
|
|
# already has on 8000; CI and the Makefile default keep using 8000.
|
|
- "${CONFORMANCE_PORT:-8000}:80"
|
|
volumes:
|
|
- ./nginx.conf:/etc/nginx/conf.d/default.conf:ro
|
|
- ../../..:/app:ro
|
|
depends_on:
|
|
- php-fpm
|
|
networks:
|
|
- mcp-net
|
|
|
|
php-fpm:
|
|
image: php:8.4-fpm-alpine
|
|
volumes:
|
|
- ../../..:/app:ro
|
|
- ../sessions:/app/tests/Conformance/sessions
|
|
- ../logs:/app/tests/Conformance/logs
|
|
working_dir: /app
|
|
networks:
|
|
- mcp-net
|
|
|
|
networks:
|
|
mcp-net:
|