Return-Path: X-Original-To: apmail-cassandra-user-archive@www.apache.org Delivered-To: apmail-cassandra-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id C8A1B99B3 for ; Wed, 18 Apr 2012 03:02:19 +0000 (UTC) Received: (qmail 62441 invoked by uid 500); 18 Apr 2012 03:02:17 -0000 Delivered-To: apmail-cassandra-user-archive@cassandra.apache.org Received: (qmail 62418 invoked by uid 500); 18 Apr 2012 03:02:17 -0000 Mailing-List: contact user-help@cassandra.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@cassandra.apache.org Delivered-To: mailing list user@cassandra.apache.org Received: (qmail 62405 invoked by uid 99); 18 Apr 2012 03:02:17 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 18 Apr 2012 03:02:17 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of jbellis@gmail.com designates 209.85.214.44 as permitted sender) Received: from [209.85.214.44] (HELO mail-bk0-f44.google.com) (209.85.214.44) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 18 Apr 2012 03:02:11 +0000 Received: by bkuw5 with SMTP id w5so6340067bku.31 for ; Tue, 17 Apr 2012 20:01:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type:content-transfer-encoding; bh=LaC//Svn+x5li4gnO14v/5kvNPNHFHY0Q+TyzFbDn1k=; b=NnqnVqYLpHqX8QxMGbTJS92LTkjy+Aulp1DCVuksLeRAANM0pVZaYz1vGhN1Fsjita G5UxQpsYLyPPhdQ+GysY+aWRku2FHacYPgkEqNOYkPEeZS7pFgH94DpL8tD8oM5xNUpZ j0XFDtDF5uriWUX76LXoUNLSBL73UIU3pPPmTkJl3goD9UNZ4JxazSmU7rrC96vvB2Jy xF9FHaqMrnZGfi2/+m7yAsyghmUb57EXRyHHKGxE6j0P3dGUSYijNhZaJPGsZA2t5AMC j8y1ZU5drt7K95Du/oQMzinlFt8xjza3x6q+cIPDTyTOMst8+gJby9vWvEEDq8RdGE8V bvaA== Received: by 10.204.157.138 with SMTP id b10mr158583bkx.75.1334718110216; Tue, 17 Apr 2012 20:01:50 -0700 (PDT) MIME-Version: 1.0 Received: by 10.204.73.15 with HTTP; Tue, 17 Apr 2012 20:01:30 -0700 (PDT) In-Reply-To: <4F8CAEA7.7090509@cse.ohio-state.edu> References: <4F8CAEA7.7090509@cse.ohio-state.edu> From: Jonathan Ellis Date: Tue, 17 Apr 2012 22:01:30 -0500 Message-ID: Subject: Re: java.nio.BufferOverflowException from cassandra server To: user@cassandra.apache.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org If I were to take a wild guess, it would be that you're using a single Thrift connection in multiple threads, which isn't supported. On Mon, Apr 16, 2012 at 6:43 PM, Aniket Chakrabarti wrote: > Hi, > > I have set up a 4 node cassandra cluster. I am using the Thrift C++ API t= o > write a simple C++ application with creates a 50% READ 50% WRITE requests= . > Every time near about a thousand request mark, I am getting the following > exception and my connection is broken: > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D > ERROR 17:30:27,647 Error occurred during processing of message. > java.nio.BufferOverflowException > =A0 =A0 =A0 =A0at java.nio.charset.CoderResult.throwException(Unknown Sou= rce) > =A0 =A0 =A0 =A0at java.lang.StringCoding$StringEncoder.encode(Unknown Sou= rce) > =A0 =A0 =A0 =A0at java.lang.StringCoding.encode(Unknown Source) > =A0 =A0 =A0 =A0at java.lang.String.getBytes(Unknown Source) > =A0 =A0 =A0 =A0at > org.apache.thrift.protocol.TBinaryProtocol.writeString(TBinaryProtocol.ja= va:185) > =A0 =A0 =A0 =A0at > org.apache.thrift.protocol.TBinaryProtocol.writeMessageBegin(TBinaryProto= col.java:92) > =A0 =A0 =A0 =A0at > org.apache.cassandra.thrift.Cassandra$Processor$insert.process(Cassandra.= java:3302) > =A0 =A0 =A0 =A0at > org.apache.cassandra.thrift.Cassandra$Processor.process(Cassandra.java:28= 89) > =A0 =A0 =A0 =A0at > org.apache.cassandra.thrift.CustomTThreadPoolServer$WorkerProcess.run(Cus= tomTThreadPoolServer.java:187) > =A0 =A0 =A0 =A0at java.util.concurrent.ThreadPoolExecutor.runWorker(Unkno= wn Source) > =A0 =A0 =A0 =A0at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unkn= own Source) > =A0 =A0 =A0 =A0at java.lang.Thread.run(Unknown Source) > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D > Some info about the config I am using: > - It is a 4 node cluster with only 1 seed. > -The consistency level is also set to ONE. > -The max heap size and new heap size is set to 4G and 800M(I tried withou= t > setting them as well) > -Java is run in the interpreted mode(-Xint) > -I'm using user mode linux > > Any pointers to what I might be doing wrong will be very helpful. > > Thanks in advance, > Aniket --=20 Jonathan Ellis Project Chair, Apache Cassandra co-founder of DataStax, the source for professional Cassandra support http://www.datastax.com