Re: [rules-users] Planner:5.5.0beta1 chained with 2 planningvariables difficulties
by ge0ffrey
Paul T wrote
> Exception in thread "main" java.lang.IllegalArgumentException: The
> valueSelectorConfig (ValueSelectorConfig(null)) has no configured
> planningVariableName (null) for planningEntityClass (class
> com.domain.Orders) and because there are multiple in the
> planningVariableNameSet ([previousTaskOrEquip, standTime]), it can not be
> deducted automatically.
You'll need to specify the planningVariableName, see the
curriculumCourseSolverConfig.xml for an example how to do that.
This is because there are 2 planning variables, it's independent of whether
or not some of them are chained.
--
View this message in context: http://drools.46999.n3.nabble.com/Planner-5-5-0beta1-chained-with-2-plann...
Sent from the Drools: User forum mailing list archive at Nabble.com.
13 years, 3 months
using "from accumulate" with wrong return type
by raffi
Hello,
I have a problem with using the /from accumulate/ statement. It is because
I'd like to optmize my code a liitle bit. There are two rules that I like to
merge.
/query "max recomm value for slot 1"
accumulate (Recommendation(slot == 1, $recomm_value : recommValue),
max : max($recomm_value))
end/
and
/query "recomms for slot 1"
recomm : Recommendation(slot == 1)
end/
So with the first rule I get the maximum of the variable recommValue. The
second rule is for searching exactly this Recommendation-fact with this
value. Now I tried to merge them in the following way:
/
query "recomm for slot 1"
$recomm : Recommendation() from
accumulate(Recommendation(
slot == 1, $recomm_value : recommValue),
max($recomm_value)
)
end/
But the returned value always is a double one. Is it because of the usage of
the maximum function? Is it possible to solve this problem with only one
query (getting that Recommendation-fact with the highest recommValue)?
Regards...
--
View this message in context: http://drools.46999.n3.nabble.com/using-from-accumulate-with-wrong-return...
Sent from the Drools: User forum mailing list archive at Nabble.com.
13 years, 3 months
Drools consuming a lot of memory for short lived objects thus impacting average response time.
by manohars
Hello,
We are using Drools 5.3.0 Final distribution using decision tables(.pkg rule
files) in our solution. However, Drools is taking a lot of memory (@ 350 mb
on Linux-64bit).
On profiling,we realize that huge number of short lived objects are getting
created.(org.drools.impl.StatefulKnowledgeSessionImpl, IndexVariableResolver
class and org.mvel2.* classes). It leads increase in Garbage Collection
cycles there by leaving an impact on average response time.
Is there any clever way to use Drools to achieve @ 1 millisecond to 2
millisecond response time given the rules are simple? We tried to use drl
based rules but no improvement.
Any idea about how to deal with this such a big memory contributors ?
Regards,
Manohar
--
View this message in context: http://drools.46999.n3.nabble.com/Drools-consuming-a-lot-of-memory-for-sh...
Sent from the Drools: User forum mailing list archive at Nabble.com.
13 years, 3 months
java.lang.LinkageError, but only sometimes
by kennywest
Dear list,
We have an application (A) deployed on JBoss 7.1.1 accepting commands (CQRS,
but only C and Q :) ). A console application (B) is sending a large volume
of commands to create entities in A. Entities in A are validated by Drools
(plain drl files, configured in spring using drools-spring). Most of the
time this works just fine. But sometimes, we get the following exception:
java.lang.LinkageError: loader (instance of
org/drools/rule/JavaDialectRuntimeData$PackageClassLoader): attempted
duplicate class definition for name:
"a/b/c/Rule_person_unique___name_656ee3db19d34e689d95e2d6b2be67b6"
at java.lang.ClassLoader.defineClass1(Native Method) [rt.jar:1.6.0_30]
at java.lang.ClassLoader.defineClassCond(ClassLoader.java:631)
[rt.jar:1.6.0_30]
at java.lang.ClassLoader.defineClass(ClassLoader.java:615)
[rt.jar:1.6.0_30]
at
org.drools.rule.JavaDialectRuntimeData$PackageClassLoader.fastFindClass(JavaDialectRuntimeData.java:615)
[drools-core-5.4.0.Final.jar:5.4.0.Final]
at
org.drools.util.CompositeClassLoader$CachingLoader.load(CompositeClassLoader.java:254)
[knowledge-api-5.4.0.Final.jar:5.4.0.Final]
at
org.drools.util.CompositeClassLoader$CachingLoader.load(CompositeClassLoader.java:237)
[knowledge-api-5.4.0.Final.jar:5.4.0.Final]
at
org.drools.util.CompositeClassLoader.loadClass(CompositeClassLoader.java:88)
[knowledge-api-5.4.0.Final.jar:5.4.0.Final]
at java.lang.ClassLoader.loadClass(ClassLoader.java:295) [rt.jar:1.6.0_30]
at java.lang.ClassLoader.loadClass(ClassLoader.java:247) [rt.jar:1.6.0_30]
at
a.b.c.Rule_gg___unique___name_656ee3db19d34e689d95e2d6b2be67b6Eval0InvokerGenerated.evaluate(Unknown
Source)
at
a.b.c.Rule_gg___unique___name_656ee3db19d34e689d95e2d6b2be67b6Eval0Invoker.evaluate(Unknown
Source)
at org.drools.rule.EvalCondition.isAllowed(EvalCondition.java:114)
[drools-core-5.4.0.Final.jar:5.4.0.Final]
Any idea where this is coming from or what's causing this.
We are using:
- JBoss 7.1.1
- drools 5.4.0.Final
- jdk 1.6u30
- Windows 7 64 bit
regards,
Kenneth
--
View this message in context: http://drools.46999.n3.nabble.com/java-lang-LinkageError-but-only-sometim...
Sent from the Drools: User forum mailing list archive at Nabble.com.
13 years, 3 months
Re: [rules-users] ArrayIndexOutOfBoundsException in MVELCompilationUnit
by Stephen Masters
Actually please ignore. I temporarily upgraded to 5.4 which identified a bug in a DSL. With that fixed, I was able to downgraded again.
Thanks anyway!
Steve
Stephen Masters <stephen.masters(a)me.com> wrote:
>Hi folks,
>
>I seem to have come across an issue with hitting an ArrayIndexOutOfBoundsException:3 during an insert. It seems to depend on how many other facts have already been inserted.
>
>This is on 5.3 Final.
>
>Can anybody give me any pointers on how to diagnose such an issue?
>
>Many thanks
>
>Steve
>_______________________________________________
>rules-users mailing list
>rules-users(a)lists.jboss.org
>https://lists.jboss.org/mailman/listinfo/rules-users
13 years, 3 months
Problem with guvnor db mysql jndi
by Leonardo Soubeste
Hello everyone,
I'm trying to use Guvnor repository with mysql. I'm using JBoss7.
I configured the datasource as jndi resource like this:
<datasource jta="true" jndi-name="java:jboss/datasources/guvnor"
pool-name="guvnor" enabled="true" use-java-context="true" use-ccm="true">
<connection-url>jdbc:mysql://localhost:3306/guvnor</connection-url>
<driver>com.mysql</driver>
<transaction-isolation>TRANSACTION_READ_COMMITTED</transaction-isolation>
<pool>
<min-pool-size>10</min-pool-size>
<max-pool-size>100</max-pool-size>
<prefill>true</prefill>
</pool>
<security>
<user-name>root</user-name>
<password>password</password>
</security>
<statement>
<prepared-statement-cache-size>32</prepared-statement-cache-size>
<share-prepared-statements>true</share-prepared-statements>
</statement>
</datasource>
Now, when I run guvnor I get this exception:
Caused by: java.sql.SQLException: You cannot set autocommit during a managed
transaction!
at
org.jboss.jca.adapters.jdbc.BaseWrapperManagedConnection.setJdbcAutoCommit(BaseWrapperManagedConnection.java:888)
at
org.jboss.jca.adapters.jdbc.WrappedConnection.setAutoCommit(WrappedConnection.java:715)
at
org.apache.jackrabbit.core.util.db.ConnectionHelper.getConnection(ConnectionHelper.java:395)
[jackrabbit-core-2.2.8.jar:2.2.8]
at
org.apache.jackrabbit.core.util.db.ConnectionHelper.reallyExec(ConnectionHelper.java:351)
[jackrabbit-core-2.2.8.jar:2.2.8]
at
org.apache.jackrabbit.core.util.db.ConnectionHelper$3.call(ConnectionHelper.java:339)
[jackrabbit-core-2.2.8.jar:2.2.8]
I think is related to the <transaction-isolation> tag. Any help?
I couldn't find any example of how to configure this. Without using JNDI it
works.
Thanks in advance
--
View this message in context: http://drools.46999.n3.nabble.com/Problem-with-guvnor-db-mysql-jndi-tp402...
Sent from the Drools: User forum mailing list archive at Nabble.com.
13 years, 3 months
Re: [rules-users] Unable to download the deployment files pointed in the Guvnor documentation pages.
by EvelthonPatrickios@tsys.com
Drools Guvnor Documentation for PDF points to:
http://docs.jboss.org/drools/release/5.5.0.Final/drools-guvnor-docs/pdf/
drools-guvnor-docs.pdf
where it SHOULD point to:
http://docs.jboss.org/drools/release/5.5.0.Final/drools-guvnor-docs/pdf/
guvnor-docs.pdf
(or change the target file name)
Same is true for some of the previous versions. (5.5.0.CR1, 5.4.0, etc)
Evelthon
-----------------------------------------
The information contained in this communication (including any
attachments hereto) is confidential and is intended solely for the
personal and confidential use of the individual or entity to whom
it is addressed. If the reader of this message is not the intended
recipient or an agent responsible for delivering it to the intended
recipient, you are hereby notified that you have received this
communication in error and that any review, dissemination, copying,
or unauthorized use of this information, or the taking of any
action in reliance on the contents of this information is strictly
prohibited. If you have received this communication in error,
please notify us immediately by e-mail, and delete the original
message. Thank you
13 years, 3 months