firevel / firestore-session-driver
适用于运行在Google App Engine内部的Laravel应用的Firestore会话驱动程序。
1.0.2
2020-08-26 15:34 UTC
Requires
- google/cloud-firestore: ^1.14
- grpc/grpc: ^1.30
This package is auto-updated.
Last update: 2024-09-27 00:29:09 UTC
README
适用于 Laravel 和 Firevel 的 Firestore 会话驱动程序,兼容 Google App Engine 标准环境(PHP 7.3)。
安装
-
使用
composer require firevel/firestore-session-driver
安装包 -
使用以下内容更新您的 app.yaml
env_variables:
SESSION_DRIVER: firestore
限制
检查 Firestore 配额和限制。
高可用性应用
如果您想在高负载应用中使用此驱动程序,请关注垃圾回收,因为它可能成为瓶颈。
修改 config.sessions.lottery
的值以设置垃圾回收发生的频率,并将 app.yaml 中的 SESSION_GC_BATCH_SIZE
设置为定义垃圾回收批次大小。
如果遇到极端情况,从 cron job 进行手动垃圾回收,或者切换到 cookie
驱动程序。