Re: [rules-users] using Drools in Tomcat 6.0 enviourment

2013-11-22 Thread Antoine Toulme
Erez, is it possible that the change of packaging is removing the file from
the classpath ?


On Thu, Nov 21, 2013 at 8:20 PM, Erez Zarini ze...@il.ibm.com wrote:

 Hi,

 I am new to Drools.

 I have successfully created a project from the Examples provided at the
 site
 using Java APP project.

 but when trying to move it as a Dynamic Web Project in Eclipse I get the
 following Exception:

 (the files kmodule and pom.xml resides in all subfolders of the project)

 21/11/2013 15:49:42
 org.drools.compiler.kie.builder.impl.ClasspathKieProject
 discoverKieModules
 INFO: Found kmodule:

 file:/C:/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/DecisionTableGvia/WEB-INF/classes/META-INF/kmodule.xml
 21/11/2013 15:49:43
 org.drools.compiler.kie.builder.impl.ClasspathKieProject
 getPomProperties
 WARNING: Unable to load pom.properties tried recursing down

 from/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/DecisionTableGvia/WEB-INF/classes
 null
 21/11/2013 15:49:43
 org.drools.compiler.kie.builder.impl.ClasspathKieProject
 discoverKieModules
 SEVERE: Unable to build index of kmodule.xml

 url=file:/C:/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/DecisionTableGvia/WEB-INF/classes/META-INF/kmodule.xml
 null
 []
 21/11/2013 15:49:43 org.apache.catalina.core.StandardWrapperValve invoke
 SEVERE: Servlet.service() for servlet getDecisionGvia threw exception
 java.lang.NullPointerException
 at

 org.drools.compiler.kie.builder.impl.KieContainerImpl.newStatelessKieSession(KieContainerImpl.java:360)
 at

 org.drools.compiler.kie.builder.impl.KieContainerImpl.newStatelessKieSession(KieContainerImpl.java:351)
 at
 gvia.PricingRuleDTExample.executeExample(PricingRuleDTExample.java:39)
 at gvia.PricingRuleDTExample.main(PricingRuleDTExample.java:32)
 at gvia.getDecisionGvia.doGet(getDecisionGvia.java:33)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
 at

 org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
 at

 org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
 at

 org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
 at

 org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
 at

 org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
 at

 org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
 at

 org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
 at
 org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
 at
 org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:849)
 at

 org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
 at
 org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:454)
 at java.lang.Thread.run(Unknown Source)



 when running as a Java project (not Java EE) it seems to work find and
 continues to find pom.xml instead of pom.properties.

 any ideas?



 --
 View this message in context:
 http://drools.46999.n3.nabble.com/using-Drools-in-Tomcat-6-0-enviourment-tp4026878.html
 Sent from the Drools: User forum mailing list archive at Nabble.com.
 ___
 rules-users mailing list
 rules-users@lists.jboss.org
 https://lists.jboss.org/mailman/listinfo/rules-users

___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users

Re: [rules-users] Optaplanner rule to assign employee only to shift when he/she has the skills

2013-11-22 Thread Wolfgang Laun
See some comments (W) to the original rule.

On 22/11/2013, ns nick.sn...@ocmwturnhout.be wrote:
 In order to make the administration simpler, I  created a table in MySQL
 that
 assigns an employee to a certain shiftType. In my code I stated that once
 an
 employee is assigned to a shiftType, he or she automatically has the skills
 needed for that shiftType, hence the skill == $shiftType part in the rule.



rule alternativeSkill
when
   $assignment : ShiftAssignment($employee : employee, $shiftType
: shiftType)

W: Here we know that $employee has skill $shiftType (according to once
an employee is assigned to a shiftType, he or she automatically has
the skills.)

   not SkillProficiency(employee == $employee, skill == $shiftType)

W: Taking proficiency in the usual meaning, isn't SkillProficiency(
E, S ) effectively the same proposition as ShiftAssignment( E, T )?

