Stateless session dis-associating listeners after first execute call. Bug or a feature?
by Michal Bali
Hello,
I am using a stateless session. First I add an agenda event listener. When
I first call session.execute(Itelable) all works as expected. However when
I call it the second time (without adding the listener again) the listener
does not seem to be called at all.
However note that when I call session.getAgendaEventListeners() the event
listener is always there.
IMHO I am guessing that the 'dispose' method that is called behind the
scenes possibly dis-associates the event listener.
I've tested this with 5.5.Final. BTW This worked fine with Drools 5.0. I
haven't checked later versions.
I wonder is this a bug or a feature?
Isolated test case is attached.
Thank you.
Best regards,
Michal
12 years, 11 months
How to determine Drools runtime version?
by Ansgar Konermann
Hi,
I'd like to determine at runtime which version of Drools is in use/on
the classpath. I cannot use reflection on the Drools classes itself, as
this will not work in the intended runtime environment (Google App Engine).
The following code works in a normal Java VM, but not in GAE:
Package droolsCorePackage = KnowledgePackageImp.class.getPackage();
String implementationTitle = droolsCorePackage.getImplementationTitle();
String implementationVersion =
droolsCorePackage.getImplementationVersion();
In GAE, the getImplementation{Title|Version} methods both return null.
Is there another, maybe more "official" way of determining the Drools
version? I'd like to support Drools 5.x.y starting at x >= 3.
Best regards
Ansgar
12 years, 11 months
error when running guvnor
by kurrent93
Hi
I've just deployed Guvnor 5.5 final into Tomcat 7.
When I go to view guvnor I get this error:
400 Sorry, a technical error occurred. Please contact a system
administrator.
500 The call failed on the server; see server log for details
In the guvnor event log I get:
Service method 'public abstract boolean
org.drools.guvnor.client.rpc.RepositoryService.isDoNotInstallSample()' threw
an unexpected exception: org.jboss.weld.exceptions.WeldException:
WELD-000049 Unable to invoke [method] @PostConstruct public
org.drools.guvnor.server.repository.RepositoryStartupService.create() on
org.drools.guvnor.server.repository.ProductionRepositoryStartupService@2d00c385
WELD-000049 Unable to invoke [method] @PostConstruct public
org.drools.guvnor.server.repository.RepositoryStartupService.create() on
org.drools.guvnor.server.repository.ProductionRepositoryStartupService@2d00c385
I dont see anything relavant in the tomcat logs.
Any idea how to fix this?
Thanks
--
View this message in context: http://drools.46999.n3.nabble.com/error-when-running-guvnor-tp4021224.html
Sent from the Drools: User forum mailing list archive at Nabble.com.
12 years, 11 months
Use of otherwise
by Manasi
Hi,
In my drools application I have following web-guided decision table:
Rule Col1 Col2 Col3
Fields
Rule1 false false abc
field1,field2
Rule2 false true (any value
field2
including "abc")
In Rule 2 above we have condition as:
*If Col1 is false and
If Col2 is true and
If Col3 is having any value including "abc" Then
*
return *field2* in action column.
We have created web-guided decision table in Guvnor and we have included
above 2 rules.
We have tried using <otherwise>, but as per <otherwise> functionality if we
use <otherwise> in Rule2 Col3 ,then it will take all values other than "abc"
and we need to consider "abc" value also.
Please suggest how to solve this scenario?
Thanks,
Manasi.
--
View this message in context: http://drools.46999.n3.nabble.com/Use-of-otherwise-tp4021306.html
Sent from the Drools: User forum mailing list archive at Nabble.com.
12 years, 11 months
Complicated Issue
by abhinay_agarwal
hey,
M using guvnor 5.3.0 Final version and two instances of guvnor.
In my first guvnor application, i ve two packages containg all my rules
which i am accessing using drools core and knowledge api v5.2.0 Final .I use
type "DRL" to extract rules from my change set.
In my second guvnor application, i just have a package which contains my
JBPM process. Here, i am using drools 5.3.1 Final jars to connect and make
my kbase. i use type = "PKG" in my chnage set, which is contradictory to
JIRA <https://issues.jboss.org/browse/JBRULES-3388> is opened that a PKG
cannot be read, but was working fine for my application.
Now i dont want to deploy two different wars of guvnor and was expecting to
do it by deploying just 1 guvnor.
So instead of taking the headache of using different jars, i used a neutral
GUVNOR and drools 5.4.0 final version. I deployed the guvnor, imported the
old repository, built the packages and tried firing the rules using type =
"DRL" in my change set. Everything Worked fine.
As soon as i changed my type = "PKG" in my change set to access the rules, i
got an error :
java.lang.UnsupportedClassVersionError:
Institutional/CalculateDateDifference : Unsupported major.minor version 51.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
at
org.drools.rule.JavaDialectRuntimeData$PackageClassLoader.fastFindClass(JavaDialectRuntimeData.java:615)
at
org.drools.util.CompositeClassLoader$CachingLoader.load(CompositeClassLoader.java:254)
at
org.drools.util.CompositeClassLoader$CachingLoader.load(CompositeClassLoader.java:237)
at
org.drools.util.CompositeClassLoader.loadClass(CompositeClassLoader.java:88)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at
org.drools.rule.MVELDialectRuntimeData.getParserConfiguration(MVELDialectRuntimeData.java:270)
at
org.drools.base.mvel.MVELCompilationUnit.getCompiledExpression(MVELCompilationUnit.java:203)
at org.drools.base.mvel.MVELConsequence.compile(MVELConsequence.java:75)
at
org.drools.rule.MVELDialectRuntimeData.onBeforeExecute(MVELDialectRuntimeData.java:173)
at
org.drools.rule.DialectRuntimeRegistry.onBeforeExecute(DialectRuntimeRegistry.java:144)
at
org.drools.common.AbstractRuleBase.addPackages(AbstractRuleBase.java:599)
at org.drools.reteoo.ReteooRuleBase.addPackages(ReteooRuleBase.java:472)
at
org.drools.impl.KnowledgeBaseImpl.addKnowledgePackages(KnowledgeBaseImpl.java:150)
at
org.drools.agent.impl.KnowledgeAgentImpl.addResourcesToKnowledgeBase(KnowledgeAgentImpl.java:1085)
at
org.drools.agent.impl.KnowledgeAgentImpl.rebuildResources(KnowledgeAgentImpl.java:824)
at
org.drools.agent.impl.KnowledgeAgentImpl.buildKnowledgeBase(KnowledgeAgentImpl.java:673)
at
org.drools.agent.impl.KnowledgeAgentImpl.applyChangeSet(KnowledgeAgentImpl.java:203)
at
org.drools.agent.impl.KnowledgeAgentImpl.applyChangeSet(KnowledgeAgentImpl.java:182)
at
com.infy.fcs.drools.adapter.DroolsGuvnorTest.readKnowledgeBase(DroolsGuvnorTest.java:196)
at
com.infy.fcs.drools.adapter.DroolsGuvnorTest.main(DroolsGuvnorTest.java:107)
When i tried to access the process package(Which is a diff package and
contains only a process), i got the following error
java.lang.UnsupportedClassVersionError:
Fatca_Process/Process_Fatca_Process_Fatca_integration_queue_f06d3a378a5f49d5b7589aae2c0b686eReturnValueEvaluator7Invoker
: Unsupported major.minor version 51.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
at
org.drools.rule.JavaDialectRuntimeData$PackageClassLoader.fastFindClass(JavaDialectRuntimeData.java:615)
at
org.drools.util.CompositeClassLoader$CachingLoader.load(CompositeClassLoader.java:254)
at
org.drools.util.CompositeClassLoader$CachingLoader.load(CompositeClassLoader.java:237)
at
org.drools.util.CompositeClassLoader.loadClass(CompositeClassLoader.java:88)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at
org.drools.rule.JavaDialectRuntimeData.wire(JavaDialectRuntimeData.java:435)
at
org.drools.rule.JavaDialectRuntimeData.wire(JavaDialectRuntimeData.java:430)
at
org.drools.rule.JavaDialectRuntimeData.onBeforeExecute(JavaDialectRuntimeData.java:256)
at
org.drools.rule.DialectRuntimeRegistry.onBeforeExecute(DialectRuntimeRegistry.java:138)
at
org.drools.common.AbstractRuleBase.addPackages(AbstractRuleBase.java:599)
at org.drools.reteoo.ReteooRuleBase.addPackages(ReteooRuleBase.java:472)
at
org.drools.impl.KnowledgeBaseImpl.addKnowledgePackages(KnowledgeBaseImpl.java:150)
at
org.drools.agent.impl.KnowledgeAgentImpl.addResourcesToKnowledgeBase(KnowledgeAgentImpl.java:1085)
at
org.drools.agent.impl.KnowledgeAgentImpl.rebuildResources(KnowledgeAgentImpl.java:824)
at
org.drools.agent.impl.KnowledgeAgentImpl.buildKnowledgeBase(KnowledgeAgentImpl.java:673)
at
org.drools.agent.impl.KnowledgeAgentImpl.applyChangeSet(KnowledgeAgentImpl.java:203)
at
org.drools.agent.impl.KnowledgeAgentImpl.applyChangeSet(KnowledgeAgentImpl.java:182)
at
com.infy.fcs.drools.adapter.DroolsGuvnorTest.readKnowledgeBase(DroolsGuvnorTest.java:196)
at
com.infy.fcs.drools.adapter.DroolsGuvnorTest.main(DroolsGuvnorTest.java:107)
here is the attached changeset that i am using
changeset_process.xml
<http://drools.46999.n3.nabble.com/file/n4020175/changeset_process.xml>
ChangeSet_rules.xml
<http://drools.46999.n3.nabble.com/file/n4020175/ChangeSet_rules.xml>
please lemme know, if wat i am trying to achieve is evne possible or not?
If yes, then where am i going wrong ?
--
View this message in context: http://drools.46999.n3.nabble.com/Complicated-Issue-tp4020175.html
Sent from the Drools: User forum mailing list archive at Nabble.com.
12 years, 12 months
UserGroupCallbackManager getProperty doesn't return the given property
by eselis
Hi,
When I have a task with more than one group assigned and I want to get the
potencial owners by one groupId, instead to get the ones filtered by the
given groupId, I get all the tasks. I found a property to available that
filtering which is "disable.all.groups", but after setting it and continue
not working, I took a look inside the code, and I found in
UserGroupCallbackManager
/
public String getProperty(String name) {
if (this.callbackproperties != null) {
this.callbackproperties.getProperty(name);
}
return null;
}
/
It's always returning null, I'm using drools version 5.4.0.Final and jbpm
version 5.3.0.Final.
I can't find a better solution that you can change it in the code :S
Thanks in advance,
Erica
--
View this message in context: http://drools.46999.n3.nabble.com/UserGroupCallbackManager-getProperty-do...
Sent from the Drools: User forum mailing list archive at Nabble.com.
12 years, 12 months