cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Berin Loritsch <blorit...@apache.org>
Subject Bundles/Blocks
Date Wed, 14 May 2003 16:28:04 GMT
I am throwing together some API stuff for managing distributables,
which I am calling Bundles.  They are somewhere in between .NET
assemblies and MacOS Bundles.

To really make it work, there are two major concepts to work with:

* Bundles (the actual distributable)
* Partitions (logical boundaries within an application)

Each Partition defines a classloader where all the classes of the
bundles can be loaded from.  It also provides one location to
grab your ResourceBundle (i.e. your internationalization stuff).
The idea is that for things like Cocoon, you can define a set
of partitions (a partition map if you will) which reference a
set of bundles.  The bundles have a unique name, and the same
distributable may be used in different partitions.  The partitions
would be isolated from each other.

Also of importance is the difference in the way partitions relate
and the way bundles relate.  Partitions are hierarchical, so you
can nest partitions inside of each other.  Every application would
have a root partition (which is where the central Cocoon/GUIApp/
whateverApp would be loaded).  Below that would be the partitions
that were either programatically defined or declared in a config
file.  Bundles refer to each other, but it is up to the partition
to satisfy that reference.  If a partition cannot satisfy all the
references, then it will throw an exception.

The API would provide for circular dependency checking, and prepare
an order for loading/unloading bundles.  Each bundle will have
a "manifest", or a list of all entries and locales supported by the
bundle.  This will allow any one partition to refresh itself on
demand and use the new bundles.

The basic definition of a Bundle is a specialized JAR file that
follows some standards.  To help with those standards, there will
be a BundleBuilder to help assemble them programatically--which
helps in instances where we might need dynamic bundles, as well
as building tools (ANT integration, etc.).

I am wanting to see if this satisfies the Cocoon and general Avalon
needs.


Mime
View raw message