then
scoreHolder.addHardConstraintMatch(kcontext, -1);
end

W: SkillProficiency has not been explained, so it's hard to correlate
this rule with the original statement.

-W
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


Re: [rules-users] Optaplanner rule to assign employee only to shift when he/she has the skills

2013-11-22 Thread ns
Thanks for the reply. It helped to see my mistake. I have now simplified the
rule for testing purposes. I now have:

rule alternativeSkill
when
$skill : Skill(code == '1')
$employee : Employee()
not SkillProficiency(employee == $employee, skill == $skill)
then
scoreHolder.addHardConstraintMatch(kcontext,
-1);//scoreHolder.addSoftConstraintMatch(kcontext, -
$contractLine.getWeight());
end

I have three employees and 19 shifts. 1 employee has the necessary skills to
do the shifts, the other 2 not. When I run the program I get:

14:42:19.237 [main] DEBUG o.o.c.i.l.DefaultLocalSearchSolverPhase - Step
index (135), time spend (2), score (-2hard/-182soft), best score
(-2hard/-182soft), accepted/selected move count (85/252) for picked step
(2013-12-09(Mon)_intake-evgey_Intaketeam(Evelien Geysen - Intaketeam) =
2013-12-05(Thu)_intake-mavan_Intaketeam(Marie Van de Vliet - Intaketeam)).
14:42:19.237 [main] INFO  o.o.c.i.l.DefaultLocalSearchSolverPhase - Phase
(1) localSearch ended: step total (136), time spend (2), best score
(-2hard/-182soft).
14:42:19.237 [main] INFO  o.o.core.impl.solver.DefaultSolver - Solving
ended: time spend (2), best score (-2hard/-182soft), average calculate
count per second (19839).

I get 2 hard errors as expected. But the best solution still assigns all
three employees to the shifts. Why do I not get a solution where only the
one qualified employee is assigned to all shifts? That way I would get 0
hard errors. Am I missing something?



--
View this message in context: 
http://drools.46999.n3.nabble.com/Optaplanner-rule-to-assign-employee-only-to-shift-when-he-she-has-the-skills-tp4026879p4026885.html
Sent from the Drools: User forum mailing list archive at Nabble.com.
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


Re: [rules-users] Optaplanner: Unexpected global [scoreHolder] - Kie API trouble

2013-11-22 Thread jonathan.labin
It seems to also throw this error any time the path includes the character: \ 
Even properly escaped in the string as \\



--
View this message in context: 
http://drools.46999.n3.nabble.com/Optaplanner-Unexpected-global-scoreHolder-tp4023837p4026886.html
Sent from the Drools: User forum mailing list archive at Nabble.com.
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


Re: [rules-users] Optaplanner: Unexpected global [scoreHolder] - Kie API trouble

2013-11-22 Thread Geoffrey De Smet
Which path in what file?

On 22-11-13 15:27, jonathan.labin wrote:
 It seems to also throw this error any time the path includes the character: \
 Even properly escaped in the string as \\



 --
 View this message in context: 
 http://drools.46999.n3.nabble.com/Optaplanner-Unexpected-global-scoreHolder-tp4023837p4026886.html
 Sent from the Drools: User forum mailing list archive at Nabble.com.
 ___
 rules-users mailing list
 rules-users@lists.jboss.org
 https://lists.jboss.org/mailman/listinfo/rules-users


___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


Re: [rules-users] Optaplanner: Unexpected global [scoreHolder] - Kie API trouble

2013-11-22 Thread jonathan.labin
I am calling KieFileSystem.write(String path ,String content) but the same
issue may be experienced with any of the versions of write that take a
path parameter but I haven't tried them.

I found that if the path parameter includes a character \ there is no error
produced when calling KieFileSystem.write(...).

