* [sup-talk] [PATCH] move xapian index loading into load_index
@ 2009-08-06 19:32 Rich Lane
2009-08-11 20:18 ` William Morgan
0 siblings, 1 reply; 2+ messages in thread
From: Rich Lane @ 2009-08-06 19:32 UTC (permalink / raw)
---
lib/sup/xapian_index.rb | 17 ++++++++---------
1 files changed, 8 insertions(+), 9 deletions(-)
diff --git a/lib/sup/xapian_index.rb b/lib/sup/xapian_index.rb
index 5a5dfc1..861c2a3 100644
--- a/lib/sup/xapian_index.rb
+++ b/lib/sup/xapian_index.rb
@@ -20,14 +20,16 @@ class XapianIndex < BaseIndex
super
@index_mutex = Monitor.new
+ end
- @entries = MarshalledGDBM.new File.join(dir, "entries.db")
- @docids = MarshalledGDBM.new File.join(dir, "docids.db")
- @thread_members = MarshalledGDBM.new File.join(dir, "thread_members.db")
- @thread_ids = MarshalledGDBM.new File.join(dir, "thread_ids.db")
- @assigned_docids = GDBM.new File.join(dir, "assigned_docids.db")
+ def load_index
+ @entries = MarshalledGDBM.new File.join(@dir, "entries.db")
+ @docids = MarshalledGDBM.new File.join(@dir, "docids.db")
+ @thread_members = MarshalledGDBM.new File.join(@dir, "thread_members.db")
+ @thread_ids = MarshalledGDBM.new File.join(@dir, "thread_ids.db")
+ @assigned_docids = GDBM.new File.join(@dir, "assigned_docids.db")
- @xapian = Xapian::WritableDatabase.new(File.join(dir, "xapian"), Xapian::DB_CREATE_OR_OPEN)
+ @xapian = Xapian::WritableDatabase.new(File.join(@dir, "xapian"), Xapian::DB_CREATE_OR_OPEN)
@term_generator = Xapian::TermGenerator.new()
@term_generator.stemmer = Xapian::Stem.new(STEM_LANGUAGE)
@enquire = Xapian::Enquire.new @xapian
@@ -35,9 +37,6 @@ class XapianIndex < BaseIndex
@enquire.docid_order = Xapian::Enquire::ASCENDING
end
- def load_index
- end
-
def save_index
end
--
1.6.4
^ permalink raw reply [flat|nested] 2+ messages in thread
* [sup-talk] [PATCH] move xapian index loading into load_index
2009-08-06 19:32 [sup-talk] [PATCH] move xapian index loading into load_index Rich Lane
@ 2009-08-11 20:18 ` William Morgan
0 siblings, 0 replies; 2+ messages in thread
From: William Morgan @ 2009-08-11 20:18 UTC (permalink / raw)
Applied, thanks!
--
William <wmorgan-sup at masanjin.net>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-08-11 20:18 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-08-06 19:32 [sup-talk] [PATCH] move xapian index loading into load_index Rich Lane
2009-08-11 20:18 ` William Morgan
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox