dragonflydb/dragonfly

No predefined configuration for cluster mode in helm chart

Closed

#3,861 opened on Oct 4, 2024

 (1 comment) (0 reactions) (0 assignees)C++ (1,177 forks)batch import
good first issuehacktoberfesthelp wanted

Repository metrics

Stars
 (30,465 stars)
PR merge metrics
 (Avg merge 2d 11h) (201 merged PRs in 30d)

Description

A problem description The default configuration didn't fit for the production purposes because on high payload it gets timeout. At this point we tried to create HPA that also didn't help because the instances doesn't balancing the requests and still got timeout. Next thing we wanted to try is cluster mode, but we didn't find a solution to configure cluster mode with helm chart because there is no values for that.

Describe the solution you'd like Helm chart values for scalable solution

Additional context The values we're using right now:

podSecurityContext:
  fsGroup: 2000

securityContext:
  capabilities:
    drop:
      - ALL
  readOnlyRootFilesystem: false
  runAsNonRoot: true
  runAsUser: 1000

serviceMonitor:
  enabled: true
  annotations:
    prometheus.io/path: "/metrics"
    prometheus.io/port: "4999"
    prometheus.io/scrape: "true"
passwordFromSecret:
  enable: true
  existingSecret:
    name: "dragonfly"
    key: "DRAGONFLY_PASSWORD"
tls:
  enabled: true
  existing_secret: "certificate-default"
extraObjects:
  - apiVersion: autoscaling/v2
    kind: HorizontalPodAutoscaler
    metadata:
      name: dragonfly-hpa
      namespace: dragonfly
    spec:
      scaleTargetRef:
        apiVersion: apps/v1
        kind: Deployment
        name: dragonfly
      minReplicas: 1
      maxReplicas: 5
      metrics:
        - type: Resource
          resource:
            name: memory
            target:
              type: Utilization
              averageUtilization: 60
        - type: Resource
          resource:
            name: cpu
            target:
              type: Utilization
              averageUtilization: 80
      behavior:
        scaleUp:
          stabilizationWindowSeconds: 30
          policies:
            - type: Percent
              value: 10
              periodSeconds: 60
        scaleDown:
          stabilizationWindowSeconds: 30
          policies:
            - type: Percent
              value: 10
              periodSeconds: 60

Contributor guide