When a KieBuilder.buildAll() is called a warning is logged:
[o.d.compiler.kie.builder.impl.AbstractKieModule   ] No files found for
KieBase defaultKieBase

Then when solving begins the exception  is thrown:
java.lang.RuntimeException: Unexpected global [scoreHolder]
(the same stack trace provided at the beginning of this thread).

For my code I've done a String regex just before the write call to swap any
\ into / 
replaceAll(,/)



--
View this message in context: 
http://drools.46999.n3.nabble.com/Optaplanner-Unexpected-global-scoreHolder-tp4023837p4026888.html
Sent from the Drools: User forum mailing list archive at Nabble.com.
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


Re: [rules-users] Optaplanner: Unexpected global [scoreHolder] - Kie API trouble

2013-11-22 Thread Geoffrey De Smet
Looks like a bug in drools, not really relate to optaplanner as it 
happens before you set this KieBase on OptaPlanner's SolverFactory, I 
presume?

If (and only if) it reproduces with drools 6.0.0.Final (optaplanner 
6.0.0.Final uses that version), create a new jira:
   https://issues.jboss.org/browse/DROOLS
We're in squashing bugs mode, so it's a perfect time to create these 
jira's :)

On 22-11-13 16:19, jonathan.labin wrote:
 I am calling KieFileSystem.write(String path ,String content) but the same
 issue may be experienced with any of the versions of write that take a
 path parameter but I haven't tried them.

 I found that if the path parameter includes a character \ there is no error
 produced when calling KieFileSystem.write(...).

 When a KieBuilder.buildAll() is called a warning is logged:
 [o.d.compiler.kie.builder.impl.AbstractKieModule   ] No files found for
 KieBase defaultKieBase

 Then when solving begins the exception  is thrown:
 java.lang.RuntimeException: Unexpected global [scoreHolder]
 (the same stack trace provided at the beginning of this thread).

 For my code I've done a String regex just before the write call to swap any
 \ into /
 replaceAll(,/)



 --
 View this message in context: 
 http://drools.46999.n3.nabble.com/Optaplanner-Unexpected-global-scoreHolder-tp4023837p4026888.html
 Sent from the Drools: User forum mailing list archive at Nabble.com.
 ___
 rules-users mailing list
 rules-users@lists.jboss.org
 https://lists.jboss.org/mailman/listinfo/rules-users


___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


Re: [rules-users] using Drools in Tomcat 6.0 enviourment

2013-11-22 Thread Erez Zarini
No. the files are there for sure. 

Best Regards



Erez-Levi Zarini
 Israel

