Definition at line 108 of file AtlRunQueryUtils.py.
 
◆ __init__()
      
        
          | def python.utils.AtlRunQueryUtils.DBConnectionController.__init__ | ( |  | self | ) |  | 
      
 
 
◆ CloseAll()
      
        
          | def python.utils.AtlRunQueryUtils.DBConnectionController.CloseAll | ( |  | self | ) |  | 
      
 
Definition at line 179 of file AtlRunQueryUtils.py.
  180         for (dbname,dbconn) 
in self.openConn.
items():
 
  181             if isinstance(dbconn,cx_Oracle.Connection):
 
  184                 dbconn.closeDatabase()
 
 
 
 
◆ get_auth()
      
        
          | def python.utils.AtlRunQueryUtils.DBConnectionController.get_auth | ( |  | self, | 
        
          |  |  |  | key | 
        
          |  | ) |  |  | 
      
 
Definition at line 134 of file AtlRunQueryUtils.py.
  134     def get_auth(self,key):
 
  135         if key 
not in self.pw:
 
  136             from os 
import environ 
as env
 
  142             auth = XMLReader(env[
'CORAL_AUTH_PATH']+
"/authentication.xml")
 
  143             for c 
in auth.connectionlist.connections:
 
  146                 self.pw[key] = dict([(p[
'name'],p[
'value']) 
for p 
in c.parameters])
 
  148             if key 
not in self.pw:
 
  149                 print (
"Can not authenticate DB",key)
 
 
 
◆ GetAtlasRunDBConnection()
      
        
          | def python.utils.AtlRunQueryUtils.DBConnectionController.GetAtlasRunDBConnection | ( |  | self | ) |  | 
      
 
Definition at line 154 of file AtlRunQueryUtils.py.
  154     def GetAtlasRunDBConnection(self):
 
  155         if 'run' not in self.openConn:
 
  156             auth = self.get_auth(
'oracle://ATLAS_COOLPROD/ATLAS_COOLOFL_TRIGGER')
 
  157             self.openConn[
'run'] = cx_Oracle.connect(
"%s/%s@ATLAS_COOLPROD" % (auth[
'user'],auth[
'password']))
 
  158         return self.openConn[
'run']
 
 
 
◆ GetDBConn()
      
        
          | def python.utils.AtlRunQueryUtils.DBConnectionController.GetDBConn | ( |  | self, | 
        
          |  |  |  | schema, | 
        
          |  |  |  | db | 
        
          |  | ) |  |  | 
      
 
for example schema=COOLONL_TRIGGER', db='CONDBR2
 
Definition at line 113 of file AtlRunQueryUtils.py.
  113     def GetDBConn(self, schema, db):
 
  114         """for example schema=COOLONL_TRIGGER', db='CONDBR2""" 
  115         if (schema,db) 
in self.openConn:
 
  116             return self.openConn[(schema,db)]
 
  118             if schema==
"DEFECTS":
 
  121                 defdb = DQDefects.DefectsDB(
"COOLOFL_GLOBAL/CONDBR2",tag=db)
 
  122                 defdb.closeDatabase = 
lambda: 
None 
  123                 self.openConn[(schema,db)] = defdb
 
  126                 from CoolConvUtilities.AtlCoolLib  
import indirectOpen
 
  127                 self.openConn[(schema,db)] = 
indirectOpen(
"%s/%s"%(schema,db),
True, logging)
 
  130             traceback.print_exc()
 
  132         return self.openConn[(schema,db)]
 
 
 
◆ GetPVSSDBConnection()
      
        
          | def python.utils.AtlRunQueryUtils.DBConnectionController.GetPVSSDBConnection | ( |  | self | ) |  | 
      
 
Definition at line 173 of file AtlRunQueryUtils.py.
  173     def GetPVSSDBConnection(self):
 
  174         if 'pvss' not in self.openConn:
 
  175             auth = self.get_auth(
'oracle://ATLAS_PVSSPROD/ATLAS_PVSS_READER')
 
  176             self.openConn[
'pvss'] = cx_Oracle.connect(
"%s/%s@ATLAS_PVSSPROD" % (auth[
'user'],auth[
'password']))
 
  177         return self.openConn[
'pvss']
 
 
 
◆ GetSFODBConnection()
      
        
          | def python.utils.AtlRunQueryUtils.DBConnectionController.GetSFODBConnection | ( |  | self | ) |  | 
      
 
Definition at line 160 of file AtlRunQueryUtils.py.
  160     def GetSFODBConnection(self):
 
  161         if 'sfo' not in self.openConn:
 
  162             auth = self.get_auth(
'oracle://ATLAS_CONFIG/ATLAS_SFO_T0_R')
 
  163             with timer(
"Opening Connection to ATLAS_SFO_T0_R @ ATLAS_CONFIG"):
 
  164                 self.openConn[
'sfo'] = cx_Oracle.connect(
"%s/%s@ATLAS_CONFIG" % (auth[
'user'],auth[
'password']))
 
  165         return self.openConn[
'sfo']
 
 
 
◆ GetTier0DBConnection()
      
        
          | def python.utils.AtlRunQueryUtils.DBConnectionController.GetTier0DBConnection | ( |  | self | ) |  | 
      
 
Definition at line 167 of file AtlRunQueryUtils.py.
  167     def GetTier0DBConnection(self):
 
  168         if 'tier0' not in self.openConn:
 
  169             auth = self.get_auth(
'oracle://ATLAS_T0/ATLAS_T0')
 
  170             self.openConn[
'tier0'] = cx_Oracle.connect(
"%s/%s@ATLAS_T0" % (auth[
'user'],auth[
'password']))
 
  171         return self.openConn[
'tier0']
 
 
 
◆ openConn
      
        
          | python.utils.AtlRunQueryUtils.DBConnectionController.openConn | 
      
 
 
◆ pw
      
        
          | python.utils.AtlRunQueryUtils.DBConnectionController.pw | 
      
 
 
The documentation for this class was generated from the following file: