This is a pre-production deployment of Warehouse, however changes made here WILL affect the production instance of PyPI.
Latest Version Dependencies status unknown Test status unknown Test coverage unknown
Project Description

Flask-Zookeeper

The Flask-Zookeeper extension provides support to Zookeeper clusters.

Quickstart

First, install cdumay-rest-client using pip:

pip install flask-zookeeper

Flask-Zookeeper depends, and will install for you, recent versions of Flask and Kazzo. Flask-Zookeeper is compatible with and tested on Python 2.7, 3.4 and 3.5.

Next, add a FlaskZookeeperClient instance to your code:

from flask import Flask
from flask_zookeeper import FlaskZookeeperClient

app = Flask(__name__)
fzc = FlaskZookeeperClient(app)

You can take a look at tests/test_base.py for more complete example.

You can also take a look at tests/test_blueprint.py for an example using Flask’s application factories and blueprints.

About setting up

Flask-Zookeeper uses additional variables which can be set in the app.config:

Main values

  • KAZOO_HOSTS: Zookeeper quorum server list separated by commas (default: 127.0.0.1:2181).
  • KAZOO_START_TIMEOUT: Time in seconds to wait for connection to succeed (default: 15).
  • KAZOO_SESSION_TIMEOUT: The longest to wait for a Zookeeper connection (default: 10.0).
  • KAZOO_RETRY: Dict of options to use for retrying the connection to Zookeeper (default: {'max_delay': 3600}).

ACL configuration

Zookeeper allow to set ACL. To enable this feature, set KAZOO_ACL_USERNAME and KAZOO_ACL_PASSWORD in the app.config.

  • KAZOO_ACL_USERNAME: Username to use for the ACL.
  • KAZOO_ACL_PASSWORD: A plain-text password to hash.
  • KAZOO_ACL_READ: Read permission (default: False).
  • KAZOO_ACL_WRITE: Write permission (default: False).
  • KAZOO_ACL_CREATE: Create permission (default: False).
  • KAZOO_ACL_DELETE: Delete permission (default: False).
  • KAZOO_ACL_ADMIN: Admin permission (default: False).
  • KAZOO_ACL_ALL: All permissions (default: False).

You can take a look at tests/test_acl.py for a complete example.

License

Apache License 2.0

Release History

Release History

0.0.8

This version

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.0.7

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.0.6

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.0.5

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.0.4

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.0.2

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.0.1

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

Download Files

Download Files

TODO: Brief introduction on what you do with files - including link to relevant help section.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
flask-zookeeper-0.0.8.tar.gz (3.6 kB) Copy SHA256 Checksum SHA256 Source Aug 18, 2016

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS HPE HPE Development Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting