From 3b73241bfb6fa47f8b7c1d6629a3e537d34aad3c Mon Sep 17 00:00:00 2001 From: Marcin Koziej Date: Wed, 9 Nov 2011 10:19:22 +0100 Subject: [PATCH] don't index tags from db. --- apps/search/index.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/apps/search/index.py b/apps/search/index.py index 2ae909a84..7ec88c619 100644 --- a/apps/search/index.py +++ b/apps/search/index.py @@ -125,7 +125,7 @@ class Index(IndexStore): doc = self.create_book_doc(book) doc.add(Field("slug", book.slug, Field.Store.NO, Field.Index.ANALYZED_NO_NORMS)) - doc.add(Field("tags", ','.join([t.name for t in book.tags]), Field.Store.NO, Field.Index.ANALYZED)) + #doc.add(Field("tags", ','.join([t.name for t in book.tags]), Field.Store.NO, Field.Index.ANALYZED)) doc.add(Field("is_book", 'true', Field.Store.NO, Field.Index.NOT_ANALYZED)) # validator, name @@ -288,11 +288,12 @@ class ReusableIndex(Index): @staticmethod def close_reusable(): if ReusableIndex.index is not None: - print("closing index") + print("wait for indexing to finish") for job in ReusableIndex.pool_jobs: job.get() sys.stdout.write('.') sys.stdout.flush() + print("done.") ReusableIndex.pool.close() ReusableIndex.index.optimize() -- 2.20.1