apollopy / laravel-memcached
此包已被 弃用 并不再维护。未建议替代包。
Laravel 5.1 的 Memcached,支持持久连接和 SASL 认证,与阿里云 OSC 兼容。
1.3.0
2017-04-26 07:23 UTC
Requires
- php: >=5.5.9
- illuminate/cache: 5.1.*|5.2.*
README
Laravel 的 Memcached,支持持久连接和 SASL 认证,与阿里云 OSC 兼容。
安装
此服务提供者必须 替换。
// config/app.php 'providers' => [ // Illuminate\Cache\CacheServiceProvider::class, ApolloPY\Memcached\CacheServiceProvider::class, ]
编辑缓存配置
// config/cache.php 'memcached' => [ 'driver' => 'memcached', 'servers' => [ [ 'host' => '127.0.0.1', 'port' => 11211, 'weight' => 100, ], ], 'persistent_id' => 'you persistent id', 'username' => 'you username', 'password' => 'you password', 'options' => [ // optional Memcached::OPT_COMPRESSION => false, Memcached::OPT_BINARY_PROTOCOL => true, ... ], 'check_version' => false, // optional, default true ],