Skip to main content

Async Eureka client

Project description

WASP Eureka

Asynchronous Naive Eureka client for the Netflix OSS/Spring Cloud bundled eureka stack.


Note: this supports Python 3.5+

$ pip install wasp-eureka

If you want to just run it standalone, include those dependencies:

$ pip install wasp-eureka[standalone]


The surface area of this module is pretty small, effectively you just need to care about the wasp_eureka.EurekaClient class and its methods:

import asyncio

from wasp_eureka import EurekaClient

# no spaces or underscores, this needs to be url-friendly
app_name = 'test-app'

port = 8080
# This needs to be an IP accessible by anyone that
# may want to discover, connect and/or use your service.
ip = ''
my_eureka_url = ''
loop = asyncio.get_event_loop()

eureka = EurekaClient(app_name, port, ip, eureka_url=my_eureka_url,

async def main():
    # Presuming you want your service to be available via eureka
    result = await eureka.register()
    assert result, 'Unable to register'

    # You need to provide a heartbeat to renew the lease,
    # otherwise the eureka server will expel the service.
    # The default is 90s, so any time <90s is ok
    while True:
        await asyncio.sleep(67)
        await eureka.renew()


Creating a Release

Bumpversion provides a simplified way to manage versioning, to check the dry run before running it:

$ bumpversion [patch,minor,major] --dry-run --verbose
$ bumpversion patch

Project details

Download files

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

Files for wasp-eureka, version 1.1.1
Filename, size File type Python version Upload date Hashes
Filename, size wasp_eureka-1.1.1-py3-none-any.whl (11.0 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size wasp-eureka-1.1.1.tar.gz (7.1 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page