Skip to content
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

Ci Test: Stackgres 1.14 #9985

Draft
wants to merge 3 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion charts/hedera-mirror-common/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ dependencies:
condition: stackgres.enabled
name: stackgres-operator
repository: https://stackgres.io/downloads/stackgres-k8s/stackgres/helm/
version: 1.13.0
version: 1.14.2
- condition: traefik.enabled
name: traefik
repository: https://helm.traefik.io/traefik
Expand Down
2 changes: 1 addition & 1 deletion charts/hedera-mirror-common/values-v2.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
minio:
enabled: false
enabled: true
stackgres:
enabled: true
zfs:
Expand Down
46 changes: 45 additions & 1 deletion charts/hedera-mirror-common/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -417,10 +417,54 @@ promtail:
operator: Exists

stackgres:
collector:
config:
exporters:
prometheus:
metric_expiration: 2m
service:
pipelines:
metrics:
receivers:
- prometheus/prometheus # This appears to be corrected to just prometheus in 1.15+ and can be updated (possibly removed) when upgrading
resources:
limits:
memory: "4Gi"
cpu: "1500m"
requests:
memory: "3Gi"
cpu: "1000m"
prometheusOperator:
monitors:
- name: mirror-prometheus-prometheus
namespace: common
metadata:
namespace: common
name: mirror-stackgres-collector
spec:
podMetricsEndpoints:
- honorLabels: true
honorTimestamps: true
interval: 1m
metricRelabelings:
- action: drop
regex: ^(pg_stat.*_user.*|pg_table.*|pg_total_relation_size_bytes)$
sourceLabels:
- __name__
path: /metrics
port: prom-http
scheme: https
tlsConfig:
ca:
secret:
key: tls.crt
name: mirror-stackgres-collector
serverName: stackgres-collector

enabled: false
operator:
image:
name: gcr.io/mirrornode/stackgres-operator
name: docker.io/xinatswirlds/stackgres-operator
prometheusRules:
enabled: true
DatabaseStorageFull:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,17 @@ metadata:
name: {{ include "hedera-mirror.stackgres" . }}
namespace: {{ include "hedera-mirror.namespace" . }}
spec:
{{- if .Values.stackgres.backup.enabled }}
configurations:
{{- if .Values.stackgres.backup.enabled }}
backups:
{{- range $backupConfig := .Values.stackgres.backup.instances }}
- sgObjectStorage: {{ include "hedera-mirror.stackgres" $ }}-object-storage
{{$backupConfig | toYaml | nindent 6}}
{{- end }}
{{- end }}
{{- end }}
observability:
disableMetrics: {{ not .Values.stackgres.observability.enableMetricsExporter }}
prometheusAutobind: {{ .Values.stackgres.observability.enableMetricsExporter }}
coordinator:
configurations:
sgPoolingConfig: {{ include "hedera-mirror.stackgres" . }}-coordinator
Expand All @@ -23,7 +26,6 @@ spec:
scripts:
- sgScript: {{ include "hedera-mirror.stackgres" . }}-coordinator
pods:
disableMetricsExporter: {{ not .Values.stackgres.coordinator.enableMetricsExporter }}
disablePostgresUtil: {{ not .Values.stackgres.coordinator.enablePostgresUtil }}
persistentVolume: {{ .Values.stackgres.coordinator.persistentVolume | toYaml | nindent 8 }}
resources:
Expand Down Expand Up @@ -51,9 +53,11 @@ spec:
ssl:
enabled: false # Disable SSL to work around https://github.com/hashgraph/hedera-mirror-node/issues/9143
version: {{ .Values.stackgres.postgresVersion | quote }}
prometheusAutobind: {{ or .Values.stackgres.coordinator.enableMetricsExporter .Values.stackgres.worker.enableMetricsExporter }}
prometheusAutobind: {{ .Values.stackgres.observability.enableMetricsExporter }}
replication:
mode: {{ .Values.stackgres.coordinator.replication.mode }}
mode: {{ .Values.stackgres.replication.mode }}
initialization:
mode: {{ .Values.stackgres.replication.initialization.mode }}
shards:
clusters: {{ .Values.stackgres.worker.instances }}
configurations:
Expand All @@ -65,7 +69,6 @@ spec:
- sgScript: {{ include "hedera-mirror.stackgres" . }}-worker
overrides: {{ .Values.stackgres.worker.overrides | toYaml | nindent 6 }}
pods:
disableMetricsExporter: {{ not .Values.stackgres.worker.enableMetricsExporter }}
disablePostgresUtil: {{ not .Values.stackgres.worker.enablePostgresUtil }}
persistentVolume: {{ .Values.stackgres.worker.persistentVolume | toYaml | nindent 8 }}
resources:
Expand Down
6 changes: 3 additions & 3 deletions charts/hedera-mirror/values-prod.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -139,16 +139,16 @@ rosetta:

stackgres:
backup:
enabled: false
enabled: true
instances:
- retention: 7
cronSchedule: "45 22 * * *"
compression: lz4
useVolumeSnapshot: true
fastVolumeSnapshot: false # Can be true once StackGres issue 2887 is resolved
fastVolumeSnapshot: true
volumeSnapshotClass: zfs
performance:
uploadDiskConcurrency: 1 # Can be 4 once StackGres issue 2887 is resolved
uploadDiskConcurrency: 1
objectStorage:
endpoint: http://mirror-minio.common:9000
bucket: stackgres-backup
Expand Down
10 changes: 6 additions & 4 deletions charts/hedera-mirror/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,6 @@ stackgres:
wal_init_zero: "off" # Not needed with ZFS
wal_recycle: "off" # Not needed with ZFS
work_mem: "12MB"
enableMetricsExporter: false
enablePostgresUtil: true
instances: 1
pgbouncer:
Expand All @@ -325,8 +324,6 @@ stackgres:
pool_mode: session
mirror_importer:
pool_mode: session
replication:
mode: sync-all
resources:
cpu: 100m
memory: 1Gi
Expand All @@ -342,9 +339,15 @@ stackgres:
- name: pg_trgm
version: "1.6"
nameOverride: citus
observability:
enableMetricsExporter: true
podAntiAffinity: true
postgresVersion: "16.2"
priorityClassName: ""
replication:
initialization:
mode: FromReplica
mode: sync-all
worker:
config:
autovacuum_max_workers: "2"
Expand All @@ -362,7 +365,6 @@ stackgres:
wal_init_zero: "off" # Not needed with ZFS
wal_recycle: "off" # Not needed with ZFS
work_mem: "12MB"
enableMetricsExporter: false
enablePostgresUtil: true
instances: 1
overrides: [] # Override shard(s) configuration
Expand Down