public ExecutorServiceBuilder executorService(String nameFormat) {
        return new ExecutorServiceBuilder(this, nameFormat);
    }
@Test
    void executorServiceThreadFactory() {
        final String expectedName = "DropWizard ThreadFactory Test";
        final String expectedNamePattern = expectedName + "-%d";

        final ThreadFactory tfactory = buildThreadFactory(expectedNamePattern);

        final ExecutorService executorService = environment.executorService("Dropwizard Service", tfactory).build();

        assertThat(executorService.submit(() -> Thread.currentThread().getName()))
            .succeedsWithin(1, TimeUnit.SECONDS, as(STRING))
            .startsWith(expectedName);
    }