News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Michael Nitschinger:
Caching Doctrine Entities with Couchbase
January 08, 2013 @ 10:19:07

Michael Nitschinger has a new post to his site today showing how you can cache the entities you've created with Doctrine using Couchbase as a simple caching tool.

As part of our ongoing efforts to make Couchbase more integrated with frameworks and libraries, we added caching support for the Doctrine ORM. [...] Caching can either be used standalone (through the API provided by doctrine/common) or integrated with the ORM functionality. We'll look at both variants through simple examples, a good documentation can also be found here. Note that at the time of writing, the CouchbaseCache is not mentioned as a caching driver because the documentation still needs to be updated.

He walks you through the steps to get everything you need installed, both through Composer and the Couchbase extension so your PHP installation will support it. He includes sample code that sets up the cache and shows how to check it to see if a key exists. With this base in place, he expands it out to working with the Doctrine ORM. He shows how to create a sample "Person" entity, inject it into the entity manager and perform a query with the Result Cache to locate the object.

0 comments voice your opinion now!
doctrine entity cache orm couchbase tutorial


blog comments powered by Disqus

Similar Posts

DevShed: Introducing Static Members and Methods in PHP 5 (Part 1)

Kevin van Zonneveld's Blog: Redis PHP Introduction

SitePoint PHP Blog: Creating a Subscription-Based Website with Laravel and Recurly, Part 1

C7Y: REST and Resource Handling with CakePHP

Chris Roane's Blog: Advanced PHP Form Validation


Community Events





Don't see your event here?
Let us know!


code community refactor series language threedevsandamaybe laravel opinion install unittest release introduction testing developer podcast symfony2 framework list interview api

All content copyright, 2014 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework