public function registerHandler(Handler $handler, int $chainProbability = 0) : void
    {
        static $first = true;
        if ($first) {
            $this->handlers = [];
            $first = false;
        }
        $this->handlers[] = [$handler, $chainProbability];
    }