drools.dump.dir属性不能通过api方法转储drool文件的Java版本?

时间:2019-12-13 13:44:36

标签: java drools rule-engine kie

drools.dump.dir属性不能通过API方法转储Drool文件的Java版本?我正在使用Drool编译器版本6.1.0.Final

我尝试了以下三种方法: 1)

        KieBaseConfiguration kieBaseConfiguration= ks.newKieBaseConfiguration();

        kieBaseConfiguration.setProperty("drools.dump.dir","C:\ects\\dump");
        kieBaseConfiguration.setProperty("drools.dialect.default","JAVA");
        kContainer.newKieBase(kieBaseConfiguration);

2)     


KnowledgeBuilderConfiguration knowledgeBuilderConfiguration = 
       KnowledgeBuilderFactory.newKnowledgeBuilderConfiguration();
       knowledgeBuilderConfiguration.setProperty("drools.dump.dir","C:\\dump");



      knowledgeBuilderConfiguration.setProperty("drools.dialect.default","JAVA");

        KnowledgeBuilder knowledgeBuilder = KnowledgeBuilderFactory.newKnowledgeBuilder(knowledgeBuilderConfiguration);

        KnowledgeBase knowledgeBase= knowledgeBuilder.newKnowledgeBase();

        KieSession kSession = knowledgeBase.newKieSession();

3)      


        KieSessionConfiguration kieSessionConfiguration                                               =ks.newKieSessionConfiguration();
        kieSessionConfiguration.setProperty("drools.dump.dir","\\dump");
        kieSessionConfiguration.setProperty("drools.dialect.default","JAVA");*/

        KieSession kSession = kContainer.newKieSession(kieSessionConfiguration );

0 个答案:

没有答案