article

Paul Toone avatar image
0 Likes"
Paul Toone posted

Dispatcher   

The dispatcher is used to control a group of transporters or operators. Task sequences are sent to the dispatcher from an object and the dispatcher delegates them to the transports or operators that are connected to its output ports.. The task sequence will be performed by the mobile resource that finally receives the request.

Details

The dispatcher object performs queueing and routing logic for task sequences. Depending on the modeler's logic, task sequences can be queued up or dispatched immediately once they are given to a dispatcher.

Ports

You use input and output ports to associate teams of task executers. When you connect the output ports of a dispatcher to the input ports of a task executer, this makes that task executer a member of the dispatcher's "team". When the dispatcher receives a task sequence, it will dispatch the task sequence to one of the task executers connected to its output ports, depending on logic you define.

Dispatching Logic

When a dispatcher receives a task sequence, triggered by the dispatchtasksequence() command, it first calls its Pass To function. This function returns the port number to pass the task sequence on to. The dispatcher will then immediately pass the task sequence on to the object connected to that port. If the function returns a 0 instead of a port number, then the task will be queued up in the dispatcher's task sequence queue. This is done by calling the queue strategy function for the task sequence. This queue strategy returns a value associated with the task sequence, and represents a priority to sort the task sequence in the queue. Higher priority values go to the front of the queue, and lower values go the back. Usually you will simply return the priority value of the task sequence, but the queue strategy function allows you to dynamically change the priority of a task sequence if needed. When ordering the task sequence in the queue, the dispatcher actually calls the queue strategy function several times, once for each task sequence in the queue, to get each priority value and compare it with the new task sequence's priority value. Once it has found the right location to put the task sequence, it ranks the new task sequence accordingly.

A dispatcher is a super-class of all TaskExecuters, or in other words all TaskExecuters are also dispatchers. This means that an Operator or Transporter can also act as a dispatcher or team leader, giving task sequences to other members of its team, as well as executing task sequences itself.

States

The dispatcher doesn't implement any states.

Properties pages

dispatcher
Triggers
Labels
General

Related Topics

Task Sequences

flexsim users manual
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Article

Contributors

paul.t contributed to this article

Navigation

FlexSim 2016.1