4

I setup a ScyllDB on my Debian 9.6 machine. When I run cqlsh I can connect to it and create tables, do queries etc.. Now I tried to write a simple program in C++ using the Datstax driver and it can't connect. It always blocks when it tries to connect.

The scylla package I installed is:

scylla | 3.0.11-0.20191126.3c91bad0d-1~stretch

cpp_driver is the current master from github: https://github.com/datastax/cpp-driver

Now I tried to run the examples/simple project which is included in the driver, so I assume that it should work, but it shows the same problem. I don't get any errors it just blocks

CassCluster* cluster = cass_cluster_new();
CassSession* session = cass_session_new();
char* hosts = "127.0.0.1";
cass_cluster_set_contact_points(cluster, hosts);
cass_cluster_set_protocol_version(cluster, CASS_PROTOCOL_VERSION_V4);
connect_future = cass_session_connect(session, cluster);

// here it blocks now forever...
er = cass_future_error_code(connect_future);

I also tried to run it on an Ubuntu 16.04 but it shows the same problem. Since the connect works, using the cqlsh I think it shouldn't be a configuration problem, but rather something with the cpp_driver.

I also traced the TCP connection, and I can see that the cpp_driver talks to the server, which looks similar to cqlsh conversation.

Devolus
  • 21,661
  • 13
  • 66
  • 113
  • Which versions of Scylla and cpp_driver are you running? I just tried with upstream of both and it worked. – Juliusz Stasiewicz Apr 01 '20 at 09:33
  • The package that I installed is 3.0.11. The cpp_driver is taken from github, so it should be the newest version. Is the github repo maybe already a bit further with new features and I should take some specific commit? scylla | 3.0.11-0.20191126.3c91bad0d-1~stretch – Devolus Apr 01 '20 at 09:44
  • @JuliuszStasiewicz, I updated the version info. – Devolus Apr 01 '20 at 09:59

1 Answers1

5

I finally found the solution for this issue. We were using cpp_driver 2.15.1 which apparently got some change in the even handling according to their release notes. When I downgraded to 2.15.0 the problem was gone and connection could be successfully established.

Devolus
  • 21,661
  • 13
  • 66
  • 113