Skip to main content

A Python 3 asyncio client for the beanstalkd work queue

Project description

aiostalk is a small and shameless Python client library for communicating with the beanstalkd work queue.

It is based on (and requires) another library called greenstalk by Justin Mayhew.

Getting Started

Presuming beanstalkd running on localhost at standard port.

>>> import asyncio
>>> import aiostalk
>>>
>>> async def main():
...    client = aiostalk.Client(('127.0.0.1', 11300))
...    await client.connect()
...    job = await client.put('hello')
...    print(job.id)
...    job = await client.reserve()
...    print(job.id)
...    print(job.body)
...    await client.delete(job)
...    await client.close()
>>>
>>> asyncio.run(main())
1
1
hello

Using the Client as an asyncio context manager is also supported.

Documentation

Please see greenstalk docs at Read the Docs.

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

aiostalk-1.1.tar.gz (5.2 kB view details)

Uploaded Source

Built Distribution

aiostalk-1.1-py3-none-any.whl (5.3 kB view details)

Uploaded Python 3

File details

Details for the file aiostalk-1.1.tar.gz.

File metadata

  • Download URL: aiostalk-1.1.tar.gz
  • Upload date:
  • Size: 5.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.6.0 importlib_metadata/4.8.2 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.2

File hashes

Hashes for aiostalk-1.1.tar.gz
Algorithm Hash digest
SHA256 7240baa7034f4c3f0fadd209f8e3e267563761e2ebfb8bb63a7b9bf3f3be6e63
MD5 964bf58b316abbaba4bc407ab793a8c5
BLAKE2b-256 252a6f625796daa7fb79289a5c98323a7a02f59241a6663bea6426be169dbe39

See more details on using hashes here.

File details

Details for the file aiostalk-1.1-py3-none-any.whl.

File metadata

  • Download URL: aiostalk-1.1-py3-none-any.whl
  • Upload date:
  • Size: 5.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.6.0 importlib_metadata/4.8.2 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.2

File hashes

Hashes for aiostalk-1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e1cfb36e99f92fd98d9034adeb2a8ae34f0e5cf7e7261d1afb0afc41eca7f6c8
MD5 321ac255e6da8f1713b6ee238b55bfc0
BLAKE2b-256 ef29f9ca0a716922e5cad70a002279a0c4c7fc48c444523dfc0dc7adc7ce157e

See more details on using hashes here.

Supported by

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