public void Stop()
        {
            if (!m_running)
            {
                return;
            }

            m_running = false;

            Thread.Sleep(100); // let the world move

            try
            {
                while (m_retryRequests.TryDequeue(out PollServiceHttpRequest req))
                {
                    req.DoHTTPstop();
                }
            }
            catch
            {
            }

            int count = 10;

            while (--count > 0 && m_workerPool.Count > 0)
            {
                Thread.Sleep(100);
            }

            m_workerPool.Dispose();
            m_workerPool = null;
        }
Esempio n. 2
0
 public void Close()
 {
     if (m_NumberScenes <= 0 && m_workerpool != null)
     {
         m_workerpool.Dispose();
         m_workerpool = null;
     }
 }
Esempio n. 3
0
        public void Close()
        {
            if (!m_Enabled)
            {
                return;
            }

            m_requestQueue.Dispose();
            m_requestQueue = null;
        }
Esempio n. 4
0
        public void Close()
        {
            if (!m_Enabled)
            {
                return;
            }

            m_localRequestsQueue.Dispose();
            m_localRequestsQueue = null;
            m_remoteRequestsQueue.Dispose();
            m_remoteRequestsQueue = null;
        }
Esempio n. 5
0
 public void Stop()
 {
     try
     {
         m_running = false;
         workQueue.Dispose();
         workQueue = null;
     }
     catch
     {
     }
 }
Esempio n. 6
0
        public void Close()
        {
            if (!m_Enabled)
            {
                return;
            }

            if (ProcessQueuedRequestsAsync)
            {
                if (m_NumberScenes <= 0 && m_workerpool != null)
                {
                    m_workerpool.Dispose();
                    m_workerpool = null;
                    m_badRequests.Dispose();
                    m_badRequests = null;
                }
            }
//            m_queue.Dispose();
        }