DiGIR Schema Readme

Explanation, Usage, and Tips

$Id: schemaReadme.html,v 1.2 2003/04/25 02:03:15 peejinator Exp $

DiGIR request and response formats are specified via a number of XML Schema documents. The primary structure of a request or response is specified in the protocol XML Schema (digir.xsd). For the latest version(s) see:

http://digir.sourceforge.net/schema/protocol

The available data elements, and their types, for searching and returning in a request or response are specified in a conceptual (or content) schema. A current conceptual schema and excellent example is that representing the Darwin Core V2 dataset (darwin2.xsd). For the latest version(s) see:

http://digir.sourceforge.net/schema/conceptual/darwin

Additionally, predefined record structures for responses can be defined and some examples of such (brief and full) can be found in subdirectories of the above location.

Understanding the DiGIR Schema

The DiGIR schema involved makes use of a variety of XML Schema offerings. Lets take a look at some of the less straightforward techniques here:

Using the DiGIR Schema to create a Conceptual (content) schema

Given how the protocol schema is defined, it is necessary that all conceptual schema adhere to certain techniques of definition. Here are some tips on creating a conceptual schema for use with the DiGIR protocal.

DiGIR Namespaces

The DiGIR namespace naming convention follows that of the w3c. The protocol schema namespaces are assigned as follows:

http://digir.net/schema/protocol/year/version

For example:

http://digir.net/schema/protocol/2003/1.0

To be consistant, many generating conceptual schemas have followed the same convention. It is important to note that although the namespaces look like URLs, they do not (nor are they required to) necessarily indicate the physical location of the schema file. At the time of writing this document, the protocol schema is stored under sourceforge and the namespace location to be used in referring documents is:

http://digir.sourceforge.net/schema/protocol/2003/1.0/digir.xsd

Understanding DiGIR Information Domains

An addition to the DiGIR protocol has been Information Domains. An Information Domain is intended to link together related schemas for the purposes of application configuration. For example, the Darwin Core version 2 folks also specify two predefined result set schemas as well as some other default information. In order to universally associate these various schemas and values, an Information Domain schema was created as an addition to the protocol schema. Information Domains are commonly referred to simply as infodos. The schema for an infodo is currently available here:

http://digir.sourceforge.net/schema/protocol/2003/1.0/infodo.xsd

As an example, please see the Darwin Core 2 infodo instance available here:

http://digir.sourceforge.net/schema/conceptual/darwin/2003/1.0/darwin2Infodo.xml

Schema Versioning Process

When dealing with any evolving specification, it is important to appropriately version it. Giving the distributed nature of this project, a clear process should be followed. The suggested process is:
  1. Use the DiGIR CVS repository on the SourceForge site. The schema documents, for both the protocal and conceptual schemas, as well as some examples, are in the xml module in CVS. All edits to a schema should be done via a checked out version of the document and commits should be done regularly. It is not recommended that you keep a document out with changes for an extended period of time as that can introduce conflicts in a multi-developer environment.
  2. Once you are satisfied with you changes and they have been tested, you are ready to "release" the schema. After the schema(s) are committed to CVS, you should tag (via cvs tag) the schema, as well as any dependant schemas with the release name (e.g. beta1, r1_0, etc.). All dependant schemas should use the same tag. Because of cvs restrictions (e.g. tags must start with a letter and cannot contain a ".", 1.0 will be tagged as r1_0.
  3. After tagging the files, create a directory with the name of the release version (e.g. beta1, 1.0, etc.) in the htdocs (webspace) area of the DiGIR SourceForge site under the appropriate directory. The directory structure also contains a year and follows the namespace paradigm. For example, protocol/schema/2003/1.0 and conceptual/darwin/2003/1.0.
  4. Then scp (secure copy) the same versions of the schema(s) to this(these) new directory(ies). Here, snapshots of all released version will reside. This location acts as, and should be used in other schema or instance documents, as the schemaLocation. You should not remove previous versions of the schemas as other people may still be referencing them.