[rules-users] Can we make our kbase object available from one context to another context (one application to another webservice)

Michael Anstis michael.anstis at gmail.com
Thu Dec 15 09:34:28 EST 2011


See my reply to your other email.

On 15 December 2011 14:16, srinivasasanda <srinivasasanda at gmail.com> wrote:

> Hi Sir,
>
> I have another Problem Please try to give some suggestion.
>
> how can i  provide my Kbase object loaded with all packages is at one
> context , and can i make it  available to other context applications or
> webservices
>
> Ex:My actual scenario is :I created all my rules and loaded my application
> as
>
>  KnowledgeBuilder kbuilder1 =
> KnowledgeBuilderFactory.newKnowledgeBuilder();
>  KnowledgeBase kbase1 = readKnowledgeBase();
>
> // Like this i added some 50 packages and build single kbase haveing 15000
> rules
> kbuilder1.add(ResourceFactory.newUrlResource("
> http://localhost:8082/guvnor-5.3.0.Final-jboss-as-5.1/org.drools.guvnor.Guvnor/products/mortgages/LATEST
> "),ResourceType.PKG);
> KnowledgeBase kbase = KnowledgeBaseFactory.newKnowledgeBase();
> kbase.addKnowledgePackages(kbuilder1.getKnowledgePackages());
>
>
> This code i made it  as .sar file,so it loads automatically when server
> start up without user control --
> which is loaded is in one context, as per  my understanding kbase object is
> present in that context.
> Now can I make that  kbase object available to web service which is present
> in some other context(some other application) , so that web service can
> make
> use of kbase which is already available (Instead of creating  and loading
> new kbase)..
>
> So far,you suggested so many solutions.Hope you will help me to get out of
> this problem.
>
> Thanks
>
> --
> View this message in context:
> http://drools.46999.n3.nabble.com/Can-we-make-our-kbase-object-available-from-one-context-to-another-context-one-application-to-anothe-tp3588689p3588689.html
> Sent from the Drools: User forum mailing list archive at Nabble.com.
> _______________________________________________
> 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/20111215/5c71f8ce/attachment.html 


More information about the rules-users mailing list