Skip to main content

Aerospike Python Client - PyO3 + Rust binding

Project description

aerospike-py

CI Python Rust PyO3 License

Aerospike Python Client built with PyO3 + Rust. Drop-in replacement for aerospike-client-python powered by the Aerospike Rust Client v2.

Features

  • Sync and Async (AsyncClient) API
  • CRUD, Batch, Query/Scan, UDF, Admin, Index, Truncate
  • CDT List/Map Operations, Expression Filters
  • Full type stubs (.pyi) for IDE autocompletion

API details: docs/api/ | Usage guides: docs/guides/

Quickstart

pip install aerospike-py

Sync Client

import aerospike_py as aerospike

with aerospike.client({
    "hosts": [("127.0.0.1", 3000)],
    "cluster_name": "docker",
}).connect() as client:

    key = ("test", "demo", "user1")
    client.put(key, {"name": "Alice", "age": 30})

    _, meta, bins = client.get(key)
    print(bins)  # {'name': 'Alice', 'age': 30}

    client.increment(key, "age", 1)
    client.remove(key)

Async Client

import asyncio
from aerospike_py import AsyncClient

async def main():
    async with AsyncClient({
        "hosts": [("127.0.0.1", 3000)],
        "cluster_name": "docker",
    }) as client:
        await client.connect()

        key = ("test", "demo", "user1")
        await client.put(key, {"name": "Bob", "age": 25})
        _, _, bins = await client.get(key)
        print(bins)

        # Concurrent operations
        tasks = [client.put(("test", "demo", f"item_{i}"), {"idx": i}) for i in range(10)]
        await asyncio.gather(*tasks)

asyncio.run(main())

Performance

Benchmark: 5,000 ops x 100 rounds, Aerospike CE (Docker), Apple M4 Pro

Operation aerospike-py sync official C client aerospike-py async Async vs C
put (ms) 0.140 0.139 0.058 2.4x faster
get (ms) 0.141 0.141 0.063 2.2x faster

Sync performance is on par with the official C client. Async throughput is 2.2-2.4x faster — the official C client has no Python async/await support (attempted and removed).

Why async matters

The official C client supports async I/O internally (libev/libuv/libevent), but its Python bindings cannot expose async/await — the attempt was abandoned and removed in PR #462. The only concurrency option with the C client is asyncio.run_in_executor() (thread pool, not true async).

aerospike-py provides native async/await via Tokio + PyO3, enabling asyncio.gather() for true concurrent I/O — critical for modern Python web frameworks (FastAPI, Starlette, etc).

Full benchmark details: benchmark/ | Run: make run-benchmark

Contributing

See CONTRIBUTING.md for development setup, running tests, and making changes.

License

Apache License 2.0 — see LICENSE for details.

Project details


Download files

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

Source Distribution

aerospike_py-0.0.1a3.tar.gz (63.5 kB view details)

Uploaded Source

Built Distributions

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

aerospike_py-0.0.1a3-pp311-pypy311_pp73-manylinux_2_28_x86_64.whl (2.1 MB view details)

Uploaded PyPymanylinux: glibc 2.28+ x86-64

aerospike_py-0.0.1a3-pp311-pypy311_pp73-manylinux_2_28_aarch64.whl (2.0 MB view details)

Uploaded PyPymanylinux: glibc 2.28+ ARM64

aerospike_py-0.0.1a3-cp314-cp314t-manylinux_2_28_aarch64.whl (2.0 MB view details)

Uploaded CPython 3.14tmanylinux: glibc 2.28+ ARM64

aerospike_py-0.0.1a3-cp314-cp314-manylinux_2_28_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.14manylinux: glibc 2.28+ x86-64

aerospike_py-0.0.1a3-cp314-cp314-manylinux_2_28_aarch64.whl (2.0 MB view details)

Uploaded CPython 3.14manylinux: glibc 2.28+ ARM64

aerospike_py-0.0.1a3-cp313-cp313t-manylinux_2_28_aarch64.whl (2.0 MB view details)

Uploaded CPython 3.13tmanylinux: glibc 2.28+ ARM64

aerospike_py-0.0.1a3-cp313-cp313-win_amd64.whl (2.4 MB view details)

Uploaded CPython 3.13Windows x86-64

aerospike_py-0.0.1a3-cp313-cp313-manylinux_2_28_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.28+ x86-64

