Skip to content

[elasticache controller] Diffs on log group configuration on elasticache ReplicationGroup #3024

Description

@shabbskagalwala

Describe the bug
The elasticache controller on adopted resources always shows a diff on the log group configuration

for example:

{
  "level": "info",
  "ts": "2026-09-02T19:50:22.604Z",
  "logger": "ackrt",
  "msg": "desired resource state has changed",
  "kind": "ReplicationGroup",
  "namespace": "ack-system",
  "name": "my-test-valkey-uw2",
  "account": "xxxxxxxxxx",
  "role": "",
  "region": "us-west-2",
  "is_adopted": true,
  "generation": 1,
  "diff": [
    {
      "Path": {
        "Parts": [
          "Spec",
          "LogDeliveryConfigurations"
        ]
      },
      "A": [
        {
          "destinationDetails": {
            "cloudWatchLogsDetails": {
              "logGroup": "/elasticache/my-test-valkey-uw2"
            }
          },
          "destinationType": "cloudwatch-logs",
          "enabled": true,
          "logFormat": "text",
          "logType": "slow-log"
        },
        {
          "destinationDetails": {
            "cloudWatchLogsDetails": {
              "logGroup": "/elasticache/my-test-valkey-uw2"
            }
          },
          "destinationType": "cloudwatch-logs",
          "enabled": true,
          "logFormat": "text",
          "logType": "engine-log"
        }
      ],
      "B": null
    }
  ]
}

However checking AWS the logs are enabled on the cluster but the controller fails to see it and detects a diff and then immediately sets the resource as synced

{
  "level": "info",
  "ts": "2026-09-02T19:50:23.241Z",
  "logger": "ackrt",
  "msg": "updated resource",
  "kind": "ReplicationGroup",
  "namespace": "ack-system",
  "name": "my-test-valkey-uw2",
  "account": "xxxxxx",
  "role": "",
  "region": "us-west-2",
  "is_adopted": true,
  "generation": 1
}

Steps to reproduce
Create a replicationgroup resource for adoption with log group enabled

Expected outcome
No diff detected for logs groups on an replication cluster

Environment: Using the latest version of the controller 1.9.0

  • Kubernetes version: 1.35
  • Using EKS (yes/no), if so version? yes
  • AWS service targeted (S3, RDS, etc.): elasticache

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/bugCategorizes issue or PR as related to a bug.needs-investigationIndicates an issue needs some investigation.service/elasticacheIndicates issues or PRs that are related to elasticache-controller.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions