Activity - xmlCollectionManagement
Activity Type: XML
Description
Run collection management operations on XMLDB data resources. The
following operations are supported:
- Create new collections.
- Remove existing collections.
- List existing collections.
Examples
<xmlCollectionManagement name="statement">
<collection>musicians</collection>
<createCollection name="folksingers"/>
<outputStream name="statementOutput"/>
</xmlCollectionManagement>
<xmlCollectionManagement name="statement">
<removeCollection name="jazzsingers"/>;
<outputStream name="statementOutput"/>
</xmlCollectionManagement>
<xmlCollectionManagement name="statement">
<<listCollections/>
<outputStream name="statementOutput"/>
</xmlCollectionManagement>
Specification
Element xmlCollectionManagement:
-
Attribute name - unique name for the
activity.
-
Element collection (zero or one) - contains
the name of the collection that the operations will be performed on.
-
Relative to the data resource's base collection.
-
For example, if a data resource is configured for the db/littleblackbook collection then the above
example would perform the operations on the db/littleblackbook/musicians collection.
-
If this element is omitted then the operations will be performed
on the base collection for the data resource, e.g. db/littleblackbook.
-
One of three operation elements:
-
Element createCollection - create a new collection.
-
Attribute name - name for new collection,
unique within the current collection.
-
Element listCollections - list the immediate
sub-collections of the current collection.
-
Element removeCollection - remove an existing
collection.
-
Attribute name - name of the collection.
-
outputStream (required) - output
stream.
-
Attribute name - name of the activity's output
stream.
XML Schema
OGSA-DAI/schema/ogsadai/xsd/activities/xml_collection_management.xsd
Implementation
OGSA-DAI/src/java/activities/uk/org/ogsadai/activity/xmldb/XMLCollectionManagementActivity.java