[rules-users] Exposing the rule engine as a web service to be accessed by the client

Mark Proctor mproctor at codehaus.org
Thu Jun 18 09:15:08 EDT 2009


tanzu wrote:
> My requirement is to expose drools rules as a web service ,which can be
> accessed by any kind of client including .net .I have built a struts based
> web application.When the user submits the struts client should be able to
> submit the data ,to the web service ,which will execute the rule engine ,and
> fire all rules ,and send a response back to the client.You said it correctly
> the drools execution server can suffice my need.
>
>
> My doubts are
> 1.Is it possible that I dont use guvnor ,and instead use just the drools
> expert with drl files with the execution server.
> 2.The data from the struts client should be converted into xml ,fact object
> and sent to the server to be used in the rules.Am I thinking right.
>
> A sample code showing how the client ,sends xml data to server ,and the
> response sent back to the client ,will be very helpful to me.
>
> Please help.I have a deadline.:-(
>   
If you are using Drools 5.0, we have the new Command and Pipeline api 
with built in XML marshalling. This was all designed to allow it to be 
easily hooked up to any service.

This unit test shows a large set of examples of working with the XML, 
via the pipeline:
http://fisheye.jboss.org/browse/JBossRules/trunk/drools-pipeline/drools-transformer-xstream/src/test/java/org/drools/runtime/pipeline/impl/XStreamBatchExecutionTest.java?r=HEAD

Mark
> tanzu
>
>
>
> pkpkpkpk wrote:
>   
>> Using the Drools execution server, the rules engine can be exposed as a
>> web
>> service.
>>
>> In
>> http://hudson.jboss.org/hudson/job/drools/lastSuccessfulBuild/artifact/trunk/target/docs/drools-guvnor/html_single/index.html,
>> check out section 1.4.7.2
>>
>> The web service can be invoked using JSON or XML, so, it is possible to
>> invoke it from any client.
>>
>> Regards,
>> Prem
>>
>>
>> On Sun, Jun 14, 2009 at 6:45 AM, tanzu <tanu421 at rediffmail.com> wrote:
>>
>>     
>>> Can the drools rule engine ,be exposed as a web service or do we need to
>>> write a web service and make an explicit call to rule engine ,using the
>>> working memory.
>>> Is it possible for a .net application to invoke drools rule engine.
>>>
>>>
>>> Please help as I am a newbie
>>>
>>>
>>> Thanks
>>> tanzu
>>> --
>>> View this message in context:
>>> http://www.nabble.com/Exposing-the-rule-engine-as-a-web-service-to-be-accessed-by-the-client-tp23961020p23961020.html
>>> Sent from the drools - user mailing list archive at Nabble.com.
>>>
>>> _______________________________________________
>>> rules-users mailing list
>>> rules-users at lists.jboss.org
>>> https://lists.jboss.org/mailman/listinfo/rules-users
>>>
>>>       
>> _______________________________________________
>> rules-users mailing list
>> rules-users at lists.jboss.org
>> https://lists.jboss.org/mailman/listinfo/rules-users
>>
>>
>>     
>
>   

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/rules-users/attachments/20090618/55d914ec/attachment.html 


More information about the rules-users mailing list