summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Witten <andrew.witten@mongodb.com>2022-03-21 22:03:54 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2022-03-21 22:36:52 +0000
commit3770d1e8611bb316b3aa478b4359f6375b537f54 (patch)
tree51b1521aee0d6f3401f148344cb99fd9ccf65c23
parentf2e7720b88030aa038bae306d197f7755fe5ef3e (diff)
downloadmongo-3770d1e8611bb316b3aa478b4359f6375b537f54.tar.gz
SERVER-64768 remove test observer_reenabled.js
-rw-r--r--jstests/sharding/health_monitor/observer_reenabled.js72
1 files changed, 0 insertions, 72 deletions
diff --git a/jstests/sharding/health_monitor/observer_reenabled.js b/jstests/sharding/health_monitor/observer_reenabled.js
deleted file mode 100644
index ac02ae1f45b..00000000000
--- a/jstests/sharding/health_monitor/observer_reenabled.js
+++ /dev/null
@@ -1,72 +0,0 @@
-/**
- * Turning off health observer during transient fault removes the associated fault facet and
- * transitions back to Ok.
- *
- * @tags: [multiversion_incompatible]
- */
-(function() {
-'use strict';
-
-const params = {
- setParameter: {
- healthMonitoringIntensities: tojson({
- values: [
- {type: "test", intensity: "off"},
- {type: "ldap", intensity: "off"},
- {type: "dns", intensity: "off"}
- ]
- }),
- featureFlagHealthMonitoring: true,
- logComponentVerbosity: tojson({processHealth: {verbosity: 4}})
- }
-};
-
-let st = new ShardingTest({
- mongos: [params],
- shards: 1,
-});
-
-function healthStatus() {
- return assert.commandWorked(st.s0.adminCommand({serverStatus: 1})).health;
-}
-
-function waitForState(state) {
- assert.soon(() => {
- let result = healthStatus();
- jsTestLog(tojson(result));
- return result.state === state;
- });
-}
-
-function changeObserverIntensity(observer, intensity) {
- let paramValue = {"values": [{"type": observer, "intensity": intensity}]};
- assert.commandWorked(
- st.s0.adminCommand({"setParameter": 1, healthMonitoringIntensities: paramValue}));
-}
-
-jsTestLog("Wait for initial health checks to complete.");
-waitForState("Ok");
-
-jsTestLog("Test observer signals fault");
-assert.commandWorked(st.s0.adminCommand({
- "configureFailPoint": 'testHealthObserver',
- "data": {"code": "InternalError", "msg": "test msg"},
- "mode": "alwaysOn"
-}));
-changeObserverIntensity("test", "critical");
-
-waitForState("TransientFault");
-
-jsTestLog("Turn off observer during transient fault");
-changeObserverIntensity("test", "off");
-
-waitForState("Ok");
-
-jsTestLog("Turn on observer after fault resolution");
-changeObserverIntensity("test", "critical");
-waitForState("TransientFault");
-
-jsTestLog("Test was successful");
-
-st.stop();
-})();