From user-return-26587-apmail-cassandra-user-archive=cassandra.apache.org@cassandra.apache.org Fri Jun 1 01:46:07 2012 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 502B69BDB for ; Fri, 1 Jun 2012 01:46:06 +0000 (UTC) Received: (qmail 15112 invoked by uid 500); 1 Jun 2012 01:46:04 -0000 Delivered-To: apmail-cassandra-user-archive@cassandra.apache.org Received: (qmail 15085 invoked by uid 500); 1 Jun 2012 01:46:04 -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 15075 invoked by uid 99); 1 Jun 2012 01:46:04 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 01 Jun 2012 01:46:04 +0000 X-ASF-Spam-Status: No, hits=2.2 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: local policy) Received: from [208.113.200.5] (HELO homiemail-a80.g.dreamhost.com) (208.113.200.5) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 01 Jun 2012 01:45:55 +0000 Received: from homiemail-a80.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a80.g.dreamhost.com (Postfix) with ESMTP id 3AD2F37A06E for ; Thu, 31 May 2012 18:45:33 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=thelastpickle.com; h=from :mime-version:content-type:subject:date:in-reply-to:to :references:message-id; q=dns; s=thelastpickle.com; b=CPUKP1X0ZB qyasBusUNboMmOUDntct2QvnDGj6rYK6cax/L3QCHkFrW2a2R7hh7CkpnV4CMvMy YK1/cSIGhmCc3WV+IR4khYRRUFPQBzhA1eAA3bbCtwMhPSv0dVKQjk8BxU9MJSkM sqLnzarhq2/+4ciK3tZEq7VMeFLfBuiN0= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=thelastpickle.com; h=from :mime-version:content-type:subject:date:in-reply-to:to :references:message-id; s=thelastpickle.com; bh=9kMWgcHR00Ud2JZM +M208KoUA58=; b=M796pgKHQQMaoAWjuUrTdXtbZBiI/mnrZh9s8uEp2g4dujzW uD4CGVsAa24Ff7fLAjRwBvqOSsvPTzvIzQqOuxlqchRNHp3RrXEMdymROh9RyxpZ rs6YjWvIKVOTGy4fvEhtTHvEwMM0c2DMbaf0+UAftX24s99GfQbGHzal5Ic= Received: from [192.168.2.189] (unknown [116.90.132.105]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) (Authenticated sender: aaron@thelastpickle.com) by homiemail-a80.g.dreamhost.com (Postfix) with ESMTPSA id 9949B37A06B for ; Thu, 31 May 2012 18:45:32 -0700 (PDT) From: aaron morton Mime-Version: 1.0 (Apple Message framework v1278) Content-Type: multipart/alternative; boundary="Apple-Mail=_24C9DCD8-5E86-4D3E-B6C6-47D9BFCDE65D" Subject: Re: java.net.SocketTimeoutException while Trying to Drop a Collection Date: Fri, 1 Jun 2012 13:45:30 +1200 In-Reply-To: To: user@cassandra.apache.org References: <7C0D81D7-5C68-404E-87F4-73FDD8D36FE4@thelastpickle.com> Message-Id: <777BD61C-2802-49F3-8624-9340688778D6@thelastpickle.com> X-Mailer: Apple Mail (2.1278) --Apple-Mail=_24C9DCD8-5E86-4D3E-B6C6-47D9BFCDE65D Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=iso-8859-1 The default value for rpc_timeout is 10000 - 10 seconds.=20 You want the socket timeout to be higher than the rpc_timeout otherwise = the client will give up before the server.=20 Cheers ----------------- Aaron Morton Freelance Developer @aaronmorton http://www.thelastpickle.com On 1/06/2012, at 3:26 AM, Christof Bornhoevd wrote: > Thanks a lot Aaron for the very fast response! > =20 > I have increased the CassandraThriftSocketTimeout from 5000 to 9000. = Is this a reasonable setting? > configurator.setCassandraThriftSocketTimeout(9000 >=20 > ); > Cheers, > Christof >=20 > 2012/5/31 aaron morton > There are two times of timeouts. The thrift TimedOutException occurs = when the coordinator times out waiting for the CL level nodes to = respond. The error is transmitted back to the client and raised. =20 >=20 > This is a client side socket timeout waiting for the coordinator to = respond. See the = CassandraHostConfigurator.setCassandraThriftSocketTimeout() setting.=20 >=20 > Cheers >=20 > ----------------- > Aaron Morton > Freelance Developer > @aaronmorton > http://www.thelastpickle.com >=20 > On 31/05/2012, at 11:44 AM, Christof Bornhoevd wrote: >=20 >> Hello, >> =20 >> We are using Cassandra 1.0.8 with Hector 1.0-5 on both Windows and = Linux. In our development/test environment we always recreate the schema = in Cassandra (first dropping all ColumnFamilies then recreating them) = and then seeding the test data. We simply use = cluster.dropColumnFamily(keyspace.getKeyspaceName(), collectionName); to = drop ColumnFamilies. The client is using ThriftFramedTransport = (configurator.setUseThriftFramedTransport(true);). >> =20 >> Every so often we run into the following exception (with different = ColumnFamilies): >> =20 >> Caused by: = me.prettyprint.hector.api.exceptions.HectorTransportException: = org.apache.thrift.transport.TTransportException: = java.net.SocketTimeoutException: Read timed out >> at = me.prettyprint.cassandra.service.ExceptionsTranslatorImpl.translate(Except= ionsTranslatorImpl.java:33) >> at = me.prettyprint.cassandra.service.AbstractCluster$7.execute(AbstractCluster= .java:279) >> at = me.prettyprint.cassandra.service.AbstractCluster$7.execute(AbstractCluster= .java:266) >> at = me.prettyprint.cassandra.service.Operation.executeAndSetResult(Operation.j= ava:103) >> at = me.prettyprint.cassandra.connection.HConnectionManager.operateWithFailover= (HConnectionManager.java:258) >> at = me.prettyprint.cassandra.service.AbstractCluster.dropColumnFamily(Abstract= Cluster.java:283) >> at = me.prettyprint.cassandra.service.AbstractCluster.dropColumnFamily(Abstract= Cluster.java:261) >> at = com.supervillains.plouton.cassandradatastore.CassandraDataStore.deleteColl= ection(CassandraDataStore.java:195) >> ... 57 more >> =20 >> Is this problem related to = https://issues.apache.org/jira/browse/CASSANDRA-3551 (which should have = been fixed with Cassandra 1.0.6) or could there be anything we do wrong = here? >> =20 >> Thanks in advance for any kind help! >> Chris >=20 >=20 --Apple-Mail=_24C9DCD8-5E86-4D3E-B6C6-47D9BFCDE65D Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=iso-8859-1 The = default value for rpc_timeout is 10000 - 10 = seconds. 

