Repository navigation
EN 16931 Semantic JSON 0.9.7
·
54 commits
to main
since this release
Immutable
release. Only release title and notes can be modified.
Added
esj serve(preview): the tools of the command line over HTTP — a REST API under/api, its
OpenAPI 3.1 description at/openapi.json, and an MCP server over Streamable HTTP at/mcp—
andesj mcp(preview), the same tools as an MCP server over the standard streams. Seven tools
from one table:validate,summary,get,convert,render,extractandinspect, and
uploadover HTTP. The server reads no document itself: every call runsesjas a child process
with--job-heap,--job-timeoutand an environment of its own, at most--max-jobsat once.
POST /api/validateanswers with the report ofesj validate --output json, byte for byte.
Loopback by default and0.0.0.0in both container images (ESJ_SERVE_BIND, port 8080
exposed), a bearer token from--token-file,Originchecked,pathonly below
--allow-dir, uploads and artefacts kept for--ttlin one temporary directory thatSIGTERM
removes. The server holds no document and no answer whole: it reads what a child wrote from
its file, keeps what a result carries and writes the answer into a spool before the call gives
back its child's place, so a call costs its heap at most 6 MiB whatever--limitslets a
child read and a client that reads slowly costs none of it, and it starts only with the
--max-jobsits heap holds (ESJ_SERVE_HEAPin the container image, besideESJ_MAX_HEAP
for the children); an MCP batch carries at most 16 messages and onetools/call. Links are
built from--public-urlor aHostthe server answers to (--allow-host) and are paths
otherwise; a file with a second name below--allow-diris refused; the texts a model reads
escape every invisible character;notifications/cancelledends the child of its call.
Everything the server holds on disk — request bodies and uploads as they are read, artefacts,
answers that wait for their client, and 64 MiB for each running child from its start, the
most it may write — is held to--max-disk(448M, within the tmpfs ofdist/compose.yaml;
--max-stored-bytes256M within it): a call that does not fit is refused with 503 and
Retry-After, never cut, and a call whose child the server ends as it stops is told so with
503, not 502. A request refused before its body was read is answered first, and the rest of
its body is read and dropped, for at most 5 s, before the connection is closed, so that the
client reads the answer and not a TCP reset.dist/compose.yamlruns it as the service
esj-api;dist/serve-smoke.shholds every packaged artefact's server against the jar's.
docs/serve.md.
Fixed
- The image stage of
dist/Dockerfile.nativecarries the runtime libraries beside the executable,
without which a rendering in it failed to load the AWT library.