In this post I’ll describe a lightweight exponential back-off and retry mechanism for Rabbit MQ consumers.

When a user on one of our sites deletes a photo we remove it from our content delivery network (CDN).

A proposed solution would have to adhere to the following constraints: A central pub-sub mechanism would suffice the first two constraints.

To help new users discover some of the most popular plugins for instrumenting their infrastructure and integrating Sensu with popular tools and services, a featured plugins page is provided on the Sensu website.

These featured plugins are the same plugins developed and maintained by the Sensu plugins project.

As a result, Nagios plugins can be used with Sensu without any modification.

The Sensu Plugins project is a community-powered open source software project that is organized by members of the Sensu community, in collaboration with the Sensu development team.

As a junior developer it was a great opportunity to work with two excellent tools for background jobs: Rabbit MQ and

We’re fairly heavy users of Rabbit MQ as Paul described in his recent post Rabbit MQ: Front the Front Line.A common issue with third-party APIs is limited availability during peak hours.Even outside peak hours, API requests can be rejected, timeout and fail.The Sensu Plugins project currently maintains of plugins providing various checks, handlers, and mutators which are used by thousands of organizations around the world.Most of the plugins maintained by the Sensu Plugins project are Ruby-based plugins which are distributed via (and installable via ).Basic Properties(content_type = "text/plain", delivery_mode = 1) channel.basic_publish(exchange = exchange Name, routing_key = properties.reply_to, properties = reply Prop, body = "Reply to %s" % (body)) channel.basic_ack(delivery_tag = method.delivery_tag) except: channel.basic_nack(delivery_tag = method.delivery_tag) while True: try: #connect credentials = pika. Connection Parameters(host = server, port = port, virtual_host = vhost, credentials = credentials, heartbeat_interval = 60)) channel = #declare exchange and queue, bind them and consume messages channel.exchange_declare(exchange = exchange Name, exchange_type = "direct", auto_delete = True) channel.queue_declare(queue = request Queue, exclusive = True, auto_delete = True) channel.queue_bind(exchange = exchange Name, queue = request Queue, routing_key = request Key) channel.basic_consume(consumer_callback = on Message, queue = request Queue, no_ack = False) channel.start_consuming() except Exception, e: #reconnect on exception print "Exception handled, reconnecting...\n Detail:\n%s" % e try: connection.close() except: pass time.sleep(5) The full documentation of this library is at https://