kubernetes-sigs / vsphere-csi-driver

vSphere storage Container Storage Interface (CSI) plugin
https://docs.vmware.com/en/VMware-vSphere-Container-Storage-Plug-in/index.html
Apache License 2.0
295 stars 181 forks source link

Fix vmservice extension name #3090

Closed deepakkinni closed 1 month ago

deepakkinni commented 1 month ago

What this PR does / why we need it: VM service team changed their extension service name from "vmservice.cns.vsphere.vmware.com" to "vmware-system-vmop-webhook-service", reflecting the same thing in the storagequotaperiodicsync

Which issue this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close that issue when PR gets merged): fixes #

Testing done: Before fix:

root@422a5584452ed95937062cf0861b089a [ ~ ]# kubectl get storagequotaperiodicsync -n vmware-system-csi storage-quota-periodic-sync -o yaml
apiVersion: cns.vmware.com/v1alpha1
kind: StorageQuotaPeriodicSync
metadata:
  creationTimestamp: "2024-10-22T06:06:19Z"
  generation: 2
  name: storage-quota-periodic-sync
  namespace: vmware-system-csi
  resourceVersion: "3167181"
  uid: 15de1707-9f28-4a4c-a9de-2c875ff2244f
spec:
  syncIntervalInMinutes: 10
status:
  expectedReservedValues:
  - namespace: e2e-test-namespace
    reserved:
      0c1551e0-0d34-49d7-beff-6c01a10b2071: "0"
      3a89cd6d-4874-4fb8-a08d-f87a5ae94ada: "0"
  - namespace: svc-tkg-domain-c52
  - namespace: svc-velero-domain-c52
  - namespace: test-gc-e2e-demo-ns
    reserved:
      3a89cd6d-4874-4fb8-a08d-f87a5ae94ada: "0"
  lastSyncTimestamp: "2024-10-24T18:33:26Z"

After fix:

apiVersion: cns.vmware.com/v1alpha1
kind: StorageQuotaPeriodicSync
metadata:
  creationTimestamp: "2024-10-22T06:06:19Z"
  generation: 2
  name: storage-quota-periodic-sync
  namespace: vmware-system-csi
  resourceVersion: "3184320"
  uid: 15de1707-9f28-4a4c-a9de-2c875ff2244f
spec:
  syncIntervalInMinutes: 10
status:
  expectedReservedValues:
  - namespace: e2e-test-namespace
    reserved:
      0c1551e0-0d34-49d7-beff-6c01a10b2071: "0"
      1b0f89fb-6546-4d21-8d2d-1cea554c0ec5: "0"
      3a89cd6d-4874-4fb8-a08d-f87a5ae94ada: "0"
      6567339e-4fd0-4062-87fe-de91657f9efb: "0"
      adbbb351-cbcf-4f63-a17a-1f53c1532748: "0"
      c87345e0-d428-4938-9661-77e750c68ab4: "0"
  - namespace: svc-tkg-domain-c52
    reserved:
      4d5f673c-536f-11e6-beb8-9e71128cae77: "0"
      862daa34-0634-48fc-b436-73ebe986fdd0: "0"
  - namespace: svc-velero-domain-c52
    reserved:
      4d5f673c-536f-11e6-beb8-9e71128cae77: "0"
      862daa34-0634-48fc-b436-73ebe986fdd0: "0"
  - namespace: test-gc-e2e-demo-ns
    reserved:
      0c1551e0-0d34-49d7-beff-6c01a10b2071: "0"
      1b0f89fb-6546-4d21-8d2d-1cea554c0ec5: "0"
      3a89cd6d-4874-4fb8-a08d-f87a5ae94ada: "0"
      6567339e-4fd0-4062-87fe-de91657f9efb: "0"
      adbbb351-cbcf-4f63-a17a-1f53c1532748: "0"
      c87345e0-d428-4938-9661-77e750c68ab4: "0"
  lastSyncTimestamp: "2024-10-24T18:57:02Z"

StorageQuota eventually gets decremented

root@422a5584452ed95937062cf0861b089a [ ~ ]# kubectl get storagequota -n test-gc-e2e-demo-ns -o yaml
apiVersion: v1
items:
- apiVersion: cns.vmware.com/v1alpha2
  kind: StorageQuota
  metadata:
    creationTimestamp: "2024-10-22T05:33:20Z"
    generation: 28
    name: total-quota
    namespace: test-gc-e2e-demo-ns
    resourceVersion: "3169687"
    uid: f5507661-33ce-4504-86d0-6e2daa3ec3a6
  spec:
    limit: 347Gi
    storagePolicyLevelLimits:
      0c1551e0-0d34-49d7-beff-6c01a10b2071: 347Gi
      1b0f89fb-6546-4d21-8d2d-1cea554c0ec5: 347Gi
      3a89cd6d-4874-4fb8-a08d-f87a5ae94ada: 347Gi
      6567339e-4fd0-4062-87fe-de91657f9efb: 347Gi
      adbbb351-cbcf-4f63-a17a-1f53c1532748: 347Gi
      c87345e0-d428-4938-9661-77e750c68ab4: 347Gi
  status:
    total:
    - policyQuotaUsage:
        reserved: "0"
        used: "0"
      storagePolicyId: adbbb351-cbcf-4f63-a17a-1f53c1532748
    - policyQuotaUsage:
        reserved: "0"
        used: "0"
      storagePolicyId: c87345e0-d428-4938-9661-77e750c68ab4
    - policyQuotaUsage:
        reserved: "0"
        used: 6Gi
      storagePolicyId: 3a89cd6d-4874-4fb8-a08d-f87a5ae94ada
    - policyQuotaUsage:
        reserved: "0"
        used: "0"
      storagePolicyId: 0c1551e0-0d34-49d7-beff-6c01a10b2071
    - policyQuotaUsage:
        reserved: "0"
        used: "0"
      storagePolicyId: 1b0f89fb-6546-4d21-8d2d-1cea554c0ec5
    - policyQuotaUsage:
        reserved: "0"
        used: "0"
      storagePolicyId: 6567339e-4fd0-4062-87fe-de91657f9efb
kind: List
metadata:
  resourceVersion: ""

Special notes for your reviewer:

Release note:

deepakkinni commented 1 month ago

/ok-to-test

vdkotkar commented 1 month ago

/approve

akankshapanse commented 1 month ago

/approve /lgtm

k8s-ci-robot commented 1 month ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: akankshapanse, deepakkinni, vdkotkar

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

The pull request process is described here

Needs approval from an approver in each of these files: - ~~[OWNERS](https://github.com/kubernetes-sigs/vsphere-csi-driver/blob/master/OWNERS)~~ [akankshapanse,deepakkinni] Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment