NodeFactoryIo/vedran

Restructure penalizing for bad metrics

MakMuftic opened this issue · 0 comments

Refactor on which conditions are node penalized. New rules are:

Node is penalized (removed from active and set on initial cooldown) if:

  1. Fails to provide RPC response
  2. Has not provided fresh ping (in last 10 seconds) - this is checked in the scheduled job

Node is removed from active nodes and not penalized if:

  1. Last provided metrics are not valid (lagging more than 10 blocks) - this is checked in the scheduled job

Node is added to active if:

  1. It is not set on cooldown (penalized) and the last provided metric is valid - this is checked in the metrics controller, and this in conjunction with #94 resolves the problem of restarting loadbalancer.
  2. Scheduled check after node cooldown resolves node as active