Skip to main content

The fastest open-source message broker for Redis.

Project description

chasquimq (Python)

Python bindings for ChasquiMQ — the fastest open-source message broker for Redis. The Rust engine pulls jobs; Python asyncio handlers process them.

Status: Phase 4, slice A4 (high-level shim). Public API is pre-1.0 and may change.

Layout

  • src-rs/ — PyO3 Rust bindings, compiled as the chasquimq._native extension module.
  • src/chasquimq/ — Python shim (the src layout); re-exports the native classes (Producer / Consumer / Scheduler) and the high-level surface (Queue / Worker / Job / QueueEvents) from one flat namespace.
  • tests/ — pytest harness.

Build

cd chasquimq-py
maturin develop          # editable install into the active venv
pytest tests/            # smoke + integration tests (needs Redis 8.6+)
maturin build --release  # wheels under target/wheels/

Quickstart

import asyncio

from chasquimq import Queue, Worker, Job, RepeatPattern


async def send_email(job: Job) -> None:
    print(f"sending {job.data}")


async def main() -> None:
    queue = Queue("emails")

    # Enqueue a one-shot job.
    await queue.add("send-email", {"to": "ada@example.com"})

    # Enqueue a recurring job (fires every 60s on this worker process).
    await queue.add(
        "daily-digest",
        {"who": "all"},
        repeat=RepeatPattern.every(60_000),
    )

    # `concurrency` defaults to 100; tune it to your handler's I/O profile.
    worker = Worker("emails", send_email)
    try:
        await worker.run()
    finally:
        await worker.close()
        await queue.close()


asyncio.run(main())

Power-user surface

Native engine handles are re-exported from the same top-level package — no private _native import needed:

from chasquimq import Producer, Consumer, Scheduler

The high-level Job dataclass wins the unqualified Job name; if you need the native value type, import it explicitly:

from chasquimq._native import Job as NativeJob

See also

License

MIT — see LICENSE at the workspace root.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

chasquimq-1.0.0-cp39-abi3-win_amd64.whl (2.6 MB view details)

Uploaded CPython 3.9+Windows x86-64

chasquimq-1.0.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (2.7 MB view details)

Uploaded CPython 3.9+manylinux: glibc 2.17+ x86-64

chasquimq-1.0.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (2.6 MB view details)

Uploaded CPython 3.9+manylinux: glibc 2.17+ ARM64

chasquimq-1.0.0-cp39-abi3-macosx_11_0_arm64.whl (2.4 MB view details)

Uploaded CPython 3.9+macOS 11.0+ ARM64

chasquimq-1.0.0-cp39-abi3-macosx_10_12_x86_64.whl (2.5 MB view details)

Uploaded CPython 3.9+macOS 10.12+ x86-64

File details

Details for the file chasquimq-1.0.0-cp39-abi3-win_amd64.whl.

File metadata

  • Download URL: chasquimq-1.0.0-cp39-abi3-win_amd64.whl
  • Upload date:
  • Size: 2.6 MB
  • Tags: CPython 3.9+, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for chasquimq-1.0.0-cp39-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 783af99aa0be5f77193dc5a6f51c5dfb95060499cdfa5b4af7de77090ec06f02
MD5 7b3487776474d5f1cc3b1a81563c33ee
BLAKE2b-256 05611315e556d788c0a70f4f2ee2f6d687ad7bb1662f84685781352be4f8ab33

See more details on using hashes here.

Provenance

The following attestation bundles were made for chasquimq-1.0.0-cp39-abi3-win_amd64.whl:

Publisher: py-ci.yml on jotarios/chasquimq

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file chasquimq-1.0.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for chasquimq-1.0.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 c10296e382de8e8548bd22ac2ae3453b5afa5cedc42622468d807eb2b629c7e7
MD5 8a1bbdf89783067592ccff35051e12fd
BLAKE2b-256 6fd706d3d82552e8f3db72e91a1eb3cbfc39555751f2e2098dfa848222838a54

See more details on using hashes here.

Provenance

The following attestation bundles were made for chasquimq-1.0.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: py-ci.yml on jotarios/chasquimq

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file chasquimq-1.0.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for chasquimq-1.0.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 e7b7e09528e0fe0a9cc5578e12f1d07b4387ce392c1ab66af6e91f534e811559
MD5 ced00bf59cd9c14c319eef9c43d70df7
BLAKE2b-256 72feca011886d44d56c076c94ee62bca016739fdd50b536b34ca550253cab60d

See more details on using hashes here.

Provenance

The following attestation bundles were made for chasquimq-1.0.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl:

Publisher: py-ci.yml on jotarios/chasquimq

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file chasquimq-1.0.0-cp39-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for chasquimq-1.0.0-cp39-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 b8d179528af6d129f45d3cb39555ae6b1d655d387a93144c07513d1f3c470135
MD5 959b76253746adfd3420ab3cf9a35a87
BLAKE2b-256 4515929741913b4a734acc64c8bc8f4f205a34609ada7ca3239b5978550b50ac

See more details on using hashes here.

Provenance

The following attestation bundles were made for chasquimq-1.0.0-cp39-abi3-macosx_11_0_arm64.whl:

Publisher: py-ci.yml on jotarios/chasquimq

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file chasquimq-1.0.0-cp39-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for chasquimq-1.0.0-cp39-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 458595e9bcf5c802bcc7eab00ab28f7cb1bb193a08eb7fa3089eb860344de997
MD5 4cfec41aa7798c79c2b1d2ae6c9b97b3
BLAKE2b-256 a85f43dc128f8055b8942affaebde8d89c05df244931113074fdfd407f4d1cc9

See more details on using hashes here.

Provenance

The following attestation bundles were made for chasquimq-1.0.0-cp39-abi3-macosx_10_12_x86_64.whl:

Publisher: py-ci.yml on jotarios/chasquimq

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page