P. Engineer - Java/.Net(c#) Programmer, VOIP.
 
Global Technology Services
 
Phone:
+972-522554-720 x8720
 

Mobile:
+972-522554-720
 

e-mail:
ze...@il.ibm.com
 





From:   Antoine Toulme-2 [via Drools] 
ml-node+s46999n4026883...@n3.nabble.com
To: Erez-Levi Zarini/Israel/IBM@IBMIL
Date:   22/11/2013 13:43
Subject:Re: [rules-users] using Drools in Tomcat 6.0 enviourment



Erez, is it possible that the change of packaging is removing the file 
from the classpath ?


On Thu, Nov 21, 2013 at 8:20 PM, Erez Zarini [hidden email] wrote:
Hi,

I am new to Drools.

I have successfully created a project from the Examples provided at the 
site
using Java APP project.

but when trying to move it as a Dynamic Web Project in Eclipse I get the
following Exception:

(the files kmodule and pom.xml resides in all subfolders of the project)

21/11/2013 15:49:42 
org.drools.compiler.kie.builder.impl.ClasspathKieProject
discoverKieModules
INFO: Found kmodule:
file:/C:/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/DecisionTableGvia/WEB-INF/classes/META-INF/kmodule.xml
21/11/2013 15:49:43 
org.drools.compiler.kie.builder.impl.ClasspathKieProject
getPomProperties
WARNING: Unable to load pom.properties tried recursing down
from/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/DecisionTableGvia/WEB-INF/classes
null
21/11/2013 15:49:43 
org.drools.compiler.kie.builder.impl.ClasspathKieProject
discoverKieModules
SEVERE: Unable to build index of kmodule.xml
url=file:/C:/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/DecisionTableGvia/WEB-INF/classes/META-INF/kmodule.xml
null
[]
21/11/2013 15:49:43 org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet getDecisionGvia threw exception
java.lang.NullPointerException
ֲ  ֲ  ֲ  ֲ  at
org.drools.compiler.kie.builder.impl.KieContainerImpl.newStatelessKieSession(KieContainerImpl.java:360)
ֲ  ֲ  ֲ  ֲ  at
org.drools.compiler.kie.builder.impl.KieContainerImpl.newStatelessKieSession(KieContainerImpl.java:351)
ֲ  ֲ  ֲ  ֲ  at
gvia.PricingRuleDTExample.executeExample(PricingRuleDTExample.java:39)
ֲ  ֲ  ֲ  ֲ  at 
gvia.PricingRuleDTExample.main(PricingRuleDTExample.java:32)
ֲ  ֲ  ֲ  ֲ  at gvia.getDecisionGvia.doGet(getDecisionGvia.java:33)
ֲ  ֲ  ֲ  ֲ  at 
javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
ֲ  ֲ  ֲ  ֲ  at 
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
ֲ  ֲ  ֲ  ֲ  at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
ֲ  ֲ  ֲ  ֲ  at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
ֲ  ֲ  ֲ  ֲ  at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
ֲ  ֲ  ֲ  ֲ  at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
ֲ  ֲ  ֲ  ֲ  at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
ֲ  ֲ  ֲ  ֲ  at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
ֲ  ֲ  ֲ  ֲ  at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
ֲ  ֲ  ֲ  ֲ  at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
ֲ  ֲ  ֲ  ֲ  at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:849)
ֲ  ֲ  ֲ  ֲ  at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
ֲ  ֲ  ֲ  ֲ  at
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:454)
ֲ  ֲ  ֲ  ֲ  at java.lang.Thread.run(Unknown Source)



when running as a Java project (not Java EE) it seems to work find and
continues to find pom.xml instead of pom.properties.

any ideas?



--
View this message in context: 
http://drools.46999.n3.nabble.com/using-Drools-in-Tomcat-6-0-enviourment-tp4026878.html

Sent from the Drools: User forum mailing list archive at Nabble.com.
___
rules-users mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/rules-users


___ 
rules-users mailing list 
[hidden email] 
https://lists.jboss.org/mailman/listinfo/rules-users 


If you reply to this email, your message will be added to the discussion 
below:
http://drools.46999.n3.nabble.com/using-Drools-in-Tomcat-6-0-enviourment-tp4026878p4026883.html
 

To unsubscribe from using Drools in Tomcat 6.0 enviourment, click here.
NAML 



_1_0DA611B80DA60DE40056739FC2257C2B (492 bytes) 
http://drools.46999.n3.nabble.com/attachment/4026890/0/_1_0DA611B80DA60DE40056739FC2257C2B




--
View this message in context: 
http://drools.46999.n3.nabble.com/using-Drools-in-Tomcat-6-0-enviourment-tp4026878p4026890.html
Sent from the Drools: User forum mailing list archive at Nabble.com.___
rules-users mailing list

Re: [rules-users] Optaplanner: Unexpected global [scoreHolder] - Kie API trouble

2013-11-22 Thread jonathan.labin
The exception is not finally thrown until the call to
solver.solve();



--
View this message in context: 
http://drools.46999.n3.nabble.com/Optaplanner-Unexpected-global-scoreHolder-tp4023837p4026891.html
Sent from the Drools: User forum mailing list archive at Nabble.com.
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


