ORIONIS API REFERENCE

THE ORIONIS API

Build with clarity.

Explore the building blocks of an async-first Python framework. Every module, class, and method — connected, searchable, and ready to build with.

class documentation

Coalesce duplicate changes and close overloaded listeners gracefully.

Method __init__ Set finite listener and per-listener buffer budgets.
Method listen Register synchronously so publication cannot race acknowledgment.
Async Method publish Publish without awaiting a slow client or creating producer tasks.
Method remove Release an iterator even if it was closed before its first read.
Async Method shutdown Stop admission and wake all consumers to send graceful completion.
Class Variable __slots__ Declare the instance attribute slots reserved by this class.
Instance Variable _closed Whether this resource has completed its close lifecycle.
Instance Variable _listeners Listeners produced by set.
Instance Variable _max_listeners Value supplied for max_listeners.
Instance Variable _size Value supplied for buffer_size.
Property listenerCount Expose aggregate lifecycle diagnostics, without subscriber identity.
def __init__(self, buffer_size: int = 64, max_listeners: int = 1024): (source)

Set finite listener and per-listener buffer budgets.

Parameters
buffer_size:intValue supplied for buffer_size.
max_listeners:intValue supplied for max_listeners.
Returns
NoneComplete the documented operation without returning a value.
def listen(self, server: type, filters: SubscriptionFilter) -> AsyncIterator[Change]: (source)

Register synchronously so publication cannot race acknowledgment.

Parameters
server:typeValue supplied for server.
filters:orionis.mcp.protocol.requests.SubscriptionFilterValue supplied for filters.
Returns
collections.abc.AsyncIterator[orionis.mcp.subscriptions.event_bus.Change]Result of the operation described above.
async def publish(self, server: type, method: str, uri: str | None = None): (source)

Publish without awaiting a slow client or creating producer tasks.

Parameters
server:typeValue supplied for server.
method:strValue supplied for method.
uri:str | NoneValue supplied for uri.
Returns
NoneComplete the documented operation without returning a value.
def remove(self, listener: _Listener): (source)

Release an iterator even if it was closed before its first read.

Parameters
listener:orionis.mcp.subscriptions.event_bus._ListenerValue supplied for listener.
Returns
NoneComplete the documented operation without returning a value.
async def shutdown(self): (source)

Stop admission and wake all consumers to send graceful completion.

Returns
NoneComplete the documented operation without returning a value.
__slots__: tuple[str, ...] = (source)

Declare the instance attribute slots reserved by this class.

Whether this resource has completed its close lifecycle.

Listeners produced by set.

_max_listeners = (source)

Value supplied for max_listeners.

Value supplied for buffer_size.

listenerCount: int = (source)

Expose aggregate lifecycle diagnostics, without subscriber identity.

Returns
intResult of the operation described above.