           intervalTime: intervalTime
         }).
         removeOnComplete(true).
+        attempts(process.env.INTERVAL_ATTEMPTS ? 999).
+        ttl(process.env.INTERVAL_TTL ? 10000).
         save =>
           redis.set "job/#{targetId}", job.id
           debug ' - created job', job.id, 'for', targetId

    @unsubscribeTarget groupId, targetId, =>
      redis.sadd "groups/#{groupId}", targetId
      redis.mset
        "repeat/#{groupId}": true
        "repeat/#{targetId}": true

      job = @queue.create('interval', {
          groupId: groupId,

    return if !targetId

    redis.srem "groups/#{groupId}", targetId
    redis.del "active/#{targetId}"

    redis.get "job/#{targetId}", (err, jobId) =>
      debug 'unsubscribeTarget group', groupId, 'target', targetId, 'job', jobId