Re: [rules-users] Optaplanner: Unexpected global [scoreHolder] - Kie API trouble

2013-11-22 Thread Geoffrey De Smet
then file a jira in optaplanner, it might be optaplanner's fault in 
ScoreDirectorFactoryConfig.java.

On 22-11-13 17:14, jonathan.labin wrote:
 The exception is not finally thrown until the call to
 solver.solve();



 --
 View this message in context: 
 http://drools.46999.n3.nabble.com/Optaplanner-Unexpected-global-scoreHolder-tp4023837p4026891.html
 Sent from the Drools: User forum mailing list archive at Nabble.com.
 ___
 rules-users mailing list
 rules-users@lists.jboss.org
 https://lists.jboss.org/mailman/listinfo/rules-users


___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


[rules-users] Exception when uploading JAR without POM in 6.0.0-Final

2013-11-22 Thread SrjTx
If you try to upload a JAR without a pom.xml, it requests GAV info and then
throws the exception included at the bottom of the list.

I'm thinking that at line 141 in FileServlet.java, gav is not null and
therefore fileData is not converted to a BufferedInputStream at line 146,
which cause line 174 to throw the exception.


This is on CentOS 6.4

Work-around is to make sure you always have pom.xml in META-INF/maven



09:29:27,273 ERROR
[org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/guvnor].[M2RepoFileServlet]]
(http-localhost/127.0.0.1:8080-4) JBWEB000236: Servlet.service() for servlet
M2RepoFileServlet threw exception:
org.guvnor.common.services.shared.exceptions.GenericPortableException:
mark/reset not supported
at
org.guvnor.common.services.backend.exceptions.ExceptionUtilities.handleException(ExceptionUtilities.java:24)
[guvnor-services-api-6.0.0.Final.jar:6.0.0.Final]
at
org.guvnor.m2repo.backend.server.FileServlet.uploadFile(FileServlet.java:180)
[guvnor-m2repo-editor-backend-6.0.0.Final.jar:6.0.0.Final]
at
org.guvnor.m2repo.backend.server.FileServlet.processUpload(FileServlet.java:84)
[guvnor-m2repo-editor-backend-6.0.0.Final.jar:6.0.0.Final]
at
org.guvnor.m2repo.backend.server.FileServlet.doPost(FileServlet.java:70)
[guvnor-m2repo-editor-backend-6.0.0.Final.jar:6.0.0.Final]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:754)
[jboss-servlet-api_3.0_spec-1.0.2.Final.jar:1.0.2.Final]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:847)
[jboss-servlet-api_3.0_spec-1.0.2.Final.jar:1.0.2.Final]
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:295)
[jbossweb-7.2.0.Final.jar:7.2.0.Final]
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)
[jbossweb-7.2.0.Final.jar:7.2.0.Final]
at
org.uberfire.security.server.UberFireSecurityFilter.doFilter(UberFireSecurityFilter.java:266)
[uberfire-security-server-0.3.0.Final.jar:0.3.0.Final]
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246)
[jbossweb-7.2.0.Final.jar:7.2.0.Final]
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)
[jbossweb-7.2.0.Final.jar:7.2.0.Final]
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
[jbossweb-7.2.0.Final.jar:7.2.0.Final]
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:149)
[jbossweb-7.2.0.Final.jar:7.2.0.Final]
at
org.jboss.as.web.session.ClusteredSessionValve.handleRequest(ClusteredSessionValve.java:134)
[jboss-as-web-7.2.0.Final.jar:7.2.0.Final]
at
org.jboss.as.web.session.ClusteredSessionValve.invoke(ClusteredSessionValve.java:99)
[jboss-as-web-7.2.0.Final.jar:7.2.0.Final]
at
org.jboss.as.web.session.JvmRouteValve.invoke(JvmRouteValve.java:92)
[jboss-as-web-7.2.0.Final.jar:7.2.0.Final]
at
org.jboss.as.web.session.LockingValve.invoke(LockingValve.java:64)
[jboss-as-web-7.2.0.Final.jar:7.2.0.Final]
at
org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:169)
[jboss-as-web-7.2.0.Final.jar:7.2.0.Final]
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:145)
[jbossweb-7.2.0.Final.jar:7.2.0.Final]
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:97)
[jbossweb-7.2.0.Final.jar:7.2.0.Final]
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:102)
[jbossweb-7.2.0.Final.jar:7.2.0.Final]
at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:336)
[jbossweb-7.2.0.Final.jar:7.2.0.Final]
at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
[jbossweb-7.2.0.Final.jar:7.2.0.Final]
at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:653)
[jbossweb-7.2.0.Final.jar:7.2.0.Final]
at
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:920)
[jbossweb-7.2.0.Final.jar:7.2.0.Final]
at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_10]




