Right now we have two ways of determining all the components and
services,
other than the ECM brute force way. Either using the Manifest, or using
a couple of XML files. Honestly, either way is perfectly fine with me,
as long as we are consistent and provide the proper tools.
I have a couple of questions nonetheless. #1 Can we standardize? #2
How do we determine a new set of components? Let me break out the two
questions in more detail below:
#1 Can we standardize?
If we use the Manifest file, then I would like to have entries like
this:
Avalon-Type: Service|Component|Extension|ExtensionHandler
That way we know if we are dealing with an interface (Service), an
implementation (Component), and extension marker class (Extension),
or an extension handler (aka Creator or Accessor) class
(ExtensionHandler).
If we use an XML file, can we limit ourselves to only one? XML is very
flexible, and I would not mind having something like this:
<avalon-types>
<service interface="org.apache.infomover.input.Input"/>
<component class="org.apache.infomover.input.DelimitedStreamInput"/>
<component class="org.apache.infomover.input.CSVStreamInput"/>
<service interface="org.apache.infomover.output.Output"/>
<component class="org.apache.infomover.output.DelimitedStreamOutput"/>
<component class="org.apache.infomover.output.CSVStreamOutput"/>
<extension
interface="org.apache.excalibur.instrument.Instrumentable"/>
<extension-handler
class="org.apache.excalibur.conatiner.InstrumentCreator"/>
</avalon-types>
That would be enough for us to gather everything we need just like the
Manifest entries.
#2 How do we determine a new set of components?
The root container can scan everything in
System.getProperty("java.class.path");
to determine if there are any components/etc. in any of the jars in the
classpath. However, it is unclear about any child containers. If a
container
manages its own classloader, everything is happy. If it uses the
classloader
that it was given, then we are SOL. How do we know what is new? How do
we
find the new services, etc. that were loaded after the system is up and
running?
Think of the Cocoon case where we aren't necessarily loading new
components
(although it is possible), but we are managing new role mappings. All
the
classes have been loaded by the Servlet engine, so it is a question of
either
preknowing the classes, or pulling them from a configuration file. If
we
had something along the lines of a Jar specification for Avalon
components,
we need to be able to get at any specific entry, or easily merge them
all....
Hopefully I am making some sense here.
"They that give up essential liberty to obtain a little temporary safety
deserve neither liberty nor safety."
- Benjamin Franklin
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>