Bug 845843 - Bug with default properties in KnowledgeStoreServiceImpl
Summary: Bug with default properties in KnowledgeStoreServiceImpl
Keywords:
Status: VERIFIED
Alias: None
Product: JBoss Enterprise BRMS Platform 5
Classification: JBoss
Component: BRE (Expert, Fusion)
Version: BRMS 5.3.0.GA
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
: ---
Assignee: Mario Fusco
QA Contact: Martin Vecera
URL:
Whiteboard:
Depends On:
Blocks: 872743
TreeView+ depends on / blocked
 
Reported: 2012-08-05 16:45 UTC by Toshiya Kobayashi
Modified: 2020-04-27 01:14 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
The default values for some properties of the KnowledgeSessionConfiguration overwrote the ones explicitly set by the user. As a result, the StatefulKnowledgeSession was created with the default configuration instead of the properties provided by the user. To resolve this issue, the default values of the KnowledgeSessionConfiguration properties can no longer override the user provided values. The StatefulKnowledgeSession is now created using the actual configuration defined by the user.
Clone Of:
: 872743 (view as bug list)
Environment:
Last Closed:
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker JBRULES-3155 0 Minor Resolved Bug with default properties in KnowledgeStoreServiceImpl 2013-05-01 10:43:58 UTC

Description Toshiya Kobayashi 2012-08-05 16:45:14 UTC
Description of problem:

Platform BZ for JBRULES-3155 : Bug with default properties in KnowledgeStoreServiceImpl

You cannot overwrite default properties set by KnowledgeStoreServiceImpl.

Steps to Reproduce:

The following code doesn't affect "drools.processInstanceManagerFactory". 

 Environment env = KnowledgeBaseFactory.newEnvironment();
 env.set(EnvironmentName.ENTITY_MANAGER_FACTORY, emf);

 Properties properties = new Properties();
 properties.put("drools.processInstanceManagerFactory", "com.example.CustomJPAProcessInstanceManagerFactory");
 KnowledgeSessionConfiguration config = KnowledgeBaseFactory.newKnowledgeSessionConfiguration(properties);
         
 StatefulKnowledgeSession ksession = JPAKnowledgeService.newStatefulKnowledgeSession(KnowledgeService.getKnowledgeBase(), config, env);
  
Actual results:

ksession.getProcessInstanceManagerFactory() returns "org.jbpm.persistence.processinstance.JPAProcessInstanceManagerFactory"

And the class is used in the ksession.

Expected results:

ksession.getProcessInstanceManagerFactory() returns "com.example.CustomJPAProcessInstanceManagerFactory"

And the class is used in the ksession.

Comment 3 JBoss JIRA Server 2012-08-20 13:11:35 UTC
Mario Fusco <mario.fusco> updated the status of jira JBRULES-3155 to Resolved

Comment 4 Iva Zakova 2012-09-17 08:48:36 UTC
Verified in 5.3.1.ER1.

Comment 5 lcarlon 2012-11-08 01:13:05 UTC
Hi Mario,

could you review this bug to see if it should be included in the release notes, and if so provide the release notes content?

Thanks
Lee

Comment 6 Mario Fusco 2012-11-08 08:25:59 UTC
Hi Lee,

I just added the content for the release notes.

Thanks for having pointed this out.
Mario

Comment 7 lcarlon 2012-11-08 09:29:46 UTC
Thanks Mario!


Note You need to log in before you can comment on or make changes to this bug.