title: DENO mongo atlas connection issue when primary cluster is changing
body: <p>As written in deno.land/x/mongo, to connect to mongo Atlas, such configuration should be use :</p>
  <pre><code>import { MongoClient } from &quot;https://deno.land/x/mongo@v0.21.0/mod.ts&quot;;
      
      const client1 = new MongoClient();
      
      await client.connect({
      db: &quot;&lt;db&gt;&quot;,
      tls: true,
      servers: [
        { 
          host: &quot;&lt;host&gt;&quot;,
          port: 27017,
        },
      ],
      credential: {
        username: &quot;&lt;user&gt;&quot;,
        password: &quot;&lt;password&gt;&quot;,
        db: &quot;&lt;db&gt;&quot;,
        mechanism: &quot;SCRAM-SHA-1&quot;,
      },
    });
      
   const db = client1.database(&quot;TestingDB&quot;);
      
   export default db;
  </code></pre>
  <p>There, <code>&lt;host&gt;</code>should be replaced by a specific cluster address (looks something like that : <code>cluster0.hmdnu.mongodb.net</code>) and not a full string as <code>mongodb+srv://user1:MYPASSWORD@cluster0.hmdnu.mongodb.net/TestingDB?retryWrites=true&amp;w=majority</code>.</p>
  <p>This solution works well. But there is, I believe, a downside : Sometimes, a Mongo cluster can fail and a Secondary cluster can become Primary. Has we are using a specific cluster on our code, that cluster might be down and our program as well. Any one encounter a similar issue ? and how did you resolve it ?</p>