hmsonline / storm-cassandra

Storm Cassandra Integration
Apache License 2.0
179 stars 90 forks source link

Use CF created with CQL3 #34

Open rjsteixeira opened 10 years ago

rjsteixeira commented 10 years ago

I'm trying to write to CF created with CQL3 but I'm getting an error.

I'm using the same config I used with CLI created CF. Do I have to make any changes?

Thanks.

5981 [batch-bolt-thread] WARN  com.netflix.astyanax.connectionpool.impl.Slf4jConnectionPoolMonitorImpl - BadRequestException: [host=10.126.96.210(10.126.96.210):9160, latency=16(16), attempts=1]InvalidRequestException(why:Not enough bytes to read value of component 0)
5995 [batch-bolt-thread] ERROR com.hmsonline.storm.cassandra.bolt.CassandraBatchingBolt - Unable to write batch.
com.netflix.astyanax.connectionpool.exceptions.BadRequestException: BadRequestException: [host=10.126.96.210(10.126.96.210):9160, latency=16(16), attempts=1]InvalidRequestException(why:Not enough bytes to read value of component 0)
    at com.netflix.astyanax.thrift.ThriftConverter.ToConnectionPoolException(ThriftConverter.java:159) ~[astyanax-1.56.24.jar:na]
    at com.netflix.astyanax.thrift.AbstractOperationImpl.execute(AbstractOperationImpl.java:61) ~[astyanax-1.56.24.jar:na]
    at com.netflix.astyanax.thrift.AbstractOperationImpl.execute(AbstractOperationImpl.java:28) ~[astyanax-1.56.24.jar:na]
    at com.netflix.astyanax.thrift.ThriftSyncConnectionFactoryImpl$ThriftConnection.execute(ThriftSyncConnectionFactoryImpl.java:151) ~[astyanax-1.56.24.jar:na]
    at com.netflix.astyanax.connectionpool.impl.AbstractExecuteWithFailoverImpl.tryOperation(AbstractExecuteWithFailoverImpl.java:69) ~[astyanax-1.56.24.jar:na]
    at com.netflix.astyanax.connectionpool.impl.AbstractHostPartitionConnectionPool.executeWithFailover(AbstractHostPartitionConnectionPool.java:253) ~[astyanax-1.56.24.jar:na]
    at com.netflix.astyanax.thrift.ThriftKeyspaceImpl.executeOperation(ThriftKeyspaceImpl.java:464) ~[astyanax-1.56.24.jar:na]
    at com.netflix.astyanax.thrift.ThriftKeyspaceImpl.access$100(ThriftKeyspaceImpl.java:67) ~[astyanax-1.56.24.jar:na]
    at com.netflix.astyanax.thrift.ThriftKeyspaceImpl$1.execute(ThriftKeyspaceImpl.java:103) ~[astyanax-1.56.24.jar:na]
    at com.hmsonline.storm.cassandra.client.AstyanaxClient.writeTuples(AstyanaxClient.java:384) ~[storm-cassandra-0.4.0-rc4-SNAPSHOT.jar:na]
    at com.hmsonline.storm.cassandra.bolt.CassandraBolt.writeTuples(CassandraBolt.java:55) ~[storm-cassandra-0.4.0-rc4-SNAPSHOT.jar:na]
    at com.hmsonline.storm.cassandra.bolt.CassandraBatchingBolt.executeBatch(CassandraBatchingBolt.java:33) ~[storm-cassandra-0.4.0-rc4-SNAPSHOT.jar:na]
    at com.hmsonline.storm.cassandra.bolt.AbstractBatchingBolt$BatchThread.run(AbstractBatchingBolt.java:118) [storm-cassandra-0.4.0-rc4-SNAPSHOT.jar:na]
Caused by: org.apache.cassandra.thrift.InvalidRequestException: null
    at org.apache.cassandra.thrift.Cassandra$batch_mutate_result.read(Cassandra.java:20253) ~[cassandra-thrift-1.1.1.jar:1.1.1]
    at org.apache.thrift.TServiceClient.receiveBase(TServiceClient.java:78) ~[libthrift-0.7.0.jar:0.7.0]
    at org.apache.cassandra.thrift.Cassandra$Client.recv_batch_mutate(Cassandra.java:922) ~[cassandra-thrift-1.1.1.jar:1.1.1]
    at org.apache.cassandra.thrift.Cassandra$Client.batch_mutate(Cassandra.java:908) ~[cassandra-thrift-1.1.1.jar:1.1.1]
    at com.netflix.astyanax.thrift.ThriftKeyspaceImpl$1$1.internalExecute(ThriftKeyspaceImpl.java:109) ~[astyanax-1.56.24.jar:na]
    at com.netflix.astyanax.thrift.ThriftKeyspaceImpl$1$1.internalExecute(ThriftKeyspaceImpl.java:106) ~[astyanax-1.56.24.jar:na]
    at com.netflix.astyanax.thrift.AbstractOperationImpl.execute(AbstractOperationImpl.java:56) ~[astyanax-1.56.24.jar:na]
    ... 11 common frames omitted
gasparms commented 10 years ago

Did you resolve this? I'm having the same issue.

rjsteixeira commented 10 years ago

Nop. I gave up and created the table with cassandra-cli...

moczkowski commented 10 years ago

I can think of 2 possibilities: 1) define your tables using WITH COMPACT STORAGE 2) read Nate Macall's blog post on Thrift CQL3 compatibility. On Dec 12, 2013 2:10 AM, "Ricardo Teixeira" notifications@github.com wrote:

Nop. I gave up and created the table with cassandra-cli...

— Reply to this email directly or view it on GitHubhttps://github.com/hmsonline/storm-cassandra/issues/34#issuecomment-30403682 .