public function setHook()
    {
        Hook::subscribe(Hook::SHUTDOWN_HOOK, [$this, 'saveCacheHook'], 10);

        foreach ($this->repository as $name => $cache)
            $this->checkExpiry($name);
    }