class LtRejectedExecutionHandler extends ThreadPoolExecutor.AbortPolicy {

    @Override
    public void rejectedExecution(Runnable runnable, ThreadPoolExecutor threadPoolExecutor) {
      String pool = ((LtThreadPoolExecutor) threadPoolExecutor).getName();
      rejectedTasks.labels(pool).inc();
      log.warn(LoggingTools.SYSTEM, "Task rejected from pool '{}' (queue full, all threads exhausted)", pool);
      super.rejectedExecution(runnable, threadPoolExecutor);
    }
  }

  private static final LtRejectedExecutionHandler handler = new LtRejectedExecutionHandler();

  @NotNull
  private static ThreadPoolExecutor getNewThreadPoolExecutor(@NotNull String identifier, int corePool, int maxThreads, int maxTaskInQueue, long keepAliveTimeSeconds, boolean isDaemon, @NotNull Thread.UncaughtExceptionHandler exceptionHandler) {
    log.debug(LoggingTools.SYSTEM, String.format("Create new threadPool with corePool: %d maxThreads: %d maxTaskInQueue: %d identifier: %s daemon: %s exceptionHandler: %s", corePool, maxThreads, maxTaskInQueue, identifier, isDaemon, exceptionHandler));
    BlockingQueue<Runnable> queue;
    if (maxTaskInQueue == 0) {
      queue = new LinkedBlockingQueue<>();
    } else if (maxTaskInQueue < 0) {
      queue = new SynchronousQueue<>();
    } else {
      // fair = true helps with respecting keep-alive time
      queue = new ArrayBlockingQueue<>(maxTaskInQueue, true);
    }
    ThreadFactory threadFactory = new ThreadFactoryBuilder()
      .setNameFormat(identifier + "-%d")
      .setDaemon(isDaemon)
      .setUncaughtExceptionHandler(exceptionHandler)
      .build();
    ThreadPoolExecutor newThreadPoolExecutor = new LtThreadPoolExecutor(identifier, corePool, maxThreads, keepAliveTimeSeconds, SECONDS, queue, threadFactory, handler);
    return newThreadPoolExecutor;
  }

  /**
   * @param identifier Name of an already created tread-pool
   * @return An optional of ThreadPoolExecutor (Null or Object)
   */
  public static Optional<ThreadPoolExecutor> getFixedThreadPoolExecutor(@NotNull String identifier) {<FILL_FUNCTION_BODY>

    ThreadPoolExecutor value = executorServices.get(identifier);
    if (value == null) {
      log.debug(LoggingTools.SYSTEM, "Request: " + identifier + " not found, returning default pool");
      return Optional.of(defaultPool);
    } else {
      return Optional.of(value);
    }
  
<no_super_class>