<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 08:35:30 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>[GODRIVER-1025] &quot;fail fast&quot; client option</title>
                <link>https://jira.mongodb.org/browse/GODRIVER-1025</link>
                <project id="14289" key="GODRIVER">Go Driver</project>
                    <description>&lt;p&gt;Hello&lt;/p&gt;

&lt;p&gt;I&apos;m migrating my code from globalsign/mgo to the official mongo driver.&lt;/p&gt;

&lt;p&gt;In my tests, I was using the &quot;FailFast&quot; option&#160;&lt;a href=&quot;https://godoc.org/github.com/globalsign/mgo#DialInfo.FailFast&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://godoc.org/github.com/globalsign/mgo#DialInfo.FailFast&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;It allows to connect to a MongoDB server with a &quot;normal&quot; timeout (e.g. 10 sec), however it will return an error after the first failed attempt.&lt;/p&gt;

&lt;p&gt;This is very useful in tests, because I want to skip my test if my local instance of MongoDB is not available.&lt;/p&gt;

&lt;p&gt;With mgo, all my tests were skipped very quickly, because the connection attempt returned an error immediately, and wasn&apos;t retried.&lt;/p&gt;

&lt;p&gt;However, in the mongo official driver, there is no such option. I can only define a very low &quot;connect timeout&quot; (e.g. 100 ms). This solution is not ideal, because on some busy CI server it could take longer to connect to MongoDB. This will cause &quot;flaky&quot; tests.&lt;/p&gt;</description>
                <environment>Linux&lt;br/&gt;
MongoDB 4.0</environment>
        <key id="759635">GODRIVER-1025</key>
            <summary>&quot;fail fast&quot; client option</summary>
                <type id="2" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14711&amp;avatarType=issuetype">New Feature</type>
                                            <priority id="3" iconUrl="https://jira.mongodb.org/images/icons/priorities/major.svg">Major - P3</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="pierrre">Pierre Durand</reporter>
                        <labels>
                    </labels>
                <created>Tue, 7 May 2019 15:15:50 +0000</created>
                <updated>Fri, 10 May 2019 06:20:43 +0000</updated>
                            <resolved>Thu, 9 May 2019 20:34:42 +0000</resolved>
                                    <version>1.0.1</version>
                                                    <component>Connections</component>
                                        <votes>0</votes>
                                    <watches>3</watches>
                                                                                                                <comments>
                            <comment id="2240963" author="pierrre" created="Fri, 10 May 2019 06:20:43 +0000"  >&lt;p&gt;OK, thank you.&lt;/p&gt;</comment>
                            <comment id="2240554" author="jeff.yemin" created="Thu, 9 May 2019 20:34:26 +0000"  >&lt;p&gt;Hi &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=pierrre&quot; class=&quot;user-hover&quot; rel=&quot;pierrre&quot;&gt;pierrre&lt;/a&gt;, &lt;/p&gt;

&lt;p&gt;The Go driver follows the cross-driver server selection specification, which only defines a &lt;a href=&quot;https://github.com/mongodb/specifications/blob/master/source/server-selection/server-selection.rst#serverselectiontimeoutms&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;server selection timeout&lt;/a&gt;.  Currently we have no plans to implement anything that&apos;s not part of that specification.&lt;/p&gt;

&lt;p&gt;As a workaround, you could try calling the &lt;tt&gt;Client.Ping&lt;/tt&gt; method using a &lt;tt&gt;Context&lt;/tt&gt; with a short timeout to accomplish your goal.&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|hunhs7:</customfieldvalue>

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