@@ -110,7 +110,7 @@ public void testMaintenanceModeAddNewInstance() {
110110
111111 @ Test
112112 public void testMaintenanceModeAddNewResource () throws Exception {
113- // Explicitly enter maintenance mode
113+ // Enter maintenance mode
114114 _gSetupTool .getClusterManagementTool ().enableMaintenanceMode (CLUSTER_NAME , true , TestHelper .getTestMethodName ());
115115
116116 // Verify we're in maintenance mode
@@ -122,11 +122,10 @@ public void testMaintenanceModeAddNewResource() throws Exception {
122122 IdealState .RebalanceMode .FULL_AUTO .name (), CrushEdRebalanceStrategy .class .getName ());
123123 _gSetupTool .getClusterManagementTool ().rebalance (CLUSTER_NAME ,
124124 newResourceAddedDuringMaintenanceMode , 3 );
125+
125126 // In maintenance mode, new resources won't get ExternalView populated (no rebalance happens).
126- // Instead of using _clusterVerifier.verifyByPolling() which would timeout,
127- // we wait for the IdealState to be created and then verify that ExternalView remains null.
128127
129- // Wait longer for IdealState to be created during maintenance mode
128+ // Wait for IdealState to be created during maintenance mode
130129 boolean idealStateCreated = TestHelper .verify (() -> {
131130 IdealState idealState = _gSetupTool .getClusterManagementTool ()
132131 .getResourceIdealState (CLUSTER_NAME , newResourceAddedDuringMaintenanceMode );
@@ -148,7 +147,6 @@ public void testMaintenanceModeAddNewResource() throws Exception {
148147 .getResourceExternalView (CLUSTER_NAME , newResourceAddedDuringMaintenanceMode );
149148
150149 // During maintenance mode, ExternalView should NOT be created for new resources
151- // since the management mode pipeline excludes ExternalViewComputeStage
152150 Assert .assertNull (externalView ,
153151 "ExternalView should be null during maintenance mode for resource created after entering maintenance mode: "
154152 + newResourceAddedDuringMaintenanceMode );
0 commit comments