Skip to main content

Bulkman

Enterprise-Grade Bulkhead Pattern for Python

Bulkman is a robust, production-ready implementation of the Bulkhead pattern, designed to isolate resources and prevent cascading failures in mission-critical distributed systems. It supports both modern async (AnyIO/asyncio) and traditional synchronous (Threading) workloads with zero overhead.

Key Capabilities

  • Resource Isolation: Limits concurrent access to prevent service exhaustion.
  • Circuit Breaker Integration: Built-in distributed circuit breaking via resilient-circuit (opt-in, disabled by default).
  • Dual Mode:
    • Async: AnyIO-based (asyncio) for high-concurrency IO.
    • Sync: Zero-overhead ThreadPoolExecutor implementation for CPU-bound or blocking IO tasks.
  • Observability: Full contextvars support for distributed tracing (OpenTelemetry/Datadog).
  • Type Safe: 100% type-hinted and rigorously tested (>92% coverage).

Documentation

Quick Install

pip install bulkman

Quick Example (Blocking/Threading)

For legacy or synchronous applications, use BulkheadThreading:

from bulkman import BulkheadThreading, BulkheadConfig

# Configure
config = BulkheadConfig(name="db_writer", max_concurrent_calls=10, timeout_seconds=5.0)
bulkhead = BulkheadThreading(config)

# Execute
try:
    future = bulkhead.execute(my_blocking_function, data)
    result = future.result(timeout=5.0)
    print(result.result)
except TimeoutError:
    print("System overloaded")

👉 See the User Guide for async examples

License

Licensed under the Apache License 2.0.

Metadata

Release files for bulkman 2.0.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for bulkman 2.0.4
File Size Uploaded Provenance Actions
bulkman-2.0.4.tar.gz 44.5 kB Without provenance Details for bulkman-2.0.4.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for bulkman 2.0.4
File Interpreter ABI Platform Actions
bulkman-2.0.4-py3-none-any.whl Python 3 none any Details for bulkman-2.0.4-py3-none-any.whl

Total release size: 70.0 kB

Release files / bulkman-2.0.4.tar.gz

Download URL bulkman-2.0.4.tar.gz
Size 44.5 kB
Tags Source
SHA-256 checksum
How to use checksums
8961d3be768c355710ff92c4d67cdbb0dd577fd06a890b2ec29324cc06b9315d
BLAKE2b-256 checksum
How to use checksums
adb43e80de8dd30db81e52e05878a0eeb4a02d47053b57b4bbd2a605872fb724
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.2

Release files / bulkman-2.0.4-py3-none-any.whl

Download URL bulkman-2.0.4-py3-none-any.whl
Size 25.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
4f532120ca0c4dba003feb9217c7ed72af507d1ab69e0c8de7dd04bba5efce45
BLAKE2b-256 checksum
How to use checksums
443b3ae7255032873c76cdbe9b6989b48dbf492691deb68f8eb5729156708a36
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.2

Security for bulkman 2.0.4

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page