File tree Expand file tree Collapse file tree 1 file changed +28
-3
lines changed
Expand file tree Collapse file tree 1 file changed +28
-3
lines changed Original file line number Diff line number Diff line change 1- # MongoDB PSR-6 adapter
2- [ ![ Build Status] ( https://travis-ci.org/php-cache/mongodb-adapter.svg?branch=master )] ( https://travis-ci.org/php-cache/mongodb-adapter ) [ ![ codecov.io] ( https://codecov.io/github/php-cache/mongodb-adapter/coverage.svg?branch=master )] ( https://codecov.io/github/php-cache/mongodb-adapter?branch=master )
1+ # MongoDB PSR-6 Cache pool
2+ [ ![ Gitter] ( https://badges.gitter.im/php-cache/cache.svg )] ( https://gitter.im/php-cache/cache?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge )
3+ [ ![ Latest Stable Version] ( https://poser.pugx.org/cache/mongodb-adapter/v/stable )] ( https://packagist.org/packages/cache/mongodb-adapter )
4+ [ ![ Total Downloads] ( https://poser.pugx.org/cache/mongodb-adapter/downloads )] ( https://packagist.org/packages/cache/mongodb-adapter )
5+ [ ![ Monthly Downloads] ( https://poser.pugx.org/cache/mongodb-adapter/d/monthly.png )] ( https://packagist.org/packages/cache/mongodb-adapter )
6+ [ ![ Software License] ( https://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat-square )] ( LICENSE )
37
4- This is a implementation for the PSR-6 for a MongoDB cache. This implementation supports tags.
8+ This is a PSR-6 cache implementation using MongoDB. It is a part of the PHP Cache organisation. To read about
9+ features like tagging and hierarchy support please read the shared documentation at [ www.php-cache.com ] ( http://www.php-cache.com ) .
10+
11+ ### Install
12+
13+ ``` bash
14+ composer require cache/mongodb-adapter
15+ ```
16+
17+ ### Use
18+
19+ ``` php
20+ $manager = new Manager('mongodb://'.getenv('MONGODB_HOST'));
21+ $collection = MongoDBCachePool::createCollection($manager, 'localhost:27017', 'psr6test.cache');
22+
23+ $pool = new MongoDBCachePool($collection);
24+ ```
25+
26+ ### Contribute
27+
28+ Contributions are very welcome! Send a pull request to the [ main repository] ( https://github.com/php-cache/cache ) or
29+ report any issues you find on the [ issue tracker] ( http://issues.php-cache.com ) .
You can’t perform that action at this time.
0 commit comments