Skip to content

Conversation

@frouioui
Copy link
Member

@frouioui frouioui commented Dec 2, 2024

This PR fixes the issue mentioned in #311 (comment), which was missed during the development and review of #494.

Fixes #311

We were merging the custom resources with the default resource setting, which led to empty field in the custom resource being filled by the default resources, even if we wanted these fields to be empty.

Here is what we get with the change introduced by the PR:

            mysqldExporter:
              resources:
                limits:
                  memory: 125Mi
                requests:
                  cpu: 100m
                  memory: 50Mi
$ kubectl describe ...
  mysqld-exporter:
    Container ID:  
    Image:         prom/mysqld-exporter:v0.11.0
    Image ID:      
    Port:          9104/TCP
    Host Port:     0/TCP
    Command:
      /bin/mysqld_exporter
    Args:
      --config.my-cnf=/vt/vtdataroot/vt_2469782763/my.cnf
      --collect.info_schema.tables.databases=sys,_vt
    State:          Waiting
      Reason:       PodInitializing
    Ready:          False
    Restart Count:  0
    Limits:
      memory:  125Mi
    Requests:
      cpu:     100m
      memory:  50Mi

@frouioui frouioui merged commit bfa0b3e into main Dec 2, 2024
12 checks passed
@frouioui frouioui deleted the fix-mysqld-limits branch December 2, 2024 21:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature Request] Allow setting mysqld-exporter resources

3 participants