Metadata-Version: 2.4
Name: zmqruntime
Version: 0.1.11
Summary: Generic ZMQ-based distributed execution framework
Project-URL: Homepage, https://github.com/OpenHCSDev/zmqruntime
Project-URL: Documentation, https://zmqruntime.readthedocs.io
Project-URL: Repository, https://github.com/OpenHCSDev/zmqruntime
Project-URL: Issues, https://github.com/OpenHCSDev/zmqruntime/issues
Author-email: Tristan Simas <tristan.simas@mail.mcgill.ca>
License: MIT
License-File: LICENSE
Keywords: distributed,execution,messaging,rpc,zeromq,zmq
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Topic :: System :: Distributed Computing
Requires-Python: >=3.10
Requires-Dist: pyzmq>=22.0
Provides-Extra: dev
Requires-Dist: black>=23.0; extra == 'dev'
Requires-Dist: pytest-cov>=4.0; extra == 'dev'
Requires-Dist: pytest>=7.0; extra == 'dev'
Requires-Dist: ruff>=0.1.0; extra == 'dev'
Provides-Extra: docs
Requires-Dist: sphinx-rtd-theme>=2.0; extra == 'docs'
Requires-Dist: sphinx>=7.0; extra == 'docs'
Provides-Extra: registry
Requires-Dist: metaclass-registry; extra == 'registry'
Description-Content-Type: text/markdown

# ZMQRuntime

Generic ZeroMQ transport, lifecycle, progress, cancellation, viewer-control,
and execution-projection primitives.

## Important boundary

``ZMQServer`` and ``ZMQClient`` are abstract application integration points.
They cannot be instantiated directly:

- a server implements ``handle_control_message`` and ``handle_data_message``;
- a client implements ``_spawn_server_process`` and ``send_data``.

The package does not provide a generic ``send_request`` API or define an
application's execution payload. Applications subclass the bases and map their
typed domain requests onto the transport.

## Transport configuration

```python
from zmqruntime import TransportMode, ZMQConfig
from zmqruntime.transport import get_zmq_transport_url

config = ZMQConfig(control_port_offset=1000)
data_url = get_zmq_transport_url(
    7777,
    host="localhost",
    mode=TransportMode.TCP,
    config=config,
)
```

Application subclasses can use ``serve_forever``, readiness probes, control
port helpers, progress records, cancellation messages, lifecycle engines, and
projection adapters without duplicating socket or process machinery.

## Installation

```bash
python -m pip install zmqruntime
```

Documentation: [zmqruntime.readthedocs.io](https://zmqruntime.readthedocs.io/).

For local development, install the documentation dependencies and run a clean,
warning-fatal build:

```bash
python -m pip install -e ".[dev,docs]"
python -m sphinx -E -W --keep-going -b html docs/source docs/_build/html
```

Repository: [OpenHCSDev/ZMQRuntime](https://github.com/OpenHCSDev/ZMQRuntime).
