Server library for NatsWork job processing system
Project description
NatsWork Server (Python)
Server library for the NatsWork job processing system.
Installation
pip install -e .
Development
# Install with development dependencies
pip install -e ".[dev,test]"
# Run tests
pytest
# Run tests with coverage
pytest --cov=src --cov-report=html
# Format code
black src tests
# Lint code
ruff src tests
# Type check
mypy src
Status
⚠️ Under Development - Implementation pending (see docs/python/001-010.md)
This package provides the foundation for:
- Job processing workers
- Queue management
- Multi-threaded job execution
- Health monitoring and metrics
- Framework integration (Django, Flask, FastAPI)
Usage
from natswork_server import job, NatsWorkServer
# Define a job
@job(queue="default", retries=3)
class MyJob:
def perform(self, x, y):
return x + y
# Start server
server = NatsWorkServer("nats://localhost:4222")
# Coming in Tasks 004-006
CLI
# Start worker server
natswork-server start --queues default --concurrency 10
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
natswork_server-0.0.1.tar.gz
(30.1 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file natswork_server-0.0.1.tar.gz.
File metadata
- Download URL: natswork_server-0.0.1.tar.gz
- Upload date:
- Size: 30.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
95749c4076acc7bc840bd1ba64e05d5c985e7e1ec282100c9ebcae7c1d91803c
|
|
| MD5 |
164db7b7115640f298840cae35c73aaf
|
|
| BLAKE2b-256 |
1f0251c0d4fcc9b762ed67e3394df8bf7fb0f7fef2f24bb34a29e1a806af01ac
|
File details
Details for the file natswork_server-0.0.1-py3-none-any.whl.
File metadata
- Download URL: natswork_server-0.0.1-py3-none-any.whl
- Upload date:
- Size: 33.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3d28c9b80b54ee5d6a0e1fc27a503e8fc47231cca6d9c5974c2e3de1c3537ea8
|
|
| MD5 |
8443f815d29b3aea084a892855b8ff92
|
|
| BLAKE2b-256 |
1fb65c087b4f29b63089ada058ade73dfc7bc5a92dfc0d4add6657bb10746cad
|