Skip to main content

AIS service discovery package for python3

Project description

ais-service-discovery-python

Cloud Application Framework

logo

Description

This repository interfaces Service Discovery, in this instance CloudMap, in order to locate and communicate with different services. As opposed to storing ARN's in environment variables, this library will interface CloudMap to find a service by a user-friendly naming convention and will understand what 'type' of service you've requested and use the correct code to communicate/call that service.

Services supported

  • Lambda (call).

TODO

  • Lambda (request)
  • SNS (publish). // subscribe not supported by SNS.
  • SQS (queue|listen),
  • Http (request|call).
  • Fargate/ECS Task (run).

Note:

This library requires Python 3.5 and above.

Examples:

Lambda Call

from ais_service_discovery import call
response=call('namespace', 'service', 'handler', {<Payload>})
print(response)

Lambda Async Call

from ais_service_discovery import call
response=call('namespace', 'service', 'handler', {<Payload>}, {'InvocationType': 'Event'})
print(response)

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

ais_service_discovery-0.0.8.tar.gz (3.4 kB view hashes)

Uploaded Source

Built Distribution

ais_service_discovery-0.0.8-py3-none-any.whl (17.1 kB view hashes)

Uploaded Python 3

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