Skip to content

chore: update PerformanceInsights parameters and ignore additional parameters when dbcluster is enabled on dbinstance#276

Open
shabbskagalwala wants to merge 2 commits intoaws-controllers-k8s:mainfrom
shabbskagalwala:add-performance-insights-to-ignore
Open

chore: update PerformanceInsights parameters and ignore additional parameters when dbcluster is enabled on dbinstance#276
shabbskagalwala wants to merge 2 commits intoaws-controllers-k8s:mainfrom
shabbskagalwala:add-performance-insights-to-ignore

Conversation

@shabbskagalwala
Copy link
Contributor

@shabbskagalwala shabbskagalwala commented Mar 13, 2026

Fixed terminal errors when PerformanceInsights* parameters cannot be changed when db instance is part of a dbcluster

  conditions:
    - message: >-
        api error InvalidParameterCombination: EnablePerformanceInsights
        conflicts with cluster level parameter.
      status: 'True'
      type: ACK.Terminal
    - lastTransitionTime: '2026-03-12T22:52:45Z'
      message: Resource not synced
      reason: resource is in terminal condition
      status: 'False'
      type: ACK.ResourceSynced
    - lastTransitionTime: '2026-03-12T22:52:45Z'
      message: >-
        api error InvalidParameterCombination: EnablePerformanceInsights
        conflicts with cluster level parameter.

Note to reviewers, the fields are not set on the dbinstance only set on the dbcluster

Issue #, if available:

Description of changes:

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@ack-prow
Copy link

ack-prow bot commented Mar 13, 2026

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: shabbskagalwala
Once this PR has been reviewed and has the lgtm label, please assign a-hilaly for approval by writing /assign @a-hilaly in a comment. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ack-prow ack-prow bot requested review from jlbutler and michaelhtm March 13, 2026 00:14
@ack-prow ack-prow bot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Mar 13, 2026
@ack-prow
Copy link

ack-prow bot commented Mar 13, 2026

Hi @shabbskagalwala. Thanks for your PR.

I'm waiting for a aws-controllers-k8s member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@a-hilaly
Copy link
Member

/ok-to-test

@ack-prow ack-prow bot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Mar 13, 2026
@shabbskagalwala shabbskagalwala force-pushed the add-performance-insights-to-ignore branch 2 times, most recently from 477421d to 9f71777 Compare March 13, 2026 00:57
@shabbskagalwala
Copy link
Contributor Author

I think the error is different. It could probably be coming from here

a.ko.Spec.PerformanceInsightsEnabled = aws.Bool(false)

Is there a reason it is explicitly set to false, instead of what is in the latest?

Can this be changed to ?

a.ko.Spec.PerformanceInsightsEnabled = b.ko.Spec.PerformanceInsightsEnabled

@shabbskagalwala shabbskagalwala force-pushed the add-performance-insights-to-ignore branch from 9f71777 to 085e323 Compare March 13, 2026 05:28
late_initialize:
skip_incomplete_check: {}
compare:
is_ignored: true
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding fields to ignore else the controller is in constant reconcile loop

This db instance is part of a db cluster

{
  "level": "info",
  "ts": "2026-03-13T05:17:50.407Z",
  "logger": "ackrt",
  "msg": "desired resource state has changed",
  "kind": "DBInstance",
  "namespace": "mytest",
  "name": "temp-db-cluster-instance",
  "account": "REDACTED",
  "role": "",
  "region": "us-west-2",
  "is_adopted": true,
  "generation": 5,
  "diff": [
    {
      "Path": {
        "Parts": [
          "Spec",
          "DBName"
        ]
      },
      "A": null,
      "B": "tempdb"
    },
    {
      "Path": {
        "Parts": [
          "Spec",
          "EngineVersion"
        ]
      },
      "A": null,
      "B": "16.8"
    },
    {
      "Path": {
        "Parts": [
          "Spec",
          "MasterUsername"
        ]
      },
      "A": null,
      "B": "superadmin"
    }
  ]
}

@shabbskagalwala shabbskagalwala force-pushed the add-performance-insights-to-ignore branch from 085e323 to 6151283 Compare March 13, 2026 05:33
@shabbskagalwala shabbskagalwala changed the title chore: ignore PerformanceInsights parameters only when DBClusterIdentifier is nil chore: update PerformanceInsights parameters and ignore additional parameters when dbcluster is enabled on dbinstance Mar 13, 2026
@shabbskagalwala
Copy link
Contributor Author

/retest-required

@shabbskagalwala shabbskagalwala force-pushed the add-performance-insights-to-ignore branch from 6151283 to c4e56ca Compare March 13, 2026 15:38
@ack-prow
Copy link

ack-prow bot commented Mar 13, 2026

@shabbskagalwala: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
rds-verify-attribution c4e56ca link false /test rds-verify-attribution

Full PR test history. Your PR dashboard.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@knottnt
Copy link
Contributor

knottnt commented Mar 13, 2026

I think the error is different. It could probably be coming from here

a.ko.Spec.PerformanceInsightsEnabled = aws.Bool(false)

Is there a reason it is explicitly set to false, instead of what is in the latest?

Can this be changed to ?

a.ko.Spec.PerformanceInsightsEnabled = b.ko.Spec.PerformanceInsightsEnabled

@michaelhtm do you recall why this is always set to false?

@shabbskagalwala Regarding the fix. If PerformanceInsightsEnabled should be managed by the DBCluster when the DBInstance's Spec.DBClusterIdentifier is set we could ignore it in the generated delta and add PerformanceInsightsEnabled under this check in custom_pre_compare. newUpdateRequestPayload will then omit setting PerformanceInsightsEnabled in the ModifyDBInstance payload.

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

Labels

ok-to-test Indicates a non-member PR verified by an org member that is safe to test.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants