Skip to content

Commit 93c9f21

Browse files
committed
fixed failing unit test in because I tried to see if picking a random nodeif all the nodes are dead over picking the one thats dead longest would work better in practice
1 parent e3784cc commit 93c9f21

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Elasticsearch.Net/ConnectionPool/StaticConnectionPool.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ public virtual Uri GetNext(int? initialSeed, out int seed, out bool shouldPingHi
7272
} while (attempts < count);
7373

7474
//could not find a suitable node retrying on node that has been dead longest.
75-
return this.NodeUris[_random.Next(0, count)];
75+
return this.NodeUris[i];
7676
}
7777

7878
public virtual void MarkDead(Uri uri, int? deadTimeout, int? maxDeadTimeout)

0 commit comments

Comments
 (0)