[Gluster-devel] Glupy connection closing

Justin Clift jclift at redhat.com
Tue Apr 30 02:45:44 UTC 2013


On 29/04/2013, at 11:00 PM, Jeff Darcy wrote:
> On 04/29/2013 12:23 PM, Justin Clift wrote:
>> Tried establishing a tcp connection during the translator _init_, then
>> re-using it for every fop invocation.  The very first time invovation
>> works, which likely executes the init code too.  Everything after that
>> though gives "broken pipe" errors:
>> 
>>  ERROR: Error received at msg.sendall() time:  [Errno 32] Broken pipe
>> 
>> Code here, if it's helpful:
>> 
>>  https://github.com/justinclift/glupy/blob/glusterflow_sharing/glusterflowclient.py
>> 
>> On IRC, Kaleb mentioned it just might be how this works.  i.e. Python
>> closing all connections at the end of each invocation
> 
> That doesn't quite make sense to me.  AIUI, the C part of the code
> should still have a borrowed reference to the Translator object from
> PyObject_CallObject, so it shouldn't be deleted.  If not, that's easy to
> fix.  However, even if that were the case, __init__ would be called on
> the new object and things would still work (albeit inefficiently).  Have
> you verified that __init__ is in fact being called multiple times?  If
> not, then it's a different kind of problem that we'll need to figure out.


Hmmm, no.  Python novice here, so not quite sure how (yet).  Will look at
it again next weekend or the one after. :)

+ Justin

--
Open Source and Standards @ Red Hat

twitter.com/realjustinclift





More information about the Gluster-devel mailing list