定制 oxhq/cachelet-request 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

oxhq/cachelet-request

最新稳定版本:v0.3.0

Composer 安装命令:

composer require oxhq/cachelet-request

包简介

Request and response caching integration for Cachelet.

README 文档

README

Route response caching with explicit vary dimensions and Cachelet coordinates.

cachelet-request turns response caches into inspectable request-family entries with route metadata, vary inputs, namespace invalidation, and safe bypass behavior.

Install

composer require oxhq/cachelet-request

Best Fit

Use this package when route responses are expensive, cacheable, and need explicit vary rules.

It provides:

  • route ->cachelet() integration
  • middleware-driven response caching
  • vary by query string, headers, locale, and authenticated user
  • namespace invalidation for request caches
  • bypass behavior for streamed, binary, and non-cacheable responses
  • canonical module = request coordinates and telemetry

Example

Route::get('/users', UserIndexController::class)
    ->name('users.index')
    ->cachelet(600, [
        'vary' => ['query' => true, 'auth' => true],
        'namespace' => 'users',
    ]);

Contract

Defaults in 0.2.x:

  • cacheable methods: GET, HEAD
  • cacheable statuses: 200
  • streamed and binary responses are bypassed
  • non-cacheable SWR refresh callbacks preserve the last good cacheable payload

Docs

统计信息

  • 总下载量: 0
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 7
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-04-20

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固