On 07/28/2011 05:29 AM, Aleksandrs Saveljevs wrote:
essentially a rewrite of the first part of the C++ example given at
http://wiki.apache.org/cassandra/ThriftExamples#C.2B-.2B- . If we run
it under strace, we see that it hangs on the call to recv() when
setting keyspace:
$ strace -s 64 ./test
...
socket(PF_INET, SOCK_STREAM, IPPROTO_IP) = 3
connect(3, {sa_family=AF_INET, sin_port=htons(9160),
sin_addr=inet_addr("127.0.0.1")}, 16) = 0
send(3,
"\0\0\0/\200\1\0\1\0\0\0\fset_keyspace\0\0\0\0\v\0\1\0\0\0\vmy_keyspace\0",
47, 0) = 47
recv(3, ^C <unfinished ...>
If we run the C++ example, it passes this step successfully. Does
anybody know where the problem is? We are using Thrift 0.6.1 and
Cassandra 0.8.1.
I didn't know that there were C bindings for thrift with cassandra. We
just did some extern stuff and got the C++ bindings to work with our C
application.
-Eric