axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Thilo Frotscher <thilo.frotsc...@web.de>
Subject Re: [Axis2] Phases concept is confusing - bug or feature? Please discuss!
Date Mon, 31 Jul 2006 05:40:03 GMT

Hello,

>> However, when sending messages to this service, Axis2 1.0 will behave
>> differently. A handler that belongs to a global phase will be invoked for
>> *all* services and *all* operations after it was engaged with a *single*
>> service or *single* operation only. This is very confusing!
>>
> agreed , but that is the behavior   :-) .

If we agree that this behavior very confusing, then it should
really be changed. How are beginners supposed to understand this
concept? As the current version is still 1.0 and probably only few
people are using modules and phases in production today, there's
still a chance to make changes like this without sacrificing too
much backwards compatibility.


> The problem is until you find the service and operation (until dispatch
> happen) you dont know the operation specific chains. 

This only applies to incoming messages on the server side. The problem
I described applies to all flows.


> So when you engage
> a module to a service , then if add a handler to global phases as you
> said it will run irrespective of the service. Since anyone can add
> handler to global phases and no one keep track of that , at the run time
> Axis2 can not figure out who add this handler into here.

My suggestion is as follows:

- it should not be allowed to engage a module with a service or operation
   if the module contains handlers that go to any of the global phases
   *before* dispatch phase. If somebody tries to do this, Axis2 should report an
   error. Modules with handlers in Transport/Security/PreDispatch phase
   can be engaged only globally, i.e. with all services and all operations,
   because this is what actually happens.
- only if all handlers of a module go to operation-specific phases or
   to global phases after dispatch, it should be allowed to engage them
   with a particular service or operation.


>> - handler method "cleanup" is never called
> 
> one more JIRA

I created a JIRA 2 months ago (AXIS2-653). It's unassigned so far.


> I also think we need to take this into consideration , so +1 for the idea.
> we need to call handler.onFault(); for all the prior handlers.

I created a new JIRA (AXIS2-942).


>> - it would be great if modules could be disengaged using the admin
>> frontend
>>
> pls create a JIRA so that we wont forget that.

Created AXIS2-943.


>> - Why is there a "Security" phase in th In Flow, but not in the Out Flow?
>>   Rampart puts its SecurityOutHandler into the "MessageOut" phase...
>>   Wouldn't it be easier to understand if there was a Security phase in
>>   the Out Flow as well?
> 
> Ruchith what do you think  ? I am +1 of doing this change.

Created AXIS2-944.

Cheers,
Thilo



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


Mime
View raw message