Processor suspension

When you shutdown services for maintenance, you may need to stop processors to prevent processes from becoming broken. You can do that by stopping the processor services, but the same can be done simpler from the Flower management console.

To stop a processor, you need to obtain its processor object by calling 'processor' function.

var prc = processor('ProcessorName');


Given a processor name the function creates a processor object. The object has parameterless 'start' and 'stop' methods. You can call them to suspend and resume all activities of a processor.

To apply operation to all active processors, run the following:

var activeProcessors = dir('/Processors/Active'),
    i;

for (i = 0; i < activeProcessors.length; i++) {
    processor(activeProcessors[i].name).stop(); // or start.
}

Last edited Nov 3, 2013 at 9:40 AM by dbratus, version 3

Comments

No comments yet.