Successfully reported this slideshow.

Haystack

1,264 views

Published on

  • Be the first to comment

  • Be the first to like this

Haystack

  1. 1. Searching for owls
  2. 2. Haystack and Whoosh
  3. 3. $ git clone git://github.com/toastdriven/django-haystack.git $ git clone http://github.com/toastdriven/whoosh.git Get from Git
  4. 4. ● Add haystack to INSTALLED_APPS ● Set HAYSTACK_SEARCH_ENGINE and HAYSTACK_WHOOSH_PATH ● Add global search_sites.py ● Add search_indexes.py for each app ● ./manage.py reindex
  5. 5. ● SearchQuerySet for building searches ● auto_query(), filter() and exclude() ● Consistent with QuerySet ● But feels the wrong model to me
  6. 6. ● Install from separate repo ● Set HAYSTACK_SEARCH_ENGINE ● Set HAYSTACK_XAPIAN_PATH ● reindex
  7. 7. Summary ● Convenient and easy to use ● Easy to switch backend ● Unsure about SearchQuerySet ● Awkward to pull data from multiple models ● Only supports one language at a time

×