[Beginner's Corner] - Newbie here.. and in need of some help with Drools
by Darren Carr
Darren Carr [http://community.jboss.org/people/DC_Drools] created the discussion
"Newbie here.. and in need of some help with Drools"
To view the discussion, visit: http://community.jboss.org/message/545605#545605
--------------------------------------------------------------
Hi All,
Firstly im so glad I found this forum and a big hello to everyone in this group!
Currently im working on a project to in which we are deciding to which is the best rules engine to apply for our clients requirements. Ive been playing around with drools and have sucessfully got it up and running with the Stock ticker example within eclipse. I have worked with Java some time ago annd must say im very impressed with drools!
Im fairly rusty with Java (but a fast learner) im trying to get up to speed asap.
Ive currently put in simple new rule with the DRL file and am trying to load in my own test data to use with the rules file. However im getting an error and really cant see what ive done wrong.
My dat file contains simple data e.g
0;5000;£199.99
0;5001;£199.99
0;5002;£199.99
0;5003;£199.99
0;5004;£199.99
0;5005;£199.99
0;5006;£199.99
0;5007;£199.99
009;5000;£9.99
010;5001;£9.99
011;5002;£9.99
012;5003;£9.99
013;5004;£9.99
014;5005;£9.99
015;5006;£9.99
016;5007;£9.99
However for some reason i receive
java.text.ParseException
: MessageFormat parse error!at java.text.MessageFormat.parse(Unknown Source)
at net.game.poc.achievements.events.PointsAwardPersister.load(
PointsAwardPersister.java:62)at net.game.poc.achievements.events.PointsAwardPersister.hasNext(
PointsAwardPersister.java:85)at net.game.poc.achievements.events.EventFeeder$FeedJob.execute(
EventFeeder.java:84)at org.drools.time.impl.JDKTimerService$JDKCallableJob.call(
JDKTimerService.java:132)at org.drools.time.impl.JDKTimerService$JDKCallableJob.call(
JDKTimerService.java:110)at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
After debugging the following code is throwing the exception from the load method below.
*public *boolean hasNext() { if( in != null ) { try { PointsAward tick = load(); next = new EventImpl<PointsAward>( tick.getTimestamp(), tick ); return true;}catch ( Exception e ) { // nothing to do, return falsee.printStackTrace();}} return false;*
*
It appears to me that it looking over the end of file but im not sure.
Has anyone got any pointers for me as im completly stuck
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/545605#545605]
Start a new discussion in Beginner's Corner at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 10 months
[jBPM] - How to start a process with variable from JBPM-Console
by Wladimir Lavrov
Wladimir Lavrov [http://community.jboss.org/people/wawan_beta] created the discussion
"How to start a process with variable from JBPM-Console"
To view the discussion, visit: http://community.jboss.org/message/545594#545594
--------------------------------------------------------------
I want to start the process with user forms and I need to declare global variables so as to continue working with them, how to do this?
example:
<?xml version="1.0" encoding="UTF-8"?>
<process name="test" xmlns=" http://jbpm.org/4.3/jpdl http://jbpm.org/4.3/jpdl">
<start g="29,490,48,48" name="StartEvent_1">
<transition to="ask name"/>
</start>
<task assignee="alex" form="org/bew/prozess/test.ftl" g="168,414,190,80" name="ask name">
<transition to="send email"/>
</task>
<mail g="387,32,179,80" language="juel" name="send email">
<to addresses=${email}/>
<subject>${subject}</subject>
<text>Hallo ${userName}</text>
<transition g="-76,-18" name="to EndEvent_1" to="EndEvent_1"/>
</mail>
<end g="676,38,48,48" name="EndEvent_1"/>
</process>
test.ftl
<html><body>
<form action="${form.action}" method="POST" enctype="multipart/form-data">
<h3>Hallo</h3>
Your Name: <input type="text" name="userName"/><br/>
<hr>
<br/><br/>
<input type="submit" name="Done"/>
</form></body></html>
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/545594#545594]
Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 10 months
[JBoss Web Services] - Endpoint.publish and programmatically deploy web service
by Panagiotis Korros
Panagiotis Korros [http://community.jboss.org/people/pkorros] created the discussion
"Endpoint.publish and programmatically deploy web service"
To view the discussion, visit: http://community.jboss.org/message/545584#545584
--------------------------------------------------------------
I am trying to dynamically (programmatically) create and deploy a new Web Service on JBoss 4.2.3. In order to do that I am using the following code:
*Web service implementation:*
@WebServiceProvider
@ServiceMode(Mode.MESSAGE)
public class ScoringDynamicWebService implements Provider<SOAPMessage> {
public SOAPMessage invoke(SOAPMessage request) {...}
}
*Web service publishing code:*
Source source = new StreamSource(new StringReader(wsdl));
source.setSystemId(url+"?wsdl");
metadata.add(source);
Map<String, Object> properties = new HashMap<String, Object>();
properties.put(Endpoint.WSDL_PORT, new QName(
" http://scoring.exodussa.com/ws http://scoring.exodussa.com/ws", webServiceName+"Port"));
properties.put(Endpoint.WSDL_SERVICE, new QName(
" http://scoring.exodussa.com/ws http://scoring.exodussa.com/ws", webServiceName+"Service"));
properties.put("CUSTOM_URL", url);
Endpoint endpoint = Endpoint.create(SOAPBinding.SOAP12HTTP_BINDING, webService);
endpoint.setMetadata(metadata);
endpoint.setProperties(properties);
endpoint.publish(url);
This code works correctly when I am running it on a console application (using jdk 1.6) and I am able to invoke it using a web service client.
When I am trying the same code under JBoss 4.2.3 I get the following exception:
java.lang.IllegalStateException: Cannot obtain wsdl location for: { http://scoring.server.guvnor.drools.org/ http://scoring.server.guvnor.drools.org/}ScoringDynamicWebServiceService
at org.jboss.wsf.stack.jbws.WSDLFilePublisher.getPublishLocation(WSDLFilePublisher.java:315)
at org.jboss.wsf.stack.jbws.WSDLFilePublisher.publishWsdlFiles(WSDLFilePublisher.java:105)
at org.jboss.wsf.stack.jbws.PublishContractDeploymentAspect.create(PublishContractDeploymentAspect.java:52)
at org.jboss.wsf.framework.deployment.DeploymentAspectManagerImpl.deploy(DeploymentAspectManagerImpl.java:118)
at org.jboss.wsf.container.jboss42.DeploymentAspectHttpServer.publish(DeploymentAspectHttpServer.java:89)
at org.jboss.ws.core.jaxws.spi.EndpointImpl.publish(EndpointImpl.java:174)
at org.jboss.ws.core.jaxws.spi.EndpointImpl.publish(EndpointImpl.java:131)
Can anyone point me to what I should do to in order to fix this?
Regards,
Panagiotis
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/545584#545584]
Start a new discussion in JBoss Web Services at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 10 months