<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Wed Feb 07 21:38:49 UTC 2024

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary append 'field=key&field=summary' to the URL of your request.
-->
<rss version="0.92" >
<channel>
    <title>MongoDB Jira</title>
    <link>https://jira.mongodb.org</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>9.7.1</version>
        <build-number>970001</build-number>
        <build-date>13-04-2023</build-date>
    </build-info>


<item>
            <title>[CSHARP-1153] MongoServer.Ping() does not detect if servers go offline</title>
                <link>https://jira.mongodb.org/browse/CSHARP-1153</link>
                <project id="10041" key="CSHARP">C# Driver</project>
                    <description>&lt;p&gt;When using a connection string with multiple servers in a replicaset, Ping() does not detect if one of the MongoDB instances go offline, it will not throw an exception.&lt;br/&gt;
Only if I call Reconnect() will the driver detect that one of the instances are offline and throw an exception when calling Ping().&lt;/p&gt;

&lt;p&gt;An easy way to test is to put one of the MongoDb instance hostnames in your hosts file and point it to 127.0.0.1, assuming you don&apos;t have mongodb running on your localhost.&lt;/p&gt;</description>
                <environment>Official NuGet package, .NET 4.5 on Windows 7</environment>
        <key id="175744">CSHARP-1153</key>
            <summary>MongoServer.Ping() does not detect if servers go offline</summary>
                <type id="1" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14703&amp;avatarType=issuetype">Bug</type>
                                            <priority id="2" iconUrl="https://jira.mongodb.org/images/icons/priorities/critical.svg">Critical - P2</priority>
                        <status id="6" iconUrl="https://jira.mongodb.org/images/icons/statuses/closed.png" description="The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.">Closed</status>
                    <statusCategory id="3" key="done" colorName="success"/>
                                    <resolution id="2">Won&apos;t Fix</resolution>
                                        <assignee username="-1">Unassigned</assignee>
                                    <reporter username="mcha">Michael C</reporter>
                        <labels>
                            <label>connection</label>
                    </labels>
                <created>Mon, 22 Dec 2014 14:30:24 +0000</created>
                <updated>Mon, 22 Dec 2014 15:04:09 +0000</updated>
                            <resolved>Mon, 22 Dec 2014 15:04:09 +0000</resolved>
                                    <version>1.9.2</version>
                                                    <component>API</component>
                                        <votes>0</votes>
                                    <watches>1</watches>
                                                                                                                <comments>
                            <comment id="792047" author="craiggwilson" created="Mon, 22 Dec 2014 15:04:03 +0000"  >&lt;p&gt;The best thing to do is do a db.RunCommand(&quot;replSetGetStatus&quot;) against the admin database. This will give you a complete overview of the replica set. &lt;/p&gt;

&lt;p&gt;However, instead of calling ping, you can simply look at the Instances property of MongoServer (&lt;a href=&quot;https://github.com/mongodb/mongo-csharp-driver/blob/v1.x/MongoDB.Driver/MongoServer.cs#L252&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-csharp-driver/blob/v1.x/MongoDB.Driver/MongoServer.cs#L252&lt;/a&gt;) and loop over them. They are as up-to-date as the last health-check the driver made (about every 10 seconds).&lt;/p&gt;

&lt;p&gt;Ping is not something we are planning on touching, so I&apos;m going to close this as Won&apos;t Fix given that the above 2 solutions are better.&lt;/p&gt;</comment>
                            <comment id="792038" author="mcha" created="Mon, 22 Dec 2014 14:51:51 +0000"  >&lt;p&gt;I&apos;m trying to check whether all the servers in the replicaset are online, so I can generate a status page for the sysops guys.&lt;/p&gt;</comment>
                            <comment id="792024" author="craiggwilson" created="Mon, 22 Dec 2014 14:35:53 +0000"  >&lt;p&gt;Hi Michael,&lt;/p&gt;

&lt;p&gt;Perhaps you could indicate what you are trying to do and why and I could point you at a better solution than the Ping method.&lt;/p&gt;

&lt;p&gt;Craig&lt;/p&gt;</comment>
                    </comments>
                    <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_15850" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hs4zen:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10558" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>154066</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            </customfields>
    </item>
</channel>
</rss>