KieBaseConfiguration kbconf = KnowledgeBaseFactory.newKnowledgeBaseConfiguration();
((RuleBaseConfiguration) kbconf).setConflictResolver( SalienceConflictResolver.getInstance() );
KnowledgeBase knowledgeBase = KnowledgeBaseFactory.newKnowledgeBase( kbconf );
knowledgeBase.addKnowledgePackages( kb.getKnowledgePackages() );
StatefulKnowledgeSession knowledgeSession = knowledgeBase.newStatefulKnowledgeSession();
List list = new ArrayList();
knowledgeSession.setGlobal( "list", list );
knowledgeSession.fireAllRules();