Hi,
Which version of drools are you using? Make sure you are using the same version in guvnor and in your application.

Best,

El jul 26, 2010 7:48 a.m., "Pardeep Ruhil" <Pardeep.Ruhil@lntinfotech.com> escribió:

Hi,

I have created a rule in Drools Guvnor and when I am trying to access it in my code I am getting the below exception.

 

java.lang.RuntimeException: KnowledgeAgent exception while trying to deserialize KnowledgeDefinitionsPackage

        at org.drools.agent.impl.KnowledgeAgentImpl.rebuildResources(KnowledgeAgentImpl.java:425)

        at org.drools.agent.impl.KnowledgeAgentImpl.applyChangeSet(KnowledgeAgentImpl.java:121)

        at org.drools.agent.impl.KnowledgeAgentImpl.applyChangeSet(KnowledgeAgentImpl.java:110)

        at org.ofbiz.drools.event.drool.RuleIntegrate.createKnowledgeBase(RuleIntegrate.java:45)

        at org.ofbiz.drools.event.drool.RuleIntegrate.createWorkingMemory(RuleIntegrate.java:29)

        at org.ofbiz.payRoll.PayRollTax.callPayRollTaxRule(PayRollTax.java:23)

        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

        at java.lang.reflect.Method.invoke(Method.java:597)

        at org.ofbiz.service.engine.StandardJavaEngine.serviceInvoker(StandardJavaEngine.java:100)

        at org.ofbiz.service.engine.StandardJavaEngine.runSync(StandardJavaEngine.java:57)

        at org.ofbiz.service.ModelServiceReader$GenericInvokerImpl.runSync(ModelServiceReader.java:761)

        at _$gen.file_58$.D_58$.Dev.swapnilcode.ofbiz_45$09_45$July_45$2010.hot_45$deploy.payRoll.servicedef.services_46$xml_35

$payRollTax.runSync(file:/D:/Dev/swapnilcode/ofbiz-09-July-2010/hot-deploy/payRoll/servicedef/services.xml#payRollTax:9)

        at org.ofbiz.service.ServiceDispatcher.runSync(ServiceDispatcher.java:399)

        at org.ofbiz.service.ServiceDispatcher.runSync(ServiceDispatcher.java:226)

        at org.ofbiz.service.GenericDispatcher.runSync(GenericDispatcher.java:165)

        at org.ofbiz.webapp.event.ServiceEventHandler.invoke(ServiceEventHandler.java:336)

        at org.ofbiz.webapp.control.RequestHandler.runEvent(RequestHandler.java:637)

        at org.ofbiz.webapp.control.RequestHandler.doRequest(RequestHandler.java:383)

        at org.ofbiz.webapp.control.ControlServlet.doGet(ControlServlet.java:227)

        at org.ofbiz.webapp.control.ControlServlet.doPost(ControlServlet.java:90)

        at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)

        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.ofbiz.webapp.control.ContextFilter.doFilter(ContextFilter.java:271)

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

        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:127)

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

        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)

        at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:555)

        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)

        at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:852)

        at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:588)

        at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)

        at java.lang.Thread.run(Thread.java:619)

Caused by: java.net.SocketException: Unexpected end of file from server

        at sun.net.www.http.HttpClient.parseHTTPHeader(HttpClient.java:769)

        at sun.net.www.http.HttpClient.parseHTTP(HttpClient.java:632)

        at sun.net.www.http.HttpClient.parseHTTPHeader(HttpClient.java:766)

        at sun.net.www.http.HttpClient.parseHTTP(HttpClient.java:632)

        at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1000)

        at org.drools.io.impl.UrlResource.grabStream(UrlResource.java:154)

        at org.drools.io.impl.UrlResource.getInputStream(UrlResource.java:102)

        at org.drools.agent.impl.KnowledgeAgentImpl.rebuildResources(KnowledgeAgentImpl.java:414)

 

 

My  changeset.xml file is :

<change-set xmlns='http://drools.org/drools-5.0/change-set'

             xmlns:xs='http://www.w3.org/2001/XMLSchema-instance'

             xs:schemaLocation='http://drools.org/drools-5.0/change-set drools-change-set-5.0.xsd' >

   <add>

       <resource source='http://localhost:8441/DroolsGuvenor/org.drools.guvnor.Guvnor/package/payRoll_pradeep/LATEST' type='PKG' />

   </add>

</change-set>

 

 

Please help me in this.

 

Thanks & Regards

Pradeep Ruhil

 



This Email may contain confidential or privileged information for the intended recipient (s) If you are not the intended recipient, please do not use or disseminate the information, notify the sender and delete it from your system.

______________________________________________________________________

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