ode-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Thilina Gunarathne" <cset...@gmail.com>
Subject Re: Axis2 Integration
Date Fri, 14 Sep 2007 21:58:14 GMT
Hi Alex & Matthieu,
Thanx a lot for the quick response and for the pointers.

My current use case is to get some custom header values from the
process instantiating messages (the receive's which create a new
process instance), and then to add those headers to all the outgoing
messages from the server.

I'm in the process of evaluating ODE as a replacement for a custom
written BPEL engine which we are using. I might come up with more
scenerio's in the due time.

>  I'm willing to help
>make this happen... just need to dive deeper into the Axis2 architecture to
>better understand how to do it.
I might be able to give a helping hand in understanding Axis2
architecture as I'm bit familiar with it.

> First our documentation at the integration layer is not that good, so far
> we've been mostly assuming it was internal stuff, however we may need to > reconsider
as more and more people are looking at it. But anyway that
> doesn't really help you.
Well... I'm sure that documentation will get improved overtime. :)

> So basically the WAR version of ODE is packaged inside Axis2, so almost
> everything that holds for a classic Axis2 deployment still holds (minor a
> couple of things specific to our configuration like the services URL space
> or ws-addressing).
Just for my info: Are you all are using the new Axis2 pluggable deployer model ?

>The integration itself is pretty simple, we just create
> services into Axis2 and use the receiver to get messages and forward them to
> our infrastructure. However everything is programmatic as we need a dynamic
> behavior (if you hot-deploy a process, the service gets created, if you
> undeploy the service is removed) as Alex mentioned. So we had to let go of
> the Axis2 static service configuration (i.e. the configuration files) to
> provide that dynamicity.
Fair enough.. But is there a configuration file for the BPEL process?
If there is one we can use it to configure the service upfront.
I can see a axis2.xml under the WEB-INF/conf/ folder. Does ODE use
it?.. I'm going to try engaging a module globally using that axis2.xml
and see how it'll go.

>  * One possibility could be to allow the inclusion of a service.xml in a
> process deployment and have ODE feed that into Axis2 when it creates the
> service for a process.
May be we can reuse a ODE process configuration file (if there is
any).. AFAIKS only a subset of the things which we can configure in
the services.xml will be usefull in ODE.

I think providing the ability to engage a axis2 module's for the
processes service interface will gain a lot for ODE. It would be
really nice if we can engage Rampart module and secure a process
endpoint, even though I'm not sure whether that kind  of use cases
actually exists.

>  * I'm not sure it's possible in Axis2 to go the other way around and
> specify, in a module, which services it should be applied on but if it was
> that could be a solution as well. You would install your module and it would
> "plug" itself on the service.
I'm not sure whether it is the correct thing to do.. Axis2 modules are
an extensibility point which extends the capabilities of the engine.
Having modules to have information about the services does not look
right at least to me.

But this might be possible using a admin console like what Axis2 has.
The problem with the Axis2 admin console is that  it is not persisting
the configuration changes.

> The first one is probably the easier, I'm just mentioning the second in case
> you already had something similar in the work.
AFAIK there are no plans in the Axis2 land for something like that.
May be we should discuss a little bit and see whether it is worthwhile
for Axis2 to provide that feature.

>
> If you want to get familiar with our integration, the easiest way for now is
> to look at the source. A service gets registered using the ODEAxisService
> [1]. Messages are sent using ExternalService[2] and received using our
> message receiver [3]. We could work out something by adding a method in
> ProcessConf (passed to createService in [1]) to access the deployed
> service.xml.
In the ExternalService[1] I found the following lines...
            if (cached == null || cached._expire < now) {
                cached = new CachedServiceClient();
                ConfigurationContext ctx = new
ConfigurationContext(_axisConfig);
Wonder whether you considered using the same configuration context of
the server for the above client invocations rather than creating new
configuration contexts for each and every client..
If we used the same config context, then in my use case I can put the
received headers in to the property bag of the config context and then
retrieve them in the out path. I know configContext is not the right
point to put them, but at least I can do that for the moment.

I'm in the process of doing a deep dive in to the ODE source code.
Hopefully more things will be clear to me after that.

Thanks again,
Thilina

>
> For the bigger picture the integration API has a decent javadoc that you can
> check at [4]. The most interesting interfaces to start with are
> MessageExchange, BindingContext and MessageExchangeContext.
>
> Let us know what you have in mind.
>
> Matthieu
>
> [1]
> http://svn.apache.org/repos/asf/ode/trunk/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisService.java
> [2]
> http://svn.apache.org/repos/asf/ode/trunk/axis2/src/main/java/org/apache/ode/axis2/ExternalService.java
> [3]
> http://svn.apache.org/repos/asf/ode/trunk/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEMessageReceiver.java
> [4]
> http://people.apache.org/~mriou/ode-site/javadoc/org/apache/ode/bpel/iapi/package-summary.html
>
>
> On 9/12/07, Thilina Gunarathne <csethil@gmail.com> wrote:
> >
> > Hi all,
> > Is there a architecutral (or any:) ) document explaining the Axis2
> > integration in Ode.
> >
> > I would like to use some custom Axis2 modules together with processes
> > deployed in ODE. For an example let's say I need to enable logging
> > module [1] in order to log all the messages sent and received by a
> > certain process.
> >
> > I also might need to write a custom module which will share some data
> > with messages sent/received by a certain  process instance. Does ODE
> > associates Axis2 service contexts or service groups contexts with a
> > running process instance?. Does ODE reuse the Axis2  server's
> > ConfigurationContext/ServiceContext when sending  message from a
> > process instance.
> >
> > thanks a lot in advance,
> > Thilina
> >
> > [1] http://ws.apache.org/axis2/1_3/modules.html
> > --
> > Thilina Gunarathne  - http://thilinag.blogspot.com
> >
>


-- 
Thilina Gunarathne  -  http://www.wso2.com - http://thilinag.blogspot.com

Mime
View raw message