Permalink
Browse files

Reordered index, tweaked api wording

  • Loading branch information...
1 parent 12ff679 commit 94289c51c08524151f26d1804df72c4174d905fc @tedivm committed May 18, 2014
Showing with 56 additions and 54 deletions.
  1. +1 −1 API.rst
  2. +55 −53 index.rst
View
@@ -26,7 +26,7 @@ setLogger
*setLogger($logger)*
-Sets a \PSR\Log\LoggerInterface style logging client to enable the tracking of errors.
+Sets a PSR LoggerInterface style logging client to enable the tracking of errors.
setNamespace
View
108 index.rst
@@ -6,6 +6,61 @@ Stash
Stash makes it easy to speed up your code by caching the results of expensive functions or code. Certain actions, like database queries or calls to external APIs, take a lot of time to run but tend to have the same results over short periods of time. This makes it much more efficient to store the results and call them back up later.
+Features
+========
+
+**Stores all PHP Datatypes**
+ Stash can store all of the php native datatypes- integers, booleans, null,
+ strings, arrays and objects that can be serialized.
+
+**Hierarchal Cache**
+ Stored items can be nested, like the folders of a filesystem. This allows
+ for related items to be groups together and erased when changed. Storing a
+ user's basic information can be nested 'users/userId/info', allow all of the
+ user's information to be removed quite easily.
+
+**Interchangeable Back Ends**
+ Stash can use a number of different storage engines to persist cache items
+ between requests. Current drivers include Filesystem, APC, Memcached, and
+ Sqlite drivers.
+
+**Staggered Drivers**
+ It occasionally makes sense to use multiple backends- for example, you may
+ have a small amount of memory to allot but a large piece of filesystem, in
+ which case using APC and the FileSystem driver together is an ideal
+ solution. Stash allows you to do this using the special backend,
+ MultiDriver, which can take an unlimited number of drivers.
+
+**Stampede Protection**
+ When a particularly expensive to generate item misses it can cause a chain
+ reaction- the system slows down as it generates the cache, but the longer it
+ takes the more processes that miss and start regenerating it. Stash gives
+ the developer the ability to limit cache regeneration to a single process,
+ as well as an assortment of ways to handle misses.
+
+**Regenerates Before Expiration**
+ Stash gives developers the option to regenerate a cached item before it
+ misses, making sure that up to data is always available while limiting
+ expensive code to running one instance at a time.
+
+**Distributed Cache Misses**
+ In order to reduce sudden spikes on a system Stash alters the expiration
+ times by lowering the cache age a random amount, thus distributing the cache
+ hits over a period of time.
+
+**Optimized Data Encoding**
+ Care is taken to use the fastest possible encoding and decoding functions
+ when storing data, with the preference being to store things in their native
+ data type. Serialization is reserved only for objects or deep
+ multidimensional arrays where breaking down each component individually
+ would be too long.
+
+**Comprehensively Unit Tested**
+ Every driver, class and wrapper is extensively tested. This includes using a
+ variety of datatypes and ranges in order to ensure that the data you put in
+ is the data you get out.
+
+
Example Usage
=============
@@ -75,59 +130,6 @@ Putting this together with the rest of Stash allows for a simple yet flexible wa
For an in-depth look at using Stash take a look at :doc:`Basic Usage <Basics>`
and :doc:`Drivers <Drivers>`.
-Features
-========
-
-**Stores all PHP Datatypes**
- Stash can store all of the php native datatypes- integers, booleans, null,
- strings, arrays and objects that can be serialized.
-
-**Hierarchal Cache**
- Stored items can be nested, like the folders of a filesystem. This allows
- for related items to be groups together and erased when changed. Storing a
- user's basic information can be nested 'users/userId/info', allow all of the
- user's information to be removed quite easily.
-
-**Interchangeable Back Ends**
- Stash can use a number of different storage engines to persist cache items
- between requests. Current drivers include Filesystem, APC, Memcached, and
- Sqlite drivers.
-
-**Staggered Drivers**
- It occasionally makes sense to use multiple backends- for example, you may
- have a small amount of memory to allot but a large piece of filesystem, in
- which case using APC and the FileSystem driver together is an ideal
- solution. Stash allows you to do this using the special backend,
- MultiDriver, which can take an unlimited number of drivers.
-
-**Stampede Protection**
- When a particularly expensive to generate item misses it can cause a chain
- reaction- the system slows down as it generates the cache, but the longer it
- takes the more processes that miss and start regenerating it. Stash gives
- the developer the ability to limit cache regeneration to a single process,
- as well as an assortment of ways to handle misses.
-
-**Regenerates Before Expiration**
- Stash gives developers the option to regenerate a cached item before it
- misses, making sure that up to data is always available while limiting
- expensive code to running one instance at a time.
-
-**Distributed Cache Misses**
- In order to reduce sudden spikes on a system Stash alters the expiration
- times by lowering the cache age a random amount, thus distributing the cache
- hits over a period of time.
-
-**Optimized Data Encoding**
- Care is taken to use the fastest possible encoding and decoding functions
- when storing data, with the preference being to store things in their native
- data type. Serialization is reserved only for objects or deep
- multidimensional arrays where breaking down each component individually
- would be too long.
-
-**Comprehensively Unit Tested**
- Every driver, class and wrapper is extensively tested. This includes using a
- variety of datatypes and ranges in order to ensure that the data you put in
- is the data you get out.
License
=======

0 comments on commit 94289c5

Please sign in to comment.