-
Notifications
You must be signed in to change notification settings - Fork 7
Document graph.memory #148
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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,56 @@ | ||
| --- | ||
| title: "GRAPH.MEMORY" | ||
| description: > | ||
| The GRAPH.MEMORY command returns detailed memory usage statistics for the specified graph. | ||
| This command can be used to monitor memory consumption at the graph level, | ||
| providing insight into how much memory is used by various internal data structures such as | ||
| nodes, edges, schemas, and indices. | ||
|
|
||
| This information is useful for debugging, monitoring, and optimizing graph workloads in FalkorDB deployments. | ||
| parent: "Commands" | ||
| --- | ||
|
|
||
| # GRAPH.MEMORY | ||
|
|
||
| The GRAPH.MEMORY command returns detailed memory usage statistics for the specified graph. | ||
| This command can be used to monitor memory consumption at the graph level, | ||
| providing insight into how much memory is used by various internal data structures such as | ||
| nodes, edges, schemas, and indices. | ||
|
|
||
| This information is useful for debugging, monitoring, and optimizing graph workloads in FalkorDB deployments. | ||
|
|
||
| The optional `SAMPLES` option can be provided, where count is the number of sampled graph entities. | ||
| The samples are averaged to estimate the total size. By default, this option is set to 100. | ||
|
|
||
|
|
||
| Usage: `GRAPH.MEMORY USAGE <graph_id> [SAMPLES <count>]` | ||
|
|
||
| ```sh | ||
| 127.0.0.1:6379> GRAPH.MEMORY USAGE flights | ||
| 1) "total_graph_sz_mb" | ||
| 2) (integer) 1086 | ||
| 3) "label_matrices_sz_mb" | ||
| 4) (integer) 96 | ||
| 5) "relation_matrices_sz_mb" | ||
| 6) (integer) 64 | ||
| 7) "amortized_node_storage_sz_mb" | ||
| 8) (integer) 120 | ||
| 9) "amortized_edge_storage_sz_mb" | ||
| 10) (integer) 54 | ||
| 11) "indices_sz_mb" | ||
| 12) (integer) 752 | ||
| ``` | ||
|
|
||
| ## Output | ||
|
|
||
| The command returns an array of key-value pairs, where each pair represents a specific memory metric and its value (in MB). | ||
|
|
||
| | Metric Name | Type | Description | | ||
| |:-------------------------------|:--------|:---------------------------------------------------| | ||
| | `total_graph_sz_mb` | integer | Total memory consumed by the graph. | | ||
| | `label_matrices_sz_mb` | integer | Amount of memory used for node labels tracking. | | ||
| | `relation_matrices_sz_mb` | integer | Amount of memory used for graph topology tracking. | | ||
| | `amortized_node_storage_sz_mb` | integer | Amount of memory used for nodes storage. | | ||
| | `amortized_edge_storage_sz_mb` | integer | Amount of memory used for relationships storage. | | ||
| | `indices_sz_mb` | integer | Amount of memory consumed by indices. | | ||
|
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.