// Simply ask the cluster object to schedule the command for execution.
 // It may or may not be immediate, depending on the number of executing commands.
 // If immediate, the command will start its execution on the current thread.
 // Otherwise, the command will start its execution from the thread pool.
 public void Execute()
 {
     if (totalTimeout > 0)
     {
         // totalTimeout is a fixed timeout. Stopwatch is started once on first
         // attempt and not restarted on retry.
         totalWatch = Stopwatch.StartNew();
         AsyncTimeoutQueue.Instance.Add(this, totalTimeout);
     }
     cluster.ScheduleCommandExecution(this);
 }
예제 #2
0
 // Simply ask the cluster object to schedule the command for execution.
 // It may or may not be immediate, depending on the number of executing commands.
 // If immediate, the command will start its execution on the current thread.
 // Otherwise, the command will start its execution from the thread pool.
 public void Execute()
 {
     cluster.ScheduleCommandExecution(this);
 }