[Checkins] SVN: z3c.sqlalchemy/trunk/ made 'twophase' option configurable
Andreas Jung
andreas at andreas-jung.com
Mon Jan 5 09:51:26 EST 2009
Log message for revision 94535:
made 'twophase' option configurable
Changed:
U z3c.sqlalchemy/trunk/CHANGES.txt
U z3c.sqlalchemy/trunk/setup.py
U z3c.sqlalchemy/trunk/src/z3c/sqlalchemy/base.py
-=-
Modified: z3c.sqlalchemy/trunk/CHANGES.txt
===================================================================
--- z3c.sqlalchemy/trunk/CHANGES.txt 2009-01-05 12:09:46 UTC (rev 94534)
+++ z3c.sqlalchemy/trunk/CHANGES.txt 2009-01-05 14:51:26 UTC (rev 94535)
@@ -1,3 +1,8 @@
+1.3.9 (06.01.2009)
+------------------
+
+ - made 'twophase' configurable
+
1.3.8 (06.01.2009)
------------------
Modified: z3c.sqlalchemy/trunk/setup.py
===================================================================
--- z3c.sqlalchemy/trunk/setup.py 2009-01-05 12:09:46 UTC (rev 94534)
+++ z3c.sqlalchemy/trunk/setup.py 2009-01-05 14:51:26 UTC (rev 94535)
@@ -21,7 +21,7 @@
'Topic :: Software Development :: Libraries :: Python Modules',
]
-version = '1.3.8'
+version = '1.3.9'
desc = open('README.txt').read().strip()
changes = open('CHANGES.txt').read().strip()
Modified: z3c.sqlalchemy/trunk/src/z3c/sqlalchemy/base.py
===================================================================
--- z3c.sqlalchemy/trunk/src/z3c/sqlalchemy/base.py 2009-01-05 12:09:46 UTC (rev 94534)
+++ z3c.sqlalchemy/trunk/src/z3c/sqlalchemy/base.py 2009-01-05 14:51:26 UTC (rev 94535)
@@ -25,7 +25,7 @@
implements(ISQLAlchemyWrapper)
- def __init__(self, dsn, model=None, transactional=True,
+ def __init__(self, dsn, model=None, transactional=True, twophase=False,
engine_options={}, session_options={},
extension_options={}, **kw):
""" 'dsn' - a RFC-1738-style connection string
@@ -52,6 +52,7 @@
self.username = self.url.username
self.password = self.url.password
self.dbname = self.url.database
+ self.twophase = twophase
self.drivername = self.url.drivername
self.transactional = transactional
self.engine_options = engine_options
@@ -135,7 +136,7 @@
self._engine = create_engine(self.dsn, **self.engine_options)
self._sessionmaker = scoped_session(sessionmaker(bind=self._engine,
transactional=True,
- twophase=True,
+ twophase=self.twophase,
autoflush=True,
extension=ZopeTransactionExtension(**self.extension_options),
**self.session_options
More information about the Checkins
mailing list