 EventEmitter = require "events"
 Promise = require "bluebird"
 uuid = require "uuid/v4"
+newrelic = _.once -> require("newrelic")
 
 ENABLE_EVENTS = process.env.ENABLE_EVENTS isnt "false"
 

      .finally => @_emitEvent "finished", { context, id, notification }
      .asCallback context.done

      return

    _emitEvent: (eventName, value) =>
      @emit eventName, value if ENABLE_EVENTS

      $promise = Promise.method(@runner) notification, context
      $promise = $promise.timeout(@timeout, "processor timeout") if @timeout?

      promise = () -> $promise
      .tap => @_emitEvent "successful", { context, id, notification }
      .catch (error) =>
        throw error unless error instanceof NonRetryable
