Skip to content

Commit 12e3720

Browse files
committed
Trim index warmup and move to bottom
1 parent ce0131a commit 12e3720

File tree

1 file changed

+8
-19
lines changed

1 file changed

+8
-19
lines changed

modules/ROOT/pages/performance/vector-index-memory-configuration.adoc

Lines changed: 8 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -7,29 +7,10 @@ When you have a vector index, you must ensure that there is sufficient memory fo
77
If Lucene has insufficient memory, the OS will perform page swapping and read data from disk, which will dramatically degrade the Neo4j vector index search performance.
88
Tools like IOTOP can assist in understanding disk I/O usage.
99

10-
== Warming up the vector index
11-
12-
The Neo4j vector index is only loaded into memory when it is accessed.
13-
Ideally, the Lucene vector index is preloaded into OS-managed memory before quering the index.
14-
However, you can also warm up the index by running a few random queries to help the OS load the index into memory.
15-
The number of queries required to warm up the index depends on the size of the index and the amount of memory available.
16-
For a smaller index (up to 1M entries), five queries should be sufficient to load the index into memory.
17-
For a larger index, you may need to run a hundred queries.
18-
It is also recommended to test the index.
19-
20-
[NOTE]
21-
====
22-
Since the Neo4j vector index is managed by the OS memory, restarting the server clears the buffer/cache, requiring the vector index to be reloaded into memory.
23-
In the event of a rolling restart/patch/upgrade, an approach may be needed to address the warmup requirement.
24-
====
25-
2610
== Optimal Neo4j memory configuration for vector indexes
2711

28-
29-
3012
The memory configuration recommendations are _Heap + Neo4j PageCache + .25(Vector Index Size) + Additional OS Managed Memory_.
3113

32-
3314
=== Considerations and caveats
3415

3516
You can reduce the Neo4j page cache if you plan not to return vectors to the user or calling application, as the vectors are not needed and should not be loaded into memory.
@@ -172,3 +153,11 @@ The following examples show how to calculate the memory requirements when vector
172153
| 410.5GB
173154
| 70.5GB
174155
|===
156+
157+
== Warming up the vector index
158+
159+
The Neo4j vector index is only loaded into memory when it is accessed.
160+
Ideally, the Lucene vector index is preloaded into OS-managed memory before quering the index.
161+
However, you can also warm up the index by running a few random queries to help the OS load the index into memory.
162+
The number of queries required to warm up the index depends on the size of the index and the amount of memory available.
163+
For a smaller index (up to 1M entries), five queries should be sufficient to load the index into memory.

0 commit comments

Comments
 (0)