cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Konstantin Naryshkin <konstant...@a-bb.net>
Subject Re: Problems using Thrift API in C
Date Thu, 04 Aug 2011 13:36:25 GMT
I have had similar issues when I generated Cassandra for Erlang. It seems that Thrift 0.6.1
(the latest stable version) does not work with Cassandra. Using Thrift 0.7 does.

I had issues where it would give me run time errors when trying to send an insert (it would
not serialize correctly).

----- Original Message -----
From: "Aleksandrs Saveljevs" <Aleksandrs.Saveljevs@zabbix.com>
To: user@cassandra.apache.org
Sent: Monday, August 1, 2011 7:41:49 AM
Subject: Re: Problems using Thrift API in C

No, at least not at the default logging level. However, we have solved 
the problem by checking out the latest revision of Thrift from the 
official repository, so it seems that it was not Cassandra's problem.

On 07/29/2011 10:13 PM, ruslan usifov wrote:
> Do you have any error messages in cassandra log?
>
> 2011/7/28 Aleksandrs Saveljevs <Aleksandrs.Saveljevs@zabbix.com
> <mailto:Aleksandrs.Saveljevs@zabbix.com>>
>
>     Dear all,
>
>     We are considering using Cassandra for storing gathered data in
>     Zabbix (see https://support.zabbix.com/__browse/ZBXNEXT-844
>     <https://support.zabbix.com/browse/ZBXNEXT-844> for more details).
>     Because Zabbix is written in C, we are considering using Thrift API
>     in C, too.
>
>     However, we are running into problems trying to get even the basic
>     code work. Consider the attached source code. This is essentially a
>     rewrite of the first part of the C++ example given at
>     http://wiki.apache.org/__cassandra/ThriftExamples#C.2B-__.2B-
>     <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.
>
>     Also, what is the current state of Thrift API in C? Can it be
>     considered stable? Has anybody used it successfully? Any examples?
>
>     Thanks,
>     Aleksandrs
>
>

Mime
View raw message