fractional-replication_cleanup.xml revision 4865
4865N/A<?xml version="1.0" encoding="UTF-8" standalone="no"?>
4865N/A<!DOCTYPE stax SYSTEM "/shared/stax.dtd">
4865N/A<!--
4865N/A ! CDDL HEADER START
4865N/A !
4865N/A ! The contents of this file are subject to the terms of the
4865N/A ! Common Development and Distribution License, Version 1.0 only
4865N/A ! (the "License"). You may not use this file except in compliance
4865N/A ! with the License.
4865N/A !
4865N/A ! You can obtain a copy of the license at
4865N/A ! trunk/opends/resource/legal-notices/OpenDS.LICENSE
4865N/A ! or https://OpenDS.dev.java.net/OpenDS.LICENSE.
4865N/A ! See the License for the specific language governing permissions
4865N/A ! and limitations under the License.
4865N/A !
4865N/A ! When distributing Covered Code, include this CDDL HEADER in each
4865N/A ! file and include the License file at
4865N/A ! trunk/opends/resource/legal-notices/OpenDS.LICENSE. If applicable,
4865N/A ! add the following below this CDDL HEADER, with the fields enclosed
4865N/A ! by brackets "[]" replaced with your own identifying information:
4865N/A ! Portions Copyright [yyyy] [name of copyright owner]
4865N/A !
4865N/A ! CDDL HEADER END
4865N/A !
4865N/A ! Copyright 2009 Sun Microsystems, Inc.
4865N/A ! -->
4865N/A<stax>
4865N/A
4865N/A <defaultcall function="fractional-replication_cleanup"/>
4865N/A
4865N/A <function name="fractional-replication_cleanup">
4865N/A <function-map-args>
4865N/A <function-arg-def name="suiteSuffix"
4865N/A type="optional"
4865N/A default="None">
4865N/A <function-arg-description>
4865N/A Test suite suffix used to copy the server logs back to the controller.
4865N/A </function-arg-description>
4865N/A <function-arg-property name="type" value="string"/>
4865N/A </function-arg-def>
4865N/A </function-map-args>
4865N/A <sequence>
4865N/A
4865N/A <block name="'fractional-replication-cleanup'">
4865N/A
4865N/A <sequence>
4865N/A
4865N/A <!-- Stop the servers in the topology -->
4865N/A <call function="'stopServers'">
4865N/A [_splitServerList]
4865N/A </call>
4865N/A
4865N/A <!-- Copy the server logs to the controller machine -->
4865N/A <if expr="suiteSuffix != None">
4865N/A <paralleliterate var="server" in="_splitServerList" indexvar="i">
4865N/A <sequence>
4865N/A <script>
4865N/A suffix = suiteSuffix + '_%s' % (i + 1)
4865N/A serverHost = server.getHostname()
4865N/A serverName = '%s:%s' % (serverHost, server.getPort())
4865N/A serverPath = '%s/%s' % (server.getDir(), OPENDSNAME)
4865N/A </script>
4865N/A
4865N/A <message>
4865N/A 'Copy %s/logs/errors from %s to %s/errors_%s on %s' % \
4865N/A (serverPath, serverName, logs.sut, suffix, STAXServiceMachine)
4865N/A </message>
4865N/A <call function="'copyFile'">
4865N/A {
4865N/A 'location' : serverHost,
4865N/A 'srcfile' : '%s/logs/errors' % serverPath,
4865N/A 'destfile' : '%s/errors_%s' % (logs.sut, suffix),
4865N/A 'remotehost' : STAXServiceMachine
4865N/A }
4865N/A </call>
4865N/A <message>
4865N/A 'Copy %s/logs/access from %s to %s/access_%s on %s' % \
4865N/A (serverPath, serverName,logs.sut, suffix, STAXServiceMachine)
4865N/A </message>
4865N/A <call function="'copyFile'">
4865N/A {
4865N/A 'location' : serverHost,
4865N/A 'srcfile' : '%s/logs/access' % serverPath,
4865N/A 'destfile' : '%s/access_%s' % (logs.sut, suffix),
4865N/A 'remotehost' : STAXServiceMachine
4865N/A }
4865N/A </call>
4865N/A <message>
4865N/A 'Copy %s/logs/fractional-replication from %s to %s/fractional-replication_%s on %s' % \
4865N/A (serverPath, serverName, logs.sut, suffix, STAXServiceMachine)
4865N/A </message>
4865N/A <call function="'copyFile'">
4865N/A {
4865N/A 'location' : serverHost,
4865N/A 'srcfile' : '%s/logs/fractional-replication' % serverPath,
4865N/A 'destfile' : '%s/fractional-replication_%s' % (logs.sut, suffix),
4865N/A 'remotehost' : STAXServiceMachine
4865N/A }
4865N/A </call>
4865N/A </sequence>
4865N/A </paralleliterate>
4865N/A </if>
4865N/A
4865N/A <!-- Remove the topology created for the test suite -->
4865N/A <message>
4865N/A 'Remove DS topology created for the Synchronization Basic Test Suite'
4865N/A </message>
4865N/A
4865N/A <call function="'removeTopology'">
4865N/A { 'multipleInstanceTopology' : True }
4865N/A </call>
4865N/A
4865N/A <call function="'checkRC'">
4865N/A { 'returncode' : RC ,
4865N/A 'result' : STAXResult }
4865N/A </call>
4865N/A
4865N/A </sequence>
4865N/A
4865N/A </block>
4865N/A
4865N/A </sequence>
4865N/A
4865N/A </function>
4865N/A
4865N/A</stax>