Component Reader (Buckminster)

From Eclipsepedia

Jump to: navigation, search

< To: Buckminster Project

Contents

Component Reader

A Component Reader is a technical adapter for a component respository (such as CVS, Subversion, FTP, filesystem, etc.). It can enumerate component branches and/or tags for a component request, and it can read individual files, and materialize component contents for a Version Selector.

A reader will typically be an adapter for a specific type of source code control system such as CVS, Subversion, Perforce, or ClearCase but it can also be an adapter for Maven repositories, FTP archives, or software that is installed on disk. One example of the latter is the "eclipse-installed" reader that will connect to components (in this case - features, plug-ins, and fragments) that are available in the Eclipse runtime.

The separation of concern between the ComponentType and ComponentReader is important as this provides a degree of freedom between how the content of the component is organized and dependencies gets created and how the content is read. Simple specify the mix you want in the RMAP.

Naturally, an important part of the reader functionality is to connect to the wanted version of the component. A URI points to the repository of one or many versions of the component, the name of the component is needed, and finally the original plain version string (like "4.5.2" or "titanic-27b") interpreted by a Version Type and translated by a Version Converter into a Version Selector such as "3.1.0/LATEST" depending on policies determined by the component owner.

Conceptually, the Component Reader normalizes across all repositories, but as a user you need to know how the component versioning is layed out in terms of branches, tags, etc. You control this with the specification of a VersionConverter in the RMAP.

Available Component Readers

In the list below, you find the available component readers. For information about how they work, and how to use them, you need to visit the respective articles.

Available Component Readers
Reader Comment
cvs

The CVS Component Reader can read a CVS repository. It is integrated with the Eclipse CVS functionality.

eclipse.platform

The eclipse.platform Component Reader reads information from the target platform (most commonly your installed features and plugins).

eclipse.import

The eclipse.import Component Reader can import features and plugins from your platform or an arbitrary site and make them projects in your workspace.

maven
maven2
The maven Component Reader is based on the url.catalog reader that lists all available jar-files in a directory to determine best version. Extended with functionality that maps component names to the maven specific groupId and artifactId.
p4

The p4 Component Reader reads Perforce repositories. It will make the commercial plugin P4WSAD from Perforce.com aware of bound components if it is present, but P4WSAD is not required.

svn

The SVN Component Reader reads Subversion repositories. It relies on the headless part of the Subclipse plugin.

url

The url Component Reader reads one single file appointed by an URL (typically a jar, dll, or other pre-compiled artifact). The file is treated as a component in its own right.

url.catalog

The url.catalog Component Reader reads files from a specific catalog (folder) appointed by an URL. The reader must have browse permissions in order for this reader to function. The reader will parse generated page content in order to list the folder contents when http or ftp protocol is used. Only file, http, and ftp are supported.

url.zipped

The url.zipped Component Reader reads individual files from a zip archive appointed by an URL during the resolvement phase. Materialization will typically involve unzipping the whole archive.

Additional readers might also be listed at the buckminster language reference page.

If you are looking for a reader for a repository not listed here, please check out the Buckminster Plugin Directory, and if not found there, add it to the Buckminster Wish List, and hope that others are also interested.

Readers for non versioned artifacts

A component reader that connects to an non versioned artifact will only understand the Version Selector notation "<default branch>/LATEST".

Extending Component Readers

New types of component readers can be added using the Buckminster Extension Point org.eclipse.buckminster.core.readerTypes.