Server
ptolemy.domains.de.lib.Server

This actor models a server with a fixed or variable service time. A server is either busy (serving a customer) or not busy at any given time. If an input arrives when the server is not busy, then the input token is produced on the output with a delay given by the <i>newServiceTime</i> parameter. If an input arrives while the server is busy, then that input is queued until the server becomes free, at which point it is produced on the output with a delay given by the <i>newServiceTime</i> parameter. If several inputs arrive while the server is busy, then they are served on a first-come, first-served basis. <p> If the <i>newServiceTime</i> parameter is not set, it defaults to 1.0. The value of the parameter can be changed at any time during execution of the model by providing an input event at the <i>newServiceTime</i> input port. The token read at that port replaces the value of the <i>newServiceTime</i> parameter. <p> This actor declares that there is delay between the <i>input</i> and the <i>output</i> ports and between <i>newServiceTime</i> and <i>output</i>. The director uses this information for assigning priorities to firings. <p> Like the TimedDelay actor, the output is produced with a future time stamp (larger than current time by <i>newServiceTime</i>). If the service time is always zero and several events arrive at the same time, the server will output the first available input and queue the other inputs to process in the future microsteps. A service time of zero can be usefully viewed as an infinitesimal service time. See <a href="../../../../ptolemy/domains/de/lib/TimedDelay.xml">ptolemy.domains.de.lib.TimedDelay</a>. <p> The key difference between the NonInterruptibleTimer actor and the Server actor is how the service time is specified. In the NonInterruptibleTimer actor, whenever an input arrives, the value of the input token specifies the service time. This actor will guarantee that much service time to be given to that input. In the Server actor, service times for inputs ar decided by the ServiceTime parameter, which may change any time during an execution. In particular, how much service time an input actually gets is decided the value of the ServiceTime parameter at the time the server is ready to serve that input.

Author(s): Lukito Muliadi, Edward A. Lee, Haiyang Zheng
Version:$Id: Server.doc.html,v 1.1 2006/02/22 18:41:22 mangal Exp $
Pt.Proposed Rating:Yellow (hyzheng)
Pt.Accepted Rating:Yellow (hyzheng)