New replication test suites + a few fixes in existing functions
7 files added
10 files modified
| New file |
| | |
| | | dn: cn=testuser-0,ou=people,o=example |
| | | objectclass: top |
| | | objectclass: person |
| | | objectclass: testobjectclass-0 |
| | | cn: testuser-0 |
| | | sn: Test |
| | | c: Testland |
| | | street: Test Lane |
| New file |
| | |
| | | dn: cn=testuser-1,ou=people,o=example |
| | | objectclass: top |
| | | objectclass: person |
| | | objectclass: testobjectclass-1 |
| | | cn: testuser-1 |
| | | sn: Test |
| | | c: Testland |
| | | street: Test Lane |
| | | testattribute-1: new test attribute |
| | | |
| New file |
| | |
| | | dn: uid=tfitter, ou=People,o=example |
| | | cn: Tom Fitter |
| | | sn: Fitter |
| | | givenname: Tom |
| | | objectclass: top |
| | | objectclass: person |
| | | objectclass: organizationalPerson |
| | | objectclass: inetOrgPerson |
| | | ou: Accounting |
| | | ou: People |
| | | l: Sunnyvale |
| | | uid: tfitter |
| | | mail: tfitter@example.com |
| | | userpassword: hamstring |
| | | |
| | |
| | | <!-- Local variables --> |
| | | <script> |
| | | myLocation=location |
| | | myPath=dsPath |
| | | taskLdifFile='import-task.ldif' |
| | | taskLdif='%s/../%s/%s' % (dsPath,relativeDataDir,taskLdifFile) |
| | | tmpTaskLdif='%s/%s' % (logsTempDir,taskLdifFile) |
| | |
| | | <!-- Start the task using ldap task interface --> |
| | | <call function="'StartLdapTask'"> |
| | | { 'location' : myLocation, |
| | | 'dsPath' : myPath, |
| | | 'taskLabel' : 'Online Import Task', |
| | | 'dsHost' : dsInstanceHost, |
| | | 'dsPort' : dsInstancePort, |
| | |
| | | <sequence> |
| | | <call function="'CheckLdapTask'"> |
| | | { 'location' : myLocation, |
| | | 'dsPath' : myPath, |
| | | 'dsTaskDn' : taskDN, |
| | | 'dsHost' : dsInstanceHost, |
| | | 'dsPort' : dsInstancePort, |
| | |
| | | <!-- Start the task using ldap task interface --> |
| | | <call function="'StartLdapTask'"> |
| | | { 'location' : myLocation, |
| | | 'dsPath' : myPath, |
| | | 'taskLabel' : 'Online Export Task', |
| | | 'dsHost' : dsInstanceHost, |
| | | 'dsPort' : dsInstancePort, |
| | |
| | | <sequence> |
| | | <call function="'CheckLdapTask'"> |
| | | { 'location' : myLocation, |
| | | 'dsPath' : myPath, |
| | | 'dsTaskDn' : taskDN, |
| | | 'dsHost' : dsInstanceHost, |
| | | 'dsPort' : dsInstancePort, |
| | |
| | | <!-- Local variables --> |
| | | <script> |
| | | myLocation=location |
| | | if dsPath: |
| | | dsBinPath='%s/%s' % (dsPath,fileFolder) |
| | | </script> |
| | | <message> |
| | | 'backup%s -n %s -d %s %s' % (fileExt,backEnd,backupDir,extraParams) |
| | |
| | | |
| | | <script> |
| | | myLocation=location |
| | | myPath=dsPath |
| | | taskLdifFile='backup-task.ldif' |
| | | taskLdif='%s/../%s/%s' % (dsPath,relativeDataDir,taskLdifFile) |
| | | tmpTaskLdif='%s/%s' % (logsTempDir,taskLdifFile) |
| | |
| | | <!-- Start the task using ldap task interface --> |
| | | <call function="'StartLdapTask'"> |
| | | { 'location' : myLocation, |
| | | 'dsPath' : myPath, |
| | | 'taskLabel' : 'Online Backup Task', |
| | | 'dsHost' : dsInstanceHost, |
| | | 'dsPort' : dsInstancePort, |
| | |
| | | <sequence> |
| | | <call function="'CheckLdapTask'"> |
| | | { 'location' : myLocation, |
| | | 'dsPath' : myPath, |
| | | 'dsTaskDn' : taskDN, |
| | | 'dsHost' : dsInstanceHost, |
| | | 'dsPort' : dsInstancePort, |
| | |
| | | <!-- Local variables --> |
| | | <script> |
| | | myLocation=location |
| | | if dsPath: |
| | | dsBinPath='%s/%s' % (dsPath,fileFolder) |
| | | </script> |
| | | |
| | | <message> |
| | |
| | | |
| | | <script> |
| | | myLocation=location |
| | | myPath=dsPath |
| | | taskLdifFile='restore-task.ldif' |
| | | taskLdif='%s/../%s/%s' % (dsPath,relativeDataDir,taskLdifFile) |
| | | tmpTaskLdif='%s/%s' % (logsTempDir,taskLdifFile) |
| | |
| | | <!-- Start the task using ldap task interface --> |
| | | <call function="'StartLdapTask'"> |
| | | { 'location' : myLocation, |
| | | 'dsPath' : myPath, |
| | | 'taskLabel' : 'Online Restore Task', |
| | | 'dsHost' : dsInstanceHost, |
| | | 'dsPort' : dsInstancePort, |
| | |
| | | <sequence> |
| | | <call function="'CheckLdapTask'"> |
| | | { 'location' : myLocation, |
| | | 'dsPath' : myPath, |
| | | 'dsTaskDn' : taskDN, |
| | | 'dsHost' : dsInstanceHost, |
| | | 'dsPort' : dsInstancePort, |
| | |
| | | <!-- Local variables --> |
| | | <script> |
| | | myLocation=location |
| | | myPath=dsPath |
| | | taskLdifFile='shutdown-task.ldif' |
| | | taskLdif='%s/../%s/%s' % (dsPath,relativeDataDir,taskLdifFile) |
| | | tmpTaskLdif='%s/%s' % (logsTempDir,taskLdifFile) |
| | |
| | | <!-- Start the task using ldap task interface --> |
| | | <call function="'StartLdapTask'"> |
| | | { 'location' : myLocation, |
| | | 'dsPath' : myPath, |
| | | 'taskLabel' : 'Online Export Task', |
| | | 'dsHost' : dsInstanceHost, |
| | | 'dsPort' : dsInstancePort, |
| | |
| | | <!-- Local variables --> |
| | | <script> |
| | | myLocation=location |
| | | myPath=dsPath |
| | | taskLdifFile='restart-task.ldif' |
| | | taskLdif='%s/../%s/%s' % (dsPath,relativeDataDir,taskLdifFile) |
| | | tmpTaskLdif='%s/%s' % (logsTempDir,taskLdifFile) |
| | |
| | | <!-- Start the task using ldap task interface --> |
| | | <call function="'StartLdapTask'"> |
| | | { 'location' : myLocation, |
| | | 'dsPath' : myPath, |
| | | 'taskLabel' : 'Online Export Task', |
| | | 'dsHost' : dsInstanceHost, |
| | | 'dsPort' : dsInstancePort, |
| | |
| | | |
| | | <script> |
| | | myLocation=location |
| | | myPath=dsPath |
| | | taskLdifFile='schema.ldif' |
| | | taskLdif='%s/../%s/%s' % (dsPath,relativeDataDir,taskLdifFile) |
| | | tmpTaskLdif='%s/%s' % (logsTempDir,taskLdifFile) |
| | |
| | | <!-- Start the task using ldap task interface --> |
| | | <call function="'StartLdapTask'"> |
| | | { 'location' : myLocation, |
| | | 'dsPath' : myPath, |
| | | 'taskLabel' : 'Online Schema Task', |
| | | 'dsHost' : dsInstanceHost, |
| | | 'dsPort' : dsInstancePort, |
| | |
| | | <!-- Check that the ldap task is completed --> |
| | | <call function="'CheckLdapTask'"> |
| | | { 'location' : myLocation, |
| | | 'dsPath' : myPath, |
| | | 'dsTaskDn' : taskDN, |
| | | 'dsHost' : dsInstanceHost, |
| | | 'dsPort' : dsInstancePort, |
| | |
| | | |
| | | <script> |
| | | myLocation=location |
| | | myPath=dsPath |
| | | taskLdifFile='leaveShutdownTask.ldif' |
| | | taskLdif='%s/../%s/%s' % (dsPath,relativeDataDir,taskLdifFile) |
| | | tmpTaskLdif='%s/%s' % (logsTempDir,taskLdifFile) |
| | |
| | | <!-- Start the task using ldap task interface --> |
| | | <call function="'StartLdapTask'"> |
| | | { 'location' : myLocation, |
| | | 'dsPath' : myPath, |
| | | 'taskLabel' : 'Online Schema Task', |
| | | 'dsHost' : dsInstanceHost, |
| | | 'dsPort' : dsInstancePort, |
| | |
| | | <!-- Check that the ldap task is completed --> |
| | | <call function="'CheckLdapTask'"> |
| | | { 'location' : myLocation, |
| | | 'dsPath' : myPath, |
| | | 'dsTaskDn' : taskDN, |
| | | 'dsHost' : dsInstanceHost, |
| | | 'dsPort' : dsInstancePort, |
| | |
| | | |
| | | </function> |
| | | |
| | | |
| | | </stax> |
| | |
| | | </function-arg-description> |
| | | <function-arg-property name="type" value="hostname"/> |
| | | </function-arg-def> |
| | | <function-arg-def name="remotehost" type="optional" default="location"> |
| | | <function-arg-description> |
| | | The name of remote host (default same as location) |
| | | </function-arg-description> |
| | | <function-arg-property name="type" value="hostname"/> |
| | | </function-arg-def> |
| | | <function-arg-def name="srcfolder" type="required"> |
| | | <function-arg-description> |
| | | The name of the source folder |
| | |
| | | <stafcmd name="'STAF Command: Copy all %s Files.' % (extension)"> |
| | | <location>'%s' % location</location> |
| | | <service>'fs'</service> |
| | | <request>'COPY DIRECTORY %s TODIRECTORY %s TOMACHINE %s EXT %s RECURSE' % (srcfolder,destfolder,location,extension) </request> |
| | | <request>'COPY DIRECTORY %s TODIRECTORY %s TOMACHINE %s EXT %s RECURSE' % (srcfolder,destfolder,remotehost,extension) </request> |
| | | </stafcmd> |
| | | <script> |
| | | cmdRC=RC |
| | |
| | | myRC = 0 |
| | | failedServers = [] |
| | | failingServerList = '' |
| | | referenceServerPath = '%s/%s' % (referenceServer.getDir(), OPENDSNAME) |
| | | referenceTree = 'referenceTree.ldif' |
| | | sampleTree = 'sampleTree.ldif' |
| | | treeDiffs = 'treeDiffs.ldif' |
| | | </script> |
| | | |
| | | <message> |
| | | 'Verify tree %s taking %s as reference.' % (treeSuffix, referenceServerPath) |
| | | </message> |
| | | |
| | | <!-- Retrieve the tree from the reference server --> |
| | | <call function="'ldapSearchWithScript'"> |
| | |
| | | |
| | | |
| | | |
| | | |
| | | <function name="verifySchemas"> |
| | | <function-prolog> |
| | | This function verifies that a schema file is synchronized all over a group of servers. |
| | | </function-prolog> |
| | | |
| | | <function-list-args> |
| | | <function-arg-def name="location" type="optional" default="'%s' % STAXServiceMachine"> |
| | | <function-arg-description> |
| | | Location of target host |
| | | </function-arg-description> |
| | | <function-arg-property name="type" value="hostname"/> |
| | | </function-arg-def> |
| | | <function-arg-def name="dsPath" type="optional" default="'%s/%s' % (DIRECTORY_INSTANCE_DIR,OPENDSNAME)"> |
| | | <function-arg-description> |
| | | Pathname to installation root |
| | | </function-arg-description> |
| | | <function-arg-property name="type" value="filepath"/> |
| | | </function-arg-def> |
| | | <function-arg-def name="referenceServer" type="required"> |
| | | <function-arg-description> |
| | | Server that should be taken as reference. |
| | | </function-arg-description> |
| | | <function-arg-property name="type" value="Server"/> |
| | | </function-arg-def> |
| | | <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> |
| | | <function-arg-def name="schemaFile" type="required"> |
| | | <function-arg-description> |
| | | Schema file to verify. |
| | | </function-arg-description> |
| | | <function-arg-property name="type" value="filename"/> |
| | | </function-arg-def> |
| | | </function-list-args> |
| | | |
| | | |
| | | |
| | | <sequence> |
| | | |
| | | <script> |
| | | myRC = 0 |
| | | failedServers = [] |
| | | failingServerList = '' |
| | | referenceServerPath = '%s/%s' % (referenceServer.getDir(), OPENDSNAME) |
| | | referenceSchema = '%s/config/schema/%s' % (referenceServerPath, schemaFile) |
| | | schemaDiffs = 'schemaDiffs.ldif' |
| | | </script> |
| | | |
| | | <message> |
| | | 'Verify schema file %s taking %s as reference.' % (schemaFile, referenceServerPath) |
| | | </message> |
| | | |
| | | <iterate var="server" in="serverList"> |
| | | <sequence> |
| | | <!-- Copy reference schema file to other server --> |
| | | <call function="'copyFile'"> |
| | | { 'location' : referenceServer.getHostname(), |
| | | 'remotehost' : server.getHostname(), |
| | | 'srcfile' : referenceSchema, |
| | | 'destfile' : '%s/reference_%s' % (server.getDir(), schemaFile) } |
| | | </call> |
| | | |
| | | <script> |
| | | serverPath = '%s/%s' % (server.getDir(), OPENDSNAME) |
| | | </script> |
| | | |
| | | <!-- Compare this schema to the reference one --> |
| | | <call function="'LdifDiffWithScript'"> |
| | | { 'location' : location, |
| | | 'dsPath' : dsPath, |
| | | 'sourceLdif' : '%s/config/schema/%s' % (serverPath, schemaFile), |
| | | 'targetLdif' : '%s/reference_%s' % (server.getDir(), schemaFile), |
| | | 'outputLdif' : '%s/%s' % (server.getDir(), schemaDiffs) } |
| | | </call> |
| | | |
| | | <script> |
| | | if STAXResult != 0 : |
| | | failedServers.append('%s:%s' % (server.getHostname(), server.getPort())) |
| | | </script> |
| | | </sequence> |
| | | </iterate> |
| | | |
| | | <if expr="len(failedServers) > 0"> |
| | | <!-- If at least one server failed to successfully compare to the reference tree, |
| | | ! return an error, along with the list of the servers that failed to do so --> |
| | | <script> |
| | | myRC = 1 |
| | | comma = ',' |
| | | failingServerList = 'List of non-synchronized servers (schema verify FAILED): %s ' % comma.join(failedServers) |
| | | </script> |
| | | <else> |
| | | <script> |
| | | failingServerList = 'All servers synchronized (schema verify SUCCEEDED).' |
| | | </script> |
| | | </else> |
| | | </if> |
| | | |
| | | |
| | | <call function="'checktestRC'"> |
| | | { 'returncode' : myRC, |
| | | 'result' : failingServerList , |
| | | 'expected' : 0 } |
| | | </call> |
| | | |
| | | <return> [myRC, failedServers] </return> |
| | | </sequence> |
| | | |
| | | </function> |
| | | |
| | | |
| | | |
| | | |
| | | <function name="deleteTrees"> |
| | | <function-prolog> |
| | | This function deletes a (sub)tree from a list of servers. |
| | | </function-prolog> |
| | | <function-list-args> |
| | | <function-arg-def name="serverList" type="required"> |
| | | <function-arg-description> |
| | | List of the servers (instances of "Server" class) where the tree will be deleted. |
| | | </function-arg-description> |
| | | <function-arg-property name="type" value="Server-list"/> |
| | | </function-arg-def> |
| | | <function-arg-def name="treeSuffix" type="required"> |
| | | <function-arg-description> |
| | | Suffix of the tree to delete. |
| | | </function-arg-description> |
| | | <function-arg-property name="type" value="DN"/> |
| | | </function-arg-def> |
| | | <function-arg-def name="startDS" type="optional" default="True"> |
| | | <function-arg-description> |
| | | Need to start the Directory Servers before deleting. |
| | | </function-arg-description> |
| | | <function-arg-property name="type" value="boolean"/> |
| | | </function-arg-def> |
| | | </function-list-args> |
| | | |
| | | <sequence> |
| | | |
| | | <if expr="startDS"> |
| | | <!-- Start the servers in the list --> |
| | | <call function="'startServers'"> |
| | | [serverList] |
| | | </call> |
| | | </if> |
| | | |
| | | <!-- Delete the tree in every server in the list --> |
| | | <paralleliterate var="server" in="serverList"> |
| | | <sequence> |
| | | <message> |
| | | 'Delete suffix %s on server running on host %s on port %s' % (treeSuffix, server.getHostname(), server.getPort()) |
| | | </message> |
| | | |
| | | <!-- Delete suffix and subtree --> |
| | | <call function="'ldapDeleteWithScript'"> |
| | | { 'location' : server.getHostname(), |
| | | 'dsPath' : '%s/%s' % (server.getDir(),OPENDSNAME), |
| | | 'dsInstanceHost' : server.getHostname(), |
| | | 'dsInstancePort' : server.getPort(), |
| | | 'dsInstanceDn' : server.getRootDn(), |
| | | 'dsInstancePswd' : server.getRootPwd(), |
| | | 'dsDn' : [treeSuffix], |
| | | 'dsDeleteSubtree' : True } |
| | | </call> |
| | | </sequence> |
| | | </paralleliterate> |
| | | |
| | | <if expr="startDS"> |
| | | <!-- Stop the servers in the list --> |
| | | <call function="'stopServers'"> |
| | | [serverList] |
| | | </call> |
| | | </if> |
| | | |
| | | </sequence> |
| | | |
| | | </function> |
| | | |
| | | |
| | | |
| | | |
| | | <function name="startServers"> |
| | | <function-prolog> |
| | | This function starts a list of servers. |
| | | </function-prolog> |
| | | <function-list-args> |
| | | <function-arg-def name="serverList" type="required"> |
| | | <function-arg-description> |
| | | List of the servers (instances of "Server" class) to be started. |
| | | </function-arg-description> |
| | | <function-arg-property name="type" value="Server-list"/> |
| | | </function-arg-def> |
| | | </function-list-args> |
| | | |
| | | <sequence> |
| | | <!-- Start the servers in the list --> |
| | | <paralleliterate var="server" in="serverList"> |
| | | <sequence> |
| | | <message> |
| | | 'Start DS on host %s to run on port %s' % (server.getHostname(),server.getPort()) |
| | | </message> |
| | | |
| | | <!--- Start DS --> |
| | | <call function="'StartDsWithScript'"> |
| | | { 'location' : server.getHostname(), |
| | | 'dsPath' : '%s/%s' % (server.getDir(),OPENDSNAME) } |
| | | </call> |
| | | |
| | | <!--- Check that DS started --> |
| | | <call function="'isAlive'"> |
| | | { 'location' : server.getHostname(), |
| | | 'dsPath' : '%s/%s' % (server.getDir(),OPENDSNAME), |
| | | 'dsInstanceHost' : server.getHostname(), |
| | | 'dsInstancePort' : server.getPort(), |
| | | 'dsInstanceDn' : server.getRootDn(), |
| | | 'dsInstancePswd' : server.getRootPwd(), |
| | | 'noOfLoops' : 5 , |
| | | 'noOfMilliSeconds' : 2000 } |
| | | </call> |
| | | </sequence> |
| | | </paralleliterate> |
| | | |
| | | </sequence> |
| | | |
| | | </function> |
| | | |
| | | |
| | | |
| | | <function name="stopServers"> |
| | | <function-prolog> |
| | | This function stops a list of servers. |
| | | </function-prolog> |
| | | <function-list-args> |
| | | <function-arg-def name="serverList" type="required"> |
| | | <function-arg-description> |
| | | List of the servers (instances of "Server" class) to be stopped. |
| | | </function-arg-description> |
| | | <function-arg-property name="type" value="Server-list"/> |
| | | </function-arg-def> |
| | | </function-list-args> |
| | | |
| | | <sequence> |
| | | <!-- Stop the servers in the list --> |
| | | <paralleliterate var="server" in="serverList"> |
| | | <sequence> |
| | | <message> |
| | | 'Stop DS on host %s running on port %s' % (server.getHostname(),server.getPort()) |
| | | </message> |
| | | |
| | | <!--- Stop DS --> |
| | | <call function="'StopDsWithScript'"> |
| | | { 'location' : server.getHostname(), |
| | | 'dsHost' : server.getHostname(), |
| | | 'dsPath' : '%s/%s' % (server.getDir(),OPENDSNAME), |
| | | 'dsPort' : server.getPort(), |
| | | 'dsBindDN' : server.getRootDn(), |
| | | 'dsBindPwd' : server.getRootPwd() } |
| | | </call> |
| | | </sequence> |
| | | </paralleliterate> |
| | | |
| | | </sequence> |
| | | |
| | | </function> |
| | | |
| | | |
| | | <function name="CLI_rebuild-index"> |
| | | <function-prolog> |
| | | This wraps the rebuild-index tool to make it easy to use from STAX |
| | |
| | | |
| | | <script> |
| | | replicationServer = syncserver.getChangelogServer() |
| | | replicatedSuffixList = server.getSynchronizedSuffixList() |
| | | replicatedSuffixList = syncserver.getSynchronizedSuffixList() |
| | | </script> |
| | | |
| | | <if expr="replicationServer"> |
| | |
| | | |
| | | <call function="'testSuite_Preamble'"/> |
| | | |
| | | <!--- Test Suite information |
| | | #@TestSuiteName Replication Basic Tests |
| | | #@TestSuitePurpose Verify that the basic operations are replicated correctly between two serrvers. |
| | | #@TestSuiteID Basic Tests |
| | | #@TestSuiteGroup Basic |
| | | #@TestGroup Replication |
| | | #@TestScript replication_basic.xml |
| | | #@TestHTMLLink http://opends.dev.java.net/ |
| | | --> |
| | | |
| | | |
| | | <import machine="'%s' % (STAF_LOCAL_HOSTNAME)" |
| | | file="'%s/testcases/replication/replication_setup.xml' % (TESTS_DIR)"/> |
| | | <call function="'replication_setup'" /> |
| | |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname(), |
| | | 'dsInstancePort' : server1.getPort(), |
| | | 'dsInstanceDn' : server1.getRootDn(), |
| | | 'dsInstancePswd' : server1.getRootPwd(), |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication_add_root_suffix.ldif' % clientDataDir } |
| | | </call> |
| | | |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : synchroSuffix , |
| | | 'dsFilter' : 'objectclass=*' } |
| | | </call> |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname(), |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'entryToBeAdded' : '%s/replication_add_single.ldif' % clientDataDir } |
| | | </call> |
| | | <call function="'ldapModifyWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsFilename' : '%s/replication_mod.ldif' % clientDataDir } |
| | | </call> |
| | | |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : entryDn, |
| | | 'dsFilter' : '%s=%s' % (attr_type,attr_value) } |
| | | </call> |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | <call function="'DeleteEntry'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : entryDn } |
| | | </call> |
| | | |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : entryDn, |
| | | 'dsFilter' : 'objectclass=*' , |
| | | 'expectedRC' : 32 } |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | <call function="'DeleteEntry'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : synchroSuffix } |
| | | </call> |
| | | |
| | |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname(), |
| | | 'dsInstancePort' : server1.getPort(), |
| | | 'dsInstanceDn' : server1.getRootDn(), |
| | | 'dsInstancePswd' : server1.getRootPwd(), |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/Example.ldif' % clientDataDir } |
| | | </call> |
| | | |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=scarter,ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : 'objectclass=*' } |
| | | </call> |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | |
| | | <!-- Modify "master" server --> |
| | | <call function="'modifyAnAttribute'"> |
| | | { 'dsPath' : server1Path, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort(), |
| | | 'dsInstanceDn' : server1.getRootDn(), |
| | | 'dsInstancePswd' : server1.getRootPwd(), |
| | | { 'dsPath' : masterPath, |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'DNToModify' : 'uid=tmorris, ou=People,%s' % synchroSuffix, |
| | | 'attributeName' : 'description', |
| | | 'newAttributeValue' : ' ', |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=tmorris, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : 'description=*' } |
| | | </call> |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | |
| | | <!-- Modify "master" server --> |
| | | <call function="'modifyAnAttribute'"> |
| | | { 'dsPath' : server1Path, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort(), |
| | | 'dsInstanceDn' : server1.getRootDn(), |
| | | 'dsInstancePswd' : server1.getRootPwd(), |
| | | { 'dsPath' : masterPath, |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'DNToModify' : 'uid=tmorris, ou=People,%s' % synchroSuffix, |
| | | 'attributeName' : 'departmentnumber', |
| | | 'newAttributeValue' : '5203214400', |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=tmorris, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : 'departmentnumber=5203214400' } |
| | | </call> |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | <call function="'ldapModifyWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsFilename' : '%s/%s' % (clientDataDir, filename) } |
| | | </call> |
| | | |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=smason, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : 'roomNumber=*', |
| | | 'expectedRC' : 0 } |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | |
| | | <!-- Modify "master" server --> |
| | | <call function="'modifyAnAttribute'"> |
| | | { 'dsPath' : server1Path, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort(), |
| | | 'dsInstanceDn' : server1.getRootDn(), |
| | | 'dsInstancePswd' : server1.getRootPwd(), |
| | | { 'dsPath' : masterPath, |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'DNToModify' : 'uid=jwalker, ou=People,%s' % synchroSuffix, |
| | | 'attributeName' : 'roomNumber', |
| | | 'newAttributeValue' : '3915', |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=jwalker, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : 'roomNumber=3915' , |
| | | 'expectedRC' : 0 } |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | |
| | | <!-- Modify "master" server --> |
| | | <call function="'modifyAnAttribute'"> |
| | | { 'dsPath' : server1Path, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort(), |
| | | 'dsInstanceDn' : server1.getRootDn(), |
| | | 'dsInstancePswd' : server1.getRootPwd(), |
| | | { 'dsPath' : masterPath, |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'DNToModify' : 'uid=jwallace, ou=People,%s' % synchroSuffix, |
| | | 'listAttributes' : valuesToAdd, |
| | | 'changetype' : 'add' } |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=jwallace, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : '&(postaladdress=Residence Parc Europe)(postaladdress=Appartement #6)(postaladdress=31 Rue General Mangin)(postaladdress=38100 Grenoble)' } |
| | | </call> |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | |
| | | <!-- Modify "master" server --> |
| | | <call function="'modifyAnAttribute'"> |
| | | { 'dsPath' : server1Path, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort(), |
| | | 'dsInstanceDn' : server1.getRootDn(), |
| | | 'dsInstancePswd' : server1.getRootPwd(), |
| | | { 'dsPath' : masterPath, |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'DNToModify' : 'uid=jwallace, ou=People,%s' % synchroSuffix, |
| | | 'listAttributes' : valuesToDelete, |
| | | 'changetype' : 'delete' } |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=jwallace, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : '|(postaladdress=Appartement #6)(postaladdress=38100 Grenoble)', |
| | | 'expectedRC' : 0 } |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | |
| | | <!-- Modify "master" server --> |
| | | <call function="'modifyAnAttribute'"> |
| | | { 'dsPath' : server1Path, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort(), |
| | | 'dsInstanceDn' : server1.getRootDn(), |
| | | 'dsInstancePswd' : server1.getRootPwd(), |
| | | { 'dsPath' : masterPath, |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'DNToModify' : 'uid=jwallace, ou=People,%s' % synchroSuffix, |
| | | 'listAttributes' : valuesToReplace, |
| | | 'changetype' : 'replace' } |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=jwallace, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : '&(postaladdress=Residence Letilleuil)(postaladdress=18 rue Nicolas Chorier)', |
| | | 'expectedRC' : 0 } |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | |
| | | <!-- Modify "master" server --> |
| | | <call function="'modifyAnAttribute'"> |
| | | { 'dsPath' : server1Path, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort(), |
| | | 'dsInstanceDn' : server1.getRootDn(), |
| | | 'dsInstancePswd' : server1.getRootPwd(), |
| | | { 'dsPath' : masterPath, |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'DNToModify' : 'uid=jwallace, ou=People,%s' % synchroSuffix, |
| | | 'listAttributes' : valuesToAdd, |
| | | 'changetype' : 'add' } |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=jwallace, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : 'postaladdress=38000 Grenoble', |
| | | 'expectedRC' : 0 } |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | |
| | | <!-- Modify "master" server --> |
| | | <call function="'modifyAnAttribute'"> |
| | | { 'dsPath' : server1Path, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort(), |
| | | 'dsInstanceDn' : server1.getRootDn(), |
| | | 'dsInstancePswd' : server1.getRootPwd(), |
| | | { 'dsPath' : masterPath, |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'DNToModify' : 'uid=jwallace, ou=People,%s' % synchroSuffix, |
| | | 'listAttributes' : valuesToDelete, |
| | | 'changetype' : 'delete' } |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=jwallace, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : 'postaladdress=Residence Letilleuil', |
| | | 'expectedRC' : 0 } |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | </message> |
| | | |
| | | |
| | | <script> |
| | | entryAttributes = [] |
| | | entryAttributes.append('cn: Tom Fitter') |
| | | entryAttributes.append('sn: Fitter') |
| | | entryAttributes.append('givenname: Tom') |
| | | entryAttributes.append('objectclass: top') |
| | | entryAttributes.append('objectclass: person') |
| | | entryAttributes.append('objectclass: organizationalPerson') |
| | | entryAttributes.append('objectclass: inetOrgPerson') |
| | | entryAttributes.append('ou: Accounting') |
| | | entryAttributes.append('ou: People') |
| | | entryAttributes.append('l: Sunnyvale') |
| | | entryAttributes.append('uid: tfitter') |
| | | entryAttributes.append('mail: tfitter@example.com') |
| | | entryAttributes.append('telephonenumber: +1 804 555 8974') |
| | | entryAttributes.append('facsimiletelephonenumber: +1 804 555 1579') |
| | | entryAttributes.append('roomnumber: 2164') |
| | | entryAttributes.append('userpassword: hamstring') |
| | | entryAttributes.append('description: PROFESSION Tap Fitter and PLUMBER') |
| | | <!-- Modify "master" server --> |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/tfitter.ldif' % clientDataDir } |
| | | </call> |
| | | |
| | | <script> |
| | | valuesToReplace = [] |
| | | valuesToReplace.append('description: Profession Tap Fitter and Plumber') |
| | | </script> |
| | | |
| | | <!-- Modify "master" server --> |
| | | <call function="'addAnEntry'"> |
| | | { 'dsPath' : server1Path, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort(), |
| | | 'dsInstanceDn' : server1.getRootDn(), |
| | | 'dsInstancePswd' : server1.getRootPwd(), |
| | | 'DNToAdd' : 'uid=tfitter, ou=People,%s' % synchroSuffix, |
| | | 'listAttributes' : entryAttributes } |
| | | </call> |
| | | |
| | | <call function="'modifyAnAttribute'"> |
| | | { 'dsPath' : server1Path, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort(), |
| | | 'dsInstanceDn' : server1.getRootDn(), |
| | | 'dsInstancePswd' : server1.getRootPwd(), |
| | | { 'dsPath' : masterPath, |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'DNToModify' : 'uid=tfitter, ou=People,%s' % synchroSuffix, |
| | | 'listAttributes' : valuesToReplace, |
| | | 'changetype' : 'replace' } |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=tfitter, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : 'description=Profession Tap Fitter and Plumber', |
| | | 'expectedRC' : 0 } |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | <call function="'ldapModifyWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsFilename' : '%s/%s' % (clientDataDir, filename) } |
| | | </call> |
| | | |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=hmiller, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : 'jpegPhoto=*', |
| | | 'expectedRC' : 0 } |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | <call function="'ldapModifyWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsFilename' : '%s/%s' % (clientDataDir, filename) } |
| | | </call> |
| | | |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=hmiller, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : 'jpegPhoto=*', |
| | | 'expectedRC' : 0 } |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | <call function="'ldapModifyWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsFilename' : '%s/%s' % (clientDataDir, filename) } |
| | | </call> |
| | | |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=hmiller, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : 'jpegPhoto=*', |
| | | 'expectedRC' : 0 } |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | <call function="'ldapModifyWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsFilename' : '%s/%s' % (clientDataDir, filename) } |
| | | </call> |
| | | |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=kvaughan, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : 'objectclass=*', |
| | | 'expectedRC' : 32 } |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=kvaughan2, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : 'objectclass=*' } |
| | | </call> |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | <call function="'ldapModifyWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsFilename' : '%s/%s' % (clientDataDir, filename) } |
| | | </call> |
| | | |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=jwallace, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : 'objectclass=*', |
| | | 'expectedRC' : 32 } |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=igueye, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : 'uid=jwallace' } |
| | | </call> |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | |
| | | <call function="'ldapModifyWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsFilename' : '%s/%s' % (clientDataDir, filename) } |
| | | </call> |
| | | |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=gfarmer, ou=People,%s' % synchroSuffix, |
| | | 'dsFilter' : 'objectclass=*', |
| | | 'expectedRC' : 32 } |
| | |
| | | <call function="'ldapSearchWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server1.getHostname() , |
| | | 'dsInstancePort' : server1.getPort() , |
| | | 'dsInstanceDn' : server1.getRootDn() , |
| | | 'dsInstancePswd' : server1.getRootPwd() , |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort() , |
| | | 'dsInstanceDn' : master.getRootDn() , |
| | | 'dsInstancePswd' : master.getRootPwd() , |
| | | 'dsBaseDN' : 'uid=gfarmer, ou=Special People, ou=Special Users,%s' % synchroSuffix, |
| | | 'dsFilter' : 'objectclass=*' } |
| | | </call> |
| | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, server1, [server2], synchroSuffix ] |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | |
| | |
| | | </message> |
| | | |
| | | <script> |
| | | server1Path = '%s/%s' % (server1.getDir(),OPENDSNAME) |
| | | synchroSuffix = server1.getSynchronizedSuffixList()[0].getSuffixDn() |
| | | synchroSuffix = master.getSynchronizedSuffixList()[0].getSuffixDn() |
| | | entryDn = 'uid=scarter,%s' % synchroSuffix |
| | | grandchildEntryDn = 'uid=scarter,ou=People,o=replication tests,%s' % synchroSuffix |
| | | mod_type = 'replace' |
| | |
| | | <call function="'main_totalupdate'" /> |
| | | |
| | | <import machine="'%s' % (STAF_LOCAL_HOSTNAME)" |
| | | file="'%s/testcases/replication/binarycopy/replication_binarycopy.xml' % (TESTS_DIR)"/> |
| | | <call function="'replication_binarycopy'" /> |
| | | |
| | | <import machine="'%s' % (STAF_LOCAL_HOSTNAME)" |
| | | file="'%s/testcases/replication/ldifimport/replication_ldifimport.xml' % (TESTS_DIR)"/> |
| | | <call function="'replication_ldifimport'" /> |
| | | |
| | | <import machine="'%s' % (STAF_LOCAL_HOSTNAME)" |
| | | file="'%s/testcases/replication/resynchronization/replication_resynchronization.xml' % (TESTS_DIR)"/> |
| | | <call function="'replication_resynchronization'" /> |
| | | |
| | | <import machine="'%s' % (STAF_LOCAL_HOSTNAME)" |
| | | file="'%s/testcases/replication/basic/replication_basic.xml' % (TESTS_DIR)"/> |
| | | <call function="'replication_basic'" /> |
| | | |
| | | <import machine="'%s' % (STAF_LOCAL_HOSTNAME)" |
| | | file="'%s/testcases/replication/schema/replication_schema.xml' % (TESTS_DIR)"/> |
| | | <call function="'replication_schema'" /> |
| | | |
| | | <call function="'testGroup_Postamble'"/> |
| | | |
| | | </sequence> |
| | |
| | | <sequence> |
| | | |
| | | <!-- Stop the servers in the topology --> |
| | | <iterate var="server" in="_topologyServerList"> |
| | | <sequence> |
| | | |
| | | <message> |
| | | 'Stop DS on host %s running on port %s' % (server.getHostname(),server.getPort()) |
| | | </message> |
| | | |
| | | <!--- Stop DS --> |
| | | <call function="'StopDsWithScript'"> |
| | | { 'location' : server.getHostname(), |
| | | 'dsHost' : server.getHostname(), |
| | | 'dsPath' : '%s/%s' % (server.getDir(),OPENDSNAME), |
| | | 'dsPort' : server.getPort(), |
| | | 'dsBindDN' : server.getRootDn(), |
| | | 'dsBindPwd' : server.getRootPwd() } |
| | | <call function="'stopServers'"> |
| | | [_topologyServerList] |
| | | </call> |
| | | |
| | | <call function="'checkRC'"> |
| | | { 'returncode' : RC , |
| | | 'result' : STAXResult } |
| | | </call> |
| | | |
| | | </sequence> |
| | | |
| | | </iterate> |
| | | |
| | | <!-- Remove the topology created for the test suite --> |
| | | <message> |
| | | 'Remove DS topology created for the Synchronization Basic Test Suite' |
| | |
| | | |
| | | server1 = _topologyServerList[0] |
| | | server2 = _topologyServerList[1] |
| | | |
| | | master = _topologyServerList[0] |
| | | masterHost = master.getHostname() |
| | | masterPath = '%s/%s' % (master.getDir(),OPENDSNAME) |
| | | masterDataDir = '%s/%s' % (master.getDir(),relativeDataDir) |
| | | |
| | | consumerList = _topologyServerList[1:] |
| | | </script> |
| | | |
| | | <!-- Start the servers in the topology --> |
| | | <iterate var="server" in="_topologyServerList"> |
| | | <sequence> |
| | | |
| | | <message> |
| | | 'Start DS on host %s to run on port %s' % (server.getHostname(),server.getPort()) |
| | | </message> |
| | | |
| | | <!--- Start DS --> |
| | | <call function="'StartDsWithScript'"> |
| | | { 'location' : server.getHostname(), |
| | | 'dsPath' : '%s/%s' % (server.getDir(),OPENDSNAME) } |
| | | <call function="'startServers'"> |
| | | [_topologyServerList] |
| | | </call> |
| | | |
| | | <call function="'checkRC'"> |
| | | { 'returncode' : RC , |
| | | 'result' : STAXResult } |
| | | </call> |
| | | |
| | | </sequence> |
| | | </iterate> |
| | | |
| | | <!-- Check that the servers in the topology started --> |
| | | <iterate var="server" in="_topologyServerList"> |
| | | <!--- Check that DS started --> |
| | | <call function="'isAlive'"> |
| | | { 'location' : server.getHostname(), |
| | | 'dsPath' : '%s/%s' % (server.getDir(),OPENDSNAME), |
| | | 'dsInstanceHost' : server.getHostname(), |
| | | 'dsInstancePort' : server.getPort(), |
| | | 'dsInstanceDn' : server.getRootDn(), |
| | | 'dsInstancePswd' : server.getRootPwd(), |
| | | 'noOfLoops' : 5 , |
| | | 'noOfMilliSeconds' : 2000 } |
| | | </call> |
| | | </iterate> |
| | | |
| | | </sequence> |
| | | |
| | | </block> |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8" standalone="no"?> |
| | | <!DOCTYPE stax SYSTEM "../../../shared/stax.dtd"> |
| | | <!-- |
| | | ! CDDL HEADER START |
| | | ! |
| | | ! The contents of this file are subject to the terms of the |
| | | ! Common Development and Distribution License, Version 1.0 only |
| | | ! (the "License"). You may not use this file except in compliance |
| | | ! with the License. |
| | | ! |
| | | ! You can obtain a copy of the license at |
| | | ! trunk/opends/resource/legal-notices/OpenDS.LICENSE |
| | | ! or https://OpenDS.dev.java.net/OpenDS.LICENSE. |
| | | ! See the License for the specific language governing permissions |
| | | ! and limitations under the License. |
| | | ! |
| | | ! When distributing Covered Code, include this CDDL HEADER in each |
| | | ! file and include the License file at |
| | | ! trunk/opends/resource/legal-notices/OpenDS.LICENSE. If applicable, |
| | | ! add the following below this CDDL HEADER, with the fields enclosed |
| | | ! by brackets "[]" replaced with your own identifying information: |
| | | ! Portions Copyright [yyyy] [name of copyright owner] |
| | | ! |
| | | ! CDDL HEADER END |
| | | ! |
| | | ! Portions Copyright 2006-2007 Sun Microsystems, Inc. |
| | | ! --> |
| | | <stax> |
| | | |
| | | <defaultcall function="replication_binarycopy"/> |
| | | |
| | | <function name="replication_binarycopy"> |
| | | |
| | | <sequence> |
| | | |
| | | <block name="'binarycopy'"> |
| | | |
| | | <sequence> |
| | | |
| | | <script> |
| | | if not CurrentTestPath.has_key('group'): |
| | | CurrentTestPath['group']='replication' |
| | | CurrentTestPath['suite']=STAXCurrentBlock |
| | | </script> |
| | | |
| | | <call function="'testSuite_Preamble'"/> |
| | | |
| | | <!--- Test Suite information |
| | | #@TestSuiteName Replication Binary Copy Tests |
| | | #@TestSuitePurpose Verify that the servers in a replicated topology can be initialised by the means of a binary copy (backup-restore). |
| | | #@TestSuiteID Binary Copy Tests |
| | | #@TestSuiteGroup Binary Copy |
| | | #@TestGroup Replication |
| | | #@TestScript replication_binarycopy.xml |
| | | #@TestHTMLLink http://opends.dev.java.net/ |
| | | --> |
| | | |
| | | |
| | | <import machine="'%s' % (STAF_LOCAL_HOSTNAME)" |
| | | file="'%s/testcases/replication/replication_setup.xml' % (TESTS_DIR)"/> |
| | | <call function="'replication_setup'" /> |
| | | |
| | | <script> |
| | | synchroSuffix = master.getSynchronizedSuffixList()[0].getSuffixDn() |
| | | </script> |
| | | |
| | | <!--- Test Case information |
| | | #@TestMarker Replication Binary Copy Tests |
| | | #@TestName Replication: Binary Copy: Off-line initialisation |
| | | #@TestID Off-line initialisation |
| | | #@TestPurpose Initialise replicated servers using off-line backup/restore |
| | | #@TestPreamble |
| | | #@TestSteps |
| | | #@TestPostamble |
| | | #@TestResult |
| | | --> |
| | | <testcase name="'Replication: Binary Copy: Off-line initialisation'"> |
| | | <sequence> |
| | | <call function="'testCase_Preamble'"/> |
| | | <message> |
| | | 'Replication: Binary Copy: Off-line initialisation. Initialise replicated servers using off-line backup/restore' |
| | | </message> |
| | | |
| | | <!-- Stop the servers in the topology --> |
| | | <call function="'stopServers'"> |
| | | [_topologyServerList] |
| | | </call> |
| | | |
| | | |
| | | <!-- Import data into "master" server --> |
| | | <call function="'ImportLdifWithScript'"> |
| | | { 'location' : masterHost, |
| | | 'dsPath' : masterPath, |
| | | 'dsLdifFile' : '%s/replication/Example.ldif' % masterDataDir } |
| | | </call> |
| | | |
| | | <!-- Check some data was imported into "master" server --> |
| | | <call function="'checkImport'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsHost' : masterHost, |
| | | 'dsPort' : master.getPort(), |
| | | 'dsDn' : master.getRootDn(), |
| | | 'dsPswd' : master.getRootPwd(), |
| | | 'expectedEntries' : ['uid=scarter,ou=People,o=example', |
| | | 'uid=dmiller, ou=People, o=example', |
| | | 'uid=rhunt, ou=People, o=example'] } |
| | | </call> |
| | | |
| | | |
| | | <!-- Backup "master" server --> |
| | | <call function="'backup'"> |
| | | { 'location' : masterHost, |
| | | 'dsPath' : masterPath, |
| | | 'backupDir' : '%s/replication/master_backup' % masterDataDir } |
| | | </call> |
| | | |
| | | <!-- Copy backup to "consumer" servers and restore it --> |
| | | <paralleliterate var="consumer" in="consumerList"> |
| | | <sequence> |
| | | <call function="'CopyFolderByExtension'"> |
| | | { 'location' : masterHost, |
| | | 'remotehost' : consumer.getHostname(), |
| | | 'srcfolder' : '%s/replication/master_backup' % masterDataDir, |
| | | 'destfolder' : '%s/%s/replication/master_backup' % (consumer.getDir(),relativeDataDir), |
| | | 'extension' : '*' } |
| | | </call> |
| | | |
| | | <call function="'restore'"> |
| | | { 'location' : consumer.getHostname(), |
| | | 'dsPath' : '%s/%s' % (consumer.getDir(), OPENDSNAME), |
| | | 'backupDir' : '%s/%s/replication/master_backup' % (consumer.getDir(),relativeDataDir) } |
| | | </call> |
| | | </sequence> |
| | | </paralleliterate> |
| | | |
| | | |
| | | |
| | | <!-- Start the servers in the topology --> |
| | | <call function="'startServers'"> |
| | | [_topologyServerList] |
| | | </call> |
| | | |
| | | |
| | | |
| | | <!-- Add entry to "master" server --> |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/tfitter.ldif' % clientDataDir } |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | | </sequence> |
| | | </testcase> |
| | | |
| | | |
| | | |
| | | <!--- Test Case information |
| | | #@TestMarker Replication Binary Copy Tests |
| | | #@TestName Replication: Binary Copy: On-line initialisation |
| | | #@TestID On-line initialisation |
| | | #@TestPurpose Initialise replicated servers using on-line backup/restore |
| | | #@TestPreamble |
| | | #@TestSteps |
| | | #@TestPostamble |
| | | #@TestResult |
| | | --> |
| | | <testcase name="'Replication: Binary Copy: On-line initialisation'"> |
| | | <sequence> |
| | | <call function="'testCase_Preamble'"/> |
| | | <message> |
| | | 'Replication: Binary Copy: On-line initialisation. Initialise replicated servers using on-line backup/restore' |
| | | </message> |
| | | |
| | | <!-- Clean the servers in the topology |
| | | <call function="'deleteTrees'"> |
| | | [_topologyServerList, synchroSuffix, False] |
| | | </call> --> |
| | | |
| | | <!-- Delete manually added entry so that replication server won't add it automatically later on --> |
| | | <call function="'ldapDeleteWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : master.getHostname(), |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'dsDn' : ['uid=tfitter, ou=People,%s' % synchroSuffix] } |
| | | </call> |
| | | |
| | | <!-- Import data into "master" server --> |
| | | <call function="'importLdifTask'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'taskID' : 'import task', |
| | | 'ldifFile' : '%s/replication/Example.ldif' % masterDataDir } |
| | | </call> |
| | | |
| | | <!-- Check some data was imported into "master" server --> |
| | | <call function="'checkImport'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsHost' : masterHost, |
| | | 'dsPort' : master.getPort(), |
| | | 'dsDn' : master.getRootDn(), |
| | | 'dsPswd' : master.getRootPwd(), |
| | | 'expectedEntries' : ['uid=scarter,ou=People,o=example', |
| | | 'uid=dmiller, ou=People, o=example', |
| | | 'uid=rhunt, ou=People, o=example'], |
| | | 'startDS' : 'no' } |
| | | </call> |
| | | |
| | | |
| | | <!-- Backup "master" server --> |
| | | <call function="'backupTask'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'taskID' : 'backup task', |
| | | 'backupDir' : '%s/replication/master_backup_online' % masterDataDir } |
| | | </call> |
| | | |
| | | <!-- Copy backup to "consumer" servers and restore it --> |
| | | <paralleliterate var="consumer" in="consumerList"> |
| | | <sequence> |
| | | <call function="'CopyFolderByExtension'"> |
| | | { 'location' : masterHost, |
| | | 'remotehost' : consumer.getHostname(), |
| | | 'srcfolder' : '%s/replication/master_backup_online' % masterDataDir, |
| | | 'destfolder' : '%s/%s/replication/master_backup_online' % (consumer.getDir(),relativeDataDir), |
| | | 'extension' : '*' } |
| | | </call> |
| | | |
| | | <call function="'restoreTask'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : consumer.getHostname(), |
| | | 'dsInstancePort' : consumer.getPort(), |
| | | 'dsInstanceDn' : consumer.getRootDn(), |
| | | 'dsInstancePswd' : consumer.getRootPwd(), |
| | | 'taskID' : 'restore task', |
| | | 'backupDir' : '%s/%s/replication/master_backup_online' % (consumer.getDir(),relativeDataDir) } |
| | | </call> |
| | | </sequence> |
| | | </paralleliterate> |
| | | |
| | | |
| | | |
| | | <!-- Add entry to "master" server --> |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/tfitter.ldif' % clientDataDir } |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | | </sequence> |
| | | </testcase> |
| | | |
| | | |
| | | |
| | | <import machine="'%s' % (STAF_LOCAL_HOSTNAME)" |
| | | file="'%s/testcases/replication/replication_cleanup.xml' % (TESTS_DIR)"/> |
| | | <call function="'replication_cleanup'" /> |
| | | |
| | | <call function="'testSuite_Postamble'"/> |
| | | |
| | | </sequence> |
| | | |
| | | </block> |
| | | |
| | | </sequence> |
| | | |
| | | </function> |
| | | |
| | | </stax> |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8" standalone="no"?> |
| | | <!DOCTYPE stax SYSTEM "../../../shared/stax.dtd"> |
| | | <!-- |
| | | ! CDDL HEADER START |
| | | ! |
| | | ! The contents of this file are subject to the terms of the |
| | | ! Common Development and Distribution License, Version 1.0 only |
| | | ! (the "License"). You may not use this file except in compliance |
| | | ! with the License. |
| | | ! |
| | | ! You can obtain a copy of the license at |
| | | ! trunk/opends/resource/legal-notices/OpenDS.LICENSE |
| | | ! or https://OpenDS.dev.java.net/OpenDS.LICENSE. |
| | | ! See the License for the specific language governing permissions |
| | | ! and limitations under the License. |
| | | ! |
| | | ! When distributing Covered Code, include this CDDL HEADER in each |
| | | ! file and include the License file at |
| | | ! trunk/opends/resource/legal-notices/OpenDS.LICENSE. If applicable, |
| | | ! add the following below this CDDL HEADER, with the fields enclosed |
| | | ! by brackets "[]" replaced with your own identifying information: |
| | | ! Portions Copyright [yyyy] [name of copyright owner] |
| | | ! |
| | | ! CDDL HEADER END |
| | | ! |
| | | ! Portions Copyright 2006-2007 Sun Microsystems, Inc. |
| | | ! --> |
| | | <stax> |
| | | |
| | | <defaultcall function="replication_ldifimport"/> |
| | | |
| | | <function name="replication_ldifimport"> |
| | | |
| | | <sequence> |
| | | |
| | | <block name="'ldifimport'"> |
| | | |
| | | <sequence> |
| | | |
| | | <script> |
| | | if not CurrentTestPath.has_key('group'): |
| | | CurrentTestPath['group']='replication' |
| | | CurrentTestPath['suite']=STAXCurrentBlock |
| | | </script> |
| | | |
| | | <call function="'testSuite_Preamble'"/> |
| | | |
| | | <!--- Test Suite information |
| | | #@TestSuiteName Replication Ldif Import Tests |
| | | #@TestSuitePurpose Verify that the servers in a replicated topology can be initialised by the means of an ldif import. |
| | | #@TestSuiteID Ldif Import Tests |
| | | #@TestSuiteGroup Ldif Import |
| | | #@TestGroup Replication |
| | | #@TestScript replication_ldifimport.xml |
| | | #@TestHTMLLink http://opends.dev.java.net/ |
| | | --> |
| | | |
| | | |
| | | <import machine="'%s' % (STAF_LOCAL_HOSTNAME)" |
| | | file="'%s/testcases/replication/replication_setup.xml' % (TESTS_DIR)"/> |
| | | <call function="'replication_setup'" /> |
| | | |
| | | <script> |
| | | synchroSuffix = master.getSynchronizedSuffixList()[0].getSuffixDn() |
| | | </script> |
| | | |
| | | <!--- Test Case information |
| | | #@TestMarker Replication Ldif Import Tests |
| | | #@TestName Replication: Ldif Import: Off-line initialisation |
| | | #@TestID Off-line initialisation |
| | | #@TestPurpose Initialise replicated servers using off-line export/import |
| | | #@TestPreamble |
| | | #@TestSteps |
| | | #@TestPostamble |
| | | #@TestResult |
| | | --> |
| | | <testcase name="'Replication: Ldif Import: Off-line initialisation'"> |
| | | <sequence> |
| | | <call function="'testCase_Preamble'"/> |
| | | <message> |
| | | 'Replication: Ldif Import: Off-line initialisation. Initialise replicated servers using off-line export/import' |
| | | </message> |
| | | |
| | | <!-- Stop the servers in the topology --> |
| | | <call function="'stopServers'"> |
| | | [_topologyServerList] |
| | | </call> |
| | | |
| | | |
| | | <!-- Import data into "master" server --> |
| | | <call function="'ImportLdifWithScript'"> |
| | | { 'location' : masterHost, |
| | | 'dsPath' : masterPath, |
| | | 'dsLdifFile' : '%s/replication/Example.ldif' % masterDataDir } |
| | | </call> |
| | | |
| | | <!-- Check some data was imported into "master" server --> |
| | | <call function="'checkImport'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsHost' : masterHost, |
| | | 'dsPort' : master.getPort(), |
| | | 'dsDn' : master.getRootDn(), |
| | | 'dsPswd' : master.getRootPwd(), |
| | | 'expectedEntries' : ['uid=scarter,ou=People,o=example', |
| | | 'uid=dmiller, ou=People, o=example', |
| | | 'uid=rhunt, ou=People, o=example'] } |
| | | </call> |
| | | |
| | | |
| | | <!-- Export data from "master" server --> |
| | | <call function="'exportLdif'"> |
| | | { 'location' : masterHost, |
| | | 'dsPath' : masterPath, |
| | | 'ldifFile' : '%s/replication/master_export.ldif' % masterDataDir } |
| | | </call> |
| | | |
| | | <!-- Copy export file to "consumer" servers and import it --> |
| | | <paralleliterate var="consumer" in="consumerList"> |
| | | <sequence> |
| | | <call function="'copyFile'"> |
| | | { 'location' : masterHost, |
| | | 'remotehost' : consumer.getHostname(), |
| | | 'srcfile' : '%s/replication/master_export.ldif' % masterDataDir, |
| | | 'destfile' : '%s/%s/replication/master_export.ldif' % (consumer.getDir(),relativeDataDir) } |
| | | </call> |
| | | |
| | | <call function="'ImportLdifWithScript'"> |
| | | { 'location' : consumer.getHostname(), |
| | | 'dsPath' : '%s/%s' % (consumer.getDir(), OPENDSNAME), |
| | | 'dsLdifFile' : '%s/%s/replication/master_export.ldif' % (consumer.getDir(),relativeDataDir) } |
| | | </call> |
| | | </sequence> |
| | | </paralleliterate> |
| | | |
| | | |
| | | |
| | | <!-- Start the servers in the topology --> |
| | | <call function="'startServers'"> |
| | | [_topologyServerList] |
| | | </call> |
| | | |
| | | |
| | | <!-- Add entry to "master" server --> |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/tfitter.ldif' % clientDataDir } |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | | </sequence> |
| | | </testcase> |
| | | |
| | | |
| | | |
| | | <!--- Test Case information |
| | | #@TestMarker Replication Ldif Import Tests |
| | | #@TestName Replication: Ldif Import: On-line initialisation |
| | | #@TestID On-line initialisation |
| | | #@TestPurpose Initialise replicated servers using on-line export/import |
| | | #@TestPreamble |
| | | #@TestSteps |
| | | #@TestPostamble |
| | | #@TestResult |
| | | --> |
| | | <testcase name="'Replication: Ldif Import: On-line initialisation'"> |
| | | <sequence> |
| | | <call function="'testCase_Preamble'"/> |
| | | <message> |
| | | 'Replication: Ldif Import: On-line initialisation. Initialise replicated servers using on-line export/import' |
| | | </message> |
| | | |
| | | <!-- Clean the servers in the topology |
| | | <call function="'deleteTrees'"> |
| | | [_topologyServerList, synchroSuffix, False] |
| | | </call> --> |
| | | |
| | | <!-- Delete manually added entry so that replication server won't add it automatically later on --> |
| | | <call function="'ldapDeleteWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : master.getHostname(), |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'dsDn' : ['uid=tfitter, ou=People,%s' % synchroSuffix] } |
| | | </call> |
| | | |
| | | <!-- Import data into "master" server --> |
| | | <call function="'importLdifTask'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'taskID' : 'import task', |
| | | 'ldifFile' : '%s/replication/Example.ldif' % masterDataDir } |
| | | </call> |
| | | |
| | | <!-- Check some data was imported into "master" server --> |
| | | <call function="'checkImport'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsHost' : masterHost, |
| | | 'dsPort' : master.getPort(), |
| | | 'dsDn' : master.getRootDn(), |
| | | 'dsPswd' : master.getRootPwd(), |
| | | 'expectedEntries' : ['uid=scarter,ou=People,o=example', |
| | | 'uid=dmiller, ou=People, o=example', |
| | | 'uid=rhunt, ou=People, o=example'], |
| | | 'startDS' : 'no' } |
| | | </call> |
| | | |
| | | |
| | | <!-- Export data from "master" server --> |
| | | <call function="'exportLdifTask'"> |
| | | { 'location' : masterHost, |
| | | 'dsPath' : masterPath, |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'taskID' : 'export task', |
| | | 'ldifFile' : '%s/replication/master_export_online.ldif' % masterDataDir } |
| | | </call> |
| | | |
| | | <!-- Copy export file to "consumer" servers and import it --> |
| | | <paralleliterate var="consumer" in="consumerList"> |
| | | <sequence> |
| | | <call function="'copyFile'"> |
| | | { 'location' : masterHost, |
| | | 'remotehost' : consumer.getHostname(), |
| | | 'srcfile' : '%s/replication/master_export_online.ldif' % masterDataDir, |
| | | 'destfile' : '%s/%s/replication/master_export_online.ldif' % (consumer.getDir(),relativeDataDir) } |
| | | </call> |
| | | |
| | | <call function="'importLdifTask'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : consumer.getHostname(), |
| | | 'dsInstancePort' : consumer.getPort(), |
| | | 'dsInstanceDn' : consumer.getRootDn(), |
| | | 'dsInstancePswd' : consumer.getRootPwd(), |
| | | 'taskID' : 'import task', |
| | | 'ldifFile' : '%s/%s/replication/master_export_online.ldif' % (consumer.getDir(),relativeDataDir) } |
| | | </call> |
| | | </sequence> |
| | | </paralleliterate> |
| | | |
| | | |
| | | |
| | | <!-- Add entry to "master" server --> |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/tfitter.ldif' % clientDataDir } |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | | </sequence> |
| | | </testcase> |
| | | |
| | | |
| | | |
| | | |
| | | <import machine="'%s' % (STAF_LOCAL_HOSTNAME)" |
| | | file="'%s/testcases/replication/replication_cleanup.xml' % (TESTS_DIR)"/> |
| | | <call function="'replication_cleanup'" /> |
| | | |
| | | <call function="'testSuite_Postamble'"/> |
| | | |
| | | </sequence> |
| | | |
| | | </block> |
| | | |
| | | </sequence> |
| | | |
| | | </function> |
| | | |
| | | </stax> |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8" standalone="no"?> |
| | | <!DOCTYPE stax SYSTEM "../../../shared/stax.dtd"> |
| | | <!-- |
| | | ! CDDL HEADER START |
| | | ! |
| | | ! The contents of this file are subject to the terms of the |
| | | ! Common Development and Distribution License, Version 1.0 only |
| | | ! (the "License"). You may not use this file except in compliance |
| | | ! with the License. |
| | | ! |
| | | ! You can obtain a copy of the license at |
| | | ! trunk/opends/resource/legal-notices/OpenDS.LICENSE |
| | | ! or https://OpenDS.dev.java.net/OpenDS.LICENSE. |
| | | ! See the License for the specific language governing permissions |
| | | ! and limitations under the License. |
| | | ! |
| | | ! When distributing Covered Code, include this CDDL HEADER in each |
| | | ! file and include the License file at |
| | | ! trunk/opends/resource/legal-notices/OpenDS.LICENSE. If applicable, |
| | | ! add the following below this CDDL HEADER, with the fields enclosed |
| | | ! by brackets "[]" replaced with your own identifying information: |
| | | ! Portions Copyright [yyyy] [name of copyright owner] |
| | | ! |
| | | ! CDDL HEADER END |
| | | ! |
| | | ! Portions Copyright 2006-2007 Sun Microsystems, Inc. |
| | | ! --> |
| | | <stax> |
| | | |
| | | <defaultcall function="replication_resynchronization"/> |
| | | |
| | | <function name="replication_resynchronization"> |
| | | |
| | | <sequence> |
| | | |
| | | <block name="'resynchronization'"> |
| | | |
| | | <sequence> |
| | | |
| | | <script> |
| | | if not CurrentTestPath.has_key('group'): |
| | | CurrentTestPath['group']='replication' |
| | | CurrentTestPath['suite']=STAXCurrentBlock |
| | | </script> |
| | | |
| | | <call function="'testSuite_Preamble'"/> |
| | | |
| | | <!--- Test Suite information |
| | | #@TestSuiteName Replication Re-Synchronization Tests |
| | | #@TestSuitePurpose Verify that the servers in a replicated topology can be initialised with an old backup and still re-synchronize. |
| | | #@TestSuiteID Re-Synchronization Tests |
| | | #@TestSuiteGroup Re-Synchronization |
| | | #@TestGroup Replication |
| | | #@TestScript replication_resynchronization.xml |
| | | #@TestHTMLLink http://opends.dev.java.net/ |
| | | --> |
| | | |
| | | |
| | | <import machine="'%s' % (STAF_LOCAL_HOSTNAME)" |
| | | file="'%s/testcases/replication/replication_setup.xml' % (TESTS_DIR)"/> |
| | | <call function="'replication_setup'" /> |
| | | |
| | | <script> |
| | | synchroSuffix = master.getSynchronizedSuffixList()[0].getSuffixDn() |
| | | </script> |
| | | |
| | | <!--- Test Case information |
| | | #@TestMarker Replication Re-Synchronization Tests |
| | | #@TestName Replication: Re-Synchronization: Off-line initialisation |
| | | #@TestID Off-line initialisation |
| | | #@TestPurpose Initialise replicated servers using off-line backup/restore |
| | | #@TestPreamble |
| | | #@TestSteps |
| | | #@TestPostamble |
| | | #@TestResult |
| | | --> |
| | | <testcase name="'Replication: Re-Synchronization: Off-line initialisation'"> |
| | | <sequence> |
| | | <call function="'testCase_Preamble'"/> |
| | | <message> |
| | | 'Replication: Re-Synchronization: Off-line initialisation. Initialise replicated servers using off-line backup/restore' |
| | | </message> |
| | | |
| | | <!-- Stop the servers in the topology --> |
| | | <call function="'stopServers'"> |
| | | [_topologyServerList] |
| | | </call> |
| | | |
| | | |
| | | <!-- Import data into "master" server --> |
| | | <call function="'ImportLdifWithScript'"> |
| | | { 'location' : masterHost, |
| | | 'dsPath' : masterPath, |
| | | 'dsLdifFile' : '%s/replication/Example.ldif' % masterDataDir } |
| | | </call> |
| | | |
| | | <!-- Check some data was imported into "master" server --> |
| | | <call function="'checkImport'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsHost' : masterHost, |
| | | 'dsPort' : master.getPort(), |
| | | 'dsDn' : master.getRootDn(), |
| | | 'dsPswd' : master.getRootPwd(), |
| | | 'expectedEntries' : ['uid=scarter,ou=People,o=example', |
| | | 'uid=dmiller, ou=People, o=example', |
| | | 'uid=rhunt, ou=People, o=example'] } |
| | | </call> |
| | | |
| | | |
| | | <!-- Backup "master" server --> |
| | | <call function="'backup'"> |
| | | { 'location' : masterHost, |
| | | 'dsPath' : masterPath, |
| | | 'backupDir' : '%s/replication/master_backup' % masterDataDir } |
| | | </call> |
| | | |
| | | |
| | | <!-- Start the "master" server --> |
| | | <call function="'StartDsWithScript'"> |
| | | { 'location' : masterHost, |
| | | 'dsPath' : masterPath } |
| | | </call> |
| | | |
| | | |
| | | <!-- Add entry to "master" server --> |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/tfitter.ldif' % clientDataDir } |
| | | </call> |
| | | |
| | | |
| | | <!-- Copy backup to "consumer" servers and restore it --> |
| | | <paralleliterate var="consumer" in="consumerList"> |
| | | <sequence> |
| | | <call function="'CopyFolderByExtension'"> |
| | | { 'location' : masterHost, |
| | | 'remotehost' : consumer.getHostname(), |
| | | 'srcfolder' : '%s/replication/master_backup' % masterDataDir, |
| | | 'destfolder' : '%s/%s/replication/master_backup' % (consumer.getDir(),relativeDataDir), |
| | | 'extension' : '*' } |
| | | </call> |
| | | |
| | | <call function="'restore'"> |
| | | { 'location' : consumer.getHostname(), |
| | | 'dsPath' : '%s/%s' % (consumer.getDir(), OPENDSNAME), |
| | | 'backupDir' : '%s/%s/replication/master_backup' % (consumer.getDir(),relativeDataDir) } |
| | | </call> |
| | | </sequence> |
| | | </paralleliterate> |
| | | |
| | | |
| | | |
| | | <!-- Start the "consumer" servers --> |
| | | <call function="'startServers'"> |
| | | [consumerList] |
| | | </call> |
| | | |
| | | |
| | | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | | </sequence> |
| | | </testcase> |
| | | |
| | | |
| | | |
| | | |
| | | <!--- Test Case information |
| | | #@TestMarker Replication Re-Synchronization Tests |
| | | #@TestName Replication: Re-Synchronization: On-line initialisation |
| | | #@TestID On-line initialisation |
| | | #@TestPurpose Initialise replicated servers using on-line backup/restore |
| | | #@TestPreamble |
| | | #@TestSteps |
| | | #@TestPostamble |
| | | #@TestResult |
| | | --> |
| | | <testcase name="'Replication: Re-Synchronization: On-line initialisation'"> |
| | | <sequence> |
| | | <call function="'testCase_Preamble'"/> |
| | | <message> |
| | | 'Replication: Re-Synchronization: On-line initialisation. Initialise replicated servers using on-line backup/restore' |
| | | </message> |
| | | |
| | | <!-- Clean the servers in the topology |
| | | <call function="'deleteTrees'"> |
| | | [_topologyServerList, synchroSuffix, False] |
| | | </call> --> |
| | | |
| | | <!-- Delete manually added entry so that replication server won't add it automatically later on --> |
| | | <call function="'ldapDeleteWithScript'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : master.getHostname(), |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'dsDn' : ['uid=tfitter, ou=People,%s' % synchroSuffix] } |
| | | </call> |
| | | |
| | | <!-- Import data into "master" server --> |
| | | <call function="'importLdifTask'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'taskID' : 'import task', |
| | | 'ldifFile' : '%s/replication/Example.ldif' % masterDataDir } |
| | | </call> |
| | | |
| | | <!-- Check some data was imported into "master" server --> |
| | | <call function="'checkImport'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsHost' : masterHost, |
| | | 'dsPort' : master.getPort(), |
| | | 'dsDn' : master.getRootDn(), |
| | | 'dsPswd' : master.getRootPwd(), |
| | | 'expectedEntries' : ['uid=scarter,ou=People,o=example', |
| | | 'uid=dmiller, ou=People, o=example', |
| | | 'uid=rhunt, ou=People, o=example'], |
| | | 'startDS' : 'no' } |
| | | </call> |
| | | |
| | | |
| | | <!-- Backup "master" server --> |
| | | <call function="'backupTask'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'taskID' : 'backup task', |
| | | 'backupDir' : '%s/replication/master_backup_online' % masterDataDir } |
| | | </call> |
| | | |
| | | |
| | | |
| | | <!-- Add entry to "master" server --> |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/tfitter.ldif' % clientDataDir } |
| | | </call> |
| | | |
| | | |
| | | <!-- Copy backup to "consumer" servers and restore it --> |
| | | <paralleliterate var="consumer" in="consumerList"> |
| | | <sequence> |
| | | <call function="'CopyFolderByExtension'"> |
| | | { 'location' : masterHost, |
| | | 'remotehost' : consumer.getHostname(), |
| | | 'srcfolder' : '%s/replication/master_backup_online' % masterDataDir, |
| | | 'destfolder' : '%s/%s/replication/master_backup_online' % (consumer.getDir(),relativeDataDir), |
| | | 'extension' : '*' } |
| | | </call> |
| | | |
| | | <call function="'restoreTask'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : consumer.getHostname(), |
| | | 'dsInstancePort' : consumer.getPort(), |
| | | 'dsInstanceDn' : consumer.getRootDn(), |
| | | 'dsInstancePswd' : consumer.getRootPwd(), |
| | | 'taskID' : 'restore task', |
| | | 'backupDir' : '%s/%s/replication/master_backup_online' % (consumer.getDir(),relativeDataDir) } |
| | | </call> |
| | | </sequence> |
| | | </paralleliterate> |
| | | |
| | | |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | | </sequence> |
| | | </testcase> |
| | | |
| | | |
| | | |
| | | <import machine="'%s' % (STAF_LOCAL_HOSTNAME)" |
| | | file="'%s/testcases/replication/replication_cleanup.xml' % (TESTS_DIR)"/> |
| | | <call function="'replication_cleanup'" /> |
| | | |
| | | <call function="'testSuite_Postamble'"/> |
| | | |
| | | </sequence> |
| | | |
| | | </block> |
| | | |
| | | </sequence> |
| | | |
| | | </function> |
| | | |
| | | </stax> |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8" standalone="no"?> |
| | | <!DOCTYPE stax SYSTEM "../../../shared/stax.dtd"> |
| | | <!-- |
| | | ! CDDL HEADER START |
| | | ! |
| | | ! The contents of this file are subject to the terms of the |
| | | ! Common Development and Distribution License, Version 1.0 only |
| | | ! (the "License"). You may not use this file except in compliance |
| | | ! with the License. |
| | | ! |
| | | ! You can obtain a copy of the license at |
| | | ! trunk/opends/resource/legal-notices/OpenDS.LICENSE |
| | | ! or https://OpenDS.dev.java.net/OpenDS.LICENSE. |
| | | ! See the License for the specific language governing permissions |
| | | ! and limitations under the License. |
| | | ! |
| | | ! When distributing Covered Code, include this CDDL HEADER in each |
| | | ! file and include the License file at |
| | | ! trunk/opends/resource/legal-notices/OpenDS.LICENSE. If applicable, |
| | | ! add the following below this CDDL HEADER, with the fields enclosed |
| | | ! by brackets "[]" replaced with your own identifying information: |
| | | ! Portions Copyright [yyyy] [name of copyright owner] |
| | | ! |
| | | ! CDDL HEADER END |
| | | ! |
| | | ! Portions Copyright 2006-2007 Sun Microsystems, Inc. |
| | | ! --> |
| | | <stax> |
| | | |
| | | <defaultcall function="replication_schema"/> |
| | | |
| | | <function name="replication_schema"> |
| | | |
| | | <sequence> |
| | | |
| | | <block name="'schema'"> |
| | | |
| | | <sequence> |
| | | |
| | | <script> |
| | | if not CurrentTestPath.has_key('group'): |
| | | CurrentTestPath['group']='replication' |
| | | CurrentTestPath['suite']=STAXCurrentBlock |
| | | </script> |
| | | |
| | | <call function="'testSuite_Preamble'"/> |
| | | |
| | | <!--- Test Suite information |
| | | #@TestSuiteName Replication Schema Replication Tests |
| | | #@TestSuitePurpose Verify that the schema is replicated as any other suffix in a replicated topology. |
| | | #@TestSuiteID Schema Replication Tests |
| | | #@TestSuiteGroup Schema Replication |
| | | #@TestGroup Replication |
| | | #@TestScript replication_schema.xml |
| | | #@TestHTMLLink http://opends.dev.java.net/ |
| | | --> |
| | | |
| | | |
| | | <import machine="'%s' % (STAF_LOCAL_HOSTNAME)" |
| | | file="'%s/testcases/replication/replication_setup.xml' % (TESTS_DIR)"/> |
| | | <call function="'replication_setup'" /> |
| | | |
| | | <script> |
| | | synchroSuffix = master.getSynchronizedSuffixList()[0].getSuffixDn() |
| | | replServerList = master.getSynchronizedSuffixList()[0].getChangelogServerList() |
| | | </script> |
| | | |
| | | <iterate var="server" in="_topologyServerList" indexvar="i"> |
| | | <sequence> |
| | | <message> |
| | | 'Create domain name for schema on server %s/%s' % (server.getDir(), OPENDSNAME) |
| | | </message> |
| | | |
| | | <call function="'createMultimasterDomain'"> |
| | | { 'location' : server.getHostname(), |
| | | 'dsPath' : '%s/%s' % (server.getDir(), OPENDSNAME), |
| | | 'dsInstanceHost' : server.getHostname(), |
| | | 'dsInstancePort' : server.getPort(), |
| | | 'dsInstanceDn' : server.getRootDn(), |
| | | 'dsInstancePswd' : server.getRootPwd(), |
| | | 'domainName' : 'schema', |
| | | 'replicationDn' : 'cn=schema', |
| | | 'serverId' : i + 1, |
| | | 'replicationServerList' : replServerList } |
| | | </call> |
| | | </sequence> |
| | | </iterate> |
| | | |
| | | |
| | | <!--- Test Case information |
| | | #@TestMarker Replication Schema Replication Tests |
| | | #@TestName Replication: Schema Replication: Add objectclass |
| | | #@TestID Add objectclass |
| | | #@TestPurpose Check schema replication when a new objectclass is added |
| | | #@TestPreamble |
| | | #@TestSteps |
| | | #@TestPostamble |
| | | #@TestResult |
| | | --> |
| | | <testcase name="'Replication: Schema Replication: Add objectclass'"> |
| | | <sequence> |
| | | <call function="'testCase_Preamble'"/> |
| | | <message> |
| | | 'Replication: Schema Replication: Add objectclass. Check schema replication when a new objectclass is added' |
| | | </message> |
| | | |
| | | <!-- Load entries into "master" server --> |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/Example.ldif' % clientDataDir } |
| | | </call> |
| | | |
| | | <script> |
| | | newObjectclass = '( testobjectclass-oid NAME \'testobjectclass-0\' SUP person MAY ( street $ c ) X-ORIGIN \'user defined\' )' |
| | | </script> |
| | | |
| | | <!-- Modify schema in "master" server --> |
| | | <call function="'modifyAnAttribute'"> |
| | | { 'dsPath' : masterPath, |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'DNToModify' : 'cn=schema', |
| | | 'attributeName' : 'objectClasses', |
| | | 'newAttributeValue' : newObjectclass, |
| | | 'changetype' : 'add' } |
| | | </call> |
| | | |
| | | <!-- Add entry to "master" server --> |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/testuser-0.ldif' % clientDataDir } |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the schema among the servers in the topology --> |
| | | <call function="'verifySchemas'"> |
| | | [ clientHost, clientPath, master, consumerList, '99-user.ldif' ] |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | | </sequence> |
| | | </testcase> |
| | | |
| | | |
| | | |
| | | |
| | | <!--- Test Case information |
| | | #@TestMarker Replication Schema Replication Tests |
| | | #@TestName Replication: Schema Replication: Add attributetype |
| | | #@TestID Add attributetype |
| | | #@TestPurpose Check schema replication when a new attributetype is added |
| | | #@TestPreamble |
| | | #@TestSteps |
| | | #@TestPostamble |
| | | #@TestResult |
| | | --> |
| | | <testcase name="'Replication: Schema Replication: Add attributetype'"> |
| | | <sequence> |
| | | <call function="'testCase_Preamble'"/> |
| | | <message> |
| | | 'Replication: Schema Replication: Add attributetype Check schema replication when a new attributetype is added' |
| | | </message> |
| | | |
| | | <script> |
| | | newObjectclass = '( testobjectclass1-oid NAME \'testobjectclass-1\' SUP person MAY ( street $ testattribute-1 $ c ) X-ORIGIN \'user defined\' )' |
| | | newAttributetype = '( testattribute1-oid NAME \'testattribute-1\' SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 X-ORIGIN \'user defined\' )' |
| | | </script> |
| | | |
| | | <!-- Modify schema in "master" server --> |
| | | <call function="'modifyAnAttribute'"> |
| | | { 'dsPath' : masterPath, |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'DNToModify' : 'cn=schema', |
| | | 'attributeName' : 'attributeTypes', |
| | | 'newAttributeValue' : newAttributetype, |
| | | 'changetype' : 'add' } |
| | | </call> |
| | | <call function="'modifyAnAttribute'"> |
| | | { 'dsPath' : masterPath, |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'DNToModify' : 'cn=schema', |
| | | 'attributeName' : 'objectClasses', |
| | | 'newAttributeValue' : newObjectclass, |
| | | 'changetype' : 'add' } |
| | | </call> |
| | | |
| | | <!-- Add entry to "master" server --> |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : masterHost, |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/testuser-1.ldif' % clientDataDir } |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the schema among the servers in the topology --> |
| | | <call function="'verifySchemas'"> |
| | | [ clientHost, clientPath, master, consumerList, '99-user.ldif' ] |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | | </sequence> |
| | | </testcase> |
| | | |
| | | |
| | | |
| | | <!--- Test Case information |
| | | #@TestMarker Replication Schema Replication Tests |
| | | #@TestName Replication: Schema Replication: Delete objectclass |
| | | #@TestID Delete objectclass |
| | | #@TestPurpose Check schema replication when an objectclass is deleted |
| | | #@TestPreamble |
| | | #@TestSteps |
| | | #@TestPostamble |
| | | #@TestResult |
| | | |
| | | <testcase name="'Replication: Schema Replication: Delete objectclass'"> |
| | | <sequence> |
| | | <call function="'testCase_Preamble'"/> |
| | | <message> |
| | | 'Replication: Schema Replication: Delete objectclass Check schema replication when an objectclass is deleted' |
| | | </message> |
| | | |
| | | <script> |
| | | newObjectclass = '( testobjectclass-oid NAME \'testobjectclass-0\' SUP person MAY ( street $ c ) X-ORIGIN \'user defined\' )' |
| | | </script> |
| | | |
| | | <!-- Modify schema in "master" server |
| | | <call function="'modifyAnAttribute'"> |
| | | { 'dsPath' : masterPath, |
| | | 'dsInstanceHost' : masterHost , |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'DNToModify' : 'cn=schema', |
| | | 'attributeName' : 'objectClasses', |
| | | 'newAttributeValue' : newObjectclass, |
| | | 'changetype' : 'delete' } |
| | | </call> |
| | | |
| | | <!-- Try to add entry to servers; should be rejected with error 65 (objectclass violation) |
| | | <iterate var="server" in="_topologyServerList"> |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | | 'dsPath' : clientPath, |
| | | 'dsInstanceHost' : server.getHostname(), |
| | | 'dsInstancePort' : server.getPort(), |
| | | 'dsInstanceDn' : server.getRootDn(), |
| | | 'dsInstancePswd' : server.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/testuser-0.ldif' % clientDataDir, |
| | | 'expectedRC' : 65 } |
| | | </call> |
| | | </iterate> |
| | | |
| | | <!-- Verify the synchronization of the schema among the servers in the topology |
| | | <call function="'verifySchemas'"> |
| | | [ clientHost, clientPath, master, consumerList, '99-user.ldif' ] |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | | </sequence> |
| | | </testcase> |
| | | --> |
| | | |
| | | <import machine="'%s' % (STAF_LOCAL_HOSTNAME)" |
| | | file="'%s/testcases/replication/replication_cleanup.xml' % (TESTS_DIR)"/> |
| | | <call function="'replication_cleanup'" /> |
| | | |
| | | <call function="'testSuite_Postamble'"/> |
| | | |
| | | </sequence> |
| | | |
| | | </block> |
| | | |
| | | </sequence> |
| | | |
| | | </function> |
| | | |
| | | </stax> |
| | |
| | | |
| | | <!-- Verify the total update --> |
| | | <call function="'checkImport'"> |
| | | { 'location' : server1.getHostname(), |
| | | 'dsPath' : '%s/%s' % (server1.getDir(),OPENDSNAME), |
| | | 'dsHost' : server1.getHostname(), |
| | | 'dsPort' : server1.getPort(), |
| | | 'dsDn' : server1.getRootDn(), |
| | | 'dsPswd' : server1.getRootPwd(), |
| | | { 'location' : server2.getHostname(), |
| | | 'dsPath' : '%s/%s' % (server2.getDir(),OPENDSNAME), |
| | | 'dsHost' : server2.getHostname(), |
| | | 'dsPort' : server2.getPort(), |
| | | 'dsDn' : server2.getRootDn(), |
| | | 'dsPswd' : server2.getRootPwd(), |
| | | 'expectedEntries' : ['uid=scarter,ou=People,o=example', |
| | | 'uid=dmiller, ou=People, o=example', |
| | | 'uid=rhunt, ou=People, o=example'], |