From: Rich Lane <rlane@club.cc.cmu.edu>
To: sup-devel@rubyforge.org
Subject: [sup-devel] [PATCH 4/4] force the index sync thread to give up the cpu
Date: Tue, 29 Dec 2009 17:38:05 -0800 [thread overview]
Message-ID: <1262137085-25928-4-git-send-email-rlane@club.cc.cmu.edu> (raw)
In-Reply-To: <1262137085-25928-3-git-send-email-rlane@club.cc.cmu.edu>
---
lib/sup/index.rb | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/lib/sup/index.rb b/lib/sup/index.rb
index 1131ec7..4f491d6 100644
--- a/lib/sup/index.rb
+++ b/lib/sup/index.rb
@@ -201,6 +201,8 @@ class BaseIndex
while m = @sync_queue.deq
return if m == :die
update_message_state m
+ # Necessary to keep Xapian calls from lagging the UI too much.
+ sleep 0.03
end
end
end
--
1.6.3.3
_______________________________________________
Sup-devel mailing list
Sup-devel@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-devel
next prev parent reply other threads:[~2009-12-30 1:39 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-12-30 1:38 [sup-devel] [PATCH 1/4] factor saving out of thread/message classes Rich Lane
2009-12-30 1:38 ` [sup-devel] [PATCH 2/4] async thread indexing Rich Lane
2009-12-30 1:38 ` [sup-devel] [PATCH 3/4] immediate " Rich Lane
2009-12-30 1:38 ` Rich Lane [this message]
2009-12-31 20:09 ` [sup-devel] [PATCH 1/4] factor saving out of thread/message classes William Morgan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1262137085-25928-4-git-send-email-rlane@club.cc.cmu.edu \
--to=rlane@club.cc.cmu.edu \
--cc=sup-devel@rubyforge.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox