我在KieWorkBench中添加了GuidedDecisionTable,已经使用KieContainer加载了KBase,能够查看该KBase下的包和规则,但是在触发规则时,它始终返回null
我已经在调试模式下检查了流程,int getNextFocus()调用DefaultAgenda始终返回null,它正在检查scheduleGroup.isEmpty(),即使AgendaGroup中都有规则,MyAgendaGroup和MAIN Agendagroup仍返回空。 / p>
KieResources资源= kieServices.getResources();
String url = upgradeServiceUrl.getValue();
UrlResource urlResource =(UrlResource)resources.newUrlResource(url); urlResource.setUsername(“ ****”); urlResource.setPassword(“ ****”);
urlResource.setBasicAuthentication(“ enabled”);
InputStream流= urlResource.getInputStream();
KieRepository存储库= kieServices.getRepository();
KieModule k = repo.addKieModule(resources.newInputStreamResource(stream));
kieContainer = kieServices.newKieContainer(k.getReleaseId());
KieSession会话= kieContainer.newKieSession();
session.getAgenda()。getAgendaGroup(“ MyAgendaGroup”)。setFocus();
FactHandle句柄= session.insert(DTO);
session.fireAllRules();
session.delete(handle);
session.dispose();