Commit Graph
6 Commits
Author SHA1 Message Date
Lucanlee 6d3962574c perf/security: V0.9.5-0.9.6 db_pending_upgrades 缓存 + config 凭据外置
- V0.9.5 (P3): db_pending_upgrades() 加 static 请求内缓存,同请求只算一次
- V0.9.6 (安全): config.php 移除明文密码,改从 gitignored 的 config.secret.php 或
  环境变量读取;新增 config.secret.php.example 模板;.gitignore 忽略 config/config.secret.php
  (修复 Webhook reset 反复覆盖明文凭据的隐患;服务器部署前需自建 config.secret.php)
2026-08-09 00:34:54 +08:00
Lucanlee d5c1edefae perf: V0.9.4 商品列表分页 + sitemap 文件缓存 + banner/asset/gzip/类型修复
- P1: Product::listing() 分页(WHERE status=1+LIMIT/OFFSET+总数),ProductController 改用并加翻页器,消除列表全表
- P1: outputSitemap() 加 storage/cache/sitemap.xml 文件缓存(TTL 3600s),消除每次爬虫全表
- P2: 首页 banner 改 whereLimit('status',1,20)
- P2: asset() 追加 ?v=filemtime 版本串,theme.css 改后自动击穿 1y 浏览器缓存
- P2: nginx 启用 gzip(文本资源压缩)
- P2: Model::count() $val 隐式可空改 mixed(PHP 8.4+ 弃用)
2026-08-08 23:53:52 +08:00
Lucanlee 4d36a284ff perf: V0.9.1-0.9.3 性能优化(count/featured 全表→聚合、请求内缓存、二级索引、PSI 未读铃铛)
- V0.9.1 (P0): Model::count() 改 SELECT COUNT(*);新增请求内 identity-map 缓存;
  Product::featured() 改 WHERE+ LIMIT 避免全表
- V0.9.2 (P1): schema.sql 内联二级索引 + install/upgrades/009_perf_indexes.sql 幂等迁移
- V0.9.3 (P1): psi_unread_events() 改 COUNT + JSON_CONTAINS,消除每页 all()+循环
2026-08-08 19:47:35 +08:00
Lucanlee dc0d2622f3 莫名 2026-08-08 17:19:44 +08:00
Lucanlee ba660d0c57 上次错误 2026-08-08 16:26:31 +08:00
Lucanlee 8101177cb5 文件还在测试中 2026-08-08 15:53:53 +08:00