<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
<title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
There is no standard api for this, you would have to get your hands
dirty with the source. Look at JavaRuleClassBuilder and you can see
where to put your printouts.<br>
<br>
Mark<br>
Yang Song wrote:
<blockquote
cite="mid:657190290708070301l1c3b295v13cc8d4549dd9b6e@mail.gmail.com"
type="cite">
<div>Greetings everyone,</div>
<div> </div>
<div>Does anyone know how to dump the class generated from .drl file
to disk? Or even better if the generated Java source file can be dumped?</div>
<div> </div>
<div>Looking for some hints here, I got a NPE when firing the rules.
However, it is really hard to find out why the NEP was thrown... If I
can have the dumped class file, then I can be disassemble it back to
Java code.</div>
<div> </div>
<div>To debug this rule in Eclipse is a bit difficult here,
because the project is a little "big" and we usually use logging to do
debugging...</div>
<div> </div>
<div>java.lang.NullPointerException<br>
at
monitor.Rule_ftp_other_host_alarm_0.consequence(Rule_ftp_other_host_alarm_0.java:23)<br>
at
monitor.Rule_ftp_other_host_alarm_0ConsequenceInvoker.evaluate(Rule_ftp_other_host_alarm_0ConsequenceInvoker.java:26)
<br>
at
org.drools.common.DefaultAgenda.fireActivation(DefaultAgenda.java:545)<br>
at
org.drools.common.DefaultAgenda.fireNextItem(DefaultAgenda.java:509)<br>
at org.drools.common.AbstractWorkingMemory.fireAllRules
(AbstractWorkingMemory.java:430)<br>
at
org.drools.common.AbstractWorkingMemory.fireAllRules(AbstractWorkingMemory.java:392)<br>
at
com.monitor.ruleengine.InferenceMachine.fireAllRules(InferenceMachine.java:400)
<br>
at
com.monitor.ruleengine.InferenceMachine.run(InferenceMachine.java:314)<br>
at java.lang.Thread.run(Thread.java:595)</div>
<div> </div>
<div>Thanks very much,</div>
<div>Yang</div>
<pre wrap="">
<hr size="4" width="90%">
_______________________________________________
rules-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a>
<a class="moz-txt-link-freetext" href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a>
</pre>
</blockquote>
<br>
</body>
</html>