<<

NAME

Inca::Config::Suite - Utility class for dealing with Inca suites

SYNOPSIS

  use Inca::Config::Suite;
  my $suite = new Inca::Config::Suite();
  $suite->read( "suite.xml" );
  my @scs = $suite->getSeriesConfigs();

DESCRIPTION

An Inca suite is a request to change (i.e., add or delete) the data collection on a resource. It is an XML document that contains a list of seriesConfigs. Each seriesConfig contains an action (add or delete), a scheduler, and a reporter. For each reporter, there is a name, version, context, and an optional list of input arguments, limits, and execution priority.

CLASS METHODS

new( )

Class constructor which returns a new Inca::Config::Suite object.

addSeriesConfig( $sc )

Add the specified series configs to the suite.

Arguments:

sc

An object of type Inca::Config::Suite::SeriesConfig.

getGuid( )

Return the guid of the suite.

Returns:

A string containing the guid of the suite.

getSeriesConfigs( )

Return the list of series configs in the suite.

Returns:

An array of Inca::Config::Suite::SeriesConfig objects.

getXmlHashArray( )

Return a hash array representation of the suite object that is appropriate for incorporating into a larger hash array that will be formatted into XML by XML::Simple.

Returns:

A hash array representation of the suite object.

read( $file )

Read an Inca suite file into the object. The suite is structured as follows:

<suite> <seriesConfig> <!-- see Inca::Config::Suite::SeriesConfig for content here --> </reporterGroup> ... </suite>

Arguments:

xmlorFile

A string containing Inca suite xml or a path to an XML file containing an Inca suite

Returns:

Returns 1 if there are no errors reading the suite file; otherwise returns 0.

resolveReporters( $rc, $uri )

Look up the existing reporters listed in this suite and locate their local copies. Set the path attribute and resolve context.

Arguments:

rc

A reference to a Inca::ReporterManager::ReporterCache object to look up local reporter copies.

uri

A string containing the uri for the reporter instance manager to contact to request proxy information in order to retrieve a proxy credential for reporter execution.

setGuid( $guid )

Set the guid of the suite.

Arguments:

guid

A string indicating the guid of the suite: inca[s]://host:port/suiteName

write( $filename )

Write an suite object to file following the suite schema

Arguments:

filename

A string containing a path to an file to which the Inca suite XML will be written to.

AUTHOR

Shava Smallen <ssmallen@sdsc.edu>

CAVEATS/WARNINGS

No known problems.

SEE ALSO

Inca::Config::Suite::SeriesConfig

<<