Validation for spreadsheet fails because it cannot find functions in the same package of Business Central
Issue
- A spreadsheet based
Decision Tablehas been uploaded in a package ofBusiness Centralwhere the rules defined inside it uses an external function defined in aDRLon the same package. In such a scenario users can successfullyBuild & Deployon the project containing thoseDecision TableandDRLinBusiness Centralbut while clicking onValidatebutton after opening theDecision Table, it fails because it cannot find functions. The following exception gets logged.
16:10:14,490 ERROR [org.drools.compiler.kie.builder.impl.AbstractKieModule] (http-/127.0.0.1:8080-3) Unable to build KieBaseModel:defaultKieBase
Unable to Analyse Expression myfunc() == 0:
[Error: unable to resolve method using strict-mode: java.lang.String.myfunc()]
[Near : {... myfunc() == 0 ....}]
^
[Line: 6, Column: 2] : [Rule name='HelloWorld_11']
Unable to Analyse Expression myfunc() == 1:
[Error: unable to resolve method using strict-mode: java.lang.String.myfunc()]
[Near : {... myfunc() == 1 ....}]
^
[Line: 14, Column: 2] : [Rule name='HelloWorld_12']
How to fix this issue?
Environment
- Red Hat JBoss BRMS (BRMS)
- 6.0.x
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
