public function callAllPromises()
    {
        $pool = $this->pool;

        usort($pool, function ($a, $b) {
            return $a['priority'] - $b['priority'];
        });

        foreach ($pool as $node) {
            $promise = $node['promise'];
            $promise();
        }
    }