I've now actually looked at jsr94 and drools a bit and think that there is no reason whatsoever to implement a jca adapter for drools, at least not for use in geronimo. The only effects would be to slow everything down. Before actually reading the spec I had formed the idea that it required access through a jca adapter: since it doesn't, lets not do it that way.

Instead, I now think that the best way to deploy in geronimo is to wrap drools in a (geronimo) mbean with a method getRulesRuntime that returns the Drools RulesRuntime implementation. This can be bound directly into a ReadOnlyContext for an ejb or servlet just as jca adapters are using the "jmx" context.

Something similar could be done for the administration interface.

Sorry for the misleading commens earlier,
I'm happy to supply more advice on request.

thanks
david jencks


On Tuesday, December 23, 2003, at 10:02 AM, David Jencks wrote:


On Tuesday, December 23, 2003, at 09:42 AM, Chris Perrin wrote:

<whimper/>

Right-o. Thanks David, that gives me a starting point, yet begs another
question and one I think I know the answer to. Would your recommend going
the MBean route with Drools?

Well, I think that whatever the problems might be, Drools needs a jsr94 interface, so I think that is a good place to start.


On the other hand, you can probably simply deploy an appropriate drools object as a GeronimoMBean simply by writing a descriptor for it. The question is then, however, what components will use it and how, and how will the transaction and security contexts get propagated. Although the jca framework's answers to these questions don't make complete sense to me in the context of a rule engine, at least they provide some answer.

I haven't looked into jsr94 enough to be able to comment on this any more intelligently yet.

david jencks



The one thing that has kept me from implementing Drools as an MBean is that
there was talk about having Geronimo itself use Drools to help run itself
and I've never written an MBean for anything other than access by client
code.


Chris





Reply via email to