avalon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Leo Simons" <m...@leosimons.com>
Subject RE: is there a set of documentatio for Avalon
Date Fri, 27 Apr 2001 20:51:08 GMT
> hi all,

hi Joseph! Welcome to Avalon ;)

> I am trying do a study on the Avalon Framework, but couldn't find
> any design
> documentation or Object diagram, same goes for Pheonix. All I
> could find on
> the web is links to Pattern designs, guidelines, etc. But without
> an general
> overview of what Avalon/Pheonix is, I am totally lost and don't know where
> to start from.

This is a problem; we're currently working on fixing the documents.
Well, I am =) ... you might want to look at the jakarta-avalon
cvs tree for an update on the framework docs (simply do checkout
and then run "./build dist" from the checkout dir).

> I would greatly appreciate if any of you can direct me to the relevant
> documents.

Will do that once they're written :-)

I had the same problem a while back. The smartest thing to do (probably)
is to take a look at the classes/api docs for
org.apache.cornerstone.demos. Also, you might find the following
overview (relevant to the 3.1a1 release; some of it is quite out-of-date
atm) useful (it is what I wrote after delving into the source):

 ---------------------------------------------------------------------
The Kernel
----------
org.apache.phoenix.engine.Main starts by parsing the command line
arguments using org.apache.avalon.util.cli.*. It creates an
instance of org.apache.phoenix.engine.DefaultKernel. It then creates
a deployer using org.apache.avalon.camelot.*.

	Camelot is a generic engine that can be used to deploy
	and undeploy java applications. This includes .war, .ear,
	.jar, .bar, or .sar files, or directory structures
	that follow the guidelines for these files.

The deployer used is org.apache.phoenix.engine.DefaultSarDeployer,
which unpacks the .sar file, and adds the contained server
to the kernel context. The server is configured using
org.apache.avalon.DefaultConfigurationBuilder (which is fed
the xml files in conf/).

When the deployer is done, the kernel is initialised and started.
The kernel extends org.apache.avalon.camelot.AbstractContainer,
which method it uses to get the
org.apache.avalon.phoenix.engine.ServerApplication s. These are
first 'prepared' and then started. The ServerApplication used is
org.apache.avalon.phoenix.engine.DefaultServerApplication, which
uses a ClassLoader to load all the classes in the various
.bars, .jars and .zips from the .sar files.
After instances of each block are created, they're fed to a
PipeLineRunner, which takes care of going through the various
Stage s using org.apache.avalon.utils.pipeline.*.

	A pipeline is a simple list of "stages". Each of these has a
	process() method which gets called when the pipeline gets to
	that stage.

After a PipeLineRunner is created, a ThreadManager (from
org.apache.avalon.utils.thread.*) is fed this runner, and
a new WorkerThread is created which is execute()ed which
finally calls Thread.notify(). This means all process()
methods of all Stage s in the Pipeline are called.

When all PipeLineRunners are finished, the kernel
is shut down and phoenix exits.

The Blocks of a ServerApplication will usually contain
some kind of java.net.ServerSocket that listens to a port
defined in the assembly.xml file.
 ---------------------------------------------------------------------

note that it is not neccessary at all to understand how phoenix/
the framework works to write perfectly compatible applications
using them.
final comment: when you can't figure things out, just ask!

> Thanks in advance.

anytime!

cheers,

LSD

<java:sig>
	About LSD  = new PersonalInfo();
	LSD.name("Leo Simons");
	LSD.email("mail@leosimons.com");
	LSD.URL( [
		http://www.leosimons.com, // personal website
		http://www.atfantasy.com, // fantasy RPG portal
		http://www.the-sign.nl    // web-design company
	] );
	LSD.quote("Buh!");
	email.setSig((String)LSD);
</java:sig>


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


Mime
View raw message