[Checkins] SVN: Products.SQLAlchemyDA/trunk/da.py
Andreas Jung
andreas at andreas-jung.com
Tue May 1 11:30:38 EDT 2007
Log message for revision 74964:
Changed:
U Products.SQLAlchemyDA/trunk/da.py
-=-
Modified: Products.SQLAlchemyDA/trunk/da.py
===================================================================
--- Products.SQLAlchemyDA/trunk/da.py 2007-05-01 15:30:07 UTC (rev 74963)
+++ Products.SQLAlchemyDA/trunk/da.py 2007-05-01 15:30:38 UTC (rev 74964)
@@ -83,7 +83,9 @@
def query(self, query_string, max_rows=None, query_data=None):
- """ *the* query() method"""
+ """ *The* query() method as used by the internal ZSQL
+ machinery.
+ """
wrapper = getSAWrapper(self.sqlalchemy_wrapper_name)
c = wrapper.connection
@@ -144,7 +146,21 @@
def connected(self):
- return True # this is a lie
+ wrapper = getSAWrapper(self.sqlalchemy_wrapper_name)
+ return wrapper.engine is not None
+
+ def manage_stop(self):
+ """ close engine """
+ wrapper = getSAWrapper(self.sqlalchemy_wrapper_name)
+ wrapper._engine = None
+ return 'All engines stopped'
+
+ def manage_start(self):
+ """ Re(start) engine """
+ wrapper = getSAWrapper(self.sqlalchemy_wrapper_name)
+ wrapper._createEngine()
+ return 'All engines started'
+
manage_info = PageTemplateFile('pt/info',
globals(),
More information about the Checkins
mailing list