--
View this message in context: 
http://drools.46999.n3.nabble.com/Exception-when-uploading-JAR-without-POM-in-6-0-0-Final-tp4026893.html
Sent from the Drools: User forum mailing list archive at Nabble.com.
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


Re: [rules-users] Exception when uploading JAR without POM in 6.0.0-Final

2013-11-22 Thread Michael Anstis
Can you please raise a JIRA for Guvnor and attach your JAR.

We have tested with some JARs that lacked a pom and all appeared ok.

Thanks,

Mike

Sent on the move
On 22 Nov 2013 17:07, SrjTx clickt...@yahoo.com wrote:

 If you try to upload a JAR without a pom.xml, it requests GAV info and then
 throws the exception included at the bottom of the list.

 I'm thinking that at line 141 in FileServlet.java, gav is not null and
 therefore fileData is not converted to a BufferedInputStream at line 146,
 which cause line 174 to throw the exception.


 This is on CentOS 6.4

 Work-around is to make sure you always have pom.xml in META-INF/maven



 09:29:27,273 ERROR

 [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/guvnor].[M2RepoFileServlet]]
 (http-localhost/127.0.0.1:8080-4) JBWEB000236: Servlet.service() for
 servlet
 M2RepoFileServlet threw exception:
 org.guvnor.common.services.shared.exceptions.GenericPortableException:
 mark/reset not supported
 at

 org.guvnor.common.services.backend.exceptions.ExceptionUtilities.handleException(ExceptionUtilities.java:24)
 [guvnor-services-api-6.0.0.Final.jar:6.0.0.Final]
 at

 org.guvnor.m2repo.backend.server.FileServlet.uploadFile(FileServlet.java:180)
 [guvnor-m2repo-editor-backend-6.0.0.Final.jar:6.0.0.Final]
 at

 org.guvnor.m2repo.backend.server.FileServlet.processUpload(FileServlet.java:84)
 [guvnor-m2repo-editor-backend-6.0.0.Final.jar:6.0.0.Final]
 at
 org.guvnor.m2repo.backend.server.FileServlet.doPost(FileServlet.java:70)
 [guvnor-m2repo-editor-backend-6.0.0.Final.jar:6.0.0.Final]
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:754)
 [jboss-servlet-api_3.0_spec-1.0.2.Final.jar:1.0.2.Final]
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:847)
 [jboss-servlet-api_3.0_spec-1.0.2.Final.jar:1.0.2.Final]
 at

 org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:295)
 [jbossweb-7.2.0.Final.jar:7.2.0.Final]
 at

 org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)
 [jbossweb-7.2.0.Final.jar:7.2.0.Final]
 at

 org.uberfire.security.server.UberFireSecurityFilter.doFilter(UberFireSecurityFilter.java:266)
 [uberfire-security-server-0.3.0.Final.jar:0.3.0.Final]
 at

 org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246)
 [jbossweb-7.2.0.Final.jar:7.2.0.Final]
 at

 org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)
 [jbossweb-7.2.0.Final.jar:7.2.0.Final]
 at

 org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
 [jbossweb-7.2.0.Final.jar:7.2.0.Final]
 at

 org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:149)
 [jbossweb-7.2.0.Final.jar:7.2.0.Final]
 at

 org.jboss.as.web.session.ClusteredSessionValve.handleRequest(ClusteredSessionValve.java:134)
 [jboss-as-web-7.2.0.Final.jar:7.2.0.Final]
 at

 org.jboss.as.web.session.ClusteredSessionValve.invoke(ClusteredSessionValve.java:99)
 [jboss-as-web-7.2.0.Final.jar:7.2.0.Final]
 at
 org.jboss.as.web.session.JvmRouteValve.invoke(JvmRouteValve.java:92)
 [jboss-as-web-7.2.0.Final.jar:7.2.0.Final]
 at
 org.jboss.as.web.session.LockingValve.invoke(LockingValve.java:64)
 [jboss-as-web-7.2.0.Final.jar:7.2.0.Final]
 at

 org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:169)
 [jboss-as-web-7.2.0.Final.jar:7.2.0.Final]
 at

 org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:145)
 [jbossweb-7.2.0.Final.jar:7.2.0.Final]
 at

 org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:97)
 [jbossweb-7.2.0.Final.jar:7.2.0.Final]
 at

 org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:102)
 [jbossweb-7.2.0.Final.jar:7.2.0.Final]
 at
 org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:336)
 [jbossweb-7.2.0.Final.jar:7.2.0.Final]
 at
 org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
 [jbossweb-7.2.0.Final.jar:7.2.0.Final]
 at

 org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:653)
 [jbossweb-7.2.0.Final.jar:7.2.0.Final]
 at
 org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:920)
 [jbossweb-7.2.0.Final.jar:7.2.0.Final]
 at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_10]




 --
 View this message in context:
 http://drools.46999.n3.nabble.com/Exception-when-uploading-JAR-without-POM-in-6-0-0-Final-tp4026893.html
 Sent from the Drools: User forum mailing list archive at Nabble.com.
 ___
 rules-users mailing list
 rules-users@lists.jboss.org
 https://lists.jboss.org/mailman/listinfo/rules-users


