[Zope3-checkins] CVS: ZODB4/ZODB - MappingStorage.py:1.9 __init__.py:1.14
Jeremy Hylton
jeremy@zope.com
Thu, 18 Jul 2002 16:26:19 -0400
Update of /cvs-repository/ZODB4/ZODB
In directory cvs.zope.org:/tmp/cvs-serv22609/ZODB
Modified Files:
MappingStorage.py __init__.py
Log Message:
Remove all the magic from ZODB's __init__.py.
You need to get ZODB.DB.DB and get_transaction() explicitly now.
=== ZODB4/ZODB/MappingStorage.py 1.8 => 1.9 ===
$Id$
"""
-import ZODB
+import ZODB.DB
from ZODB import BaseStorage, POSException, utils
from ZODB.TimeStamp import TimeStamp
@@ -98,9 +98,9 @@
version_pool_size=3, version_cache_size=100,
version_cache_deactivate_after=10):
ms = MappingStorage(name)
- db = ZODB.DB(ms, pool_size, cache_size, cache_deactivate_after,
- version_pool_size, version_cache_size,
- version_cache_deactivate_after)
+ db = ZODB.DB.DB(ms, pool_size, cache_size, cache_deactivate_after,
+ version_pool_size, version_cache_size,
+ version_cache_deactivate_after)
return db
class MappingStorage(BaseStorage.BaseStorage):
=== ZODB4/ZODB/__init__.py 1.13 => 1.14 ===
# FOR A PARTICULAR PURPOSE.
#
##############################################################################
-from zLOG import register_subsystem
-register_subsystem('ZODB')
-del register_subsystem
-from DB import DB
-
-# The following provides some backward compat:
-from Transaction import get_transaction
-import __main__
-__main__.__builtins__.get_transaction=get_transaction
-del __main__
-del get_transaction
-import sys, Transaction
-sys.modules['ZODB.Transaction']=Transaction
-del sys
-del Transaction