The Web Graph Database


Anatomy of a StandardModule


Any Module, regardless whether it is a StandardModule or a ModelModule, is distributed in two parts:

The ModuleAdvertisement tends to be small and thus can be downloaded very quickly, while the JAR is often orders of magnitude larger. By allowing independent download of the ModuleAdvertisement, it becomes more viable to implement software architectures in which applications can dynamically evaluate Modules on the network for possible use during the current application run. InfoGrid originally implemented this architecture to enable Java WebStart-based rich client applications to learn about, and possibly add, additional available Modules at run-time.


The ModuleAdvertisement of a StandardModule is defined in XML by the developer.

Here is an example:

 <username>JEE/REST support for InfoGrid.</username>
 <userdescription>Makes developing REST-ful applications with InfoGrid easier.</userdescription>
  <requires name="org.infogrid.jee"/>
  <requires name="org.infogrid.kernel"/>
  <requires name="org.infogrid.util"/>

The fields have the following meaning:

name the computable name of the StandardModule
username the internationalizable name of the StandardModule that should be shown to a human user
userdescription the internationalizable description of the StandardModule that should be shown to a human user
provides section listing the JAR files the StandardModule uses
jar lists the name of one of the StandardModule's JAR files. By convention, it is named after the StandardModule's name with a .jar extension
dependencies section listing dependencies of this StandardModule on other StandardModules or ModelModules
requires one dependency on another Module. The name of the required Module is required.

As part of the default build process:

  • the ModuleAdvertisement is exported not using the generic module.adv name that is used by developers to define it, but using the name of the StandardModule and potentially a version identifier with a .adv extension. In the example above, this would be
  • the XML form of the ModuleAdvertisement is translated in a more efficient form using Java object serialization. This is an alternate form of the ModuleAdvertisement, named
  • both forms are also included in the Module's JAR file at location infogrid-moduleads/.

See also:

Last modified 9 years ago Last modified on 07/17/09 19:15:58