[Freeipa-devel] [PATCH 487] ldap: Make ldap2 connection management thread-safe again
thierry bordaz
tbordaz at redhat.com
Wed Sep 2 14:20:22 UTC 2015
On 09/02/2015 03:16 PM, Jan Cholasta wrote:
> On 2.9.2015 14:51, Martin Basti wrote:
>>
>>
>> On 09/02/2015 02:32 PM, Jan Cholasta wrote:
>>> Hi,
>>>
>>> the attached patch fixes
>>> <https://fedorahosted.org/freeipa/ticket/5268>.
>>>
>>> Honza
>>>
>>>
>>>
>>
>> This patch needs a big rebase to ipa-4-2 branch
>
> Patch attached.
>
>
>
Hello,
Two minors questions. LDAPClient close/__del__/__exit__ are now just
resetting self._conn without disconnecting the connection.
Only ldap2.close() disconnect the connection. Could it be a risk to see
connection leaks with __del__ or __exit__ ?
Also in the fix there is:
@@ -118,10 +115,11 @@ class ldap2(CrudBackend, LDAPClient):
if debug_level:
_ldap.set_option(_ldap.OPT_DEBUG_LEVEL, debug_level)
- LDAPClient._connect(self)
- conn = self._conn
+ client = LDAPClient(self.ldap_uri,
+ force_schema_updates=self._force_schema_updates)
+ conn = client._conn
Is it the same as 'conn = client.conn()' ?
Thanks
thierry
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/freeipa-devel/attachments/20150902/daa1c9b8/attachment.htm>
More information about the Freeipa-devel
mailing list