code: protected void checkPaused() throws IOException {
          if (this.paused.get()) {
              synchronized (this.paused) {
                  if (this.paused.get()) {
                      PoolUtils.doWorkInPoolNicely(this.jedisPool, new PoolWork<Jedis, Void>() {
                          /**
                           * {@inheritDoc}
                           */
                          @Override
                          public Void doWork(final Jedis jedis) throws IOException {
                              jedis.set(key(WORKER, name), pauseMsg());
                              return null;
                          }
                      });
                  }
                  while (this.paused.get()) {
                      try {
                          this.paused.wait();
                      } catch (InterruptedException ie) {
                          LOG.warn("Worker interrupted", ie);
                      }
                  }
                  PoolUtils.doWorkInPoolNicely(this.jedisPool, new PoolWork<Jedis, Void>() {
                      /**
                       * {@inheritDoc}
                       */
                      @Override
                      public Void doWork(final Jedis jedis) {
                          jedis.del(key(WORKER, name));
                          return null;
                      }
                  });
              }
          }
      }
docs: Checks to see if worker is paused. If so, wait until unpaused.
  
  @throws IOException if there was an error creating the pause message