[rules-users] Compiling drools-examples

2013-11-22 Thread baloodevil
Newbie question.  I've imported drools-examples project into Eclipse (Kepler)
(which has GEF installed).  I resolved build path errors by creating folders
src/test/java and src/test/resources.  I resolved another issue by adding an
External JAR of org.eclipse.jdt.core_3.10.0.v20131029-1755.jar to the
project.  (Those two changes allow me to create a new Drools Hello World
project and execute, however no such luck with complete examples)  There are
hundreds of Drools Errors and hundreds of Java Problems, which I assume can
only be because of setup issues.  The first Drools error is
ArrayList is a raw type. References to generic type ArrayListE should be
parameterized   AdventureFrame.java
/drools-examples/src/main/java/org/drools/games/adventures.  That file
shows an import problem with 
import net.miginfocom.layout.ConstraintParser; and import
net.miginfocom.swing.MigLayout;.  Those are referenced in the pom.xml file
in...
dependency
   groupIdcom.miglayout/groupId
   artifactIdmiglayout/artifactId
   version3.7.4/version
/dependency

I don't know where to go next.  Complete Drools newbie, and also fumbling
around with Eclipse.





--
View this message in context: 
http://drools.46999.n3.nabble.com/Compiling-drools-examples-tp4026895.html
Sent from the Drools: User forum mailing list archive at Nabble.com.
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


[rules-users] CurriculumCourse - extending for multiple teachers per course

2013-11-22 Thread clients
Hi, 

I have been playing around with the optaplanner library for the past couple
of weeks trying to learn a bit of the basics. I have been making some
progress but I have a simple variation I am trying to accomplish to the
stock CurriculumCourse example and am hitting a wall. 

