A python package that works to provide service registration and discovery for http://microhackaton.github.io/2014/
Project description
Python library to interact with other microservices at http://microhackaton.github.io/2014/
Installation
$ pip install microhackaton-service-discovery-py
Usage
from service_discovery import ServiceDiscovery
sd = ServiceDiscovery('/pl/pl/microhackaton', 'zookeeper.microhackathon.pl:2181')
How to register your service?
instance_id = sd.register('something-collector', '12.34.56.78', 8080)
How to find instances of other service?
urls_as_list = sd.get_instances('blog-collector')
How to find random service instance?
url_as_str = sd.get_instances('blog-collector')
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
Close
Hashes for microhackaton-service-discovery-py-0.0.3.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | d83181ca7ed01b2ed0030578eb59d9405a7ce63f7c5772976ab3f50e8690ab96 |
|
MD5 | 9473ec753ee2ca40535a0071cb2ec84e |
|
BLAKE2b-256 | c0ab85c5164266501f3f1f7d3097b12c531123264c1d7048647c1a5005d833b2 |