neos/cache
Composer 安装命令:
composer require neos/cache
包简介
Neos Cache Framework
README 文档
README
This is a generic cache package for use in projects. It implements PSR-6 and PSR-16 but also brings own interfaces used in Flow and Neos which support additional featuers.
Note
This repository is a read-only subsplit of a package that is part of the
Flow framework (learn more on http://flow.neos.io <http://flow.neos.io/>_).
All pull requests and issues should be opened in the main repository.
The package is usable without the Flow framework, but if you
want to use it, please have a look at the Flow documentation <http://flowframework.readthedocs.org/en/stable/>_
Installation
Install latest version via composer:
composer require neos/cache
Basic usage
$environmentConfiguration = new \Neos\Cache\EnvironmentConfiguration('appIdentifier', __DIR__);
// This cache factory can be used for PSR-6 caches
// and for the Neos CacheInterface
$cacheFactory = new \Neos\Cache\Psr\Cache\CacheFactory(
$environmentConfiguration
);
// Create a PSR-6 compatible cache
$cachePool = $cacheFactory->create(
'myCache',
\Neos\Cache\Backend\SimpleFileBackend::class
);
// Create a PSR-16 compatible cache
$simpleCacheFactory = new \Neos\Cache\Psr\SimpleCache\SimpleCacheFactory(
$environmentConfiguration
);
$simpleCache = $simpleCacheFactory->create(
'myCache',
\Neos\Cache\Backend\SimpleFileBackend::class
);
The first argument given to either factory is a unique identifier for the specific cache instance. If you need different caches you should give them separate identifiers.
Documentation
Both the PSR-6 CachePool and the PSR-16 SimpleCache are separate implementations with their respective factories,
but both use the existing backends
that can also be used with the \Neos\Cache\Frontend\FrontendInterface implementations, which are slightly
different than the PSR caches but also implement additional features like tagging.
Note
Both PSR implementations are not integrated in Flow yet, so when you use them within a Flow installation
it's your responsibility to flush them correctly as ./flow flow:cache:flush will not do that in this case.
Contribute
If you want to contribute to this package or the Flow framework, please have a look at https://github.com/neos/flow-development-collection - it is the repository used for development and all pull requests should go into it.
neos/cache 适用场景与选型建议
neos/cache 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 2.2M 次下载、GitHub Stars 达 10, 最近一次更新时间为 2016 年 11 月 17 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 neos/cache 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 neos/cache 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 neos/cache 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
This module allows drag & drop grouping of items in a GridField
Adds text size controls and text-to-speech controls to Flarum discussion content.
Native Blade date, datetime, and date range pickers.
Symfony and Flysystem integration for the maintained KCFinder continuation.
Laravel integration for the maintained KCFinder continuation.
PHPStan rules shared across KnpLabs organization projects
统计信息
- 总下载量: 2.2M
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 10
- 点击次数: 9
- 依赖项目数: 22
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2016-11-17