Commit Graph
4 Commits
Author SHA1 Message Date
h3cx 03279597e7 Further json isolation and endpoint implementation
Further isolated json specifics to their own module under protocols/json

Moved global packet classes to their own protocols/packets module

Implemented ConnectorEndpoint and ConnectorRegistry as transport
agnostic connector endpoints for universal connector handling, exposed a
ConnectorRegistry API that will need to be made available to the
JsonServer for it to be able to register and unregister endpoints as it
opens and closes connections

Implemented a top down shutdown architecture where each object is
responsible for its children, this allows for a logical and heirachical
flow, each object has its own stop event, which when its stop method is
called, it sets and then awaits the stopped event to be set by any
worker threads etc, with a mandatory timeout to avoid hanging on
shutdown
2026-08-03 22:56:21 +01:00
h3cx 482c093f38 Server isolation and detailed errors
Isolated the JsonServer to server.py inside protocols/json

Added specific errors for server startup timeout and server startup
failed

Refactored errors for Core to CoreError generic and refactored
StateError to CoreStateMismatchError derived from CoreError
2026-08-03 17:17:33 +01:00
h3cx 321ccb178e Initial json server implementation
Completed the initial implementation of the JsonServer class, handling
the worker thread that runs the async task, as well as the connection
handler callback

The current handler awaits readline to cleanly exit when the connection
is closed, no data ingress is happening yet

Next steps include gating the start procedure to wait for everything to
start proprerly in order to avoid having start exit early and async
tasks crashing later
2026-08-03 16:06:28 +01:00
h3cx 85d25e8381 Initial commit 2026-08-03 12:15:49 +01:00