[Groonga-commit] groonga/groonga at 2fac70e [master] doc lock_clear: add

Back to archive index

Kouhei Sutou null+****@clear*****
Sun Dec 28 23:32:19 JST 2014


Kouhei Sutou	2014-12-28 23:32:19 +0900 (Sun, 28 Dec 2014)

  New Revision: 2fac70e70aba0a72de32842ce7575ba8e6cf304a
  https://github.com/groonga/groonga/commit/2fac70e70aba0a72de32842ce7575ba8e6cf304a

  Message:
    doc lock_clear: add

  Added files:
    doc/source/example/reference/commands/lock_clear/column.log
    doc/source/example/reference/commands/lock_clear/database.log
    doc/source/example/reference/commands/lock_clear/table.log
    doc/source/reference/commands/lock_clear.rst
  Modified files:
    doc/source/reference/commands/clearlock.rst

  Added: doc/source/example/reference/commands/lock_clear/column.log (+8 -0) 100644
===================================================================
--- /dev/null
+++ doc/source/example/reference/commands/lock_clear/column.log    2014-12-28 23:32:19 +0900 (581cd75)
@@ -0,0 +1,8 @@
+Execution example::
+
+  table_create Site TABLE_HASH_KEY ShortText
+  # [[0, 1337566253.89858, 0.000355720520019531], true]
+  column_create Site title COLUMN_SCALAR ShortText
+  # [[0, 1337566253.89858, 0.000355720520019531], true]
+  lock_clear Site.title
+  # [[0, 1337566253.89858, 0.000355720520019531], true]

  Added: doc/source/example/reference/commands/lock_clear/database.log (+4 -0) 100644
===================================================================
--- /dev/null
+++ doc/source/example/reference/commands/lock_clear/database.log    2014-12-28 23:32:19 +0900 (983d450)
@@ -0,0 +1,4 @@
+Execution example::
+
+  lock_clear
+  # [[0, 1337566253.89858, 0.000355720520019531], true]

  Added: doc/source/example/reference/commands/lock_clear/table.log (+8 -0) 100644
===================================================================
--- /dev/null
+++ doc/source/example/reference/commands/lock_clear/table.log    2014-12-28 23:32:19 +0900 (6e5c316)
@@ -0,0 +1,8 @@
+Execution example::
+
+  table_create Entry TABLE_NO_KEY
+  # [[0, 1337566253.89858, 0.000355720520019531], true]
+  column_create Entry body COLUMN_SCALAR Text
+  # [[0, 1337566253.89858, 0.000355720520019531], true]
+  lock_clear Entry
+  # [[0, 1337566253.89858, 0.000355720520019531], true]

  Modified: doc/source/reference/commands/clearlock.rst (+3 -0)
===================================================================
--- doc/source/reference/commands/clearlock.rst    2014-12-28 23:27:13 +0900 (5c6f292)
+++ doc/source/reference/commands/clearlock.rst    2014-12-28 23:32:19 +0900 (a5a37b6)
@@ -8,6 +8,9 @@
 Summary
 -------
 
+.. deprecated:: 4.0.9
+   Use :doc:`lock_clear` instead.
+
 clearlock - オブジェクトにセットされたロックを解除する
 
 Groonga組込コマンドの一つであるclearlockについて説明します。組込コマンドは、groonga実行ファイルの引数、標準>入力、またはソケット経由でgroongaサーバにリクエストを送信することによって実行します。

  Added: doc/source/reference/commands/lock_clear.rst (+90 -0) 100644
===================================================================
--- /dev/null
+++ doc/source/reference/commands/lock_clear.rst    2014-12-28 23:32:19 +0900 (a86d9c6)
@@ -0,0 +1,90 @@
+.. -*- rst -*-
+
+.. highlightlang:: none
+
+.. groonga-command
+.. database: lock_clear
+
+``lock_clear``
+==============
+
+Summary
+-------
+
+``lock_clear`` command clear the lock of the target object
+recursively. The target object is one of database, table and column.
+
+.. note::
+
+   This is a dangerous command. You must not use this command while
+   other process or thread is doing a write operation to the target
+   object. If you do it, your database may be broken and/or your
+   process may be crashed.
+
+
+Syntax
+------
+
+``truncate`` command takes only one parameter.
+
+There is no required parameter::
+
+  lock_clear [target_name=null]
+
+If ``target_name`` parameters is omitted, database is used for the
+target object. It means that all locks in the database are cleared.
+
+Usage
+-----
+
+Here is an example to clear all locks in the database::
+
+.. groonga-command
+.. include:: ../../example/reference/commands/lock_clear/database.log
+.. lock_clear
+
+Here is an example to clear locks of ``Entry`` table and ``Entry``
+table columns::
+
+.. groonga-command
+.. include:: ../../example/reference/commands/lock_clear/table.log
+.. table_create Entry TABLE_NO_KEY
+.. column_create Entry body COLUMN_SCALAR Text
+.. lock_clear Entry
+
+Here is an example to clear the lock of ``Site.title`` column::
+
+.. groonga-command
+.. include:: ../../example/reference/commands/lock_clear/column.log
+.. table_create Site TABLE_HASH_KEY ShortText
+.. column_create Site title COLUMN_SCALAR ShortText
+.. lock_clear Site.title
+
+Parameters
+----------
+
+This section describes all parameters.
+
+``target_name``
+"""""""""""""""
+
+It specifies the name of table or column.
+
+If you don't specify it, database is used for the target object.
+
+The default is none. It means that the target object is database.
+
+Return value
+------------
+
+::
+
+ [HEADER, SUCCEEDED_OR_NOT]
+
+``HEADER``
+
+  See :doc:`/reference/command/output_format` about ``HEADER``.
+
+``SUCCEEDED_OR_NOT``
+
+  If command succeeded, it returns true, otherwise it returns false on error.
-------------- next part --------------
HTML����������������������������...
Download 



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