Xushaohong commented on code in PR #4265:
URL: https://github.com/apache/ozone/pull/4265#discussion_r1106569882


##########
hadoop-ozone/dist/src/main/smoketest/omha/testOMHA.robot:
##########
@@ -182,4 +194,38 @@ Restart OM and Verify Ratis Logs
     # Verify that the logs match with the Leader OMs logs
     List Should Contain Sub List    ${logsAfter}        ${logsLeader}
 
+Transfer Leadership for OM
+    # Check OM write operation before failover
+    Create volume and bucket
+    Write Test File
+
+    # Find Leader OM and one Follower OM
+    ${leaderOM} =           Get OM Leader Node
+                            LOG                     Leader OM: ${leaderOM}
+    ${followerOM} =         Get One OM Follower Node
+                            LOG                     Follower OM: ${followerOM}
+    # Transfer leadership to the Follower OM
+    ${result} =             Execute                 ozone admin om transfer 
--service-id=omservice -n ${followerOM}
+                            LOG                     ${result}
+                            Should Contain          ${result}               
Transfer leadership successfully
+
+    ${newLeaderOM} =        Get OM Leader Node
+                            Should be Equal         ${followerOM}           
${newLeaderOM}
+    Write Test File
+
+Transfer Leadership for OM randomly
+    # Check OM write operation before failover
+    Create volume and bucket
+    Write Test File
 
+    # Find Leader OM and one Follower OM
+    ${leaderOM} =           Get OM Leader Node
+                            LOG                     Leader OM: ${leaderOM}
+    # Transfer leadership to the Follower OM
+    ${result} =             Execute                 ozone admin om transfer -r
+                            LOG                     ${result}
+                            Should Contain          ${result}               
Transfer leadership successfully
+
+    ${newLeaderOM} =        Get OM Leader Node
+                            Should Not be Equal     ${leaderOM}             
${newLeaderOM}

Review Comment:
   > `testOMHA.robot` is not run in CI, as it is only part of the `ozone-om-ha` 
environment, which is disabled:
   
   @adoroszlai I see, the robot test could be left to be fixed.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to