aerospike_py-0.0.1a3-cp313-cp313-manylinux_2_28_aarch64.whl (2.0 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.28+ ARM64

aerospike_py-0.0.1a3-cp313-cp313-macosx_11_0_arm64.whl (1.9 MB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

aerospike_py-0.0.1a3-cp313-cp313-macosx_10_12_x86_64.whl (2.0 MB view details)

Uploaded CPython 3.13macOS 10.12+ x86-64

aerospike_py-0.0.1a3-cp312-cp312-manylinux_2_28_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.28+ x86-64

aerospike_py-0.0.1a3-cp312-cp312-manylinux_2_28_aarch64.whl (2.0 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.28+ ARM64

aerospike_py-0.0.1a3-cp311-cp311-manylinux_2_28_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ x86-64

aerospike_py-0.0.1a3-cp311-cp311-manylinux_2_28_aarch64.whl (2.0 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ ARM64

aerospike_py-0.0.1a3-cp310-cp310-manylinux_2_28_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ x86-64

aerospike_py-0.0.1a3-cp310-cp310-manylinux_2_28_aarch64.whl (2.0 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ ARM64

File details

Details for the file aerospike_py-0.0.1a3.tar.gz.

File metadata

  • Download URL: aerospike_py-0.0.1a3.tar.gz
  • Upload date:
  • Size: 63.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for aerospike_py-0.0.1a3.tar.gz
Algorithm Hash digest
SHA256 f0730933a165b7d2480cbf7fe9ead8b89d53e8d5031cea34d486f1c4f4d9f446
MD5 7b2860138a27e33b315023cc8d126c64
BLAKE2b-256 7b99037822f725477ebdebef32540e53fa104947be75f7ff5e6a8198af3fd7b7

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3.tar.gz:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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

File details

Details for the file aerospike_py-0.0.1a3-pp311-pypy311_pp73-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for aerospike_py-0.0.1a3-pp311-pypy311_pp73-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 94d20bb5caeec4bfc177b1dc85393485ad6e8aa844663ee18fc4c85c58d3e683
MD5 a1024c3c73b9399dc50dd4cf6b3c983d
BLAKE2b-256 7a8dd0d05c50807bc4d549c841a7b861bc81055874beccf474ab375d0b8aeebb

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3-pp311-pypy311_pp73-manylinux_2_28_x86_64.whl:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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

File details

Details for the file aerospike_py-0.0.1a3-pp311-pypy311_pp73-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for aerospike_py-0.0.1a3-pp311-pypy311_pp73-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 a2442fa01389391e70901477c4893e5a0a3634847464240eeaabc8baf3f27c54
MD5 d7f5003942ef07ac6088e19778db8fb6
BLAKE2b-256 c65a40bfb2b8b8eb13f8a676f0b48c6a7d9bba7bf07a015b96403f7a8195248d

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3-pp311-pypy311_pp73-manylinux_2_28_aarch64.whl:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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

File details

Details for the file aerospike_py-0.0.1a3-cp314-cp314t-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for aerospike_py-0.0.1a3-cp314-cp314t-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 e628b7acaa40d74c29e8842f619cd29bc532c6d59a832e1f03f0c5e2d3c00fdd
MD5 15ea273c8617cf3d48556e8a4ecfa670
BLAKE2b-256 3ddb8f9db1f6889465002567e68de1cacb708f5533d504403e2cdc95cb5f78ad

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3-cp314-cp314t-manylinux_2_28_aarch64.whl:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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

File details

Details for the file aerospike_py-0.0.1a3-cp314-cp314-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for aerospike_py-0.0.1a3-cp314-cp314-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 78325e7588b6f669b2e5ee5c17bc02a549e2a34724d1b74814dbcdc02a148d4a
MD5 5dfc4dd8cc61c4044a5c7714ae117153
BLAKE2b-256 4356ea4c4276a6138d611d66bfd39c781008b16d592142737a56e963ea23b95a

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3-cp314-cp314-manylinux_2_28_x86_64.whl:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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

File details

Details for the file aerospike_py-0.0.1a3-cp314-cp314-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for aerospike_py-0.0.1a3-cp314-cp314-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 73723ddd0f1fddf4da32fecf3659f650ae9735f69dc4411bbf1fe9d8c776bbc6
MD5 3b11079ddac18976defb098f72081bd0
BLAKE2b-256 e14033b559d9ab556c7d38631f6ff3036df555d4f5025a388689021d61e7ee04

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3-cp314-cp314-manylinux_2_28_aarch64.whl:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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

File details

Details for the file aerospike_py-0.0.1a3-cp313-cp313t-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for aerospike_py-0.0.1a3-cp313-cp313t-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 600400b34d6ad3d966db0398c1ac18658767dca3bd0f9675b69f4746234412a9
MD5 46e1d38db2d25f6b4d0ed0c47eda1d1c
BLAKE2b-256 8ea4af6f704daa8a560b043eae11dc69e7c7c6de286723ac9348cfc9a9b61bcd

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3-cp313-cp313t-manylinux_2_28_aarch64.whl:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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

File details

Details for the file aerospike_py-0.0.1a3-cp313-cp313-win_amd64.whl.

File metadata

File hashes

Hashes for aerospike_py-0.0.1a3-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 6e220a82ca421c4d89152e53586bd169c5b6ade3422cd57aaab25a559f687c99
MD5 bcb3e18b7aed38a602465263b8bd5c93
BLAKE2b-256 fdd35abac6c9cd8cedfe9f24549e5f53766894d446ee4ab5c1f5baf458d60f96

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3-cp313-cp313-win_amd64.whl:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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

File details

Details for the file aerospike_py-0.0.1a3-cp313-cp313-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for aerospike_py-0.0.1a3-cp313-cp313-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 d1877aa5787d69284306bf8e270447ec763060ecb6af850a502f350149a23325
MD5 d47c6acb4de8ce2dd6e0602253fb1dd6
BLAKE2b-256 910b732dd4cd81091236e54e0a848db189cd30be2d394b085f72ad5e410e2b2d

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3-cp313-cp313-manylinux_2_28_x86_64.whl:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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

File details

Details for the file aerospike_py-0.0.1a3-cp313-cp313-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for aerospike_py-0.0.1a3-cp313-cp313-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 31fd6821c56609b53e33b47d149556ce80a0de0c6463f56b36264e88c72ca815
MD5 f15282c5bf6e6bfc1fa792164a0ea44a
BLAKE2b-256 01e70d35728ac8cf7ad2b9dcf6fbaebbef2878ab37c2cdcd575ef03364e78c37

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3-cp313-cp313-manylinux_2_28_aarch64.whl:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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

File details

Details for the file aerospike_py-0.0.1a3-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for aerospike_py-0.0.1a3-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 ca99f3e2af4047f3f85ee0d4e2c98f9d47d452871821d742dc8683871cff9b8f
MD5 38cbb2dbc659d7a2472e62f6a78a9ab2
BLAKE2b-256 ab97c0ede58c730f94068a44c978216383ea24abb8938b45e59bff07decefd34

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3-cp313-cp313-macosx_11_0_arm64.whl:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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

File details

Details for the file aerospike_py-0.0.1a3-cp313-cp313-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for aerospike_py-0.0.1a3-cp313-cp313-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 62d513d5ce7a584d18ffff334c186ae43daf88f92fc75e2ce19b6bf4b56e3e49
MD5 a1ed3229d455272f11b03d649b9de7e4
BLAKE2b-256 7600e598866187b471360eb48caa7dee7942b6748ed6e418a5220ba06d78f013

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3-cp313-cp313-macosx_10_12_x86_64.whl:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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

File details

Details for the file aerospike_py-0.0.1a3-cp312-cp312-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for aerospike_py-0.0.1a3-cp312-cp312-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 734e33174f2e656b3c6340300d6bcc34a707f98b42c35df6d014c00a2abb8f5f
MD5 aa724e5466145028425bc8a8061e73dd
BLAKE2b-256 def1ea3f639db378dc81b1d099c5e0a475d3a09ee92a09525d407be342a19de8

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3-cp312-cp312-manylinux_2_28_x86_64.whl:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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

File details

Details for the file aerospike_py-0.0.1a3-cp312-cp312-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for aerospike_py-0.0.1a3-cp312-cp312-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 4fdaafe323a4af99f1da09220f4a16608261187a4c7266c1969f5503616d70c0
MD5 a8939a4dc76a489d69a653e6ad3bfa43
BLAKE2b-256 d426e7f2f5f375790cf0dc5e056d46727ea3b42665c385665fccb75e67d94c0b

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3-cp312-cp312-manylinux_2_28_aarch64.whl:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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

File details

Details for the file aerospike_py-0.0.1a3-cp311-cp311-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for aerospike_py-0.0.1a3-cp311-cp311-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 1da03ebc1a6767f5c61582fe80ac4725d684eed245be62386df027f87b76b36c
MD5 13e3d041662ca5a5414786986b796059
BLAKE2b-256 08226c1641b499278220b2fce48ee71f00cfd1ec0c066cebd017079b9722f7e1

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3-cp311-cp311-manylinux_2_28_x86_64.whl:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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

File details

Details for the file aerospike_py-0.0.1a3-cp311-cp311-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for aerospike_py-0.0.1a3-cp311-cp311-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 27cc7023cc435ca4b8133c1917db10b4d3e80079ea6498fbb80cd5f8110a0d03
MD5 18e1a878b920e5c554181a89586afa57
BLAKE2b-256 3db4c0e6f80fefe3c44f34e86cadb29086ab280e2eec7822dfdf015d0638b5ff

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3-cp311-cp311-manylinux_2_28_aarch64.whl:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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

File details

Details for the file aerospike_py-0.0.1a3-cp310-cp310-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for aerospike_py-0.0.1a3-cp310-cp310-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 ca718160d07db7e095b0c9852632d42be06db54575eaa3be80f8a71cd1a77fd2
MD5 76c41d83a317d26c58ac4d7e7b3cbe9f
BLAKE2b-256 17eb72c21b7f15a2aa2f4769e48dbf0457aeb11113b3c98e09d339e513b5c1fe

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3-cp310-cp310-manylinux_2_28_x86_64.whl:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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

File details

Details for the file aerospike_py-0.0.1a3-cp310-cp310-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for aerospike_py-0.0.1a3-cp310-cp310-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 4529c4fdb0d455af03f5454a378de84174dc1de797f2b69f71aa98e2d58ea201
MD5 441c67bd6a3803cad1d84c50f6e1915a
BLAKE2b-256 6e9614a3ab7bdc41acd30e7cabf76ab517ae75f95a1d2871dbebcaeef04b6c52

See more details on using hashes here.

Provenance

The following attestation bundles were made for aerospike_py-0.0.1a3-cp310-cp310-manylinux_2_28_aarch64.whl:

Publisher: publish.yaml on KimSoungRyoul/aerospike-py

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