code: public void stop() {
          if (!this.isActive) {
              return;
          }
  
          coreThread.shutdown();
          criticalThread.shutdown();
          for(int i=0;i<workerThreads.length;i++)
          	workerThreads[i].shutdown();
          
          for(int i=0;i<criticalWorkerThreads.length;i++)
          	criticalWorkerThreads[i].shutdown();
          
          try
          {
          	Thread.sleep(40);
          }
          catch(InterruptedException e)
  		{                				
  		}
          
          for(int i=0;i<taskQueues.length;i++)
          	taskQueues[i].clear();
          
          for(int i=0;i<heartBeatQueue.length;i++)
          	heartBeatQueue[i].clear();
      }
docs: Stops scheduler.