From 350dd2d4704fa54d46aaf77108bb18008457954a Mon Sep 17 00:00:00 2001 From: richard Date: Mon, 9 Sep 2002 02:58:35 +0000 Subject: [PATCH] more 'n' -> 'c' :( git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/trunk@1094 57a73879-2fb5-44c3-a270-3262357dd7e2 --- roundup/backends/back_bsddb.py | 7 +++++-- roundup/backends/sessions.py | 10 ++++++++-- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/roundup/backends/back_bsddb.py b/roundup/backends/back_bsddb.py index 5984078..ce4a6a1 100644 --- a/roundup/backends/back_bsddb.py +++ b/roundup/backends/back_bsddb.py @@ -15,7 +15,7 @@ # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. # -#$Id: back_bsddb.py,v 1.21 2002-09-03 07:33:01 richard Exp $ +#$Id: back_bsddb.py,v 1.22 2002-09-09 02:58:34 richard Exp $ ''' This module defines a backend that saves the hyperdatabase in BSDDB. ''' @@ -49,7 +49,7 @@ class Database(Database): if os.path.exists(path): return bsddb.btopen(path, mode) else: - return bsddb.btopen(path, 'n') + return bsddb.btopen(path, 'c') def opendb(self, name, mode): '''Low-level database opener that gets around anydbm/dbm @@ -131,6 +131,9 @@ class Database(Database): # #$Log: not supported by cvs2svn $ +#Revision 1.21 2002/09/03 07:33:01 richard +#allow overiding of the index args roundup/cgi/templating.py +# #Revision 1.20 2002/07/19 03:36:34 richard #Implemented the destroy() method needed by the session database (and possibly #others). At the same time, I removed the leading underscores from the hyperdb diff --git a/roundup/backends/sessions.py b/roundup/backends/sessions.py index ea105da..32563bf 100644 --- a/roundup/backends/sessions.py +++ b/roundup/backends/sessions.py @@ -1,4 +1,4 @@ -#$Id: sessions.py,v 1.1 2002-07-30 08:22:38 richard Exp $ +#$Id: sessions.py,v 1.2 2002-09-09 02:58:35 richard Exp $ ''' This module defines a very basic store that's used by the CGI interface to store session information. @@ -86,7 +86,7 @@ class Sessions: # new database? let anydbm pick the best dbm if not db_type: - return anydbm.open(path, 'n') + return anydbm.open(path, 'c') # open the database with the correct module dbm = __import__(db_type) @@ -97,5 +97,11 @@ class Sessions: # #$Log: not supported by cvs2svn $ +#Revision 1.1 2002/07/30 08:22:38 richard +#Session storage in the hyperdb was horribly, horribly inefficient. We use +#a simple anydbm wrapper now - which could be overridden by the metakit +#backend or RDB backend if necessary. +#Much, much better. +# # # -- 2.30.2