Public API

This page documents the stable public API surface of EDRI. Symbols not listed here are internal implementation details and may change without notice in minor releases.

Stability levels

Level

Meaning

Examples

Stable

Backward-compatible within the same CalVer version

edri.EDRI, edri.abstract.ManagerBase

Advanced

Public but requires deeper framework knowledge; may change more often

edri.api.broker.EventInfo, edri.utility.validation

Experimental

May be removed or redesigned in any release

edri.abstract.AsyncManagerBase, edri.testing

Internal

Not part of the public API — do not import from outside the framework

edri.router, edri.api.listener

What is NOT public

The following are internal and must not be imported by application code:

  • Each built-in event's paired *Response dataclass (e.g. HealthCheckResponse, GetResponse) — read its fields via event.response, never import the class

  • edri.router, edri.router.connector — Router, Cache, HealthChecker, Connector, and Socket are constructed exclusively inside EDRI()'s own start_connector()/run() methods; an application never imports or constructs them directly

  • edri.switch.* (the Switch is a standalone server)

  • edri.config.constant, except ApiType

  • edri.api.handlers, edri.api.listener (internal API layer); edri.api.broker, except EventInfo

  • edri.utility.function, except inject, camel2snake, and snake2camel

  • edri.utility.queue, edri.utility.watcher

  • Private attributes (prefixed with _) on any public class

Import paths stability

The import paths listed above are part of the compatibility promise. Deeper paths (e.g. edri.abstract.manager.manager_base.ManagerBase) may be restructured and should not be relied upon.

Version compatibility

EDRI uses CalVer versioning (YYYY.MM.DD with optional rcN prerelease suffix). Compatibility requires an exact version match across all components in a cluster. Mixed-version deployments are not supported.

Component

Compatibility

Python package

Exact version match (from importlib.metadata import version; version('edri') must be identical across nodes)

Switch protocol

Exact version match — the frame header, handshake, pickle schema, and FrameType values may change between versions

Event wire format

Exact version match — event class definitions must be identical on both sides of the wire

Docker images

Must use the same EDRI CalVer tag as the application package

Python runtime

Same Python major.minor version recommended; pickle protocol compatibility varies across Python releases

What exact-version-match means

Every component in a distributed EDRI deployment must run the same YYYY.MM.DD release (including the same rcN prerelease suffix). This applies to:

  • The EDRI Python package version on every node.

  • The Switch Docker image tag (traced back to the same git tag).

  • Event class definitions, which are serialised with pickle and must match on the sending and receiving side.

Why not SemVer terms

EDRI uses CalVer, not SemVer. Version strings like 2026.10.03 encode a release date, not a semantic version. There is no major.minor.patch distinction — any release may contain breaking changes. The safety guarantee is: if every component runs from the exact same release tag, they are compatible.