Watchdog (ElevatorProject v0.1.0)

If a watchdog timer is started for an order and not stopped before the timeout, the corresponding order gets reinjected into the system by calling OrderAssigner.assign_order/1. Keeps track of all active timers through a map from button type and floor to the timer reference.

Uses the following modules:

Link to this section Summary

Functions

Returns a specification to start this module under a supervisor.

Starts a watchdog timer for the given order.

Stops the watchdog timer for the given order

Link to this section Functions

Link to this function

child_spec(init_arg)

Returns a specification to start this module under a supervisor.

See Supervisor.

Starts a watchdog timer for the given order.

Parameters

  • order: Order to start watchdog timer for :: %Order{}

Return

  • :ok :: atom()

Stops the watchdog timer for the given order

Parameters

  • order: Order to stop watchdog timer for :: %Order{}

Return

  • :ok :: atom()