<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Wed Feb 07 21:41:19 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-1997] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 10.0.0.12:27017</title>
                <link>https://jira.mongodb.org/browse/CSHARP-1997</link>
                <project id="10041" key="CSHARP">C# Driver</project>
                    <description>&lt;p&gt;Driver - 2.4.3&lt;br/&gt;
MongoDB Community - 3.4.4&lt;/p&gt;

&lt;p&gt;&lt;b&gt;Environment:&lt;/b&gt;&lt;br/&gt;
Server A: MongoDB Standalone server (2 Core 3.5 G RAM) &lt;span class=&quot;error&quot;&gt;&amp;#91;Windows Server 2012 R2&amp;#93;&lt;/span&gt;&lt;br/&gt;
Server B: Web App (4 Core 7 G RAM) &lt;span class=&quot;error&quot;&gt;&amp;#91;Windows Server 2012 R2&amp;#93;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;As i was trying out MongoDB and performing Load Test. I was hit with the following &lt;b&gt;2 types of errors repetitively&lt;/b&gt; for 30 seconds and it back to normal.&lt;/p&gt;

&lt;p&gt;&lt;b&gt;Error Type 1:&lt;/b&gt;&lt;br/&gt;
System.TimeoutException: 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;10.0.0.12:27017&quot; }
&lt;p&gt;&quot;, EndPoint: &quot;10.0.0.12:27017&quot;, State: &quot;Disconnected&quot;, Type: &quot;Unknown&quot; }] }.&lt;br/&gt;
   at MongoDB.Driver.Core.Clusters.Cluster.ThrowTimeoutException(IServerSelector selector, ClusterDescription description)&lt;br/&gt;
   at MongoDB.Driver.Core.Clusters.Cluster.WaitForDescriptionChangedHelper.HandleCompletedTask(Task completedTask)&lt;br/&gt;
   at MongoDB.Driver.Core.Clusters.Cluster.WaitForDescriptionChanged(IServerSelector selector, ClusterDescription description, Task descriptionChangedTask, TimeSpan timeout, CancellationToken cancellationToken)&lt;br/&gt;
   at MongoDB.Driver.Core.Clusters.Cluster.SelectServer(IServerSelector selector, CancellationToken cancellationToken)&lt;br/&gt;
   at MongoDB.Driver.Core.Bindings.WritableServerBinding.GetWriteChannelSource(CancellationToken cancellationToken)&lt;br/&gt;
   at MongoDB.Driver.Core.Operations.BulkMixedWriteOperation.Execute(IWriteBinding binding, CancellationToken cancellationToken)&lt;br/&gt;
   at MongoDB.Driver.OperationExecutor.ExecuteWriteOperation&lt;span class=&quot;error&quot;&gt;&amp;#91;TResult&amp;#93;&lt;/span&gt;(IWriteBinding binding, IWriteOperation`1 operation, CancellationToken cancellationToken)&lt;br/&gt;
   at MongoDB.Driver.MongoCollectionImpl`1.ExecuteWriteOperation&lt;span class=&quot;error&quot;&gt;&amp;#91;TResult&amp;#93;&lt;/span&gt;(IWriteOperation`1 operation, CancellationToken cancellationToken)&lt;br/&gt;
   at MongoDB.Driver.MongoCollectionImpl`1.BulkWrite(IEnumerable`1 requests, BulkWriteOptions options, CancellationToken cancellationToken)&lt;br/&gt;
   at MongoDB.Driver.MongoCollectionBase`1.InsertOne(TDocument document, InsertOneOptions options, CancellationToken cancellationToken)&lt;br/&gt;
   at ILT.Data.Agents.MongoDBAgent.Create(Sample sample)&lt;br/&gt;
   at ILT.Business.TestComponent.TestNoSQLMongoDBMethod()&lt;/p&gt;

&lt;p&gt;&lt;b&gt;Error Type 2:&lt;/b&gt;&lt;br/&gt;
System.TimeoutException: 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;10.0.0.12:27017&quot; }
&lt;p&gt;&quot;, EndPoint: &quot;10.0.0.12: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; System.Net.Sockets.SocketException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 10.0.0.12:27017&lt;br/&gt;
   at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult)&lt;br/&gt;
   at System.Threading.Tasks.TaskFactory`1.FromAsyncCoreLogic(IAsyncResult iar, Func`2 endFunction, Action`1 endAction, Task`1 promise, Boolean requiresSynchronization)&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.TcpStreamFactory.&amp;lt;ConnectAsync&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.Connections.TcpStreamFactory.&amp;lt;CreateStreamAsync&amp;gt;d__4.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 MongoDB.Driver.Core.Servers.ServerMonitor.&amp;lt;HeartbeatAsync&amp;gt;d__27.MoveNext()&quot; }] }.&lt;br/&gt;
   at MongoDB.Driver.Core.Clusters.Cluster.ThrowTimeoutException(IServerSelector selector, ClusterDescription description)&lt;br/&gt;
   at MongoDB.Driver.Core.Clusters.Cluster.WaitForDescriptionChangedHelper.HandleCompletedTask(Task completedTask)&lt;br/&gt;
   at MongoDB.Driver.Core.Clusters.Cluster.WaitForDescriptionChanged(IServerSelector selector, ClusterDescription description, Task descriptionChangedTask, TimeSpan timeout, CancellationToken cancellationToken)&lt;br/&gt;
   at MongoDB.Driver.Core.Clusters.Cluster.SelectServer(IServerSelector selector, CancellationToken cancellationToken)&lt;br/&gt;
   at MongoDB.Driver.Core.Bindings.WritableServerBinding.GetWriteChannelSource(CancellationToken cancellationToken)&lt;br/&gt;
   at MongoDB.Driver.Core.Operations.BulkMixedWriteOperation.Execute(IWriteBinding binding, CancellationToken cancellationToken)&lt;br/&gt;
   at MongoDB.Driver.OperationExecutor.ExecuteWriteOperation&lt;span class=&quot;error&quot;&gt;&amp;#91;TResult&amp;#93;&lt;/span&gt;(IWriteBinding binding, IWriteOperation`1 operation, CancellationToken cancellationToken)&lt;br/&gt;
   at MongoDB.Driver.MongoCollectionImpl`1.ExecuteWriteOperation&lt;span class=&quot;error&quot;&gt;&amp;#91;TResult&amp;#93;&lt;/span&gt;(IWriteOperation`1 operation, CancellationToken cancellationToken)&lt;br/&gt;
   at MongoDB.Driver.MongoCollectionImpl`1.BulkWrite(IEnumerable`1 requests, BulkWriteOptions options, CancellationToken cancellationToken)&lt;br/&gt;
   at MongoDB.Driver.MongoCollectionBase`1.InsertOne(TDocument document, InsertOneOptions options, CancellationToken cancellationToken)&lt;br/&gt;
   at ILT.Data.Agents.MongoDBAgent.Create(Sample sample)&lt;br/&gt;
   at ILT.Business.TestComponent.TestNoSQLMongoDBMethod()&lt;/p&gt;

&lt;p&gt;&lt;b&gt;This is my Code. No async method used.&lt;/b&gt;&lt;br/&gt;
private static readonly MongoClient _mongoClient;&lt;/p&gt;

&lt;p&gt;static MongoDBAgent()&lt;/p&gt;
{
    _mongoClient = new MongoClient(ConfigurationManager.ConnectionStrings[&quot;MongoDB&quot;].ConnectionString);
}

&lt;p&gt;public void Create(Sample sample)&lt;/p&gt;
{
    var db = _mongoClient.GetDatabase(&quot;ILT&quot;);
    var collection = db.GetCollection&amp;lt;Sample&amp;gt;(&quot;Sample&quot;);

    collection.InsertOne(sample);
}

&lt;p&gt;&lt;b&gt;This is my mongodb connectionString.&lt;/b&gt;&lt;br/&gt;
mongodb://username:password@10.0.0.12:27017/ILT&lt;/p&gt;

&lt;p&gt;&lt;b&gt;ILT is the database name.&lt;/b&gt;&lt;br/&gt;
10.0.0.12 is mongodb standalone local IP address.&lt;/p&gt;

&lt;p&gt;After that i tried to simulate again and again but couldn&apos;t get back the error. I have attach the log file for your information.&lt;/p&gt;</description>
                <environment>Standalone MongoDB - Windows Server 2012 R2 </environment>
        <key id="392591">CSHARP-1997</key>
            <summary>A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 10.0.0.12:27017</summary>
                <type id="1" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14703&amp;avatarType=issuetype">Bug</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="5">Cannot Reproduce</resolution>
                                        <assignee username="robert@mongodb.com">Robert Stam</assignee>
                                    <reporter username="myjlan">Jaryllan</reporter>
                        <labels>
                    </labels>
                <created>Sun, 11 Jun 2017 13:06:52 +0000</created>
                <updated>Mon, 22 Jan 2018 14:11:16 +0000</updated>
                            <resolved>Mon, 22 Jan 2018 14:11:16 +0000</resolved>
                                    <version>2.4.3</version>
                                                    <component>Connectivity</component>
                                        <votes>1</votes>
                                    <watches>2</watches>
                                                                                                                <comments>
                            <comment id="1666821" author="rstam" created="Thu, 7 Sep 2017 13:54:33 +0000"  >&lt;p&gt;This is the error you would expect to get if the network between the application and the MongoDB server was down or if the MongoDB server was not running or not responding to connection requests in a timely fashion.&lt;/p&gt;

&lt;p&gt;The underlying error (a System.Net.Sockets.SocketException) is being reported by the .NET Framework itself.&lt;/p&gt;</comment>
                            <comment id="1593946" author="myjlan" created="Sun, 11 Jun 2017 13:19:08 +0000"  >&lt;p&gt;I would like to amend that Instead of 30 seconds, the error actually happens for 1 minute 30 seconds based on the log file.&lt;/p&gt;</comment>
                    </comments>
                    <attachments>
                            <attachment id="158320" name="MongoDB_1.log" size="671214" author="myjlan" created="Sun, 11 Jun 2017 12:49:33 +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|ht106v:</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>