Optional<PriorityAndResource> getPriorityAndResource(
            final TaskExecutorProcessSpec taskExecutorProcessSpec) {
        tryAdaptAndAddTaskExecutorResourceSpecIfNotExist(taskExecutorProcessSpec);
        return Optional.ofNullable(
                taskExecutorProcessSpecToPriorityAndResource.get(taskExecutorProcessSpec));
    }
@Test
    void testMaxContainerResource() {
        final TaskExecutorProcessSpecContainerResourcePriorityAdapter adapter = getAdapter();
        assertThat(adapter.getPriorityAndResource(TASK_EXECUTOR_PROCESS_SPEC_EXCEED_MAX))
                .isNotPresent();
    }