diff options
| author | Machiavelli <none@none> | 2010-09-03 10:52:32 +0200 |
|---|---|---|
| committer | Machiavelli <none@none> | 2010-09-03 10:52:32 +0200 |
| commit | 273679c5baba2c8f8978b1d5d0caadf1c933ebda (patch) | |
| tree | bff84137e930a2dec85216669505aa5370f669bd /src/server/worldserver/CommandLine | |
| parent | 277f2674ac278e981bb483c13b34b0a2d2f28a2b (diff) | |
Core/DBLayer
- Store threadbundlemask internally per database pool and prevent direct access to config file post startup
- Fix threadbundlemask flag checking for ReactorRunnable, WorldRunnable
- Remove CLI threadbundlemask flag, CLI doesn´t need a seperate mysql connection nor thread
- Remove unused Character Database connection from WorldSocketMgr / ReactorRunnable
- Add proper LoginDatabase connection to RA Runnable (soon to be overhauled)
Note: still experimental and not tested for live use
--HG--
branch : trunk
Diffstat (limited to 'src/server/worldserver/CommandLine')
| -rw-r--r-- | src/server/worldserver/CommandLine/CliRunnable.cpp | 34 |
1 files changed, 0 insertions, 34 deletions
diff --git a/src/server/worldserver/CommandLine/CliRunnable.cpp b/src/server/worldserver/CommandLine/CliRunnable.cpp index cd93964b709..d5aa0364eaf 100644 --- a/src/server/worldserver/CommandLine/CliRunnable.cpp +++ b/src/server/worldserver/CommandLine/CliRunnable.cpp @@ -698,29 +698,6 @@ int kb_hit_return() /// %Thread start void CliRunnable::run() { - ///- Init MySQL threads or connections - bool needInit = true; - if (!(sWorld.getIntConfig(CONFIG_MYSQL_BUNDLE_WORLDDB) & MYSQL_BUNDLE_RA)) - { - WorldDatabase.Init_MySQL_Connection(); - needInit = false; - } - - if (!(sWorld.getIntConfig(CONFIG_MYSQL_BUNDLE_LOGINDB) & MYSQL_BUNDLE_RA)) - { - LoginDatabase.Init_MySQL_Connection(); - needInit = false; - } - - if (!(sWorld.getIntConfig(CONFIG_MYSQL_BUNDLE_CHARDB) & MYSQL_BUNDLE_RA)) - { - CharacterDatabase.Init_MySQL_Connection(); - needInit = false; - } - - if (needInit) - MySQL::Thread_Init(); - ///- Display the list of available CLI functions then beep //sLog.outString(""); #if PLATFORM != WINDOWS @@ -786,15 +763,4 @@ void CliRunnable::run() } } - - ///- Free MySQL thread resources and deallocate lingering connections - if (!(sWorld.getIntConfig(CONFIG_MYSQL_BUNDLE_WORLDDB) & MYSQL_BUNDLE_RA)) - WorldDatabase.End_MySQL_Connection(); - if (!(sWorld.getIntConfig(CONFIG_MYSQL_BUNDLE_LOGINDB) & MYSQL_BUNDLE_RA)) - LoginDatabase.End_MySQL_Connection(); - - if (!(sWorld.getIntConfig(CONFIG_MYSQL_BUNDLE_CHARDB) & MYSQL_BUNDLE_RA)) - CharacterDatabase.End_MySQL_Connection(); - if (needInit) - MySQL::Thread_End(); } |
