342N/A<?
xml version="1.0" encoding="UTF-8" standalone="no"?>
342N/A ! The contents of this file are subject to the terms of the 342N/A ! Common Development and Distribution License, Version 1.0 only 342N/A ! (the "License"). You may not use this file except in compliance 342N/A ! You can obtain a copy of the license at 342N/A ! See the License for the specific language governing permissions 342N/A ! and limitations under the License. 342N/A ! When distributing Covered Code, include this CDDL HEADER in each 342N/A ! file and include the License file at 1472N/A ! add the following below this CDDL HEADER, with the fields enclosed 1472N/A ! by brackets "[]" replaced with your own identifying information: 342N/A ! Portions Copyright [yyyy] [name of copyright owner] 1879N/A ! Copyright 2007-2010 Sun Microsystems, Inc. 1879N/A <!-- This function uses make ldif to generate LDIF data files --> 1879N/A <
function name="MakeLdifWithScript">
1879N/A This function uses make ldif to generate LDIF data files
342N/A <
function-
arg-
def name="location" 342N/A default="STAF_REMOTE_HOSTNAME">
342N/A <
function-
arg-
description>
342N/A Location of target host
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="hostname"/>
342N/A <
function-
arg-
def name="dsPath" 342N/A default="'%s/%s' % (DIRECTORY_INSTANCE_BIN,OPENDSNAME)">
342N/A <
function-
arg-
description>
342N/A Pathname to installation root
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filepath"/>
342N/A <
function-
arg-
def name="version" type="optional">
342N/A <
function-
arg-
description>
342N/A Display Directory Server version information
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="string"/>
1311N/A <
function-
arg-
def name="templateFile" type="optional">
342N/A <
function-
arg-
description>
807N/A Path to the template file
807N/A </
function-
arg-
description>
807N/A <
function-
arg-
property name="type" value="filename"/>
342N/A <
function-
arg-
def name="ldifFile" type="optional">
342N/A <
function-
arg-
description>
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filename"/>
342N/A <
function-
arg-
def name="randomSeed" type="optional">
342N/A <
function-
arg-
description>
342N/A The seed to use to initialize the random number generator
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="integer"/>
342N/A <
function-
arg-
def name="Help" type="optional">
342N/A <
function-
arg-
description>
1394N/A </
function-
arg-
description>
1394N/A <
function-
arg-
property name="help" value="option"/>
1394N/A <
function-
arg-
def name="expectedRC" type="optional" default="0">
342N/A <
function-
arg-
description>
1394N/A Expected return code value. Default value is 0.
342N/A Wildcard 'noCheck' to not check the RC
342N/A </
function-
arg-
description>
1394N/A <
function-
arg-
def name="knownIssue" type="optional" default="None">
342N/A <
function-
arg-
description>
342N/A Known issue. Corresponds to an issue number.
342N/A </
function-
arg-
description>
342N/A dsBinPath='%s/%s' % (dsPath,fileFolder)
545N/A STAFCmdParams=' '.join(STAFCmdParamsList)
342N/A <
call function="'createMultiFolders'">
342N/A 'folderslist' : foldersToCreate
342N/A '%s %s' % (STAFCmd, STAFCmdParams)
342N/A <
call function="'runCommand'">
342N/A { 'name' : 'Make Ldif Script',
342N/A 'arguments' : STAFCmdParams,
342N/A 'expectedRC': expectedRC,
342N/A 'knownIssue': knownIssue
342N/A <
return>STAXResult</
return>
342N/A <!-- This function uses make ldif to generate LDIF data files --> 342N/A <
function name="MakeAMakeLdifTemplate">
796N/A This function makes a make-ldif template file
342N/A <
function-
arg-
def name="numEntries" type="required">
342N/A <
function-
arg-
description>
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="string"/>
942N/A <
function-
arg-
def name="startFrom" 342N/A <
function-
arg-
description>
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="string"/>
342N/A <
function-
arg-
def name="suffix" 342N/A default="DIRECTORY_INSTANCE_SFX">
342N/A <
function-
arg-
description>
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="string"/>
342N/A <
function-
arg-
def name="templateFile" type="required">
342N/A <
function-
arg-
description>
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filename"/>
342N/A <
function-
arg-
def name="templateLocation" 342N/A default="STAXServiceMachine">
342N/A <
function-
arg-
description>
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filename"/>
342N/A <
function-
arg-
def name="additionalAttributes" 342N/A <
function-
arg-
description>
342N/A Add (or not) additional attributes
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="integer"/>
342N/A <
function-
arg-
def name="extraLine" type="optional">
342N/A <
function-
arg-
description>
342N/A Extra line to add to the mkae-ldif template
342N/A </
function-
arg-
description>
636N/A <
function-
arg-
property name="type" value="string"/>
342N/A <!-- Build the import task configuration object --> 342N/A if additionalAttributes == True:
526N/A <!-- Write out the make-ldif template file --> 526N/A outfile = open(tmpTemplateFile,"w")
342N/A <
if expr="STAXCode != 0">
342N/A <
message level="'error'">
1576N/A 'creation of a make-ldif template failed (Code=%s,Reason=%s).' % (STAXCode,STAXReason)
1576N/A <
call function="'checktestRC'">
1576N/A { 'returncode' : STAXCode ,
1576N/A <
call function="'copyFile'">
1576N/A { 'location' : STAXServiceMachine,
1576N/A 'srcfile' : tmpTemplateFile,
342N/A 'destfile' : templateFile,
342N/A 'remotehost' : templateLocation }
342N/A <
call function="'checktestRC'">
342N/A <
return>[RC, STAXResult]</
return>
342N/A <!-- This function compares two LDIF files using the ldif-diff script --> 342N/A <
function name="LdifDiffWithScript">
342N/A This function compares two LDIF files and reports the differences in LDIF format
342N/A <
function-
arg-
def name="location" 342N/A default="STAF_REMOTE_HOSTNAME">
342N/A <
function-
arg-
description>
342N/A Location of target host
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="hostname"/>
342N/A <
function-
arg-
def name="dsPath" 342N/A default="'%s/%s' % (DIRECTORY_INSTANCE_BIN,OPENDSNAME)">
342N/A <
function-
arg-
description>
342N/A Pathname to installation root
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filepath"/>
342N/A <
function-
arg-
def name="version" type="optional">
342N/A <
function-
arg-
description>
342N/A Display Directory Server version information
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="string"/>
342N/A <
function-
arg-
def name="sourceLdif" type="required">
342N/A <
function-
arg-
description>
342N/A LDIF file to use as the source data
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filepath"/>
342N/A <
function-
arg-
def name="targetLdif" type="required">
342N/A <
function-
arg-
description>
342N/A LDIF file to use as the target data
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filepath"/>
342N/A <
function-
arg-
def name="outputLdif" type="required">
342N/A <
function-
arg-
description>
342N/A File to which the diffs should be written
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filepath"/>
342N/A <
function-
arg-
def name="ignoreAttrsFile" 342N/A <
function-
arg-
description>
342N/A File containing a list of attributes to ignore when computing the
342N/A </
function-
arg-
description>
545N/A <
function-
arg-
property name="type" value="filepath"/>
545N/A <
function-
arg-
def name="overwriteExisting" type="optional" default="True">
1576N/A Overwrite existing output file rather than append to it
1576N/A </
function-
arg-
description>
1576N/A <
function-
arg-
property name="type" value="option"/>
1576N/A <
function-
arg-
def name="singleValueChanges" type="optional">
342N/A Write each attribute-level change as a separate modification
342N/A per attribute value rather than one modification per entry
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="option"/>
342N/A <
function-
arg-
def name="Help" type="optional">
342N/A <
function-
arg-
description>
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="help" value="option"/>
342N/A <!-- Build the Command --> 342N/A dsBinPath='%s/%s' % (dsPath,fileFolder)
526N/A STAFCmdParams=' '.join(STAFCmdParamsList)
526N/A <
call function="'createMultiFolders'">
526N/A { 'location' : location,
526N/A 'folderslist' : foldersToCreate
526N/A '%s %s' % (STAFCmd, STAFCmdParams)
1394N/A <
process name="'LDIF Diff Script'">
1394N/A <
location>location</
location>
1394N/A <
parms>STAFCmdParams</
parms>
1394N/A <
workdir>dsBinPath</
workdir>
1576N/A ['PATH=/bin:/
usr/
bin:%s' % dsBinPath, 'JAVA_HOME=%s' % JAVA_HOME]
1576N/A <!-- Check the size of the diff file, and avoid reading its 1576N/A content with getFile if the file is too big to prevent 1576N/A the staf process from running out of memory --> 1576N/A <
call function="'GetEntry'">
342N/A # GetEntry returns: STAXResult = [cmdRC, cmdResult]
342N/A diffsFileSize = int(STAXResult[1]['lowerSize'])
1629N/A msg = 'File: %s Size (bytes): %s' % (outputLdif, diffsFileSize)
1629N/A diffsFileSize = MAX_READABLE_SIZE
1629N/A msg = 'Could not retrieve the size of file %s' % outputLdif
1629N/A <
message log="1"> 'LdifDiffWithScript: %s' % msg </
message>
342N/A <
if expr="diffsFileSize < MAX_READABLE_SIZE">
342N/A <
call function="'getFile'">
342N/A { 'location' : location,
342N/A 'filename' : outputLdif
342N/A # getFile returns: STAXResult = [cmdRC, cmdResult]
342N/A diffsFileContent = STAXResult[1]
342N/A # diffs file to big to be read
342N/A diffsFileContent = 'File too big to be read.'
616N/A # if the diff file is too big, it means that there ARE
616N/A # actually some diffs, so we may deduce diffRC = 1
342N/A <
message log="1" level="'Error'">
342N/A 'LdifDiffWithScript: command run FAILED.'
342N/A 'NO DIFFERENCES were detected between the source and the target \
1394N/A <
message log="1" level="'Error'">
1394N/A 'Source and target LDIF files are DIFFERENT: \n\n%s' % \
342N/A <
return> diffRC </
return>
342N/A <!-- This function modifies an LDIF file using ldifmodify script --> 342N/A <
function name="LdifModifyWithScript">
342N/A This function modifies an LDIF file with the changes contained in another LDIF file
342N/A <
function-
arg-
def name="location" 342N/A default="STAF_REMOTE_HOSTNAME">
342N/A <
function-
arg-
description>
342N/A Location of target host
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="hostname"/>
342N/A <
function-
arg-
def name="dsPath" 342N/A default="'%s/%s' % (DIRECTORY_INSTANCE_BIN,OPENDSNAME)">
342N/A <
function-
arg-
description>
342N/A Pathname to installation root
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filepath"/>
342N/A <
function-
arg-
def name="version" type="optional">
342N/A <
function-
arg-
description>
342N/A Display Directory Server version information
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="string"/>
342N/A <
function-
arg-
def name="sourceLdif" type="required">
342N/A <
function-
arg-
description>
342N/A LDIF file containing the data to be updated
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filepath"/>
342N/A <
function-
arg-
def name="targetLdif" type="required">
342N/A <
function-
arg-
description>
342N/A LDIF file that will contain the updated data
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filepath"/>
342N/A <
function-
arg-
def name="changesLdif" type="required">
342N/A <
function-
arg-
description>
342N/A LDIF file containing the changes to apply
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filepath"/>
342N/A <
function-
arg-
def name="Help" type="optional">
342N/A <
function-
arg-
description>
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="help" value="option"/>
342N/A <
function-
arg-
def name="expectedRC" type="optional" default="0">
342N/A <
function-
arg-
description>
342N/A Expected return code value. Default value is 0.
342N/A Wildcard 'noCheck' to not check the RC
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
def name="knownIssue" type="optional" default="None">
342N/A <
function-
arg-
description>
342N/A Known issue. Corresponds to an issue number.
342N/A </
function-
arg-
description>
342N/A <!-- Build the Command --> 342N/A dsBinPath='%s/%s' % (dsPath,fileFolder)
636N/A STAFCmdParams=' '.join(STAFCmdParamsList)
636N/A <
call function="'createMultiFolders'">
636N/A { 'location' : location,
636N/A 'folderslist' : foldersToCreate
636N/A '%s %s' % (STAFCmd, STAFCmdParams)
636N/A <
call function="'runCommand'">
636N/A { 'name' : 'LDIF Modify Script',
342N/A 'arguments' : STAFCmdParams,
342N/A 'expectedRC': expectedRC,
342N/A 'knownIssue': knownIssue
342N/A <
return>STAXResult</
return>
342N/A <
function name="verifyTrees">
342N/A This function verifies that the trees in a group of ldap servers are
1753N/A <
function-
arg-
def name="location" 1753N/A default="STAF_REMOTE_HOSTNAME">
342N/A <
function-
arg-
description>
342N/A Location of target host
1629N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="hostname"/>
616N/A <
function-
arg-
def name="dsPath" 1625N/A default="'%s/%s' % (DIRECTORY_INSTANCE_BIN,OPENDSNAME)">
1625N/A Pathname to installation root
1625N/A </
function-
arg-
description>
1625N/A <
function-
arg-
property name="type" value="filepath"/>
342N/A <
function-
arg-
def name="referenceServer" type="required">
342N/A <
function-
arg-
description>
342N/A Server that should be taken as reference.
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="Server"/>
342N/A <
function-
arg-
def name="serverList" type="required">
342N/A <
function-
arg-
description>
342N/A List of the servers to verify against the referenceServer.
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="Server-list"/>
1753N/A <
function-
arg-
def name="treeSuffix" type="required">
342N/A <
function-
arg-
description>
342N/A Suffix of the tree to verify.
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="DN"/>
342N/A <
function-
arg-
def name="knownIssue" type="optional" default="None">
342N/A <
function-
arg-
description>
342N/A Known issue. Corresponds to an issue number.
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
def name="ignoreAttrsFile" 342N/A <
function-
arg-
description>
342N/A File containing a list of attributes to ignore when computing the
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filepath"/>
342N/A myKnownIssue = knownIssue
353N/A <!-- Verify the synchronization of the trees among the servers in 353N/A <
call function="'getReplicationStatus'">
342N/A { 'location' : location,
1625N/A 'replicationDnList' : [treeSuffix],
342N/A 'noOfMilliSeconds' : 6000
342N/A 'Verify tree %s taking %s as reference.' \
342N/A % (treeSuffix, referenceServerPath)
1092N/A <!-- Retrieve the tree from the reference server --> 342N/A <
call function="'exportLdifWithScript'">
342N/A { 'location' : location,
342N/A 'ldifFile' : '%s/../%s' % (dsPath, referenceTree),
342N/A 'includeBranches' : [treeSuffix]
342N/A <!-- If the reference tree could not be retrieved, return an error --> 342N/A <
return> [1, None] </
return>
342N/A <
iterate var="server" in="serverList">
342N/A <!-- Retrieve the same tree for every other server in the list --> 342N/A <
call function="'exportLdifWithScript'">
342N/A { 'location' : location,
342N/A 'ldifFile' : '%s/../%s' % (filePath, sampleTree),
342N/A 'includeBranches' : [treeSuffix]
342N/A <
if expr="not isSameLocation">
342N/A <!-- Copy sample tree file to reference server --> 342N/A <
call function="'copyFile'">
342N/A 'remotehost' : location,
342N/A 'srcfile' : '%s/../%s' % (filePath, sampleTree),
342N/A 'destfile' : '%s/../%s' % (dsPath, sampleTree)
342N/A <!-- Compare this tree to the reference one --> 342N/A <
call function="'LdifDiffWithScript'">
342N/A { 'location' : location,
342N/A 'sourceLdif' : '%s/../%s' % (dsPath, sampleTree),
342N/A 'targetLdif' : '%s/../%s' % (dsPath, referenceTree),
342N/A 'outputLdif' : '%s/../%s' % (dsPath, treeDiffs),
342N/A 'ignoreAttrsFile' : ignoreAttrsFile
342N/A <
if expr="STAXResult != 0">
342N/A <
message log="1" level="'Error'">
342N/A 'Tree is DIFFERENT for %s:%s compared to %s:%s' % \
342N/A <
if expr="len(failedServers) > 0">
342N/A <!-- If at least one server failed to successfully compare to the 342N/A ! reference tree, return an error, along with the list of the 342N/A ! servers that failed to do so --> 342N/A 'List of non-synchronized servers (tree verify FAILED): %s ' \
342N/A 'All servers synchronized (tree verify SUCCEEDED).'
342N/A <
call function="'checktestRC'">
342N/A 'result' : failingServerList,
342N/A <
return>[myRC, failedServers]</
return>
342N/A <
function name="verifySchemas">
342N/A This function verifies that a schema file is synchronized all over a group of servers.
342N/A <
function-
arg-
def name="location" 342N/A default="STAF_REMOTE_HOSTNAME">
342N/A <
function-
arg-
description>
342N/A Location of target host
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="hostname"/>
342N/A <
function-
arg-
def name="dsPath" 342N/A default="'%s/%s' % (DIRECTORY_INSTANCE_BIN,OPENDSNAME)">
342N/A <
function-
arg-
description>
342N/A Pathname to installation root
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filepath"/>
342N/A <
function-
arg-
def name="referenceServer" type="required">
342N/A <
function-
arg-
description>
342N/A Server that should be taken as reference.
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="Server"/>
342N/A <
function-
arg-
def name="serverList" type="required">
342N/A <
function-
arg-
description>
342N/A List of the servers to verify against the referenceServer.
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="Server-list"/>
342N/A <
function-
arg-
def name="schemaFile" type="required">
342N/A <
function-
arg-
description>
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filename"/>
342N/A <
function-
arg-
def name="knownIssue" type="optional" default="None">
342N/A <
function-
arg-
description>
342N/A Known issue. Corresponds to an issue number.
342N/A </
function-
arg-
description>
342N/A myKnownIssue = knownIssue
678N/A 'Verify schema file %s taking %s as reference.' % (schemaFile, referenceServerPath)
342N/A <
iterate var="server" in="serverList">
678N/A <!-- Copy reference schema file to other server --> 678N/A <
call function="'copyFile'">
678N/A 'srcfile' : referenceSchema,
342N/A <!-- Compare this schema to the reference one --> 342N/A <
call function="'LdifDiffWithScript'">
342N/A { 'location' : location,
342N/A <
if expr="len(failedServers) > 0">
342N/A <!-- If at least one server failed to successfully compare to the reference tree, 342N/A ! return an error, along with the list of the servers that failed to do so --> 342N/A failingServerList = 'List of non-synchronized servers (schema verify FAILED): %s ' %
comma.join(failedServers)
342N/A 'All servers synchronized (schema verify SUCCEEDED).'
342N/A <
call function="'checktestRC'">
342N/A 'result' : failingServerList ,
390N/A <
return>[myRC, failedServers]</
return>
342N/A <
function name="deleteTrees">
342N/A This function deletes a (sub)tree from a list of servers.
342N/A <
function-
arg-
def name="serverList" type="required">
342N/A <
function-
arg-
description>
342N/A List of the servers (instances of "Server" class) where the tree will be deleted.
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="Server-list"/>
342N/A <
function-
arg-
def name="treeSuffix" type="required">
342N/A <
function-
arg-
description>
342N/A Suffix of the tree to delete.
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="DN"/>
342N/A <
function-
arg-
def name="startDS" type="optional" default="True">
342N/A <
function-
arg-
description>
342N/A Need to start the Directory Servers before deleting.
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="boolean"/>
342N/A <!-- Start the servers in the list --> 342N/A <
call function="'startServers'">
342N/A <!-- Delete the tree in every server in the list --> 342N/A <
paralleliterate var="server" in="serverList">
342N/A <!-- Delete suffix and subtree --> 342N/A <
call function="'ldapDeleteWithScript'">
342N/A 'dsDeleteSubtree' : True
342N/A <!-- Stop the servers in the list --> 342N/A <
call function="'stopServers'">
1027N/A <
function name="startServers">
1027N/A This function starts a list of servers.
1194N/A <
function-
arg-
def name="serverList" type="required">
1194N/A List of the servers (instances of "Server" class) to be started.
1194N/A </
function-
arg-
description>
1194N/A <
function-
arg-
property name="type" value="Server-list"/>
1166N/A <!-- Check if using coverage in which case we'll avoid doing parallele iterate --> 1027N/A <
call function="'GetEntry'">
1027N/A 'location' : STAF_REMOTE_HOSTNAME ,
1027N/A <
script>coverage = True</
script>
1027N/A <
script>coverage = False</
script>
1194N/A <!-- Start the servers in the list --> 1027N/A <
if expr="coverage == True">
1027N/A <
message>'starting servers in sequence using "iterate"'</
message>
342N/A <
iterate var="server" in="serverList">
342N/A <
call function="'StartDsWithScript'">
342N/A <!--- Check that DS started --> 342N/A <
call function="'isAlive'">
342N/A <
message>'starting servers in parallel using "paralleliterate"'</
message>
342N/A <
paralleliterate var="server" in="serverList">
342N/A <
call function="'StartDsWithScript'">
342N/A <!--- Check that DS started --> 342N/A <
call function="'isAlive'">
342N/A 'noOfMilliSeconds' : 2000
811N/A <
function name="stopServers">
838N/A This function stops a list of servers.
342N/A <
function-
arg-
def name="serverList" type="required">
838N/A <
function-
arg-
description>
838N/A List of the servers (instances of "Server" class) to be stopped.
838N/A </
function-
arg-
description>
838N/A <
function-
arg-
property name="type" value="Server-list"/>
342N/A <
function-
arg-
def name="noOfLoops" 342N/A <
function-
arg-
description>
342N/A Number of iterations (for isStopped())
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="integer"/>
342N/A <
function-
arg-
def name="noOfMilliSeconds" 342N/A <
function-
arg-
description>
342N/A Number of seconds to wait between iterations (for isStopped())
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="seconds"/>
342N/A <!-- Stop the servers in the list --> 342N/A <
paralleliterate var="server" in="serverList">
1394N/A <
call function="'StopDsWithScript'">
342N/A 'noOfLoops' : noOfLoops,
342N/A 'noOfMilliSeconds' : noOfMilliSeconds
342N/A <!-- This function perform a search operation in a LDIF file --> 342N/A <
function name="ldifSearchWithScript" scope="local">
342N/A This function perform a search operation in a LDIF file
342N/A <
function-
arg-
def name="location" 811N/A default="STAF_REMOTE_HOSTNAME">
811N/A <
function-
arg-
description>
811N/A Location of target host
811N/A </
function-
arg-
description>
811N/A <
function-
arg-
property name="type" value="hostname"/>
811N/A <
function-
arg-
def name="dsPath" 811N/A default="'%s/%s' % (DIRECTORY_INSTANCE_BIN,OPENDSNAME)">
811N/A <
function-
arg-
description>
811N/A Pathname to installation root
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filepath"/>
342N/A <
function-
arg-
def name="dsBaseDN" type="optional">
342N/A <
function-
arg-
description>
342N/A The baseDN for the search operation
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="dn"/>
342N/A <
function-
arg-
def name="dsFilterFile" type="optional">
342N/A <
function-
arg-
description>
342N/A File containing a list of search filter strings
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filename"/>
342N/A <
function-
arg-
def name="dsLdifFile" type="required">
342N/A <
function-
arg-
description>
342N/A LDIF file to use as the source data
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filename"/>
342N/A <
function-
arg-
def name="dsOutputFile" type="optional">
342N/A <
function-
arg-
description>
342N/A File to which the search results should be written
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filename"/>
342N/A <
function-
arg-
def name="dsOverwriteExisting" 342N/A <
function-
arg-
description>
342N/A Overwrite the output file specified
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filename"/>
342N/A <
function-
arg-
def name="dsSearchScope" type="optional">
342N/A <
function-
arg-
description>
811N/A The scope of the search operation
811N/A </
function-
arg-
description>
811N/A <
function-
arg-
property name="type" value="option"/>
811N/A <
function-
arg-
def name="dsTimeLimit" type="optional">
811N/A <
function-
arg-
description>
811N/A Maximum length of time in seconds to allow for the search
811N/A </
function-
arg-
description>
811N/A <
function-
arg-
property name="type" value="integer"/>
811N/A <
function-
arg-
def name="dsSizeLimit" type="optional">
811N/A <
function-
arg-
description>
811N/A Maximum number of entries to return from the search
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="integer"/>
342N/A <
function-
arg-
def name="dsDontWrap" type="optional">
342N/A <
function-
arg-
description>
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="option"/>
811N/A <
function-
arg-
def name="dsHelp" type="optional">
811N/A <
function-
arg-
description>
342N/A Display this usage information
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="option"/>
342N/A <
function-
arg-
def name="dsVersion" type="optional">
342N/A <
function-
arg-
description>
342N/A Display Directory Server version information
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="option"/>
342N/A <
function-
arg-
def name="dsFilter" type="optional">
342N/A <
function-
arg-
description>
342N/A The filter for the search operation
342N/A </
function-
arg-
description>
342N/A <
function-
arg-
property name="type" value="filter"/>
342N/A <
function-
arg-
def name="dsAttributes" type="optional">
342N/A <
function-
arg-
description>
342N/A Only return these attributes
342N/A </
function-
arg-
description>
796N/A <
function-
arg-
property name="type" value="string"/>
796N/A <
function-
arg-
def name="expectedRC" type="optional" default="0">
796N/A <
function-
arg-
description>
796N/A Expected return code value. Default value is 0
796N/A Wildcard 'noCheck' to not check the RC
796N/A </
function-
arg-
description>
796N/A <
function-
arg-
property name="type" value="integer"/>
342N/A <!-- Build the Command --> 342N/A dsBinPath='%s/%s' % (dsPath,fileFolder)
342N/A if dsOverwriteExisting:
845N/A STAFCmdParams=' '.join(STAFCmdParamsList)
845N/A <
call function="'runCommand'" >
845N/A 'name' : 'LDIF Search Script',
845N/A 'arguments' : STAFCmdParams,
845N/A 'expectedRC' : expectedRC
845N/A <
return>STAXResult</
return>
845N/A <!-- This function execute the encode-password tool --> 845N/A <
function name="encodePasswordWithScript" scope="local">
845N/A This function execute the encode-password tool
845N/A <
function-
arg-
def name="location" 845N/A default="STAF_REMOTE_HOSTNAME">
845N/A <
function-
arg-
description>
845N/A Location of target host
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="hostname"/>
1391N/A <
function-
arg-
def name="dsPath" 845N/A default="'%s/%s' % (DIRECTORY_INSTANCE_BIN,OPENDSNAME)">
845N/A <
function-
arg-
description>
1391N/A Pathname to installation root
1391N/A </
function-
arg-
description>
1391N/A <
function-
arg-
property name="type" value="filepath"/>
1391N/A <
function-
arg-
def name="authPwdSyntax" type="optional">
1391N/A Use the authentication password syntax.
1391N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="option"/>
845N/A <
function-
arg-
def name="clearPwd" type="optional">
845N/A <
function-
arg-
description>
845N/A Specify the clear-text password.
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="string"/>
845N/A <
function-
arg-
def name="encodedPwd" type="optional">
1391N/A Specify the encoded password.
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="string"/>
845N/A <
function-
arg-
def name="encodedPwdFile" type="optional">
845N/A Use the encoded password from the specified file.
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="filename"/>
845N/A <
function-
arg-
def name="clearPwdFile" type="optional">
845N/A <
function-
arg-
description>
845N/A Use the clear-text password from the specified file.
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="filename"/>
845N/A <
function-
arg-
def name="listSchemes" type="optional">
845N/A <
function-
arg-
description>
845N/A Display a list of the password storage schemes that are available
845N/A for use in the OpenDS server.
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="option"/>
845N/A <
function-
arg-
def name="useCmpRC" type="optional">
845N/A <
function-
arg-
description>
845N/A Use an exit code that indicates whether a given clear-text password
845N/A matched a provided encoded password.
845N/A Results are an exit code of 6 (COMPARE_TRUE) or
845N/A an exit code of 5 (COMPARE_FALSE).
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="option"/>
845N/A <
function-
arg-
def name="storageScheme" type="optional">
845N/A <
function-
arg-
description>
845N/A Specify the name of the password storage scheme to use when
845N/A encoding a clear-text password.
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="option"/>
845N/A <
function-
arg-
def name="dsHelp" type="optional">
845N/A <
function-
arg-
description>
845N/A Display this usage information
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="option"/>
845N/A <
function-
arg-
def name="dsVersion" type="optional">
845N/A <
function-
arg-
description>
845N/A Display Directory Server version information
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="option"/>
845N/A <
function-
arg-
def name="expectedRC" type="optional" default="0">
845N/A <
function-
arg-
description>
845N/A Expected return code value. Default value is 0.
845N/A Wildcard 'noCheck' to not check the RC
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="integer"/>
845N/A <
function-
arg-
def name="knownIssue" type="optional" default="None">
845N/A <
function-
arg-
description>
845N/A Known issue. Corresponds to an issue number.
845N/A </
function-
arg-
description>
845N/A <!-- Build the Command --> 845N/A dsBinPath='%s/%s' % (dsPath,fileFolder)
845N/A STAFCmdParams=' '.join(STAFCmdParamsList)
845N/A <
call function="'runCommand'">
845N/A 'name' : 'Encode password script',
845N/A 'arguments' : STAFCmdParams,
845N/A 'knownIssue' : knownIssue
845N/A <
return>STAXResult</
return>
845N/A <!-- This function check task execution--> 845N/A <
function name="checkTaskExecution" scope="local">
1391N/A This functioncheck task execution
845N/A <
function-
arg-
def name="location" 845N/A default="STAF_REMOTE_HOSTNAME">
845N/A <
function-
arg-
description>
845N/A Location of target host
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="hostname"/>
845N/A <
function-
arg-
def name="dsPath" 845N/A default="'%s/%s' % (DIRECTORY_INSTANCE_BIN,OPENDSNAME)">
845N/A <
function-
arg-
description>
845N/A Pathname to installation root
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="filepath"/>
845N/A <
function-
arg-
def name="outputToCheck" type="required">
845N/A <
function-
arg-
description>
845N/A The output result of the task
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="string"/>
845N/A <
function-
arg-
def name="dsInstanceDn" type="required">
845N/A <
function-
arg-
description>
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="DN" />
845N/A <
function-
arg-
def name="dsInstanceAdminPort" 845N/A default="DIRECTORY_INSTANCE_ADMIN_PORT">
845N/A <
function-
arg-
description>
845N/A Directory server admin port number
1391N/A </
function-
arg-
description>
1391N/A <
function-
arg-
property name="type" value="Port number" />
845N/A <
function-
arg-
def name="dsInstanceHost" 845N/A default="STAF_REMOTE_HOSTNAME">
845N/A <
function-
arg-
description>
845N/A Directory server hostname or IP address
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="hostname" />
845N/A <
function-
arg-
def name="dsInstancePswd" type="required">
845N/A <
function-
arg-
description>
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="string" />
845N/A resultString = outputToCheck
845N/A for str in resultSplitted:
845N/A 'Command task Id : %s' % taskId
845N/A 'Check ldif command successfully completed with manage-task'
845N/A <
script>checkRC=9999</
script>
845N/A <
loop from="1" to="10" var="loop" while="checkRC != 0">
845N/A <
message>'LOOP %s' % loop</
message>
845N/A <
call function="'manage-tasks'">
845N/A 'dsInstanceHost' : dsInstanceHost ,
845N/A 'dsInstanceAdminPort' : dsInstanceAdminPort,
845N/A 'dsInstanceDn' : dsInstanceDn ,
845N/A 'dsInstancePswd' : dsInstancePswd ,
845N/A 'expectedRC' : 'noCheck'
845N/A returnString = STAXResult[0][1]
845N/A msg = 'Status Completed successfully'
845N/A <
call function="'searchString'">
845N/A 'expectedString' : msg ,
845N/A 'returnString' : returnString ,
845N/A 'expectedRC' : 'noCheck'
1782N/A { 'sleepForMilliSeconds' : 2000 }
1782N/A <
call function="'checktestRC'">
845N/A 'result' : "Task succeeds" ,
845N/A <!-- This function compares two LDIF files using the ldif-diff script --> 845N/A <
function name="LdifDiffWithScript-new" scope="local">
845N/A This function compares two LDIF files and reports the differences
1391N/A <
function-
arg-
def name="location" 1391N/A default="STAF_REMOTE_HOSTNAME">
845N/A Location of target host
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="hostname"/>
845N/A <
function-
arg-
def name="dsPath" 845N/A default="'%s/%s' % (DIRECTORY_INSTANCE_BIN,OPENDSNAME)">
845N/A <
function-
arg-
description>
845N/A Pathname to installation root
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="filepath"/>
845N/A <
function-
arg-
def name="dsVersion" type="optional">
845N/A <
function-
arg-
description>
845N/A Display Directory Server version information
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="option"/>
845N/A <
function-
arg-
def name="sourceLdif" type="required">
845N/A <
function-
arg-
description>
845N/A LDIF file to use as the source data
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="filepath"/>
845N/A <
function-
arg-
def name="targetLdif" type="required">
845N/A <
function-
arg-
description>
845N/A LDIF file to use as the target data
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="filepath"/>
845N/A <
function-
arg-
def name="outputLdif" type="required">
845N/A <
function-
arg-
description>
845N/A File to which the diffs should be written
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="filepath"/>
845N/A <
function-
arg-
def name="overwriteExisting" type="optional" default="True">
845N/A <
function-
arg-
description>
845N/A Overwrite existing output file rather than append to it
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="option"/>
845N/A <
function-
arg-
def name="singleValueChanges" type="optional">
845N/A <
function-
arg-
description>
845N/A Write each attribute-level change as a separate modification
845N/A per attribute value rather than one modification per entry
845N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="type" value="option"/>
845N/A <
function-
arg-
def name="dsHelp" type="optional">
845N/A <
function-
arg-
description>
1531N/A </
function-
arg-
description>
845N/A <
function-
arg-
property name="help" value="option"/>
845N/A <
function-
arg-
def name="expectedRC" type="optional" default="0">
845N/A <
function-
arg-
description>
845N/A Expected return code value. Default value is 0.
845N/A Wildcard 'noCheck' to not check the RC
845N/A </
function-
arg-
description>
1629N/A <
function-
arg-
property name="type" value="integer"/>
845N/A <
function-
arg-
def name="knownIssue" type="optional" default="None">
845N/A <
function-
arg-
description>
845N/A Known issue. Corresponds to an issue number.
845N/A </
function-
arg-
description>
1629N/A dsBinPath='%s/%s' % (dsPath,fileFolder)
845N/A STAFCmdParams=' '.join(STAFCmdParamsList)
845N/A <
call function="'createMultiFolders'">
845N/A { 'location' : location,
845N/A 'folderslist' : foldersToCreate
1782N/A '%s %s' % (STAFCmd, STAFCmdParams)
845N/A <
call function="'runCommand'">
1782N/A 'name' : 'Ldif diff script',
845N/A 'arguments' : STAFCmdParams,
1879N/A 'expectedRC' : expectedRC ,
'knownIssue' : knownIssue
<
return>STAXResult</
return>
<!-- This function execute the dsjavaproperties tool --> <
function name="dsJavaPropertiesWithScript" scope="local">
This function execute the dsjavaproperties tool
<
function-
arg-
def name="location" default="STAF_REMOTE_HOSTNAME">
<
function-
arg-
description>
</
function-
arg-
description>
<
function-
arg-
property name="type" value="hostname"/>
<
function-
arg-
def name="dsPath" default="'%s/%s' % (DIRECTORY_INSTANCE_BIN,OPENDSNAME)">
<
function-
arg-
description>
Pathname to installation root
</
function-
arg-
description>
<
function-
arg-
property name="type" value="filepath"/>
<
function-
arg-
def name="Version" type="optional">
<
function-
arg-
description>
Display Directory Server version information
</
function-
arg-
description>
<
function-
arg-
property name="type" value="option"/>
<
function-
arg-
def name="Quiet" type="optional">
<
function-
arg-
description>
Run dsjavaproperties in quiet mode
Quiet mode does not output progress information to standard output
</
function-
arg-
description>
<
function-
arg-
property name="type" value="option"/>
<
function-
arg-
def name="Help" type="optional">
<
function-
arg-
description>
</
function-
arg-
description>
<
function-
arg-
property name="help" value="option"/>
<
function-
arg-
def name="expectedRC" type="optional" default="0">
<
function-
arg-
description>
Expected return code value. Default value is 0.
Wildcard 'noCheck' to not check the RC
</
function-
arg-
description>
<
function-
arg-
property name="type" value="integer"/>
<!-- Build the Command --> dsBinPath='%s/%s' % (dsPath,fileFolder)
STAFCmdParams=' '.join(STAFCmdParamsList)
<
call function="'runCommand'">
'name' : 'dsjavaproperties script',
'arguments' : STAFCmdParams,
'expectedRC' : expectedRC
<
return>STAXResult</
return>
<!-- This function uses manage-account to manage users account--> <
function name="manageAccountWithScript">
This function uses manage-account to manage users account
<
function-
arg-
def name="location" default="STAF_REMOTE_HOSTNAME">
<
function-
arg-
description>
</
function-
arg-
description>
<
function-
arg-
property name="type" value="hostname" />
<
function-
arg-
def name="dsPath" default="'%s/%s' % (DIRECTORY_INSTANCE_BIN,OPENDSNAME)">
<
function-
arg-
description>
Pathname to installation root
</
function-
arg-
description>
<
function-
arg-
property name="type" value="filepath" />
<
function-
arg-
def name="dsInstanceHost" default="STAF_REMOTE_HOSTNAME">
<
function-
arg-
description>
Directory server hostname or IP address
</
function-
arg-
description>
<
function-
arg-
property name="type" value="hostname" />
<
function-
arg-
def name="dsInstanceAdminPort" default="DIRECTORY_INSTANCE_ADMIN_PORT">
<
function-
arg-
description>
Directory server admin port number
</
function-
arg-
description>
<
function-
arg-
property name="type" value="Port number" />
<
function-
arg-
def name="dsInstanceDn" type="required">
<
function-
arg-
description>
</
function-
arg-
description>
<
function-
arg-
property name="type" value="DN" />
<
function-
arg-
def name="targetDn" type="required">
<
function-
arg-
description>
Specifies the DN of the user entry for which to get and set password
</
function-
arg-
description>
<
function-
arg-
property name="type" value="dn"/>
<
function-
arg-
def name="dsInstancePswd" type="required">
<
function-
arg-
description>
</
function-
arg-
description>
<
function-
arg-
property name="type" value="string" />
<
function-
arg-
def name="dsBindPasswordFile" type="optional">
<
function-
arg-
description>
</
function-
arg-
description>
<
function-
arg-
property name="type" value="filename"/>
<
function-
arg-
def name="subcommand" type="required">
<
function-
arg-
description>
manage-account subcommand to execute
</
function-
arg-
description>
<
function-
arg-
property name="type" value="string" />
<
function-
arg-
def name="expectedRC" type="optional" default="0">
<
function-
arg-
description>
Expected return code value. Default value is 0.
Wildcard 'noCheck' to not check the RC
</
function-
arg-
description>
<
function-
arg-
property name="type" value="string" />
<
function-
arg-
def name="dsHelp" type="optional">
<
function-
arg-
description>
</
function-
arg-
description>
<
function-
arg-
property name="help" value="option"/>
<
function-
arg-
def name="dsVersion" type="optional">
<
function-
arg-
description>
Display Directory Server version information
</
function-
arg-
description>
<
function-
arg-
property name="type" value="option"/>
<
function-
arg-
def name="dsCertNickname" type="optional">
<
function-
arg-
description>
Nickname of certificate for SSL client authentication
</
function-
arg-
description>
<
function-
arg-
property name="type" value="string"/>
<
function-
arg-
def name="dsKeyStorePath" type="optional">
<
function-
arg-
description>
Certificate keystore path
</
function-
arg-
description>
<
function-
arg-
property name="type" value="filename"/>
<
function-
arg-
def name="dsSaslOption" type="optional">
<
function-
arg-
description>
</
function-
arg-
description>
<
function-
arg-
property name="type" value="string"/>
<
function-
arg-
def name="dsTrustStorePath" type="optional">
<
function-
arg-
description>
Certificate trust store path
</
function-
arg-
description>
<
function-
arg-
property name="type" value="filename"/>
<
function-
arg-
def name="dsUseStartTLS" type="optional">
<
function-
arg-
description>
Use StartTLS to secure communication with the server
</
function-
arg-
description>
<
function-
arg-
property name="type" value="option"/>
<
function-
arg-
def name="dsTrustStorePassword" type="optional">
<
function-
arg-
description>
Certificate trust store PIN
</
function-
arg-
description>
<
function-
arg-
property name="type" value="string"/>
<
function-
arg-
def name="dsTrustStorePasswordFile" type="optional">
<
function-
arg-
description>
Certificate trust store PIN file
</
function-
arg-
description>
<
function-
arg-
property name="type" value="filename"/>
<
function-
arg-
def name="dsKeyStorePasswordFile" type="optional">
<
function-
arg-
description>
Certificate keystore PIN file
</
function-
arg-
description>
<
function-
arg-
property name="type" value="filename"/>
<
function-
arg-
def name="dsKeyStorePassword" type="optional">
<
function-
arg-
description>
</
function-
arg-
description>
<
function-
arg-
property name="type" value="string"/>
<
function-
arg-
def name="dsUseSSL" type="optional">
<
function-
arg-
description>
Use SSL for secure communication with the server
</
function-
arg-
description>
<
function-
arg-
property name="type" value="option"/>
<
function-
arg-
def name="dsTrustAll" type="optional">
<
function-
arg-
description>
Trust all server SSL certificates
</
function-
arg-
description>
<
function-
arg-
property name="type" value="option"/>
<
function-
arg-
def name="dsOperationValue" type="optional">
<
function-
arg-
description>
dsOperationValue is true or false
</
function-
arg-
description>
<
function-
arg-
property name="type" value="boolean"/>
<!-- Build the Command --> dsBinPath='%s/%s' % (dsPath,fileFolder)
if dsTrustStorePasswordFile:
if dsKeyStorePasswordFile:
STAFCmdParams=' '.join(STAFCmdParamsList)
<
call function="'runCommand'" >
{ 'name' : 'Manage-account script',
'arguments' : STAFCmdParams,
<
function name="verifyReplication">
This function verifies that replication is working, that is, the updates
done on any of the servers in the topology are being pushed to the other
<
function-
arg-
def name="serverList" type="required">
<
function-
arg-
description>
List of the servers to verify against the referenceServer.
</
function-
arg-
description>
<
function-
arg-
property name="type" value="Server-list"/>
<
function-
arg-
def name="replicatedSuffix" type="required">
<
function-
arg-
description>
Suffix of the tree to verify.
</
function-
arg-
description>
<
function-
arg-
property name="type" value="DN"/>
<
function-
arg-
def name="knownIssue" type="optional" default="None">
<
function-
arg-
description>
Known issue. Corresponds to an issue number.
</
function-
arg-
description>
'verifyReplication: Verify updates on the suffix %s are being \
replicated.' % replicatedSuffix
<
iterate var="server" in="serverList" indexvar="i">
otherServersList = serverList[:i] + serverList[i+1:]
entryDn = 'uid=testentry-%s, %s' % (i, replicatedSuffix)
myKnownIssue = knownIssue
failedServers = STAXGlobal( [] )
<!-- Add entry to one of the other servers --> 'verifyReplication: Add entry %s to server %s:%s' % \
<
call function="'addAnEntry'">
{ 'location' : serverHost,
'dsInstanceHost' : serverHost,
'listAttributes' : listAttr
<
call function="'Sleep'">
{ 'sleepForMilliSeconds' : 2000 }
<!-- Check the update has been propagated --> <
paralleliterate var="otherServer" in="otherServersList">
<
call function="'ldapSearchWithScript'">
'dsFilter' : 'objectclass=*',
searchResult = STAXResult[0][1]
resultLength = len(searchResult) > 0
<
if expr="resultLength != 0">
'+++++++++++ LDAPSEARCH RESULT for %s:%s ++++++++\n%s' \
'verifyReplication: Entry %s NOT found in server %s:%s' % \
<
if expr="len(failedServers) > 0">
<!-- If at least one server failed to receive the update return an ! error, along with the list of the servers that failed to do so 'List of non-synchronized servers (replication verify FAILED \
for entry %s): %s ' % (entryDn,
comma.join(failedServers))
'All servers synchronized (replication verify SUCCEEDED for \
<
call function="'checktestRC'">
'result' : failingServerList,
<!-- Remove footprint: delete the entry just added --> <
call function="'ldapDeleteWithScript'">
{ 'location' : serverHost,
'dsInstanceHost' : serverHost,