richardmichel/passport-cache-token

v1.0.2 2023-02-11 04:55 UTC

This package is auto-updated.

Last update: 2024-09-11 08:10:05 UTC


README

使 laravel/passport 令牌可缓存。

安装

$ composer require richardmichel/passport-cache-token -vvv

用法

感谢Laravel的自动包发现机制,您无需进行任何额外操作。

当然,您也可以自由控制缓存策略,只需在配置文件中配置以下内容

config/passport.php

return [
    //...
    'cache' => [
        // Cache key prefix
        'prefix' => 'passport_',
        
        // The lifetime of token cache,
        // Unit: second
        'expires_in' => 300,
        
        // Cache tags
        'tags' => [],
    ],
];