dogpile.cache


Namedogpile.cache JSON
Version 1.3.3 PyPI version JSON
download
home_pageNone
SummaryA caching front-end based on the Dogpile lock.
upload_time2024-05-05 17:01:36
maintainerNone
docs_urlhttps://pythonhosted.org/dogpile.cache/
authorNone
requires_python>=3.8
licenseMIT
keywords caching
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            dogpile
=======

Dogpile consists of two subsystems, one building on top of the other.

``dogpile`` provides the concept of a "dogpile lock", a control structure
which allows a single thread of execution to be selected as the "creator" of
some resource, while allowing other threads of execution to refer to the previous
version of this resource as the creation proceeds; if there is no previous
version, then those threads block until the object is available.

``dogpile.cache`` is a caching API which provides a generic interface to
caching backends of any variety, and additionally provides API hooks which
integrate these cache backends with the locking mechanism of ``dogpile``.

Overall, dogpile.cache is intended as a replacement to the `Beaker
<https://pypi.org/project/Beaker/>`_ caching system, the internals of which are
written by the same author.   All the ideas of Beaker which "work" are re-
implemented in dogpile.cache in a more efficient and succinct manner, and all
the cruft (Beaker's internals were first written in 2005) relegated to the
trash heap.

Documentation
-------------

See dogpile.cache's full documentation at
`dogpile.cache documentation <https://dogpilecache.sqlalchemy.org>`_.  The
sections below provide a brief synopsis of the ``dogpile`` packages.

Features
--------

* A succinct API which encourages up-front configuration of pre-defined
  "regions", each one defining a set of caching characteristics including
  storage backend, configuration options, and default expiration time.
* A standard get/set/delete API as well as a function decorator API is
  provided.
* The mechanics of key generation are fully customizable.   The function
  decorator API features a pluggable "key generator" to customize how
  cache keys are made to correspond to function calls, and an optional
  "key mangler" feature provides for pluggable mangling of keys
  (such as encoding, SHA-1 hashing) as desired for each region.
* The dogpile lock, first developed as the core engine behind the Beaker
  caching system, here vastly simplified, improved, and better tested.
  Some key performance
  issues that were intrinsic to Beaker's architecture, particularly that
  values would frequently be "double-fetched" from the cache, have been fixed.
* Backends implement their own version of a "distributed" lock, where the
  "distribution" matches the backend's storage system.  For example, the
  memcached backends allow all clients to coordinate creation of values
  using memcached itself.   The dbm file backend uses a lockfile
  alongside the dbm file.  New backends, such as a Redis-based backend,
  can provide their own locking mechanism appropriate to the storage
  engine.
* Writing new backends or hacking on the existing backends is intended to be
  routine - all that's needed are basic get/set/delete methods. A distributed
  lock tailored towards the backend is an optional addition, else dogpile uses
  a regular thread mutex. New backends can be registered with dogpile.cache
  directly or made available via setuptools entry points.
* Included backends feature three memcached backends (python-memcached, pylibmc,
  bmemcached), a Redis backend, a backend based on Python's
  anydbm, and a plain dictionary backend.
* Space for third party plugins, including one which provides the
  dogpile.cache engine to Mako templates.


The SQLAlchemy Project
----------------------

Dogpile is part of the `SQLAlchemy Project <https://www.sqlalchemy.org>`_ and
adheres to the same standards and conventions as the core project.

Development / Bug reporting / Pull requests
___________________________________________

Please refer to the
`SQLAlchemy Community Guide <https://www.sqlalchemy.org/develop.html>`_ for
guidelines on coding and participating in this project.

Code of Conduct
_______________

Above all, SQLAlchemy places great emphasis on polite, thoughtful, and
constructive communication between users and developers.
Please see our current Code of Conduct at
`Code of Conduct <https://www.sqlalchemy.org/codeofconduct.html>`_.

License
-------

Dogpile is distributed under the `MIT license
<https://opensource.org/licenses/MIT>`_.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "dogpile.cache",
    "maintainer": null,
    "docs_url": "https://pythonhosted.org/dogpile.cache/",
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "caching",
    "author": null,
    "author_email": "Mike Bayer <mike_mp@zzzcomputing.com>",
    "download_url": "https://files.pythonhosted.org/packages/81/3b/83ce66995ce658ad63b86f7ca83943c466133108f20edc7056d4e0f41347/dogpile.cache-1.3.3.tar.gz",
    "platform": null,
    "description": "dogpile\n=======\n\nDogpile consists of two subsystems, one building on top of the other.\n\n``dogpile`` provides the concept of a \"dogpile lock\", a control structure\nwhich allows a single thread of execution to be selected as the \"creator\" of\nsome resource, while allowing other threads of execution to refer to the previous\nversion of this resource as the creation proceeds; if there is no previous\nversion, then those threads block until the object is available.\n\n``dogpile.cache`` is a caching API which provides a generic interface to\ncaching backends of any variety, and additionally provides API hooks which\nintegrate these cache backends with the locking mechanism of ``dogpile``.\n\nOverall, dogpile.cache is intended as a replacement to the `Beaker\n<https://pypi.org/project/Beaker/>`_ caching system, the internals of which are\nwritten by the same author.   All the ideas of Beaker which \"work\" are re-\nimplemented in dogpile.cache in a more efficient and succinct manner, and all\nthe cruft (Beaker's internals were first written in 2005) relegated to the\ntrash heap.\n\nDocumentation\n-------------\n\nSee dogpile.cache's full documentation at\n`dogpile.cache documentation <https://dogpilecache.sqlalchemy.org>`_.  The\nsections below provide a brief synopsis of the ``dogpile`` packages.\n\nFeatures\n--------\n\n* A succinct API which encourages up-front configuration of pre-defined\n  \"regions\", each one defining a set of caching characteristics including\n  storage backend, configuration options, and default expiration time.\n* A standard get/set/delete API as well as a function decorator API is\n  provided.\n* The mechanics of key generation are fully customizable.   The function\n  decorator API features a pluggable \"key generator\" to customize how\n  cache keys are made to correspond to function calls, and an optional\n  \"key mangler\" feature provides for pluggable mangling of keys\n  (such as encoding, SHA-1 hashing) as desired for each region.\n* The dogpile lock, first developed as the core engine behind the Beaker\n  caching system, here vastly simplified, improved, and better tested.\n  Some key performance\n  issues that were intrinsic to Beaker's architecture, particularly that\n  values would frequently be \"double-fetched\" from the cache, have been fixed.\n* Backends implement their own version of a \"distributed\" lock, where the\n  \"distribution\" matches the backend's storage system.  For example, the\n  memcached backends allow all clients to coordinate creation of values\n  using memcached itself.   The dbm file backend uses a lockfile\n  alongside the dbm file.  New backends, such as a Redis-based backend,\n  can provide their own locking mechanism appropriate to the storage\n  engine.\n* Writing new backends or hacking on the existing backends is intended to be\n  routine - all that's needed are basic get/set/delete methods. A distributed\n  lock tailored towards the backend is an optional addition, else dogpile uses\n  a regular thread mutex. New backends can be registered with dogpile.cache\n  directly or made available via setuptools entry points.\n* Included backends feature three memcached backends (python-memcached, pylibmc,\n  bmemcached), a Redis backend, a backend based on Python's\n  anydbm, and a plain dictionary backend.\n* Space for third party plugins, including one which provides the\n  dogpile.cache engine to Mako templates.\n\n\nThe SQLAlchemy Project\n----------------------\n\nDogpile is part of the `SQLAlchemy Project <https://www.sqlalchemy.org>`_ and\nadheres to the same standards and conventions as the core project.\n\nDevelopment / Bug reporting / Pull requests\n___________________________________________\n\nPlease refer to the\n`SQLAlchemy Community Guide <https://www.sqlalchemy.org/develop.html>`_ for\nguidelines on coding and participating in this project.\n\nCode of Conduct\n_______________\n\nAbove all, SQLAlchemy places great emphasis on polite, thoughtful, and\nconstructive communication between users and developers.\nPlease see our current Code of Conduct at\n`Code of Conduct <https://www.sqlalchemy.org/codeofconduct.html>`_.\n\nLicense\n-------\n\nDogpile is distributed under the `MIT license\n<https://opensource.org/licenses/MIT>`_.\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "A caching front-end based on the Dogpile lock.",
    "version": "1.3.3",
    "project_urls": {
        "Documentation": "https://dogpilecache.sqlalchemy.org",
        "Homepage": "https://github.com/sqlalchemy/dogpile.cache",
        "Issue Tracker": "https://github.com/sqlalchemy/dogpile.cache/"
    },
    "split_keywords": [
        "caching"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "c9b6eb8bb5bced9f0bf475b22a53e86e4ed80fa60949de1133e2e673e23282d7",
                "md5": "af0aecdb0b2a85ba45d5065bcab2663d",
                "sha256": "5e211c4902ebdf88c678d268e22454b41e68071632daa9402d8ee24e825ed8ca"
            },
            "downloads": -1,
            "filename": "dogpile.cache-1.3.3-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "af0aecdb0b2a85ba45d5065bcab2663d",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 58651,
            "upload_time": "2024-05-05T17:01:40",
            "upload_time_iso_8601": "2024-05-05T17:01:40.046142Z",
            "url": "https://files.pythonhosted.org/packages/c9/b6/eb8bb5bced9f0bf475b22a53e86e4ed80fa60949de1133e2e673e23282d7/dogpile.cache-1.3.3-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "813b83ce66995ce658ad63b86f7ca83943c466133108f20edc7056d4e0f41347",
                "md5": "b457cc3878850b16da75d3393fb68177",
                "sha256": "f84b8ed0b0fb297d151055447fa8dcaf7bae566d4dbdefecdcc1f37662ab588b"
            },
            "downloads": -1,
            "filename": "dogpile.cache-1.3.3.tar.gz",
            "has_sig": false,
            "md5_digest": "b457cc3878850b16da75d3393fb68177",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 272404,
            "upload_time": "2024-05-05T17:01:36",
            "upload_time_iso_8601": "2024-05-05T17:01:36.355140Z",
            "url": "https://files.pythonhosted.org/packages/81/3b/83ce66995ce658ad63b86f7ca83943c466133108f20edc7056d4e0f41347/dogpile.cache-1.3.3.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-05-05 17:01:36",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "sqlalchemy",
    "github_project": "dogpile.cache",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "tox": true,
    "lcname": "dogpile.cache"
}
        
Elapsed time: 0.61700s