本文整理匯總了PHP中DbManager::shutdown方法的典型用法代碼示例。如果您正苦於以下問題:PHP DbManager::shutdown方法的具體用法?PHP DbManager::shutdown怎麽用?PHP DbManager::shutdown使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類DbManager
的用法示例。
在下文中一共展示了DbManager::shutdown方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: __destruct
public function __destruct()
{
DbManager::shutdown();
}
示例2: initDb
protected static function initDb($should_perform_shutdown = false)
{
KalturaLog::debug("----------------- Initializing DB ------------------- ");
if (self::$s_databaseManager == NULL) {
$dbConf = kConf::getDB();
DbManager::setConfig($dbConf);
//self::$s_databaseManager = new sfDatabaseManager();
}
if ($should_perform_shutdown) {
KalturaLog::debug("Attempting shutdown of DB due to errors");
// All of this brutal shutdown & init is to release all DB connections and restart as clean as possible
//
//self::$s_databaseManager->shutdown();
//propel::close();
//propel::initialize();
DbManager::shutdown();
DbManager::initialize();
}
DbManager::initialize();
//self::$s_databaseManager->initialize();
}