Test Intervals

From FreeNATS Wiki
Jump to: navigation, search

Test intervals can be set on a per-node and per-test basis (additionally a nodeside monitor pull interval can also be defined).

The way this system works is as follows:

  • The main tester script is run via a scheduler, usually every one minute.
  • Each node is checked to see if it is
  • If a node is scheduled and due then it is tested
  • Each local test (server-side test) is checked to see if it is due
  • If a test is due:
    • it is run
    • the result is recorded
    • it is set to be due again in the test interval number of minutes
  • If a nodeside pull is due
    • it is performed
    • the result is recorded
    • it is set to be due again in the nodeside pull interval number of minutes
  • The node finishes testing
    • it is recorded
    • it is set to be due again in the node interval number of minutes

In any interval 0 means no delay - it is scheduled to be run at every opportunity.

With this method nodes can only be tested as often as the scheduler fires and individual tests can only be performed as often as the node is due to be tested, for example a test with a 1 minute interval on a node with a 5 minute interval will only be run once every five minutes, when the node is due for testing.