[Groonga-commit] droonga/fluent-plugin-droonga at 7c2a4e6 [master] Add handler for "watch.sweep" to run garbage collection

Back to archive index

YUKI Hiroshi null+****@clear*****
Fri Nov 1 16:21:49 JST 2013


YUKI Hiroshi	2013-11-01 16:21:49 +0900 (Fri, 01 Nov 2013)

  New Revision: 7c2a4e61e1aed79ecdf0a1274a45f71a16cdc54f
  https://github.com/droonga/fluent-plugin-droonga/commit/7c2a4e61e1aed79ecdf0a1274a45f71a16cdc54f

  Message:
    Add handler for "watch.sweep" to run garbage collection

  Modified files:
    lib/droonga/plugin/handler_watch.rb

  Modified: lib/droonga/plugin/handler_watch.rb (+7 -0)
===================================================================
--- lib/droonga/plugin/handler_watch.rb    2013-11-01 16:15:11 +0900 (bbb6a2e)
+++ lib/droonga/plugin/handler_watch.rb    2013-11-01 16:21:49 +0900 (1d442cf)
@@ -16,6 +16,7 @@
 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 
 require "droonga/watcher"
+require "droonga/sweeper"
 require "droonga/handler"
 
 module Droonga
@@ -25,6 +26,7 @@ module Droonga
     def initialize(*args)
       super
       @watcher = Watcher.new(@context)
+      @sweeper = Sweeper.new(@context)
     end
 
     command "watch.subscribe" => :subscribe
@@ -61,6 +63,11 @@ module Droonga
       end
     end
 
+    command "watch.sweep" => :sweep
+    def sweep(request)
+      @sweeper.sweep_expired_subscribers
+    end
+
     private
     def parse_request(request)
       subscriber = request["subscriber"]
-------------- next part --------------
HTML����������������������������...
Download 



More information about the Groonga-commit mailing list
Back to archive index