尝试新的CQL 3时出现Cassandra错误

时间:2012-06-20 19:37:36

标签: nosql cassandra

我下载了Cassandra 1.1.1并在版本3下启动了cqlsh

我尝试创建一个新的列系列:

CREATE TABLE stats (
 pid          blob,
 period      int,
 targetid     blob,
 sum         counter,
PRIMARY KEY (pid, period, targetid)
);

但我得到了这个:

  

追踪(最近一次通话):     在perform_statement中输入文件" ./ cqlsh",第908行       self.cursor.execute(语句,解码器=解码器)     文件" ./../ lib / cql-internal-only-1.0.10.zip / cql-1.0.10 / cql / cursor.py",第117行,执行       response = self.handle_cql_execution_errors(doquery,prepared_q,compress)     文件" ./../ lib / cql-internal-only-1.0.10.zip / cql-1.0.10 / cql / cursor.py",第132行,在handle_cql_execution_errors中       返回执行者(* args,** kwargs)     文件" ./../ lib / cql-internal-only-1.0.10.zip / cql-1.0.10 / cql / cassandra / Cassandra.py",第1583行,在execute_cql_query中       self.send_execute_cql_query(查询,压缩)     文件" ./../ lib / cql-internal-only-1.0.10.zip / cql-1.0.10 / cql / cassandra / Cassandra.py",第1593行,在send_execute_cql_query中       自 oprot.trans.flush()     文件" ./../ lib / thrift-python-internal-only-0.7.0.zip / thrift / transport / TTransport.py",第293行,同花顺       自 _trans.write(BUF)     文件" ./../ lib / thrift-python-internal-only-0.7.0.zip / thrift / transport / TSocket.py",第117行,写入       加= self.handle.send(buff)   错误:[Errno 32]管道破裂

在服务器控制台上:

  

处理消息时出错。   java.lang.IllegalArgumentException异常       在java.nio.Buffer.limit(Buffer.java:247)       at org.apache.cassandra.db.marshal.AbstractCompositeType.getBytes(AbstractCompositeType.java:51)       at org.apache.cassandra.db.marshal.AbstractCompositeType.getWithShortLength(AbstractCompositeType.java:60)       at org.apache.cassandra.db.marshal.AbstractCompositeType.getString(AbstractCompositeType.java:140)       在org.apache.cassandra.config.CFMetaData.validate(CFMetaData.java:929)       在org.apache.cassandra.service.MigrationManager.announceNewColumnFamily(MigrationManager.java:131)       在org.apache.cassandra.cql3.statements.CreateColumnFamilyStatement.announceMigration(CreateColumnFamilyStatement.java:83)       在org.apache.cassandra.cql3.statements.SchemaAlteringStatement.execute(SchemaAlteringStatement.java:99)       在org.apache.cassandra.cql3.QueryProcessor.processStatement(QueryProcessor.java:108)       在org.apache.cassandra.cql3.QueryProcessor.process(QueryProcessor.java:121)       在org.apache.cassandra.thrift.CassandraServer.execute_cql_query(CassandraServer.java:1237)       在org.apache.cassandra.thrift.Cassandra $ Processor $ execute_cql_query.getResult(Cassandra.java:3542)       在org.apache.cassandra.thrift.Cassandra $ Processor $ execute_cql_query.getResult(Cassandra.java:3530)       在org.apache.thrift.ProcessFunction.process(ProcessFunction.java:32)       在org.apache.thrift.TBaseProcessor.process(TBaseProcessor.java:34)       在org.apache.cassandra.thrift.CustomTThreadPoolServer $ WorkerProcess.run(CustomTThreadPoolServer.java:186)       at java.util.concurrent.ThreadPoolExecutor $ Worker.runTask(ThreadPoolExecutor.java:886)       at java.util.concurrent.ThreadPoolExecutor $ Worker.run(ThreadPoolExecutor.java:908)       在java.lang.Thread.run(Thread.java:680)

1 个答案:

答案 0 :(得分:2)