void MySqlThreadResPool::DoTask( FvWorkerThread::ITask& task, MySqlThreadData& threadData ) { if (!threadData.m_kConnection.HasFatalError()) { if (this->IsMainThreadData( threadData )) { FvWorkerThreadPool::DoTaskInCurrentThread( task ); } else { FV_VERIFY( ThreadPool().DoTask( task ) ); } } else { task.OnRunComplete(); } }
ThreadPool::ThreadPool() { ThreadPool(2); }