Eventhive

Latest version: v0.5.0

Safety actively analyzes 623642 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

0.5.0

API Additions

* `eventhive.register`
The `eventhive.register(event, function)` can now register any function to any specific event. It has the same effect with `eventhive.hook` decorator, but can be used with function objects, not only with function definitions.

* `eventhive.hook`
The `eventhive.hook(event)` decorator now automatically adds the `event` `str` or `list` to the `eventhive.EVENTS`.

* `eventhive.init(required=[])`
The `eventhive.init` now has the `required` keyword parameter. If a Connector is required for the `eventhive` application to work,
its name can be appended in this list and `eventhive.init` will fail if the Connector fails to get initialized.

Bug Fixes

* Now the `server.<server_name>.endpoint` now works and is not hardcoded to `/pubsub`.

0.4.0

bash
pip install eventhive==0.4.0 for the standard FastAPI backend
pip install eventhive[redis]==0.4.0 for the Redis backend
pip install eventhive[dev]==0.4.0 for the tests


Huge changes since the last release, moving `eventhive` closer to a stable version!


Highlights of the changes:
Service Discovery
If there is an already running Eventhive Server in the Local Network with `server.<server_name>.broadcast: true` in the Configuration,
then other Eventhive processes with `connectors.<connector_name>.from_broadcast: true` will automatically connect to the server (if `connector_name` = `server_name`). No need to specify initialization parameters (IPs, ports, etc). It's all provided by the Server broadcast.

Encryption and Signing
All messages are automatically encrypted and signed if `connectors.<connector_name>.secret` in the Configuration is set to any string value! That's application level encryption, totally transparent to the API. No code changes - just setting the `secret` does the job!

Create a Server - if needed
Any Eventhive process can create an Eventhive Server *only* if it doesn't find one in the network (through Service Discovery)! The `server.<server_name>.create` Configuration key accepts the `needed` (other values `always`, `never`). Tag along with `server.<server_name>.broadcast: true` to create an `eventhive` cluster with auto-promote!

0.2.0

Do your PubSub communications like a Beehive!
Gather your Bees, split them in groups, define what they do, and command them like a Queen Bee!

Use your code both as a PubSub server and client, enable auto-discovery for bees to find their beehive,
or use an external system as your Beehive (Redis currently supported, more to come).

Go ahead! Get your 🐝🐝🐝 to work!

bash
pip install eventhive


Redis support:
bash
pip install eventhive[redis]


To develop / run the tests:
bash
pip install eventhive[redis,dev]

Links

Releases

Has known vulnerabilities

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.