Skip to main content

Making postgres listen/notify easier.

Project description

Installing

To install :

pip install trunk

Usage

Trunk tries to be as simple as possible

t = Trunk("postgres://localhost/noclue")
for channel, payload in t.notifications("clues"):
    print channel, payload
t.notify("clues", "chandelier")
t.unlisten("clues")

Celery

Trunk provides a Kombu transport, that allows you to use trunk with Celery, to do so, configure Celery with :

BROKER_URL = 'trunk.transport.Transport://localhost/database'

Setup

You will need to create a new table and add two functions to your database. See table.sql and ddl.sql.

Project details


Download files

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

Source Distribution

trunk-0.3.0.tar.gz (4.1 kB view details)

Uploaded Source

File details

Details for the file trunk-0.3.0.tar.gz.

File metadata

  • Download URL: trunk-0.3.0.tar.gz
  • Upload date:
  • Size: 4.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for trunk-0.3.0.tar.gz
Algorithm Hash digest
SHA256 29da400d7d7f7685e2a834a78fbccaf2feeb04f7892763c0c0f7b75ed27a1c0a
MD5 16aa0e9bfa5662286033ad571f96cae2
BLAKE2b-256 7af1104742c3842bafe5d426dd19e5e8c5cac08f472d8b9b82d5edd3756b49c4

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page