Skip to main content

Use redis as a persistence layer for Whoosh and Haystack

Project description

A Whoosh storage engine using redis for persistence. A Haystack SearchBackend subclass is also provided. Normally the STORAGE key could just be set but Haystack 2.0.0alpha is only aware of file and ram backends.

This is especially useful for small sites hosted on Heroku, which does not allow writing to local disk. The REDISTOGO_URL environment variable is read, falling back to the localhost default port.

Usage

Configure your Haystack connections in settings.py:

import tempfile
HAYSTACK_CONNECTIONS = {
    'default': {
        'ENGINE': 'haystack_redis.RedisEngine',
        'PATH': tempfile.gettempdir(),
    },
}

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

haystack-redis-0.0.1.tar.gz (4.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

haystack_redis-0.0.1-py3-none-any.whl (3.9 kB view details)

Uploaded Python 3

File details

Details for the file haystack-redis-0.0.1.tar.gz.

File metadata

  • Download URL: haystack-redis-0.0.1.tar.gz
  • Upload date:
  • Size: 4.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.0

File hashes

Hashes for haystack-redis-0.0.1.tar.gz
Algorithm Hash digest
SHA256 ccfea88bdc1387c9f7f6f19e9bc062a3612039ef94cfd3e78cf59a96ddd269b2
MD5 d919710184576eb818fa8f331a0412ae
BLAKE2b-256 541961c1338797e37f92013c9efd91a90feba88297a84a76d4c0e7352afff734

See more details on using hashes here.

File details

Details for the file haystack_redis-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: haystack_redis-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 3.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.0

File hashes

Hashes for haystack_redis-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 4fdeee5a9d8daadb1fed4584fd2ffbb25b1ed2315dacb97b53093756d6b54467
MD5 8cb4700aacccf2ca0de5093288df48cf
BLAKE2b-256 f0e35b5c37f581d1074816a330a6a62a3133bd4067c2e91064e4558694fa6c0c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page