| perfSONAR_PS-Services-Daemon documentation | view source | Contained in the perfSONAR_PS-Services-Daemon distribution. |
perfSONAR_PS::Services::Echo - A simple module that implements perfSONAR echo functionality.
This module aims to provide a request handler that is compatible with the perfSONAR echo specification.
$handler->registerEventHandler("EchoRequest", "http://schemas.perfsonar.net/tools/admin/echo/2.0", $self);
$handler->registerEventHandler("EchoRequest", "http://schemas.perfsonar.net/tools/admin/echo/ls/2.0", $self);
$handler->registerEventHandler("EchoRequest", "http://schemas.perfsonar.net/tools/admin/echo/ma/2.0", $self);
$handler->registerEventHandler_Regex("EchoRequest", "^echo.*", $self);
$handler->registerEventEquivalence("EchoRequest", "echo.ma", "http://schemas.perfsonar.net/tools/admin/echo/2.0");
$handler->registerEventEquivalence("EchoRequest", "echo.ma", "http://schemas.perfsonar.net/tools/admin/echo/ma/2.0");
$handler->registerEventEquivalence("EchoRequest", "echo.ma", "http://schemas.perfsonar.net/tools/admin/echo/ls/2.0");
return 0;
}
return 0; }
$logger->warn("Can't register an echo handler with an LS");
return -1;
}
my $output = $parameters->{"output"};
my $messageId = $parameters->{"messageId"};
my $messageType = $parameters->{"messageType"};
my $message_parameters = $parameters->{"messageParameters"};
my $eventType = $parameters->{"eventType"};
my $d = $parameters->{"data"};
my $raw_request = $parameters->{"rawRequest"};
my @subjects = @{ $parameters->{'subject'} };
my $md = $subjects[0];
my $mdID = "metadata.".genuid();
my $msg = "The echo request has passed.";
getResultCodeMetadata($output, $mdID, $md->getAttribute("id"), "success.echo");
getResultCodeData($output, "data.".genuid(), $mdID, $msg, 1);
return;
}
1;
__END__ =head1 SEE ALSO
perfSONAR_PS::Services::Base, perfSONAR_PS::Common, perfSONAR_PS::Messages, perfSONAR_PS::RequestHandler
To join the 'perfSONAR-PS' mailing list, please visit:
https://mail.internet2.edu/wws/info/i2-perfsonar
The perfSONAR-PS subversion repository is located at:
https://svn.internet2.edu/svn/perfSONAR-PS
Questions and comments can be directed to the author, or the mailing list.
$Id:$
Aaron Brown, aaron@internet2.edu
You should have received a copy of the Internet2 Intellectual Property Framework along with this software. If not, see <http://www.internet2.edu/membership/ip.html>
Copyright (c) 2004-2007, Internet2 and the University of Delaware
All rights reserved.
| perfSONAR_PS-Services-Daemon documentation | view source | Contained in the perfSONAR_PS-Services-Daemon distribution. |