public @NotNull GradleModelConsumer createModelConsumer(@NotNull ExecutorService converterExecutor) {
    return new GradleModelConsumer() {
      @Override
      public void consumeBuildModel(@NotNull BuildModel buildModel, @NotNull Object object, @NotNull Class<?> clazz) {
        consumeModel(object, GradleModelId.createBuildModelId(buildModel, clazz));
      }

      @Override
      public void consumeProjectModel(@NotNull BasicGradleProject projectModel, @NotNull Object object, @NotNull Class<?> clazz) {
        consumeModel(object, GradleModelId.createProjectModelId(projectModel, clazz));
      }

      private void consumeModel(@NotNull Object model, @NotNull GradleModelId modelId) {
        GradleExecutorServiceUtil.submitTask(converterExecutor, myConvertedModelQueue, () -> {
          Object convertedModel = mySerializer.convert(model);
          return new ConvertedModel(modelId, convertedModel);
        });
      }
    };
  }
public @NotNull GradleModelConsumer createModelConsumer(@NotNull ExecutorService converterExecutor)