-
Notifications
You must be signed in to change notification settings - Fork 911
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
doc: Add datastoreusage command to the docs
Signed-off-by: Peter Neuroth <[email protected]>
- Loading branch information
Showing
8 changed files
with
99 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -59,7 +59,7 @@ Rusty Russell <<[email protected]>> is mainly responsible. | |
SEE ALSO | ||
-------- | ||
|
||
lightning-listdatastore(7), lightning-deldatastore(7) | ||
lightning-listdatastore(7), lightning-deldatastore(7), lightning-datastoreusage(7) | ||
|
||
RESOURCES | ||
--------- | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
lightning-datastoreusage -- Command for listing datastore usage info | ||
============================================================ | ||
|
||
SYNOPSIS | ||
-------- | ||
|
||
**datastoreusage** | ||
|
||
DESCRIPTION | ||
----------- | ||
|
||
The **datastoreusage** RPC command allows the caller to fetch the | ||
total bytes that are stored under a certain *key* (or from the root), | ||
including the size of the *key*. | ||
|
||
All descendants of the *key* (or root) are taken into account. | ||
RETURN VALUE | ||
------------ | ||
|
||
[comment]: # (GENERATE-FROM-SCHEMA-START) | ||
On success, an object containing **datastoreusage** is returned. It is an object containing: | ||
|
||
- **key** (string): The key from which the database was traversed. | ||
- **total\_bytes** (u64): The total bytes that are stored under the *key*, including the all descendants data and the size of the keys themselves. | ||
|
||
[comment]: # (GENERATE-FROM-SCHEMA-END) | ||
|
||
AUTHOR | ||
------ | ||
|
||
Peter Neuroth <<[email protected]>> is mainly responsible. | ||
|
||
SEE ALSO | ||
-------- | ||
|
||
lightning-datastore(7), lightning-deldatastore(7), lightning-listdatastore(7) | ||
|
||
RESOURCES | ||
--------- | ||
|
||
Main web site: <https://github.com/ElementsProject/lightning> | ||
|
||
[comment]: # ( SHA256STAMP:743b3308974872f191362fcd0b1af647ea1efd28ae30ea04f6deb22418871a17) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -42,7 +42,7 @@ Rusty Russell <<[email protected]>> is mainly responsible. | |
SEE ALSO | ||
-------- | ||
|
||
lightning-listdatastore(7), lightning-datastore(7) | ||
lightning-listdatastore(7), lightning-datastore(7), lightning-datastoreusage(7) | ||
|
||
RESOURCES | ||
--------- | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -40,7 +40,7 @@ Rusty Russell <<[email protected]>> is mainly responsible. | |
SEE ALSO | ||
-------- | ||
|
||
lightning-datastore(7), lightning-deldatastore(7) | ||
lightning-datastore(7), lightning-deldatastore(7), lightning-datastoreusage(7) | ||
|
||
RESOURCES | ||
--------- | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
{ | ||
"$schema": "http://json-schema.org/draft-07/schema#", | ||
"type": "object", | ||
"additionalProperties": false, | ||
"required": [], | ||
"added": "v23.08", | ||
"properties": { | ||
"key": { | ||
"oneOf": [ | ||
{ | ||
"type": "array", | ||
"description": "key is an array of values (though a single value is treated as a one-element array). Used as the staring point to traverse the datastore.", | ||
"items": { | ||
"type": "string" | ||
} | ||
}, | ||
{ | ||
"type": "string" | ||
} | ||
] | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
{ | ||
"$schema": "http://json-schema.org/draft-07/schema#", | ||
"type": "object", | ||
"additionalProperties": false, | ||
"required": [ | ||
"datastoreusage" | ||
], | ||
"properties": { | ||
"datastoreusage": { | ||
"type": "object", | ||
"additionalProperties": false, | ||
"required": [ | ||
"key", | ||
"total_bytes" | ||
], | ||
"properties": { | ||
"key": { | ||
"type": "string", | ||
"description": "The key from which the database was traversed." | ||
}, | ||
"total_bytes": { | ||
"type": "u64", | ||
"description": "The total bytes that are stored under the *key*, including the all descendants data and the size of the keys themselves." | ||
} | ||
} | ||
} | ||
} | ||
} |