lists.arthurdejong.org
RSS feed

nss-pam-ldapd branch master updated. 0.8.12-71-g7c01898

[Date Prev][Date Next] [Thread Prev][Thread Next]

nss-pam-ldapd branch master updated. 0.8.12-71-g7c01898



This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "nss-pam-ldapd".

The branch, master has been updated
       via  7c01898fd02c0f71d4632cca27d3fb92554caa18 (commit)
      from  b9395c8f5796d899c61b1133aa313c89b89f5e0d (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://arthurdejong.org/git/test/commit/?id=7c01898fd02c0f71d4632cca27d3fb92554caa18

commit 7c01898fd02c0f71d4632cca27d3fb92554caa18
Author: Arthur de Jong <arthur@arthurdejong.org>
Date:   Wed Jan 9 23:53:28 2013 +0100

    disable pynslcd cache for now

diff --git a/pynslcd/cache.py b/pynslcd/cache.py
index 8fcb813..ce706be 100644
--- a/pynslcd/cache.py
+++ b/pynslcd/cache.py
@@ -28,8 +28,11 @@ import sqlite3
 
 # TODO: probably create a config table
 
+
+
+
 # FIXME: store the cache in the right place and make it configurable
-filename = '/var/run/nslcd/cache.sqlite'
+filename = '/tmp/cache.sqlite'
 dirname = os.path.dirname(filename)
 if not os.path.isdir(dirname):
     os.mkdir(dirname)
diff --git a/pynslcd/common.py b/pynslcd/common.py
index 3ce0b12..208e321 100644
--- a/pynslcd/common.py
+++ b/pynslcd/common.py
@@ -25,7 +25,7 @@ import ldap
 import ldap.dn
 
 from attmap import Attributes
-import cache
+#import cache
 import cfg
 import constants
 
@@ -191,10 +191,11 @@ class Request(object):
         self.calleruid = calleruid
         module = sys.modules[self.__module__]
         self.search = getattr(module, 'Search', None)
-        if not hasattr(module, 'cache_obj'):
-            cache_cls = getattr(module, 'Cache', None)
-            module.cache_obj = cache_cls() if cache_cls else None
-        self.cache = module.cache_obj
+        #if not hasattr(module, 'cache_obj'):
+        #    cache_cls = getattr(module, 'Cache', None)
+        #    module.cache_obj = cache_cls() if cache_cls else None
+        #self.cache = module.cache_obj
+        self.cache = None
 
     def read_parameters(self, fp):
         """This method should read the parameters from ths stream and
@@ -205,7 +206,8 @@ class Request(object):
         """This method handles the request based on the parameters read
         with read_parameters()."""
         try:
-            with cache.con:
+            #with cache.con:
+            if True:
                 for dn, attributes in self.search(conn=self.conn, 
parameters=parameters):
                     for values in self.convert(dn, attributes, parameters):
                         self.fp.write_int32(constants.NSLCD_RESULT_BEGIN)

-----------------------------------------------------------------------

Summary of changes:
 pynslcd/cache.py  |    5 ++++-
 pynslcd/common.py |   14 ++++++++------
 2 files changed, 12 insertions(+), 7 deletions(-)


hooks/post-receive
-- 
nss-pam-ldapd

-- 
To unsubscribe send an email to
nss-pam-ldapd-commits-unsubscribe@lists.arthurdejong.org or see
http://lists.arthurdejong.org/nss-pam-ldapd-commits/