Production Environment Fault - Failed to get connections

We recently faced a issue where VMs were accessible. But MongoDb connection was failing and no application was able to connect during that duration. We had to restart one of the VM shard. Though the issue resolved after an hour , we are trying to investigate the issue.

After checking we found this “NetworkInterfaceExceededTimeLimit” error in mongos log, which I believe has been taken cared in Mongo 4.0 version. We are using Mongo version 4.4.7 currently.
Also to mention , we have enough RAM : 400 GB RAM

1.Error message received in application:
A.
com.mongodb.MongoBulkWriteException:Bulk write operation error on server . Write errors: [BulkWriteError{index=0, code=202, message=‘Write results unavailable from :: caused by :: Couldn’t get a connection within the time limit of 181ms’, details={ }}].

B.
'message ‘Encountered non-retryable error during query :: caused by :: Couldn’t get a connection within the time limit of 650ms’ on server

2.Error message in Mongos logs:

{
“s”: “I”,
“c”: “NETWORK”,
“id”: 4712102,
“ctx”: “conn11471844”,
“msg”: “Host failed in replica set”,
“attr”: {
“replicaSet”: “rs1”,
“host”: “host:port”,
“error”:

{ “code”: 202, “codeName”: “NetworkInterfaceExceededTimeLimit”, “errmsg”: “Couldn’t get a connection within the time limit of 16ms” }
,
“action”: {
“dropConnections”: false,
“requestImmediateCheck”: false,
“outcome”:

{ “host”: “host:port”, “success”: false, “errorMessage”: “NetworkInterfaceExceededTimeLimit: Couldn’t get a connection within the time limit of 16ms” }
}
}
}