You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@avalon.apache.org by Berin Loritsch <bl...@apache.org> on 2003/01/28 04:37:55 UTC
[A4:Fortress/Merlin] Coming to grips with terminology
One of the issues that any Avalon newbie has to come to grips with is
a new vocabulary. Component Oriented Programming is similar in many
respects to its OOP cousin, but there are a few terms that need to
be understood first. One of my concerns with the Merlin effort isn't
so much the technology, but the overloading of terms and adding
semantics that don't exist in other contexts.
We are all very clear on what constitutes a component. We also are
aware that they interact with a container. The problem is the exact
definition of the container. I think we need to standardize on what
we mean by that word, and leverage what is already out there. That
way we all speak the same language.
Everywhere I have looked regarding component systems defines containers
very broadly as:
* the code or server that manages component instances and component
implementation mappings.
The exact text changes, but the concept is still the same. In fact
that is the rough definition I run off of. In other words, a container
not only controls the component instances, but it also controls what
we call the "assembly".
The Merlin project adds two more terms and overloads the meaning of a
third:
Container (overloaded meaning), Block, and Appliance
In essence my understanding is that Merlin places the distinction
between the container which only manages the component implementation
mappings (or assembly), and the appliance which only manages the
component instances. I am not sure exactly what the block is.
Stephen, I am going to need your help one coming up with the proper
terminology. I am not against the separation of the two functionalities
of the container (i.e. assembly and instance management), but I am
against the redefinition of container--which will only server to
confuse people.
In essence, the traditional container as described in all texts that I
have read is the combination of a Merlin container and an Appliance.
If we are going to separate the concepts, we need to come up with a
new name to express the assembly contract.
The only plausible definition I can think of for a Block is a
component that also behaves as an embeded container (traditional).
Hense a Block can be recursive.
We need to strive for simplicity in our naming schemes and consistency
in our definitions. I myself want to be able to come up to speed
more quickly with the Merlin effort, and it will help if we have the
definitions down.
BTW, the results of the definitions we choose need to go on the web
site.
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: [A4:Fortress/Merlin] Coming to grips with terminology
Posted by Leo Simons <le...@apache.org>.
Leo Sutic wrote:
> Stephen McConnell wrote:
>
>>Take a look at the JavaDoc for Appliance at the following URL and let
>>me know if it's understandable.
>
> Stephen, that was not the right level.
>
> Although I think Leo's analogy was a bit overkill,
just a bit, eh? I really did enjoy myself writing it tho' :D Hope I got
the point across.
<snip>
> I've tried many times and I *STILL* don't get the difference between
> METAINFO and METADATA! Please, can we come up with some other names for
> them?
>
> I know that one of them specifies information specific to the
> component type, while the other is the component type information
> *plus* deployment parameters such as configuration.
FWIW, different terms are in use in merlin atm, I believe
Type <------ MetaInfo
Profile <--- MetaData
TypeInfo == Type == MetaInfo: all information associated with a
component that is defined during component development/definition time
but not in the form of javacode. .xinfo, .xconf, .xlong, .xblaat.
Basically .Net attributes at the class level.
RuntimeInfo == Profile == MetaData: all other information, usually
provided as configuration files, but potentially fed in through JMX or
another mechanism.
In a really dynamic system (I've been playing around :D), the difference
does not really exist, except that TypeInfo is loaded somewhere soon
after startup and RuntimeInfo at some point in time thereafter.
cheers,
- Leo
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: [A4:Fortress/Merlin] Coming to grips with terminology
Posted by Leo Simons <le...@apache.org>.
Ulrich Mayring wrote:
> Leo Simons wrote:
>
>> That is somewhat more understandable. I think it is also
>> wrong....getting an analogy right is real difficult :D It is important
>> to write docs this way though; it forces you to be real clear about
>> the contracts imposed, the assumptions made. If the code cannot be
>> explained, the code is bad code :D
>
> I don't necessarily agree with that, because very frequently I find
> myself in the same position. When you're deeply involved in abstract
> concepts, then you're the wrong person to explain it to a layman. You
> need to explain it to someone moderately competent and he has to
> translate it "down the food chain".
>
> The big problem is always to find someone, who is sufficiently
> interested in the topic, so that he delves into it and becomes the
> moderately competent person.
me, me, me! :D
Good point, yep, I ment in general that if it's not possible to create
the "food chain" there's a problem. I'm not exactly a layman, and the
other Leo is like hyper-smart. If we don't get it, who will 8-)
- LSD, had a Very Long Day today....
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: [A4:Fortress/Merlin] Coming to grips with terminology
Posted by Ulrich Mayring <ul...@denic.de>.
Leo Simons wrote:
> That is somewhat more understandable. I think it is also
> wrong....getting an analogy right is real difficult :D It is important
> to write docs this way though; it forces you to be real clear about the
> contracts imposed, the assumptions made. If the code cannot be
> explained, the code is bad code :D
I don't necessarily agree with that, because very frequently I find
myself in the same position. When you're deeply involved in abstract
concepts, then you're the wrong person to explain it to a layman. You
need to explain it to someone moderately competent and he has to
translate it "down the food chain".
The big problem is always to find someone, who is sufficiently
interested in the topic, so that he delves into it and becomes the
moderately competent person.
So, the code that can't be explained is not necessarily bad. But it
might not solve a universally relevant problem, because otherwise there
would be moderately competent translators :)
Ulrich
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
RE: [A4:Fortress/Merlin] Coming to grips with terminology
Posted by Leo Sutic <le...@inspireinfrastructure.com>.
Stephen McConnell wrote:
> Take a look at the JavaDoc for Appliance at the following URL and let
> me know if it's understandable.
Stephen, that was not the right level.
Although I think Leo's analogy was a bit overkill, you ***need*** to
explain things in less technical terms. I'm not saying you
should write *more* text, but you have to stop using all those
long words that basically don't mean anything.
For example: "establishment of a component type"
What is meant by that? These are *not* generally accepted terms.
My advice would not be to mix in restaurants etc., but to
start simplifying the text you have.
"An appliance is responsible for component lifestyle and lifecycle
management during the deployment and decommission cycles."
What "decommission cycle"? Is that a cycle? Does it really mean
that the component ends up where it started, which is the definition
of a cycle?
"Appliances handle component creation and disposal, bringing components
from not-existing to fully initialized as well as taking them out
of service and destroying them at the end of their lifecycle."
> From: news [mailto:news@main.gmane.org] On Behalf Of Leo Simons
>
> What is an appliance?
> ---------------------
> An appliance is a piece of code internal to the container. It
> is used to
> manage one or more related components, including their metadata,
> metainfo
I've tried many times and I *STILL* don't get the difference between
METAINFO and METADATA! Please, can we come up with some other names for
them?
I know that one of them specifies information specific to the
component type, while the other is the component type information
*plus* deployment parameters such as configuration.
Or maybe it was the other way around.
I think metainfo was the type-level information, and metadata
the deployment-time information.
How about:
MetaInfo -> TypeData / ClassData
MetaData -> InstanceData
This would be analogous to the Type/Class/Instance of OOP.
/LS
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: [A4:Fortress/Merlin] Coming to grips with terminology
Posted by Leo Simons <le...@apache.org>.
Stephen McConnell wrote:
> Take a look at the JavaDoc for Appliance at the following URL and let me
> know if it's understandable. Sorry - no pictures just yet. Maybe later.
>
> http://www.osm.net/doc/assembly/api/org/apache/avalon/assembly/appliance/DefaultAppliance.html
short answer: no.
long answer:
"The DefaultAppliance class manages the establishment of a component
type relative to a deployment criteria. Once established, an appliance
provides support for the deployment of component instances..."
and that is just about where I got lost. What I'm looking for is
something like:
=========Readable=Documentation=Sample=Follows===========================
What is an appliance?
---------------------
An appliance is a piece of code internal to the container. It is used to
manage one or more related components, including their metadata,
metainfo, and any other deployment information. It may also do things
like dynamic proxying and pooling.
Any class which implements the Appliance interface can be provided to
the container's Kernel to do component management. It is even possible
to supply the Kernel with different Appliances for different components
and blocks.
(go on about cocoon blocks, phoenix blocks, granularity, ..., available
appliance implementations, etc etc etc etc)
Analogy
-------
Think of yourself as a client in a restaurant. You communicate with the
restaurant through a protocol, usually by uttering some human language
against a waiter. Let's say you order a steak dinner. The waiter
translates your request for food to the chef, who then sets off to
satisfy your request. To do so, he uses lots of different kitchen
appliances, like a microwave or a frying pan.
In this analogy, you are client code, the protocol might be SOAP, the
waiter is a RequestHandler, the chef is the Kernel, and the appliances
we call "appliances" :D The Avalon Components used to create your dinner
include potatoes, cow meat, and a few tomatoes. Appliances are
responsible for management of these components, and they chop, fry, etc,
on Kernel request.
How do I use an appliance?
--------------------------
You normally use an appliance by specifying which class to use in the
kernel.xml file:
<kernel>
<appliance class="foo.bla.MyAppliance"/>
</kernel>
How do I create an appliance?
-----------------------------
Extend AbstractAppliance and override foo() and blah() to customize the
behaviour. Take a look at DefaultAppliance for a simple implementation.
How does the container use an appliance?
----------------------------------------
the appliance is presented with a context containing information on
which components it is to manage, then start()ed. Once running, the
appliance has to respond to 'get( String ROLE )' requests by returning
an instance of a service or service proxy satisfying the ROLE contract.
Typically, the following happens
MyComponent Appliance Container Appliance OtherComponent
| |<-setup---| | |
| |<-start---| | |
| | |--setup->| |
| | |--start->| |
|<-compose-| | | |
| | | | |
|--get()-->|--get()-->|--get()->|-new()->|
| | | | |
|-provide--|-provide--|-provide-| |
| | | | |
|<-dispose-| | | |
| |-release--|-release-| |
| | | |-dispose|
IE, the container sets up the initial appliance on startup. The
appliance happily runs on its own until a component is requested which
it cannot provide itself. The container then finds another appliance
that can provide that particular component, and passes the result on to
the first appliance, which provides it to the component.
When the component is disposed, it no longer needs the service provided,
so the appliance notifies the container, which notifies the appliance,
and the service is released.
=========Readable=Documentation=Sample=Ends==============================
That is somewhat more understandable. I think it is also
wrong....getting an analogy right is real difficult :D It is important
to write docs this way though; it forces you to be real clear about the
contracts imposed, the assumptions made. If the code cannot be
explained, the code is bad code :D
cheers,
- Leo
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: [A4:Fortress/Merlin] Coming to grips with terminology
Posted by Nicola Ken Barozzi <ni...@apache.org>.
Berin Loritsch wrote:
> Again, this is greek to me.
^^^^^^^^
Did you mean /geek/ ;-)
Stephen, I don't understand either. You are too ahead of us in the use
of this terminology, it's like talking about members and ineritance to C
developers... well, al least on the terminology side.
Just forget we are smart and treat us like dumb nuts, and you'll
probably get more real in the explanation.
thanks :-)
--
Nicola Ken Barozzi nicolaken@apache.org
- verba volant, scripta manent -
(discussions get forgotten, just code remains)
---------------------------------------------------------------------
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: [A4:Fortress/Merlin] Coming to grips with terminology
Posted by Berin Loritsch <bl...@apache.org>.
Stephen McConnell wrote:
>
> Take a look at the JavaDoc for Appliance at the following URL and let
me know if it's understandable. Sorry - no pictures just yet. Maybe later.
>
> :-)
>
>
>
http://www.osm.net/doc/assembly/api/org/apache/avalon/assembly/appliance/DefaultAppliance.html
You are packing too much into each sentence. Simplify by building
knowledge one step at a time. The hardest thing for me to learn was
how to go back and bring my readers to where I was. The ASCII text
below will hopefully show what I mean:
--*-------------*------------->
Reader Me Where I want to go
^ ^
+------+------+
|
Gap that needs to be bridged first.
This is the general feeling. Break it down really simple.
From the JavaDoc mentioned:
>
> The DefaultAppliance class manages the establishment of a component
> type relative to a deployment criteria. Once established, an appliance
> provides support for the deployment of component instances on request.
> An appliance is responsible for component lifestyle and lifecycle
> management during the deployment and decommission cycles.
Immediate questions:
Deployment criteria? What is that? How do I control it?
Deployment of component instances is confusing.
From Merrium Webster (http://www.m-w.com):
One entry found for deploy.
Main Entry: de·ploy
Pronunciation: di-'ploi
Function: verb
Etymology: French déployer, literally, to unfold, from Old French
desploier, from des- dis- + ploier, plier to fold -- more at PLY
Date: 1786
transitive senses
1 a : to extend (a military unit) especially in width b : to place in
battle formation or appropriate positions
2 : to spread out, utilize, or arrange especially strategically
intransitive senses : to move in being deployed
- de·ploy·able /-&-b&l/ adjective
- de·ploy·ment /-m&nt/ noun
Definition 2 is the deployment we are speaking of. To me deployment
speaks more of assembly and the process of putting the *whole*
application into service. Deploying a component is the process of
putting it into service--more generally than what you are using it
for.
The last sentence makes no sense at all.
Lifestyle:
Main Entry: life·style
Pronunciation: 'lIf-'stI(&)l, -"stI(&)l
Function: noun
Date: 1939
: the typical way of life of an individual, group, or culture
I.e. in our terminology how the component lives inside the container.
Lifecycle :
Main Entry: life cycle
Function: noun
Date: 1873
1 : the series of stages in form and functional activity through which
an organism passes between successive recurrences of a specified primary
stage
2 : LIFE HISTORY 2
3 : a series of stages through which something (as an individual,
culture, or manufactured product) passes during its lifetime
I.e. how a component is instantiated and destroyed.
I tend to lean toward the appliance doing too much if it cannot be
easily explained. Your docs are saying that the appliance is
responsible for four functions:
Deployment (a container concern)
Decommissioning (a container concern)
Lifecycle
Lifestyle
Lifecycle is constant (or should be), so that can easily be handled
via a Factory like I did with Fortress. Lifestyle is consistent,
which means each lifestyle is handled the same way, like I did with
the ComponentHandler in Fortress.
Deployment and Decommissioning is something that the Fortress
container conserns itself with.
Deployment is the process by which the component is placed into the
list of usable components, the container assembles it or connects it
to other components that need to use it. The Lifecycle and Lifestyle
do not come into play here.
Decommissioning is the opposite process by which the component is
removed from the list of usable components, and the container
unassembles or deconnects it from other components that need to use
it. The process of decommissioning one component may have a waterfall
effect and force the decommissioning of other components.
> The implementation supports the association of possibly multiple
> appliance instances as service providers in accordance with component
> type dependency declarations during assembly. Once assembled, an
> appliance is capable of handling resolve and release requests.
> Components instances returned from the resolve method are guaranteed
> to be fully deployed. Client applications may subsequently release the
> acquired component back to the appliance when no longer needed. The
> appliance implementation will apply appropriate recovery policies
> based on the lifestyle policy associated with the component type.
>
Again, this is greek to me. Take knowledge that is built elsewhere
and use that. In the context of JavaDocs, use the @see tag to point
to where the different terms are originally defined.
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: [A4:Fortress/Merlin] Coming to grips with terminology
Posted by Stephen McConnell <mc...@apache.org>.
Stephen McConnell wrote:
>
>
> Leo Simons wrote:
>
>>> en, I am going to need your help one coming up with the proper
>>> terminology.
>>
>>
>>
>> Hey Steve, you should try and explain the abstractions and
>> decompositions you're arriving at in merlin in the terminology of a
>> high school textbook (well, sort-of), with some pictures, diagrams,
>> and analogies. I'm guessing we'll all be sort-of agreeing much more
>> then.
>>
>> (I just read
>> http://jakarta.apache.org/avalon/excalibur/merlin/dictionary.html
>> again, and it's 90% abracadabra. It feels like corba.org ;))
>
>
>
> OK - hint taken.
> I'll put something together.
Take a look at the JavaDoc for Appliance at the following URL and let me
know if it's understandable. Sorry - no pictures just yet. Maybe later.
:-)
http://www.osm.net/doc/assembly/api/org/apache/avalon/assembly/appliance/DefaultAppliance.html
Cheers, Steve.
>
>
> Cheers, Steve.
>
>
--
Stephen J. McConnell
mailto:mcconnell@apache.org
http://www.osm.net
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: [A4:Fortress/Merlin] Coming to grips with terminology
Posted by Stephen McConnell <mc...@apache.org>.
Leo Simons wrote:
>> en, I am going to need your help one coming up with the proper
>> terminology.
>
>
> Hey Steve, you should try and explain the abstractions and
> decompositions you're arriving at in merlin in the terminology of a
> high school textbook (well, sort-of), with some pictures, diagrams,
> and analogies. I'm guessing we'll all be sort-of agreeing much more then.
>
> (I just read
> http://jakarta.apache.org/avalon/excalibur/merlin/dictionary.html
> again, and it's 90% abracadabra. It feels like corba.org ;))
OK - hint taken.
I'll put something together.
Cheers, Steve.
--
Stephen J. McConnell
mailto:mcconnell@apache.org
http://www.osm.net
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: [A4:Fortress/Merlin] Coming to grips with terminology
Posted by Leo Simons <le...@apache.org>.
Berin Loritsch wrote:
> One of the issues that any Avalon newbie has to come to grips with is
> a new vocabulary. Component Oriented Programming is similar in many
> respects to its OOP cousin, but there are a few terms that need to
> be understood first. One of my concerns with the Merlin effort isn't
> so much the technology, but the overloading of terms and adding
> semantics that don't exist in other contexts.
+1
> We are all very clear on what constitutes a component. We also are
> aware that they interact with a container. The problem is the exact
> definition of the container. I think we need to standardize on what
> we mean by that word, and leverage what is already out there. That
> way we all speak the same language.
+1. Deja-vu feeling here though. You said that before, we talked about
it, nothing came out. How does one put it..."verba volant, scripta
manent"...:D
> Stephen, I am going to need your help one coming up with the proper
> terminology.
Hey Steve, you should try and explain the abstractions and
decompositions you're arriving at in merlin in the terminology of a high
school textbook (well, sort-of), with some pictures, diagrams, and
analogies. I'm guessing we'll all be sort-of agreeing much more then.
(I just read
http://jakarta.apache.org/avalon/excalibur/merlin/dictionary.html again,
and it's 90% abracadabra. It feels like corba.org ;))
cheers,
- Leo
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: [A4:Fortress/Merlin] Coming to grips with terminology
Posted by Berin Loritsch <bl...@apache.org>.
Stephen McConnell wrote:
>
> Berin Loritsch wrote:
>
>> The Merlin project adds two more terms and overloads the meaning of a
>> third:
>>
>> Container (overloaded meaning), Block, and Appliance
>
>
>
>
> I disagree on the "overloaded" - see below.
>
> :-)
The description I had of what I understood came from "overhearing" your
conversations with others on the list.
>> In essence my understanding is that Merlin places the distinction
>> between the container which only manages the component implementation
>> mappings (or assembly), and the appliance which only manages the
>> component instances. I am not sure exactly what the block is.
>
>
>
> I'm completely ok with the above definition. Relative to what exists
in Avalon I would class Fortress, Merlin and Phoenix as containers. The
all share the common characteristic of managing component instances.
So the "appliance" is merely an internal construct to a container?
> Looking inside-out:
>
> The Fortress DefaultContainer provides the developer with access
> to ComponentHandlers. This is sort of parallel with the Merlin
> DefaultContainer in that an implementation can access Appliance
> instances.
>
> In Fortress / ComponentHander
>
> Object get();
> void put( Object object );
>
> In Assembly / Appliance
>
> Object resolve( Object partition);
> void release( Object object, Object partition );
Ok.
> In Fortress a component handler is dedicated to a particular
> lifestyle whereas the Appliance class encapsulates a lifestyle
> handler based on meta data. The Fortress component manager
> uses a factory object that implements the classic Avalon
> lifecycle stages. Appliance lifecycle management is a little
> different in that the component type can declare alternative
> lifecycle strategies (i.e. non-Avalon approaches). Another
> important difference is that the Appliance pre-builds context
> and service managers based on (a) dependencies declared in meta
> information, using (b) a repository of appliance instances when
> populating service mangers and context instances. Both Fortress
> and Merlin use the respective ComponentHandler/Appliance
> instances within a service manager (enabling activation on
> demand). Merlin also the same approach inside context objects.
>
> Conclusion:
>
> ComponentHandler is the equivalent abstract to Appliance.
I see. So if Fortress were to be incorporated into Merlin,
it would have to be a Container and you lose whatever benefit
you had with the Appliance.
Of course, in the codename Merlin release of Avalon container,
we could adjust the Fortress container to use Appliances instead
of ComponentHandlers
> This separation is demonstrated by the fact that you manage
> component establishment using only the Assembly package. I.e.
> the Assembly package is an API supporting component
> establishment.
I thought it was a package supporting component declaration. IOW,
the meta info/data is declarative and the container interprets it.
IMO that is the best model. Isn't that how the Assembly package
relates?
> When we compare the Fortress Container and Merlin Container we
> need to introduce the notion of a Block. A Block is specialized
> appliance that manages a component type called Container. This
> is similar to relationship between the Fortress ContainerManager
> and Container. However, there is an important distinction between
> Fortress and Merlin at this point - while specialization of
> DefaultContainer in Fortress and Merlin are for all practical
> purposed equivalent, the Block abstract considers a container to
> be nothing more than the implementation mechanisms through which
> a set of services are established.
Let me try to rephrase that and see if I "got it".
A Block is approximately like the ContainerManager (itself a special
purpose container that manages one service [the container itself]).
In Fortress the ContainerManager can be used within a container,
and as such it is recursive.
I am still not clear on the distinction. The ContainerManager
has some knowledge about what services the container will need
to operate. Are you saying that the Block makes no assumption,
and uses meta data to find out what the container needs? Is
that the distinction?
> For example - consider the James block. It is a container of a
> bunch of different components (mail store, user store, thread
> manager, DNS server, POP server, SMTP server, etc.). However, the
> actually services that a James Block can publish to other components
> will be quite different (perhaps the dynamic addition of a mailet,
> suspend/resume reconfigure functionality, etc.). This ability is
> described by the block, acting in the role of a component.
>
> Conclusion:
>
> Fortress / Container is the equivalent abstract to the Merlin
> Container.
>
> Block is a composite component.
Block is an abstract representing a component collection? Or
Block is an abstraction representing a mechanism by which we can
expose services to a higher level?
>> Stephen, I am going to need your help one coming up with the proper
>> terminology. I am not against the separation of the two functionalities
>> of the container (i.e. assembly and instance management), but I am
>> against the redefinition of container--which will only server to
>> confuse people.
>
>
>
> I would rephrase the seperation - mainly because the word assembly
can be used on both sides (to assemble versus an assembly). I think we
have three main areas of functionality: meta management; deployment and
decommissioning; and the management of a containerment context.
Ok, I will concede that there is no real distinction in our concepts of
"container. However now we have a new distinction here that you
introduced. The container is responsible for the assembly, which means
it needs to assemble by inference. One is the final product, and the
other is the action used to get there. By simple logic, if a Container
needs an assembly, it needs to assemble the component mappings. Whether
it hands that off to a library to take care of the nitty gritty details
or not is irrelevant--the container initiates the assembly process and
uses the product of that assembly process.
>> If we are going to separate the concepts, we need to come up with a
>> new name to express the assembly contract.
>>
>> The only plausible definition I can think of for a Block is a
>> component that also behaves as an embeded container (traditional).
>> Hense a Block can be recursive.
>
>
> I think the Cocoon documentation of Block functional requirements is
> the best reference. The above information is more about "block" as a
> computational approach to encapsulation of a composite component model
> as the implementation solution to service provision.
>
> I'm sure I'm probably raising more questions than answers - sorry about
> that but I'm also trying to factor into my thinking the possible areas
> where we can synchronize Fortress/Merlin before releasing Fortress.
That's fine. We can put all our definitions in a document and use them
consistently. I want to get away from artificial distinctions or words
that are so close together yet have a different connotation. IOW I want
us to simplify our language set.
> * Appliance & ApplianceContext <-----> ComponentHandler
>
> First step could be seperation out the Reclaimable
> interface and use this on both Appliance and Component
> Handler.
> Further convergence is possible by building meta
> information based on roles and conf information and
> then evolving ComponentManager towards Appliance.
Right. I had started that when I had time, and then I didn't have time
anymore.
> * DefaultContainer <-----> DefaultContainer
>
> There are some immediate things that could be done here
> such as a common approach to contextualization of the
> container and using the same lookup keys. This would
> eliminate the need to expose all of those protected state
> members. I also think (with some help from yourself) that
> we could update the event model on the Merlin container
> to bring it in line with the Fortress approach.
Right. Managing things in the background makes it so much easier
to reduce the overhead associated with component based design.
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: [A4:Fortress/Merlin] Coming to grips with terminology
Posted by Stephen McConnell <mc...@apache.org>.
Berin Loritsch wrote:
> One of the issues that any Avalon newbie has to come to grips with is
> a new vocabulary. Component Oriented Programming is similar in many
> respects to its OOP cousin, but there are a few terms that need to
> be understood first. One of my concerns with the Merlin effort isn't
> so much the technology, but the overloading of terms and adding
> semantics that don't exist in other contexts.
>
> We are all very clear on what constitutes a component. We also are
> aware that they interact with a container. The problem is the exact
> definition of the container. I think we need to standardize on what
> we mean by that word, and leverage what is already out there. That
> way we all speak the same language.
>
> Everywhere I have looked regarding component systems defines containers
> very broadly as:
>
> * the code or server that manages component instances and component
> implementation mappings.
>
> The exact text changes, but the concept is still the same. In fact
> that is the rough definition I run off of. In other words, a container
> not only controls the component instances, but it also controls what
> we call the "assembly".
>
> The Merlin project adds two more terms and overloads the meaning of a
> third:
>
> Container (overloaded meaning), Block, and Appliance
I disagree on the "overloaded" - see below.
:-)
>
>
> In essence my understanding is that Merlin places the distinction
> between the container which only manages the component implementation
> mappings (or assembly), and the appliance which only manages the
> component instances. I am not sure exactly what the block is.
I'm completely ok with the above definition. Relative to what exists in
Avalon I would class Fortress, Merlin and Phoenix as containers. The
all share the common characteristic of managing component instances.
Looking inside-out:
The Fortress DefaultContainer provides the developer with access
to ComponentHandlers. This is sort of parallel with the Merlin
DefaultContainer in that an implementation can access Appliance
instances.
In Fortress / ComponentHander
Object get();
void put( Object object );
In Assembly / Appliance
Object resolve( Object partition);
void release( Object object, Object partition );
In Fortress a component handler is dedicated to a particular
lifestyle whereas the Appliance class encapsulates a lifestyle
handler based on meta data. The Fortress component manager
uses a factory object that implements the classic Avalon
lifecycle stages. Appliance lifecycle management is a little
different in that the component type can declare alternative
lifecycle strategies (i.e. non-Avalon approaches). Another
important difference is that the Appliance pre-builds context
and service managers based on (a) dependencies declared in meta
information, using (b) a repository of appliance instances when
populating service mangers and context instances. Both Fortress
and Merlin use the respective ComponentHandler/Appliance
instances within a service manager (enabling activation on
demand). Merlin also the same approach inside context objects.
Conclusion:
ComponentHandler is the equivalent abstract to Appliance.
Most of the content in Fortress is dealing with the above and
can be compared (generally speaking) with the Assembly package.
When we at the remaining classes in Fortress we are left with
the Container abstraction. In effect the handler and lifecycle
packages are simply the mechanisms used to provide containment
functionality. This is similar in Merlin - the Assembly package
handles the concerns related to lifecycle, lifestyle, etc. and
the abstract concerning "containment" is separated out into the
Merlin package.
This separation is demonstrated by the fact that you manage
component establishment using only the Assembly package. I.e.
the Assembly package is an API supporting component
establishment.
When we compare the Fortress Container and Merlin Container we
need to introduce the notion of a Block. A Block is specialized
appliance that manages a component type called Container. This
is similar to relationship between the Fortress ContainerManager
and Container. However, there is an important distinction between
Fortress and Merlin at this point - while specialization of
DefaultContainer in Fortress and Merlin are for all practical
purposed equivalent, the Block abstract considers a container to
be nothing more than the implementation mechanisms through which
a set of services are established.
Block provides the bridge between published services and an
implementation strategy that happens to be based on a container
hierarchy. This bridge enables a complete approach to composition
in that service and dependencies published by a block are the
dynamic equivalent of a classic component.
For example - consider the James block. It is a container of a
bunch of different components (mail store, user store, thread
manager, DNS server, POP server, SMTP server, etc.). However, the
actually services that a James Block can publish to other components
will be quite different (perhaps the dynamic addition of a mailet,
suspend/resume reconfigure functionality, etc.). This ability is
described by the block, acting in the role of a component.
Conclusion:
Fortress / Container is the equivalent abstract to the Merlin
Container.
Block is a composite component.
>
> Stephen, I am going to need your help one coming up with the proper
> terminology. I am not against the separation of the two functionalities
> of the container (i.e. assembly and instance management), but I am
> against the redefinition of container--which will only server to
> confuse people.
I would rephrase the seperation - mainly because the word assembly can
be used on both sides (to assemble versus an assembly). I think we have
three main areas of functionality: meta management; deployment and
decommissioning; and the management of a containerment context.
* support for *meta* management
- management of information about a component *type*
- management of information about a component *profile* or
(templates)
- management of a *registry* of deployment candidates (type and
deployment *criteria* - e.g. roles and xconf)
- candidate *establishment* and *termination*
- the ability to *assemble* and *disassemble* candidates
* the ability to support *deployment* and *decommissioning* of
component instances
- *sequence* management
- *lifestyle* management
- *lifecycle* management
* and management of the *containment-context*
- component isolation
- management localization
>
> In essence, the traditional container as described in all texts that I
> have read is the combination of a Merlin container and an Appliance.
I agree.
> If we are going to separate the concepts, we need to come up with a
> new name to express the assembly contract.
>
> The only plausible definition I can think of for a Block is a
> component that also behaves as an embeded container (traditional).
> Hense a Block can be recursive.
I think the Cocoon documentation of Block functional requirements is
the best reference. The above information is more about "block" as a
computational approach to encapsulation of a composite component model
as the implementation solution to service provision.
I'm sure I'm probably raising more questions than answers - sorry about
that but I'm also trying to factor into my thinking the possible areas
where we can synchronize Fortress/Merlin before releasing Fortress.
* Appliance & ApplianceContext <-----> ComponentHandler
First step could be seperation out the Reclaimable
interface and use this on both Appliance and Component
Handler.
Further convergence is possible by building meta
information based on roles and conf information and
then evolving ComponentManager towards Appliance.
* DefaultContainer <-----> DefaultContainer
There are some immediate things that could be done here
such as a common approach to contextualization of the
container and using the same lookup keys. This would
eliminate the need to expose all of those protected state
members. I also think (with some help from yourself) that
we could update the event model on the Merlin container
to bring it in line with the Fortress approach.
Cheers, Steve.
--
Stephen J. McConnell
mailto:mcconnell@apache.org
http://www.osm.net
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>