Skip to content

removing limits from objectsore does not tirgger a pod reboot #817

@smiyc

Description

@smiyc

Barman 0.11.0
cnpg-controller-manager 1.28.1

When changing the resource limits (removing it)

from

...
# https://github.com/cloudnative-pg/plugin-barman-cloud/issues/385
    resources:
      limits:
        # cpu: 500m
        memory: 500Mi
      # requests:
        # cpu: 200m
        # memory: 256Mi  
...

to

...
# # https://github.com/cloudnative-pg/plugin-barman-cloud/issues/385
#     resources:
#       limits:
#         # cpu: 500m
#         memory: 500Mi
#       # requests:
#         # cpu: 200m
#         # memory: 256Mi  
...

the objectstore spec gets updated

from

...
 ⎈ cl-postgres-test (cnpg-system) 
▶ kubectl describe objectstores.barmancloud.cnpg.io confluence-wit-test-c800 | grep Resources: -A 2
    Resources:
      Limits:
        Memory:                         500Mi

fo

 ⎈ cl-postgres-test (cnpg-system) 
▶ kubectl describe objectstores.barmancloud.cnpg.io confluence-wit-test-c800 | grep Resources: -A 2

but no pod restart is triggered and the cluster needs to be restarted manually in order to apply the changes to the sidecar.

▶ kubectl describe pods confluence-wit-test-1 | grep plugin-barman-cloud: -A 17
  plugin-barman-cloud:
...
    Limits:
      memory:  500Mi
    Requests:
      memory:  500Mi
 ⎈ cl-postgres-test (cnpg-system) 
▶ kubectl cnpg restart confluence-wit-test
▶ kubectl describe pods confluence-wit-test-1 | grep plugin-barman-cloud: -A 17
  plugin-barman-cloud:
...
no limits
...

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions