This is a pre-production deployment of Warehouse, however changes made here WILL affect the production instance of PyPI.
Latest Version Dependencies status unknown Test status unknown Test coverage unknown
Project Description

What is this?

mongodb-triggers is a light-weight library to allow trigger capabilities with mongodb. the triggers are similar to ones that can be found in RDBM, although it is not on the server side but on the client side.

What is it good for?

Modern applications have become near real-time response and updates, this leads to the requirement that any changes done in the data to be propagated up to the top level of the application as soon as possible.

In order to allow this to happen, any changes in the databases must be notified, similar project that use this method is


PyInstaller is available on PyPI. You can install it through pip:

$ pip install mongotriggers

How to use?

Let’s assume the system in development is a financial one, and every deletion in the database is extremely important, so we would like to notified for each deletion.

from mongotrigger import MongoTrigger
from pymongo import MongoClient

def notify_manager(op_document):
    print ('wake up! someone is stealing money')

def myfunc():
    client = MongoClient(host='localhost', port=27017)
    triggers = MongoTrigger(conn)
    triggers.register_delete_trigger(notify_manager, 'my_account', 'my_transactions')
    thread = threading.Thread(target=triggers.listen_start)

    // do something impressive


Keep in mind that it is meant to run in a defered context in order to run endlessly until it is cancelled.


The API functionality includes:

  • register_insert_trigger
  • register_update_trigger
  • register_delete_trigger
  • listen_start
  • listen_stop
Release History

Release History


This version

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

Download Files

Download Files

TODO: Brief introduction on what you do with files - including link to relevant help section.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
mongotriggers-0.0.1.dev14-py2.py3-none-any.whl (5.7 kB) Copy SHA256 Checksum SHA256 py2.py3 Wheel Oct 18, 2016
mongotriggers-0.0.1.dev14.tar.gz (5.5 kB) Copy SHA256 Checksum SHA256 Source Oct 18, 2016

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS HPE HPE Development Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting