Skip to main content

Aiomisc Entrypoint

Alternative way to run aiomisc entrypoint with processors added behavior to start and stop events of entrypoint and custom query logger.

Basic usage

from aiomisc_entrypoint import Entrypoint

ep = Entrypoint()
ep.clear_environ()
ep.change_user()
ep.system_signals_listener()
ep.register_services_in_context()
ep.first_start_last_stop()

ep.run_forever()

Extended usage

from signal import SIGINT, SIGTERM, SIGKILL
from aiomisc import Service
from aiomisc_entrypoint import Entrypoint

class TestService(Service):
    
    async def start(self):
        ...

    
async def main():
    ...


services = (
    TestService(context_name='svc1'),
    TestService(context_name='svc2'),
)
    
ep = Entrypoint(*services)
ep.clear_environ(lambda x: x.startwith('APP_'))
ep.change_user('user')
ep.system_signals_listener(SIGINT, SIGTERM, SIGKILL)
ep.register_services_in_context()
ep.first_start_last_stop()

ep.run_until_complete(main())

Release Notes:

v1.0.1

  • fix error with set loop for asyncio.Event in SysSignalListener

Metadata

Release files for aiomisc-entrypoint 1.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for aiomisc-entrypoint 1.2.0
File Size Uploaded
aiomisc_entrypoint-1.2.0.tar.gz 4.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for aiomisc-entrypoint 1.2.0
File Interpreter ABI Platform
aiomisc_entrypoint-1.2.0-py3-none-any.whl Python 3 none any Details

Total release size: 11.3 kB

Release files / aiomisc_entrypoint-1.2.0.tar.gz

Download URL aiomisc_entrypoint-1.2.0.tar.gz
Size 4.1 kB
Tags Source
SHA-256 checksum
How to use checksums
8b13df6a408be1d01fe8d185e106038ce46e243cce3c20ae1d29d742b524a0e4
BLAKE2b-256 checksum
How to use checksums
c76eca92f96d2875d55e52a356993c42e9afa8446409503d7d1d1dd4a3e1109d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.4.2 CPython/3.9.12 Darwin/22.5.0

Release files / aiomisc_entrypoint-1.2.0-py3-none-any.whl

Download URL aiomisc_entrypoint-1.2.0-py3-none-any.whl
Size 7.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b82953c1b42d134b3784454ca93c669bb7ae61d2db5262cd703b05d66dcf68a6
BLAKE2b-256 checksum
How to use checksums
1ff02e42fc672949829e648e11771598d6f30e96a641d6f1c7df23f5a00464e9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.4.2 CPython/3.9.12 Darwin/22.5.0

Release history Release notifications | RSS feed

This release

1.2.0 This release

2 release files

1.1.0

2 release files

1.0.1

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page