incubator-cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tyler Hobbs <ty...@datastax.com>
Subject Re: who to contact?
Date Wed, 30 Mar 2011 19:31:05 GMT
Actually, it looks like you're probably looking at the bundled Thrift in
phpcassa 0.7.a.3.  This issue is fixed in Thrift trunk and the phpcassa
master branch.

On Wed, Mar 30, 2011 at 2:28 PM, Tyler Hobbs <tyler@datastax.com> wrote:

> Are you looking at Thrift trunk, the thrift package that ships with
> phpcassa 0.7.a.3, or the phpcassa master branch?
>
>
> On Wed, Mar 30, 2011 at 2:26 PM, William Oberman <oberman@civicscience.com
> > wrote:
>
>> Nevermind, the header of the file says it's an apache project, so I'll
>> contact them.  Though, if anyone else is running PHP and is worried about
>> dropped connections thrashing their server, apply this patch :-)
>>
>>
>> On Wed, Mar 30, 2011 at 3:18 PM, William Oberman <
>> oberman@civicscience.com> wrote:
>>
>>> I think I found a bug in the cassandra PHP client.  I'm using phpcassa,
>>> but the bug is in thrift itself, which I think that library phpcassa just
>>> wraps.  In any case, I was trying to test on my local machine, which has
>>> limited RAM, so I reduced the JVM heap size.  Of course I immediately had an
>>> OOM causing my local cassandra server to crash, but that caused my unit
>>> tests to stall at 100% CPU, which seemed weird to me.  I had to figure out
>>> why.  It seems that TSocket doesn't test for EOF (it's only checking for a
>>> socket timeout), causing a tight infinite loop when the connection
>>> disappears.  Checking for EOF in an else if seems like an easy fix, but
>>> given how deep this code is in the library I'll leave it to the experts.
>>>
>>> My diff of the file:
>>> @@ -255,6 +255,9 @@
>>>          if (true === $md['timed_out'] && false === $md['blocked']) {
>>>            throw new TTransportException('TSocket: timed out reading
>>> '.$len.' bytes from '.
>>>                                 $this->host_.':'.$this->port_);
>>> +        } else if(feof($this->handle_)) {
>>> +           throw new TTransportException('TSocket: EOF reading '.$len.'
>>> bytes from '.
>>> +                               $this->host_.':'.$this->port_);
>>>          } else {
>>>            $pre .= $buf;
>>>            $len -= $sz;
>>>
>>>
>>> --
>>> Will Oberman
>>> Civic Science, Inc.
>>> 3030 Penn Avenue., First Floor
>>> Pittsburgh, PA 15201
>>> (M) 412-480-7835
>>> (E) oberman@civicscience.com
>>>
>>
>>
>>
>> --
>> Will Oberman
>> Civic Science, Inc.
>> 3030 Penn Avenue., First Floor
>> Pittsburgh, PA 15201
>> (M) 412-480-7835
>> (E) oberman@civicscience.com
>>
>
>
>
> --
> Tyler Hobbs
> Software Engineer, DataStax <http://datastax.com/>
> Maintainer of the pycassa <http://github.com/pycassa/pycassa> Cassandra
> Python client library
>
>


-- 
Tyler Hobbs
Software Engineer, DataStax <http://datastax.com/>
Maintainer of the pycassa <http://github.com/pycassa/pycassa> Cassandra
Python client library

Mime
View raw message