diff --git a/charts/hono/Chart.yaml b/charts/hono/Chart.yaml
index 162c9265..17183600 100755
--- a/charts/hono/Chart.yaml
+++ b/charts/hono/Chart.yaml
@@ -15,7 +15,7 @@ name: hono
description: |
Eclipse Hono™ provides remote service interfaces for connecting large numbers of IoT devices to a back end and
interacting with them in a uniform way regardless of the device communication protocol.
-version: 2.2.1
+version: 2.2.2
# Version of Hono being deployed by the chart
appVersion: 2.2.0
keywords:
diff --git a/charts/hono/config/infinispan/hono-data-grid.xml b/charts/hono/config/infinispan/hono-data-grid.xml
index 654b3ea3..effa332e 100644
--- a/charts/hono/config/infinispan/hono-data-grid.xml
+++ b/charts/hono/config/infinispan/hono-data-grid.xml
@@ -38,7 +38,20 @@
+ {{- if .Values.dataGridExample.persistence.enabled }}
+
+
+
+
+
+
+ {{- end }}
+ {{- if .Values.dataGridExample.persistence.enabled }}
+
+
+
+ {{- end }}
diff --git a/charts/hono/templates/example-data-grid/pvc.yaml b/charts/hono/templates/example-data-grid/pvc.yaml
new file mode 100644
index 00000000..4c18e9c8
--- /dev/null
+++ b/charts/hono/templates/example-data-grid/pvc.yaml
@@ -0,0 +1,13 @@
+{{- if .Values.dataGridExample.persistence.enabled -}}
+kind: PersistentVolumeClaim
+apiVersion: v1
+metadata:
+ {{- $args := dict "dot" . "component" "data-grid" "name" "data-grid-pvc" }}
+ {{- include "hono.metadata" $args | nindent 2 }}
+spec:
+ accessModes:
+ - ReadWriteOnce
+ resources:
+ requests:
+ storage: {{ .Values.dataGridExample.persistence.pvcSize }}
+{{- end }}
diff --git a/charts/hono/templates/example-data-grid/statefulset.yaml b/charts/hono/templates/example-data-grid/statefulset.yaml
index 6d509c8f..330c801c 100644
--- a/charts/hono/templates/example-data-grid/statefulset.yaml
+++ b/charts/hono/templates/example-data-grid/statefulset.yaml
@@ -65,6 +65,8 @@ spec:
name: conf
subPath: mgmt-groups.properties
readOnly: true
+ - name: storage
+ mountPath: /opt/infinispan/server/data
{{- include "hono.component.healthChecks" $args | nindent 8 }}
{{- with .Values.dataGridExample.resources }}
resources:
@@ -75,4 +77,10 @@ spec:
- name: conf
configMap:
name: {{ printf "%s-%s-conf" .Release.Name $args.name }}
+ {{- if .Values.dataGridExample.persistence.enabled }}
+ - name: storage
+ persistentVolumeClaim:
+ claimName: {{ printf "%s-%s-pvc" .Release.Name $args.name | quote }}
+ {{- end}}
+
{{- end }}
diff --git a/charts/hono/values.yaml b/charts/hono/values.yaml
index 31d4108e..e391a3de 100755
--- a/charts/hono/values.yaml
+++ b/charts/hono/values.yaml
@@ -1983,6 +1983,13 @@ dataGridExample:
# dataMaxSize contains the maximum size of off-heap memory used for storing data per Infinispan node
dataMaxSize: "30 MB"
+ # persistence contains configuration on the dataGrid persitence settings.
+ persistence:
+ # enabled defines whether or not persistence is enabled for the example dataGrid
+ enabled: false
+ # pvcSize determines the size of the pvc created to write the cache data to
+ pvcSize: "100M"
+
jaegerBackendExample:
# enabled indicates whether the example Jaeger all-in-one