urbanindo/yii2-elasticmemcache Yii2 component for elastic memcache without node discovery plugin

yii2-elasticmemcache

Yii2 component for AWS Elasticache Memcache without node discovery plugin

Latest Stable Version Total Downloads Latest Unstable Version Build Status

Installation

The preferred way to install this extension is through composer.

Either run

php composer.phar require --prefer-dist urbanindo/yii2-elasticmemcache "*"

or add

"urbanindo/yii2-elasticmemcache": "*"

to the require section of your composer.json file.

Usage

'components' => [
    'cache' => [
        'class' => UrbanIndo\Yii2\ElasticMemcache\Cache::class,
        'serverConfigs' => [
            [
                    'host' => 'CacheClusterConfiguration1.cache.amazonaws.com', // modify this
                    'port' => 11211,
                    'weight' => 60,
            ],
            [
                    'host' => 'CacheClusterConfiguration2.cache.amazonaws.com', // modify this
                    'port' => 11211,
                    'weight' => 40,
            ]
        ],
        'cache' => [
            'class' => yii\caching\FileCache::class
        ]
    ]
]

Running Test

  • copy test/template-local.php to local.php
  • modify it to your aws elasticache configuration
  • run vendor/bin/phpunit --bootstrap test/bootstrap.php test/CacheTest

Statistics

Downloads
GitHub Stars
GitHub Forks

Releases

Comments



1.0.1 is the latest of 2 releases



MIT license
Stats
1 github stars & 1 github forks
0 downloads in the last day
0 downloads in the last 30 days
19301 total downloads