/serverless-discovery-sdk-python

Python bindings to consume data from a serverless discovery service

Primary LanguagePythonMIT LicenseMIT

serverless-discovery-sdk

PyPI GitHub license

The last serverless micro-service you'll ever wonder how to find

The AWS Serverless Discovery SDK interacts with a discovery microservice to discover endpoints for micro-services written for a serverless architecture. This is similar to clustered services such as Consul or ZooKeeper, but without the concept of instances or nodes that must be monitored for online state. This library is designed to support use both on the server side (for service-to-service lookups) and on the browser/client side.

This project contains the Python bindings for the discovery service; Other bindings can be found in the AdAstraDev organization on GitHub

Installation

python3 -m pip install serverless-discovery-sdk

Usage

Python

from serverless_discovery_sdk.DiscoverySdk import DiscoverySdk
sdk = DiscoverySdk('https://abcdefghij.execute-api.us-east-1.amazonaws.com/prod')
endpoints = sdk.lookupService('my-service', 'dev')