Skip to content

mcode-cc/py-beanstalk

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

94 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PyPI PyPI - Python Version PyPI - License

beanstalkm

beanstalkm is a client library for beanstalkd, a fast, distributed, in‑memory work queue service.

beanstalkm supports Python 2.7 and Python 3.6+.

Usage

Here is a short example, to illustrate the flavor of beanstalkm:

from beanstalkm import Client, DEFAULT_TUBE

beanstalk = Client()
message = beanstalk({"say": "hey!"})
message.send()

beanstalk.queue.watch(DEFAULT_TUBE)
message = beanstalk.reserve(timeout=0, drop=False)
print(message.body)
message.delete()

or:

import beanstalkm

beanstalk = beanstalkm.Client(host="127.0.0.1", port=11300)
message = beanstalk.put({"say": "hey!"})

beanstalk.queue.watch(beanstalkm.DEFAULT_TUBE)
message = beanstalk.reserve(timeout=0, drop=True)
print(message.body)

For more information, see the tutorial, which explains most everything.

License

Copyright (C) 2017 MCode GmbH, Licensed under the GNU AFFERO GENERAL PUBLIC LICENSE.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages