We're updating the issue view to help you get more done. 

Very slow connect

Description

We've been experiencing a very slow connect to cluster from c# driver. Like 10 seconds. And it's only happening when using c# driver - DevCenter and python driver are able to connect withing couple of milliseconds.

Interesting that specifying 100 msec as connect timeout drastically decreases connection time, but specifying less resulting in timeout.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 WriteLine("[{0:G}] Start. Using cassandra c# driver version {1}", DateTime.Now, typeof(Cluster).Assembly.GetName().Version); using (var cluster = Cluster.Builder() .AddContactPoints("192.168.16.38", "192.168.16.40", "192.168.16.43") .WithCredentials("test", "test") // .WithSocketOptions(new SocketOptions().SetConnectTimeoutMillis(100)) - with this option it connects fast .Build()) { WriteLine("[{0:G}] Cluster built", DateTime.Now); using (var session = cluster.Connect("system")) { WriteLine("[{0:G}] Connected", DateTime.Now); var rows = session.Execute("select * from local").GetRows().ToList(); WriteLine("[{0:G}] Selected {1} rows", DateTime.Now, rows.Count); } }

Environment

None

Pull Requests

None

Status

Assignee

Unassigned

Reporter

Michael Logutov

Labels

None

Reproduced in

None

PM Priority

None

Fix versions

None

External issue ID

None

External issue ID

None

External issue ID

None

External issue ID

None

External issue ID

None

External issue ID

None

Doc Impact

None

Reviewer

None

Epic Link

None

Sprint

None

Size

None

Priority

Major