Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion FastDFS/Common/ConnectionManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,8 @@ public static bool Initialize(List<IPEndPoint> trackers)
public static Connection GetTrackerConnection()
{
Random random = new Random();
int index = random.Next(trackerPools.Count);
//int index = random.Next(trackerPools.Count);
int index = random.Next(listTrackers.Count); //Pool中的数据个数大于Trackers的
Pool pool = trackerPools[listTrackers[index]];
return pool.GetConnection();
}
Expand Down