Skip to main content

As in Ginkgo (of which this module was inspired). Provides gevent primitives to orchestrate different orthogonal servers and services together.

Basic usage:

from gevent import wsgi

import biloba


def hello_world(environ, start_response):
    start_response('200 OK', [('Content-Type', 'text/html')])

    return ['<b>Hello world!</b>\n']


class MyService(biloba.Service):
    def make_web_server(self):
        return wsgi.WSGIServer(
            ('localhost', 5000),
            hello_world
        )

    def do_start(self):
        self.web_server = self.make_web_server()

        self.spawn(self.web_server.serve_forever)

        # you can add more servers/services here


if __name__ == '__main__':
    my_service = MyService()

    # start is called by join

    try:
        my_service.join()
    except KeyboardInterrupt:
        pass

    # as is stop

Download files

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

Source Distribution

biloba-1.1.0.tar.gz (12.7 kB view details)

Uploaded Source

File details

Details for the file biloba-1.1.0.tar.gz.

File metadata

  • Download URL: biloba-1.1.0.tar.gz
  • Upload date:
  • Size: 12.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for biloba-1.1.0.tar.gz
Algorithm Hash digest
SHA256 4d4fbd317d479cad79b63b0c8a9e37f088aba954ccbc56370e0ed7a30403825e
MD5 d38baadb8d0b1beba2cb0accdb43d326
BLAKE2b-256 a7046b662353ab4a7e167c15bea8dba150641947228ac3094bfa537fcbe6c021

See more details on using hashes here.

Release history Release notifications | RSS feed

3.1.0

1 file

3.0.0

1 file

2.0.0

1 file

1.2.2

1 file

1.2.1

1 file

1.2.0

1 file

1.1.3

1 file

1.1.2

1 file

1.1.1

1 file

This release

1.1.0 This release

1 file

1.0.0

1 file

0.10.1

1 file

0.10.0

1 file

0.9.4

1 file

0.9.3

1 file

0.9.2

1 file

0.9.1

1 file

0.9.0

1 file

0.2.1

1 file

0.2.0

1 file

0.1.4

1 file

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