Skip to main content

A ready-to-use SSE messaging microservice implementation.

Introduction

Backend documentation https://laxertu.github.io/eric/docs.html
REST services rely on FastApi + Uvicorn

Features:

  • channel subscription
  • broadcasting
  • message deliver to one client
  • SSE compliant streaming

Installation:

pip install eric-api

Start webserver

uvicorn eric_api:app

API documentation is available at http://127.0.0.1:8000/docs by default

See correspondant uvicorn configuration https://www.uvicorn.org/deployment/#running-from-the-command-line

Bug Tracker: https://github.com/laxertu/eric-api/issues

Docker stuff

Here you can find a couple of prefabs for redis and api itself

Services exposed are

http://127.0.0.1:5540/ Redis Insights. Host to use when creating dbs have to be "redis", as per service definition http://127.0.0.1:8000/docs Swagger

Environment setup

Configuration file is /.eric-api.env

Logging

Setup logging level

Activate it by setting .eric-api.env LOGLEVEL variable according to literals supported by python logger, for example:

LOGLEVEL=DEBUG

LOGGING_CHANNEL activates a channel identified by its value that receive broadcasts from logger used in the API. You can enable it if you want to open a real time SSE alerting service.

LOGGING_CHANNEL=logging_channel_id

Redis persistence support

Setup it with the following:

QUEUES_FACTORY=redis

Redis host is configured by

REDIS_HOST=[host to use]
REDIS_PORT=[port]
REDIS_DB=[db number]

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

eric_api-1.6.0.9.tar.gz (4.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

eric_api-1.6.0.9-py3-none-any.whl (5.0 kB view details)

Uploaded Python 3

File details

Details for the file eric_api-1.6.0.9.tar.gz.

File metadata

  • Download URL: eric_api-1.6.0.9.tar.gz
  • Upload date:
  • Size: 4.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.0.1 CPython/3.10.12 Linux/6.8.0-94-generic

File hashes

Hashes for eric_api-1.6.0.9.tar.gz
Algorithm Hash digest
SHA256 60b4107d69d93b3364ff93232bb24596b3af3c0aeb3f72470499f45fb910bc95
MD5 6ab5f1b1c611106a73362e020dcb5f60
BLAKE2b-256 c0c183fa00e2e43e9dcb99dc5093368cbd09e786d3112948310edd8ba894d31d

See more details on using hashes here.

File details

Details for the file eric_api-1.6.0.9-py3-none-any.whl.

File metadata

  • Download URL: eric_api-1.6.0.9-py3-none-any.whl
  • Upload date:
  • Size: 5.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.0.1 CPython/3.10.12 Linux/6.8.0-94-generic

File hashes

Hashes for eric_api-1.6.0.9-py3-none-any.whl
Algorithm Hash digest
SHA256 148b20f2b4d14c7b1ce7321b8c2202d8ca11c866241470a1fd4239edd305fb0a
MD5 9c06845742fc0cfd9011c61b96f90a92
BLAKE2b-256 4c64d1862845e8509e2f059009f376a51f50fc4da1d918a1e3921be69b9863eb

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

1.6.0.9 This release

2 files

1.6.0.8

2 files

1.6.0.7

2 files

1.6.0.5

2 files

1.6.0.4

2 files

1.6.0.3

2 files

1.6.0.2

2 files

1.6.0.1

2 files

1.6.0

2 files

1.5.1.4

2 files

1.5.1.3

2 files

1.5.1.2

2 files

1.5.1.1

2 files

1.5.1

2 files

1.5.0.1

2 files

1.5.0

2 files

1.4.3.5

2 files

1.4.3.4

2 files

1.4.3.3

2 files

1.4.3.2

2 files

1.4.3.1

2 files

1.4.3

2 files

1.4.2

2 files

1.4.1

2 files

1.4.0

2 files

1.3.1.2

2 files

1.3.1.1

2 files

1.3.1

2 files

1.3.0

2 files

1.2.2

2 files

1.2.1

2 files

1.2.0

2 files

1.1.0

2 files

1.0.1

2 files

1.0.0

2 files

0.0.4

2 files

0.0.3

2 files

0.0.2

2 files

0.0.1

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page