{"record":{"id":"964faa513137caa2","repo":"quarkusio/quarkus","slug":"no-system-java-compiler-provided","errorCode":null,"errorMessage":"No system java compiler provided","messagePattern":"No system java compiler provided","errorType":"exception","errorClass":"RuntimeException","httpStatus":null,"severity":"error","filePath":"core/deployment/src/main/java/io/quarkus/deployment/dev/JavaCompilationProvider.java","lineNumber":65,"sourceCode":"        return Set.of(\".java\");\n    }\n\n    @Override\n    public void compile(Set<File> filesToCompile, CompilationProvider.Context context) {\n        if (this.compiler == null) {\n            this.compiler = ToolProvider.getSystemJavaCompiler();\n            this.compilerFlags = new CompilerFlags(COMPILER_OPTIONS,\n                    context.getCompilerOptions(PROVIDER_KEY),\n                    context.getReleaseJavaVersion(),\n                    context.getSourceJavaVersion(),\n                    context.getTargetJvmVersion(),\n                    context.getAnnotationProcessors()).toList();\n        }\n\n        final JavaCompiler compiler = this.compiler;\n\n        if (compiler == null) {\n            throw new RuntimeException(\"No system java compiler provided\");\n        }\n\n        final QuarkusFileManager.Context sourcesContext = new QuarkusFileManager.Context(\n                context.getClasspath(), context.getReloadableClasspath(),\n                context.getOutputDirectory(), context.getGeneratedSourcesDirectory(),\n                context.getAnnotationProcessorPaths(),\n                context.getSourceEncoding(),\n                context.ignoreModuleInfo());\n\n        if (this.fileManager == null) {\n            final Supplier<StandardJavaFileManager> supplier = () -> {\n                final Charset charset = context.getSourceEncoding();\n                return compiler.getStandardFileManager(null, null, charset);\n            };\n\n            if (context.getReloadableClasspath().isEmpty()) {\n                this.fileManager = new StaticFileManager(supplier, sourcesContext);\n            } else {","sourceCodeStart":47,"sourceCodeEnd":83,"githubUrl":"https://github.com/quarkusio/quarkus/blob/e1c734241f34c7919086ceb4c9262b4a58f6de44/core/deployment/src/main/java/io/quarkus/deployment/dev/JavaCompilationProvider.java#L47-L83","documentation":"JavaCompilationProvider.compile() uses the javax.tools JavaCompiler obtained from the system ToolProvider. When the running JVM does not provide a system Java compiler (this.compiler == null), it throws a RuntimeException with 'No system java compiler provided'. This happens when Quarkus runs on a JRE rather than a JDK.","triggerScenarios":"Invoking live reload / runtime compilation while the JVM lacks javax.tools.JavaCompiler, i.e. JAVA_HOME points to a JRE or a JDK image compiled without the jdk.compiler module.","commonSituations":"Docker images based on JRE-only distributions; CI runners configured with a JRE; IDE run configurations using a JRE runtime.","solutions":["Set JAVA_HOME to a full JDK and restart dev mode.","Use a JDK-based container image (e.g. eclipse-temurin:17-jdk instead of ...-jre).","Verify with 'java -version' / 'javac -version' that javac is available in the same JVM."],"exampleFix":"// before\nFROM eclipse-temurin:17-jre\n\n// after\nFROM eclipse-temurin:17-jdk","handlingStrategy":"validation","validationCode":"if (javax.tools.ToolProvider.getSystemJavaCompiler() == null) {\n    throw new IllegalStateException(\"JAVA_HOME must point to a JDK, not a JRE\");\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Use -jdk based container images for dev mode.","Verify javac is on PATH in CI runners.","Pin JAVA_HOME to a JDK in your shell profile and IDE configs."],"tags":["quarkus","compiler","jdk","environment"],"backgroundTag":"no-system-java-compiler","analyzedSha":"e1c734241f34c7919086ceb4c9262b4a58f6de44","analyzedAt":"2026-09-05T17:01:29.979Z","contentChangedAt":"2026-09-05T17:01:29.979Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}