Skip to main content

Small Task Queue

Project description

============
hakka-py
============

.. image:: https://img.shields.io/pypi/v/hakka.svg
:target: https://pypi.python.org/pypi/hakka

.. image:: https://img.shields.io/travis/Himenon/hakka-py.svg
:target: https://travis-ci.org/Himenon/hakka-py

.. image:: https://readthedocs.org/projects/hakka-py/badge/?version=latest
:target: https://hakka-py.readthedocs.io/en/latest/?badge=latest
:alt: Documentation Status

.. image:: https:/ /pyup.io/repos/github/Himenon/hakka-py/shield.svg
:target: https://pyup.io/repos/github/Himenon/hakka-py/
:alt: Updates


Small Task Queue

* Free software: MIT license
* Documentation: <https://hakka.readthedocs.io>.

Usage
=====

.. code-block:: bash

$ pip install hakka


**Worker**

.. code-block:: python

from hakka import Hakka

app = Hakka()

@app.watch('hello:msg')
def hello_msg(name=None, msg=None, **kwargs):
print("Hello {name}!, {msg}".format(name=name, msg=msg))

app.listen('localhost', 6379, 0, debug=True)

**Sender**

.. code-block:: python

from hakka import HakkaRedisClient

if __name__ == '__main__':
client = HakkaRedisClient()

message = {
"name": "hakka",
"reading": "books"
}
for i in range(10):
message.update({
"msg": "Hello World x {}!".format(i),
})
client.set_value('hello:msg', message)

.. code-block:: bash

$ redis-cli lpush hello:msg '{"name": "yourname", "msg": "Congratulation!"}'

How to Develop
==============

Using: Docker, docker-compose

.. code-block:: bash

$ docker-compose up
# start pytest-watch



=======
History
=======

0.1.0 (2018-02-23)
------------------

* First release on PyPI.


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

hakka-0.2.1.tar.gz (12.2 kB view details)

Uploaded Source

Built Distribution

hakka-0.2.1-py2.py3-none-any.whl (8.3 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file hakka-0.2.1.tar.gz.

File metadata

  • Download URL: hakka-0.2.1.tar.gz
  • Upload date:
  • Size: 12.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for hakka-0.2.1.tar.gz
Algorithm Hash digest
SHA256 78db4b343b6d2818c68bd8e3cbc4faf16c3585bc35ac3978b1d41a9256af0c88
MD5 ade384617f9d6ed4a77bd61f8a892eec
BLAKE2b-256 bfbbdd8af5240145d2f9ec7ac7ac84c588745869d1d0df3557cd10f3853cc654

See more details on using hashes here.

File details

Details for the file hakka-0.2.1-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for hakka-0.2.1-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 ebe5d409c44e338ffcb364bcdd069373c469032b09eff12ee0765dde85fcf5b7
MD5 d5db56ad595260d426180a75ce766349
BLAKE2b-256 a0eca6f0bcfd3e06ed715490d74c15a2cb2bc0ed5ff342d77eb7ec717bd00ecc

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