What I am trying to do is modify the CurriculumCourse example to also allow
the teachers to be planning variables. I plan on extending it to give
constraints on which courses individual teachers can teach, but to start I
am just assuming each teacher can teach any class to make things easier. 

- First I tried to add the Course entity as a second planning entity with
the teacher being a PlanningVariable but keep on running into an exception
based on the solver configuration

java.lang.IllegalArgumentException: The entityPlacerConfig
(QueuedEntityPlacerConfig(null, null)) has no entitySelector configured and
because there are multiple in the planningEntityClassSet ([class
org.optaplanner.examples.curriculumcourse.domain.Lecture, class
org.optaplanner.examples.curriculumcourse.domain.Course]), it can not be
deducted automatically. at
org.optaplanner.core.config.constructionheuristic.placer.EntityPlacerConfig.deduceEntityDescriptor(EntityPlacerConfig.java:43)


I can't seem to figure out where the entitySelector is missing or what the
entityPlacer is used for or where it is configured. I have read that
multiple planning entities are possible, but can't determine how to get this
*simple* example to work.

- Second I tried to see if i could move the teacher planning variable to the
Lecture planningEntity, but cant figure out a way to keep all of the
lectures of one course stuck with the same teacher. I dont believe I can
change other planning entities on my own when one is updated.

I am still new to looking at these problems and determining the best model
to fit it, so hoping someone might have some tips/help on how to handle this
scenario.

Thanks in advanced,



--
View this message in context: 
http://drools.46999.n3.nabble.com/CurriculumCourse-extending-for-multiple-teachers-per-course-tp4026896.html
Sent from the Drools: User forum mailing list archive at Nabble.com.
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


Re: [rules-users] Compiling drools-examples

2013-11-22 Thread Matthew Versaggi
My experience is that those examples will still run properly despite the
errors. I did have to add in a few odd libraries etc, but they did work.
The examples (in maven) from the drools dev 5X 2013 book are another issue
entirely ... but with some work, even those work.


On Fri, Nov 22, 2013 at 3:20 PM, baloodevil dukek...@hotmail.com wrote:

 Newbie question.  I've imported drools-examples project into Eclipse
 (Kepler)
 (which has GEF installed).  I resolved build path errors by creating
 folders
 src/test/java and src/test/resources.  I resolved another issue by adding
 an
 External JAR of org.eclipse.jdt.core_3.10.0.v20131029-1755.jar to the
 project.  (Those two changes allow me to create a new Drools Hello World
 project and execute, however no such luck with complete examples)  There
 are
 hundreds of Drools Errors and hundreds of Java Problems, which I assume can
 only be because of setup issues.  The first Drools error is
 ArrayList is a raw type. References to generic type ArrayListE should be
 parameterized   AdventureFrame.java
 /drools-examples/src/main/java/org/drools/games/adventures.  That file
 shows an import problem with
 import net.miginfocom.layout.ConstraintParser; and import
 net.miginfocom.swing.MigLayout;.  Those are referenced in the pom.xml file
 in...
 dependency
groupIdcom.miglayout/groupId
artifactIdmiglayout/artifactId
version3.7.4/version
 /dependency

 I don't know where to go next.  Complete Drools newbie, and also fumbling
 around with Eclipse.





 --
 View this message in context:
 http://drools.46999.n3.nabble.com/Compiling-drools-examples-tp4026895.html
 Sent from the Drools: User forum mailing list archive at Nabble.com.
 ___
 rules-users mailing list
 rules-users@lists.jboss.org
 https://lists.jboss.org/mailman/listinfo/rules-users




-- 
#
Matthew R. Versaggi, President  CEO
Versaggi Information Systems, Inc.
Adjunct Professor of eBusiness DePaul University
Email: mailto:m...@versaggi.com, profversa...@gmail.com
M: 630-292-8422
LinkedIn:  http://www.linkedin.com/in/versaggi
#
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users