Niclas Hedhman wrote:

Hi,

while looking for alternate ways to implement the Security framework in Merlin, I took a peek at the LifeCycle extensions.

I am a bit hesitant to the current design.

public interface Creator
{
   void create( Object object, Context context )
       throws Exception;
   void destroy( Object object, Context context );
}

and

public interface Accessor
{
   void access( Object object, Context context )
       throws Exception;

   void release( Object object, Context context );
}

Shouldn't the create() and the access() methods return Object, which much be an object of the same type as the parameter object?

By doing that, it is possible to wrap any component with an pluggable interceptor mechanism. As it is now, that is not possible. Or am I supposed to do something like that elsewhere?

Furthermore, why does the component need to declare/associate the stage in its type declaration? It is not done for Serviceable? IMVHO, Life Cycle extensions are "Installed" into the container, and for each component the container checks if it implements the Extension interface, if so service it.

An ideal LifeCycle extension system, would allow us to break out all the existing stages, and configure them via the extension mechanism. Wouldn't that be the ultimate goal? That is at the moment not possible, as I can't specify the stage order for construction.

Just some thoughts about the subject...


Some additional content - its not interceptor stuff, but its a lot more useful ..
http://avalon.apache.org/merlin/api/org/apache/avalon/activation/lifecycle/LifecycleCreateExtension.html
http://avalon.apache.org/merlin/api/org/apache/avalon/activation/lifecycle/LifecycleDestroyExtension.html
Steve.



Niclas


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--


Stephen J. McConnell
mailto:[EMAIL PROTECTED]

|------------------------------------------------|
| Magic by Merlin                                |
| Production by Avalon                           |
|                                                |
| http://avalon.apache.org/merlin                |
| http://dpml.net/                               |
|------------------------------------------------|





---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to