/usr/lib/python3/dist-packages/pika_pool-0.1.3.egg-info/PKG-INFO is in python3-pika-pool 0.1.3-1ubuntu1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 | Metadata-Version: 1.1
Name: pika-pool
Version: 0.1.3
Summary: Pools for pikas.
Home-page: https://github.com/bninja/pika-pool
Author: egon
Author-email: egon@gb.com
License: BSD
Description: =========
pika-pool
=========
.. image:: https://travis-ci.org/bninja/pika-pool.png
:target: https://travis-ci.org/bninja/pika-pool
.. image:: https://coveralls.io/repos/bninja/pika-pool/badge.png?branch=master
:target: https://coveralls.io/r/bninja/pika-pool?branch=master
Pika connection pooling inspired by:
- `flask-pika <https://github.com/WeatherDecisionTechnologies/flask-pika>`_
- `sqlalchemy.pool.Pool <http://docs.sqlalchemy.org/en/latest/core/pooling.html#sqlalchemy.pool.Pool>`_
Typically you'll go with local `shovels <https://www.rabbitmq.com/shovel.html>`_, `krazee-eyez kombu <http://bit.ly/1txcnnO>`_, etc. but this works too.
usage
-----
Get it:
.. code:: bash
pip install pika-pool
and use it:
.. code:: python
import json
import pika
import pika_pool
params = pika.URLParameters(
'amqp://guest:guest@localhost:5672/?'
'socket_timeout=10&'
'connection_attempts=2'
)
pool = pika_pool.QueuedPool(
create=lambda: pika.BlockingConnection(parameters=params),
max_size=10,
max_overflow=10,
timeout=10,
recycle=3600,
stale=45,
)
with pool.acquire() as cxn:
cxn.channel.basic_publish(
body=json.dumps({
'type': 'banana',
'description': 'they are yellow'
}),
exchange='',
routing_key='fruits',
properties=pika.BasicProperties(
content_type='application/json',
content_encoding='utf-8',
delivery_mode=2,
)
)
release
-------
Tests pass:
.. code:: bash
py.test test.py --cov=pika_pool --cov-report term-missing
so update ``__version__`` in:
- ``__init__.py``
then commit and tag it:
.. code:: bash
git commit -am "release v{version}"
git tag -a v{version} -m "release v{version}"
git push --tags
and `travis <https://travis-ci.org/bninja/pika-pool>`_ will publish it to `pypi <https://pypi.python.org/pypi/pika-pool/>`_.
Platform: any
Classifier: Environment :: Web Environment
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: BSD License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|