code: public static InstrumentedScheduledExecutorService newScheduledThreadPool(
              int corePoolSize, MetricRegistry registry) {
          return new InstrumentedScheduledExecutorService(
                  Executors.newScheduledThreadPool(corePoolSize), registry);
      }
docs: Creates an instrumented thread pool that can schedule commands to run after a
  given delay, or to execute periodically.
  
  @param corePoolSize the number of threads to keep in the pool,
  even if they are idle
  @param registry     the {@link MetricRegistry} that will contain the metrics.
  @return a newly created scheduled thread pool
  @throws IllegalArgumentException if {@code corePoolSize < 0}
  @see Executors#newScheduledThreadPool(int)