<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Wed Feb 07 21:41:32 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-2070] A timeout occured after 30000ms selecting a server using CompositeServerSelector</title>
                <link>https://jira.mongodb.org/browse/CSHARP-2070</link>
                <project id="10041" key="CSHARP">C# Driver</project>
                    <description>&lt;p&gt;I want to learn C# ASP MVC 5 with mongodb .&lt;/p&gt;

&lt;p&gt;in Tutorial at &lt;a href=&quot;http://www.c-sharpcorner.com/article/simple-crud-operation-using-asp-net-mvc-and-mongodb/&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://www.c-sharpcorner.com/article/simple-crud-operation-using-asp-net-mvc-and-mongodb/&lt;/a&gt; ,&lt;/p&gt;

&lt;p&gt;My Connection in Attachment .&lt;/p&gt;

&lt;p&gt;at command :&lt;br/&gt;
&lt;font color=&quot;red&quot;&gt;var carDetails = _dbContext._database.GetCollection&amp;lt;CarModel&amp;gt;(&quot;CarModel&quot;).FindAll().SetLimit(10).ToList();&lt;/font&gt;&lt;/p&gt;

&lt;p&gt;I have a Error : &lt;/p&gt;

&lt;p&gt;A timeout occured after 30000ms selecting a server using CompositeServerSelector{ Selectors = WritableServerSelector, LatencyLimitingServerSelector&lt;/p&gt;
{ AllowedLatencyRange = 00:00:00.0150000 }
&lt;p&gt; }. Client view of cluster state is { ClusterId : &quot;1&quot;, ConnectionMode : &quot;Automatic&quot;, Type : &quot;Unknown&quot;, State : &quot;Disconnected&quot;, Servers : [{ ServerId: &quot;&lt;/p&gt;
{ ClusterId : 1, EndPoint : &quot;Unspecified/localhost:27017&quot; }
&lt;p&gt;&quot;, EndPoint: &quot;Unspecified/localhost:27017&quot;, State: &quot;Disconnected&quot;, Type: &quot;Unknown&quot;, HeartbeatException: &quot;MongoDB.Driver.MongoConnectionException: An exception occurred while opening a connection to the server. ---&amp;gt; MongoDB.Driver.MongoAuthenticationException: Unable to authenticate username &apos;demouser&apos; on database &apos;CarDatabase&apos;. ---&amp;gt; MongoDB.Driver.MongoCommandException: Command authenticate failed: auth failed.&lt;br/&gt;
  at MongoDB.Driver.Core.WireProtocol.CommandWireProtocol`1.ProcessReply(ConnectionId connectionId, ReplyMessage`1 reply)&lt;br/&gt;
  at MongoDB.Driver.Core.WireProtocol.CommandWireProtocol`1.&amp;lt;ExecuteAsync&amp;gt;d__11.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
  at MongoDB.Driver.Core.Authentication.MongoDBCRAuthenticator.&amp;lt;AuthenticateAsync&amp;gt;d__7.MoveNext()&lt;br/&gt;
  &amp;#8212; End of inner exception stack trace &amp;#8212;&lt;br/&gt;
  at MongoDB.Driver.Core.Authentication.MongoDBCRAuthenticator.&amp;lt;AuthenticateAsync&amp;gt;d__7.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
  at MongoDB.Driver.Core.Authentication.AuthenticationHelper.&amp;lt;AuthenticateAsync&amp;gt;d__1.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
  at MongoDB.Driver.Core.Connections.ConnectionInitializer.&amp;lt;InitializeConnectionAsync&amp;gt;d__3.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
  at MongoDB.Driver.Core.Connections.BinaryConnection.&amp;lt;OpenHelperAsync&amp;gt;d__48.MoveNext()&lt;br/&gt;
  &amp;#8212; End of inner exception stack trace &amp;#8212;&lt;br/&gt;
  at MongoDB.Driver.Core.Connections.BinaryConnection.&amp;lt;OpenHelperAsync&amp;gt;d__48.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
  at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)&lt;br/&gt;
  at MongoDB.Driver.Core.Servers.ServerMonitor.&amp;lt;HeartbeatAsync&amp;gt;d__27.MoveNext()&quot; }] }&lt;/p&gt;</description>
                <environment></environment>
        <key id="449263">CSHARP-2070</key>
            <summary>A timeout occured after 30000ms selecting a server using CompositeServerSelector</summary>
                <type id="3" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14718&amp;avatarType=issuetype">Task</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="13202">Works as Designed</resolution>
                                        <assignee username="robert@mongodb.com">Robert Stam</assignee>
                                    <reporter username="ibnu1995">Ibnu Setiawan</reporter>
                        <labels>
                            <label>question</label>
                    </labels>
                <created>Mon, 23 Oct 2017 03:40:08 +0000</created>
                <updated>Fri, 27 Oct 2023 13:25:05 +0000</updated>
                            <resolved>Mon, 22 Jan 2018 14:13:01 +0000</resolved>
                                                                    <component>Configuration</component>
                    <component>Connectivity</component>
                                        <votes>0</votes>
                                    <watches>3</watches>
                                                                                                                <comments>
                            <comment id="5259636" author="james.kovacs" created="Wed, 8 Mar 2023 19:42:55 +0000"  >&lt;p&gt;For more information, see &lt;a href=&quot;https://www.mongodb.com/docs/drivers/csharp/current/faq/#why-does-the-driver-throw-a-timeout-during-server-selection-&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;Why Does the Driver Throw a Timeout During Server Selection?&lt;/a&gt; in the MongoDB .NET/C# Driver FAQ.&lt;/p&gt;</comment>
                            <comment id="1705983" author="jeff.yemin" created="Mon, 23 Oct 2017 12:54:18 +0000"  >&lt;p&gt;It looks like the root cause is an authentication error:&lt;/p&gt;

&lt;blockquote&gt;&lt;p&gt;Unable to authenticate username &apos;demouser&apos; on database &apos;CarDatabase&apos;.&lt;/p&gt;&lt;/blockquote&gt;

&lt;p&gt;Please double check whether a user with the name &apos;&apos;demouser&apos;&apos; is defined in the &apos;CarDatabase&apos; database, and that the password that you provided is correct.  You can confirm in the mongo shell like this:&lt;/p&gt;

&lt;p/&gt;
&lt;div id=&quot;syntaxplugin&quot; class=&quot;syntaxplugin&quot; style=&quot;border: 1px dashed #bbb; border-radius: 5px !important; overflow: auto; max-height: 30em;&quot;&gt;
&lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;0&quot; width=&quot;100%&quot; style=&quot;font-size: 1em; line-height: 1.4em !important; font-weight: normal; font-style: normal; color: black;&quot;&gt;
		&lt;tbody &gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;  margin-top: 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;MongoDB Enterprise &amp;gt; use CarDatabase&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;switched to db CarDatabase&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   margin-bottom: 10px;  width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;MongoDB Enterprise &amp;gt; db.auth(&apos;demouser&apos;, &apos;password&apos;)&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
			&lt;/tbody&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;p/&gt;
</comment>
                    </comments>
                    <attachments>
                            <attachment id="168923" name="MongoContext.cs" size="1447" author="ibnu1995" created="Mon, 23 Oct 2017 03:36:19 +0000"/>
                    </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|htaaif:</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>