我们使用 Java 11 开发了一个 SpringBoot 项目,optaplanner-core
并在 Drools 文件中定义规则。使用 JDK 在 intelliJ 中运行应用程序没有问题。
然后,我们将应用部署到安装了 JRE 的 Azure 应用服务上。我们收到以下错误:
Caused by: org.kie.memorycompiler.KieMemoryCompilerException:
Cannot find the System's Java compiler. Please use JDK instead of JRE or add drools-ecj dependency to use in memory Eclipse compiler
我们尝试添加以下依赖项,但仍然出现相同的错误:
<dependency>
<groupId>org.optaplanner</groupId>
<artifactId>optaplanner-core</artifactId>
<version>8.4.1.Final</version>
</dependency>
<dependency>
<groupId>org.drools</groupId>
<artifactId>drools-ecj</artifactId>
<version>7.51.0.Final</version>
</dependency>
<dependency>
<groupId>org.eclipse.jdt</groupId>
<artifactId>ecj</artifactId>
<version>3.26.0</version>
</dependency>
有人知道如何解决这个问题吗?
谢谢