You want the socket timeout to be = higher than the rpc_timeout otherwise the client will give up before the = server. 

Cheers

http://www.thelastpickle.com

On 1/06/2012, at 3:26 AM, Christof Bornhoevd = wrote:

Thanks a lot Aaron for the very fast response!
 
I have increased the CassandraThriftSocketTimeout from 5000 to = 9000. Is this a reasonable setting?

configurator.setCassandraThriftSocketTimeout(9000

);
Cheers,
Christof

2012/5/31 aaron morton <aaron@thelastpickle.com>
There are two times of timeouts. The = thrift TimedOutException occurs when the coordinator times out waiting = for the CL level nodes to respond. The error is transmitted back to the = client and raised.  =20

This is a client side socket timeout waiting for the coordinator to = respond. See the = CassandraHostConfigurator.setCassandraThriftSocketTimeout() = setting. 

Cheers

-----------------
Aaron Morton
Freelance Developer
@aaronmorton

On 31/05/2012, at 11:44 AM, Christof Bornhoevd wrote:

Hello,

 

We = are using Cassandra 1.0.8 with Hector 1.0-5 on both Windows and Linux. = In our development/test = environment we always recreate the schema in Cassandra (first dropping all ColumnFamilies then = recreating them) and then seeding the test data. We simply use cluster.dropColumnFamily(keyspace.getKeyspaceName(), = collectionName); to = drop ColumnFamilies. The = client is using ThriftFramedTransport (configurator.setUseThriftFramedTransport(true);).

 

Every= so often we run into the following exception (with different = ColumnFamilies):

 

Caused by: = me.prettyprint.hector.api.exceptions.HectorTransportException: = org.apache.thrift.transport.TTransportException: = java.net.SocketTimeoutException:= Read timed out
at = me.prettyprint.cassandra.service.ExceptionsTranslatorImpl.translate(ExceptionsTranslatorImpl.java:33)
at = me.prettyprint.cassandra.service.AbstractCluster$7.execute(AbstractCluster.java:279)
at = me.prettyprint.cassandra.service.AbstractCluster$7.execute(AbstractCluster.java:266)
at = me.prettyprint.cassandra.service.Operation.executeAndSetResult(Operation.java:103)
at = me.prettyprint.cassandra.connection.HConnectionManager.operateWithFailover(HConnectionManager.java:258)
at = me.prettyprint.cassandra.service.AbstractCluster.dropColumnFamily(AbstractCluster.java:283)
at = me.prettyprint.cassandra.service.AbstractCluster.dropColumnFamily(AbstractCluster.java:261)
at = com.supervillains.plouton.cassandradatastore.CassandraDataStore.deleteCollection(CassandraDataStore.java:195)
... = 57 more

 

Is = this problem related to https://issues.apache.org/jira/browse/CASSANDRA-3551 (which should have been fixed = with Cassandra 1.0.6) or could there be anything we do wrong here?

 

Thanks in advance for any kind help!
Chris



= --Apple-Mail=_24C9DCD8-5E86-4D3E-B6C6-47D9BFCDE65D--