rutkai/featureflipperbundle
最新稳定版本:v1.0.1
Composer 安装命令:
composer require rutkai/featureflipperbundle
包简介
Provides advanced feature toggling support for Symfony2 based projects
README 文档
README
This bundle provides a feature flipper interface for Symfony2. Main features:
- Feature checks in twigs and controllers (via DI)
- Assigning expiration date to features
- Assigning responsible people to features
Installation
Add this bundle to composer.json file:
"require": {
...
"rutkai/featureflipperbundle": "~1.0"
},
Register it in AppKernel:
$bundles = array(
...
new Rutkai\FeatureFlipperBundle\RutkaiFeatureFlipperBundle(),
);
Usage
Configuration
# config.yml
rutkai_feature_flipper:
enable_undefined_feature: true # Optional, sets the default strategy for undefined features
expiration_warning: 7 # Optional, expiration e-mails will be sent to responsibles if expiration occurs within the next x days
feature_class: Rutkai\FeatureFlipperBundle\Feature\Feature # Optional, default feature container, must implement FeatureInterface
templates:
warning_console: RutkaiFeatureFlipperBundle:FeatureCheck:warning.txt.twig # Optional, output warning template for feature check command
warning_email: RutkaiFeatureFlipperBundle:FeatureCheck:warning.txt.twig # Optional, e-mail warning template for feature check command
alert_console: RutkaiFeatureFlipperBundle:FeatureCheck:alert.txt.twig # Optional, output alert template for feature check command
alert_email: RutkaiFeatureFlipperBundle:FeatureCheck:alert.txt.twig # Optional, e-mail alert template for feature check command
email:
from: architect@example.com # Required, sender of the warning (default: noreply@example.com)
subject: Expired feature # Optional, subject for the warnings
features:
feature_id:
enabled: true # Required
expiration: "2015-03-03 12:00:00" # Optional
responsible: "András Rutkai" # Optional
responsible_email: email@domain.com # Optional
feature_id_2:
enabled: false
expiration: ~ # no expiration
responsible: ~ # no responsible
Twig
{% if feature_enabled("feature_id") %}
...
{% endif %}
Twig functions:
feature_enabled('feature_id')has_feature('feature_id')
Controller or services
$featureManager = $this->get('feature.manager');
if ($featureManager->isEnabled("feature_id"))
...
Feature manager functions:
$featureManager->isEnabled('feature_id')$featureManager->hasFeature('feature_id')$featureManager->getFeature('feature_id')$featureManager->addFeature($feature)where$featureimplementsFeatureInterface
Roadmap
- 1.0.0: YML/XML based configuration, notifications using e-mail
- 1.1.0: Doctrine backend for storing features
- 1.2.0: Redis backend for storing features
rutkai/featureflipperbundle 适用场景与选型建议
rutkai/featureflipperbundle 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 23 次下载、GitHub Stars 达 1, 最近一次更新时间为 2015 年 02 月 08 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「feature toggle」 「feature toggling」 「feature flipping」 「feature flipper」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 rutkai/featureflipperbundle 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 rutkai/featureflipperbundle 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 rutkai/featureflipperbundle 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
A block that displays featured content - large image, title, description and link.
Laravel Eloquent boolean & timestamp flagged attributes behavior.
Feature toggler extension for Nette Framewrok
MaxAl Subscriptions is a flexible plans and subscription management system for Laravel, with the required tools to run your SAAS like services efficiently. It's simple architecture, accompanied by powerful underlying to afford solid platform for your business.
Feature Flip, Feature Flag, Feature Switch
yii2 toggle column for update in gridview
统计信息
- 总下载量: 23
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 24
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2015-02-08