Navigation Menu

Skip to content

Commit

Permalink
Put "object.count" under "system.statistics" namespace
Browse files Browse the repository at this point in the history
  • Loading branch information
piroor committed Apr 22, 2015
1 parent b5c9c4e commit 0e448f4
Show file tree
Hide file tree
Showing 12 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion doc/text/news.md
Expand Up @@ -15,7 +15,7 @@
* `dump` command: forwarded messages are now have their own `date` field.
* `Collectors::RecursiveSum` is introduced.
* `system.status` command: now the reporter node and its internal name is reported as a part of response body.
* `system.object.count` command is now available. It is used by command line utilities internally.
* `system.statistics.object.count` command is now available. It is used by command line utilities internally.
* `system.absorb-data` command is now available. It is used by command line utilities internally.
* Command line utilities:
* `droonga-engine-join` and `droonga-engine-absorb-data` commands work more surely.
Expand Down
2 changes: 1 addition & 1 deletion lib/droonga/plugins/system.rb
Expand Up @@ -25,5 +25,5 @@ module System
end

require "droonga/plugins/system/status"
require "droonga/plugins/system/object"
require "droonga/plugins/system/statistics"
require "droonga/plugins/system/absorb_data"
2 changes: 1 addition & 1 deletion lib/droonga/plugins/system/absorb_data.rb
Expand Up @@ -209,7 +209,7 @@ def on_finish

def count_total_n_objects(&block)
count_message = {
"type" => "system.object.count",
"type" => "system.statistics.object.count",
"dataset" => current_dataset,
"body" => {
"output" => ["total"],
Expand Down
Expand Up @@ -19,7 +19,7 @@
module Droonga
module Plugins
module System
class ObjectCountHandler < Droonga::Handler
class StatisticsObjectCountHandler < Droonga::Handler
include DatabaseScanner

def handle(message)
Expand All @@ -44,8 +44,8 @@ def handle(message)
end

define_single_step do |step|
step.name = "system.object.count"
step.handler = ObjectCountHandler
step.name = "system.statistics.object.count"
step.handler = StatisticsObjectCountHandler
step.collector = Collectors::RecursiveSum
end
end
Expand Down
@@ -1,7 +1,7 @@
{
"inReplyTo": "request-id",
"statusCode": 200,
"type": "system.object.count.result",
"type": "system.statistics.object.count.result",
"body": {
"tables": 0,
"columns": 0,
Expand Down
@@ -1,5 +1,5 @@
{
"type": "system.object.count",
"type": "system.statistics.object.count",
"dataset": "Default",
"body": {
"output": [
Expand Down
@@ -1,7 +1,7 @@
{
"inReplyTo": "request-id",
"statusCode": 200,
"type": "system.object.count.result",
"type": "system.statistics.object.count.result",
"body": {
"tables": 2,
"columns": 0,
Expand Down
Expand Up @@ -10,7 +10,7 @@
}
#@enable-logging
{
"type": "system.object.count",
"type": "system.statistics.object.count",
"dataset": "Default",
"body": {
"output": [
Expand Down
@@ -1,7 +1,7 @@
{
"inReplyTo": "request-id",
"statusCode": 200,
"type": "system.object.count.result",
"type": "system.statistics.object.count.result",
"body": {
"tables": 2,
"columns": 0,
Expand Down
@@ -1,6 +1,6 @@
#@require-catalog-version 2
{
"type": "system.object.count",
"type": "system.statistics.object.count",
"dataset": "Default",
"body": {
"output": [
Expand Down

0 comments on commit 0e448f4

Please sign in to comment.