- android - 多次调用 OnPrimaryClipChangedListener
- android - 无法更新 RecyclerView 中的 TextView 字段
- android.database.CursorIndexOutOfBoundsException : Index 0 requested, 光标大小为 0
- android - 使用 AppCompat 时,我们是否需要明确指定其 UI 组件(Spinner、EditText)颜色
我使用的是 drool 版本 7.x。我可以使用“LATEST”让 KieScanner 在我的本地 Maven 存储库上工作。但是每次我更新工作台上的规则时,我都必须手动运行 mvn install 才能更新我的本地存储库,以便KieScanner 可以拾取更改。是这样吗?或者是否可以在每次扫描仪运行时强制下载?
我需要从我的自定义存储库中获取最新的 jar。
我的配置
KieServices ks = KieServices.Factory.get();
ReleaseId releaseId = ks.newReleaseId( "com.test", "poc", "LATEST" );
KieContainer kContainer = ks.newKieContainer(releaseId);
KieScanner kieScanner = ks.newKieScanner(kContainer);
kieScanner.start( 10000L );
Scanner scanner = new Scanner(System.in);
while (true) {
kieScanner.scanNow();
String line = scanner.nextLine();
runRule(kContainer);
}
}
我已在 Maven 设置文件中配置了自定义存储库。
<profile>
<id>development</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<repositories>
<repository>
<id>customRepo</id>
<url>https://customRepo/v2</url>
<releases>
<enabled>false</enabled>
<updatePolicy>always</updatePolicy>
</releases>
<snapshots>
<enabled>true</enabled>
<updatePolicy>always</updatePolicy>
</snapshots>
</repository>
</repositories>
</profile>
</profiles>
<activeProfiles>
<activeProfile>development</activeProfile>
</activeProfiles>
Exception : Unable to resolve artifact: com.test :LATEST
我已经尝试了下面的所有链接。但运气不好
KieScanner cannot fetch LATEST version automatically!
KieScanner with remote maven repo
Loading Drools/KIE Workbench artifacts directly from the repository
How do I tell Maven to use the latest version of a dependency?
how do I tell maven 3.6.3 to get latest version of artifact from custom repository
https://access.redhat.com/solutions/1592893
KieScanner not updating KieSessions at runtime
KieScanner not working in Drools 6.1
KieScanner not updating jar from remote nexus repository (Drools 6.5.0.Final)
有人请建议解决这个问题吗?
最佳答案
LATEST
和 RELEASE
是 Maven 2 关键字。它们的行为难以预测,并在 Maven 3 中被完全删除。
引用号。 https://www.baeldung.com/maven-dependency-latest-version#1-deprecated-syntax
关于java - KieScanner 无法从自定义 Maven 存储库获取最新的 Jars - Maven - 3.6.3,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/60266133/
我是一名优秀的程序员,十分优秀!