Skip to content

Commit 8fa0c01

Browse files
DOC-573: add mount PVC topic (#330)
For https://hazelcast.atlassian.net/browse/DOC-573 As part of the Diagnostic Logging work, we need to document how to mount one or more Persistent Volume Claims (PVCs) directly to a Hazelcast cluster. Sergii suggests this goes into a new topic under Configuration properties. The work to add the fields to the CRD has been done in PR: hazelcast/hazelcast-platform-operator#1432
1 parent 9caeddb commit 8fa0c01

File tree

2 files changed

+42
-0
lines changed

2 files changed

+42
-0
lines changed

docs/modules/ROOT/nav.adoc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@
8080
** xref:hazelcast-parameters.adoc[System properties]
8181
** xref:custom-config.adoc[Custom configuration]
8282
** xref:jvm-parameters.adoc[JVM parameters]
83+
** xref:mount-pvc.adoc[Mount PVC on a cluster]
8384
8485
* Management Center
8586
** xref:management-center-clusters.adoc[Hazelcast clusters]
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
= Mount Persistent Volume Claims for Hazelcast clusters
2+
3+
You can mount one or more Persistent Volume Claims (PVCs) directly to your Hazelcast cluster. Each PVC defined in the `persistenceVolumeClaims` section will be mounted under the path `/data/<name-of-pvc>`. This approach allows you to use PVCs for any Hazelcast feature that requires persistent storage, simply by referencing the PVC by its name.
4+
5+
== How it works
6+
7+
- Define one or more PVCs in the `persistenceVolumeClaims` section of your Hazelcast custom resource (CR).
8+
- Each PVC will be mounted at `/data/<name>`, where `<name>` is the value of the name field in your PVC configuration.
9+
- Features that require persistent storage (such as diagnostics, persistence, or the CP Subsystem) can reference the PVC by specifying its name, using the appropriate field (e.g., `pvcName`).
10+
11+
This mechanism decouples the PVC definition from feature configuration, making it easier to manage and reuse storage across different Hazelcast features.
12+
13+
For more information, see the xref:api-ref.adoc#[API]. For a tutorial on enabling persistence, see link:https://docs.hazelcast.com/hazelcast/latest/getting-started/persistence[Persist Map Entries on Disk]
14+
15+
== Example: Configure diagnostics with a named PVC
16+
17+
Below is an example configuration that shows how to define a PVC and use it for diagnostics logging by specifying the `pvcName` field. The diagnostics logs will be stored in the PVC mounted at `/data/diagnostics-pvc-volume`.
18+
19+
[source,yaml]
20+
----
21+
apiVersion: hazelcast.com/v1alpha1
22+
kind: Hazelcast
23+
metadata:
24+
name: hazelcast
25+
spec:
26+
clusterSize: 3
27+
repository: 'docker.io/hazelcast/hazelcast-enterprise'
28+
version: 5.6.0-SNAPSHOT
29+
licenseKeySecretName: hazelcast-license-key
30+
diagnostics:
31+
outputType: STDOUT
32+
maxRolledFileCount: 10
33+
maxRolledFileSize: '50M'
34+
pvcName: diagnostics-pvc-volume
35+
persistenceVolumeClaims:
36+
- accessModes: [ "ReadWriteOnce" ]
37+
requestStorage: 1Gi
38+
storageClassName: "standard"
39+
name: diagnostics-pvc-volume
40+
----
41+

0 commit comments

Comments
 (0)