From fb78547723555ba09e883ee66546826e8e1c6ae0 Mon Sep 17 00:00:00 2001 From: Chris Laprun Date: Wed, 18 Oct 2023 14:39:50 +0200 Subject: [PATCH] fix: unsupported java version --- .../generator/apt/CustomResourceAnnotationProcessor.java | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/crd-generator/apt/src/main/java/io/fabric8/crd/generator/apt/CustomResourceAnnotationProcessor.java b/crd-generator/apt/src/main/java/io/fabric8/crd/generator/apt/CustomResourceAnnotationProcessor.java index 05db77bac34..70758e5e3e2 100644 --- a/crd-generator/apt/src/main/java/io/fabric8/crd/generator/apt/CustomResourceAnnotationProcessor.java +++ b/crd-generator/apt/src/main/java/io/fabric8/crd/generator/apt/CustomResourceAnnotationProcessor.java @@ -41,6 +41,7 @@ import java.util.Set; import javax.annotation.processing.*; +import javax.lang.model.SourceVersion; import javax.lang.model.element.Element; import javax.lang.model.element.Name; import javax.lang.model.element.TypeElement; @@ -54,6 +55,12 @@ public class CustomResourceAnnotationProcessor extends AbstractProcessor { public static final String PROCESSOR_OPTION_PARALLEL = "io.fabric8.crd.generator.parallel"; private final CRDGenerator generator = new CRDGenerator(); + @Override + public SourceVersion getSupportedSourceVersion() { + return SourceVersion.latestSupported(); + } + + @SuppressWarnings("unchecked") public boolean process(Set annotations, RoundEnvironment roundEnv) { if (roundEnv.processingOver()) { final Messager messager = processingEnv.getMessager();