Uploaded image for project: 'Red Hat 3scale API Management'
  1. Red Hat 3scale API Management
  2. THREESCALE-8934

Upgrade with APIcast Operator from 2.12 to 2.13 fails

    XMLWordPrintable

Details

    • False
    • None
    • False
    • Not Started
    • Not Started
    • Not Started
    • Not Started
    • Not Started
    • Not Started

    Description

      Issue: 

      When upgrading APIcast self-managed from 2.12 to 2.13 the operator upgraded correctly but APIcast deployment is not upgraded. The operator logs shows the following: 

      {"level":"error","ts":1669364853.5170798,"logger":"controller-runtime.manager.controller.apicast","msg":"Reconciler error","reconciler group":"apps.3scale.net","reconciler kind":"APIcast","name":"example-apicast","namespace":"apicastsm","error":"Deployment.apps \"apicast-example-apicast\" is invalid: spec.template.metadata.labels: Invalid value: map[string]string{\"com.company\":\"Red_Hat\", \"deployment\":\"apicast-example-apicast\", \"rht.comp\":\"3scale_apicast\", \"rht.comp_ver\":\"2.13\", \"rht.prod_name\":\"Red_Hat_Integration\", \"rht.prod_ver\":\"master\", \"rht.subcomp\":\"apicast\", \"rht.subcomp_t\":\"application\"}: `selector` does not match template `labels`","stacktrace":"(...)
      

      Additional information:

      1) When deploying APIcast self-managed with the Operator version 2.12 we can see:

      1.1) Deployment YAML apicast-example-apicast the following image:

      image: >-
                  registry.redhat.io/3scale-amp2/apicast-gateway-rhel8@sha256:33c614270adc42b75b60e2addf1d7176add51d1e7a3a02b8cbe94dfde196c155
      

      1.2) Deployment YAML apicast-example-apicast the following selectors and template metadata:

      spec:
        replicas: 1
        selector:
          matchLabels:
            com.company: Red_Hat
            deployment: apicast-example-apicast
            rht.comp: 3scale_apicast
            rht.comp_ver: '2.12'
            rht.prod_name: Red_Hat_Integration
            rht.prod_ver: 2021.Q4
            rht.subcomp: apicast
            rht.subcomp_t: application
        template:
          metadata:
            creationTimestamp: null
            labels:
              com.company: Red_Hat
              deployment: apicast-example-apicast
              rht.comp: 3scale_apicast
              rht.comp_ver: '2.12'
              rht.prod_name: Red_Hat_Integration
              rht.prod_ver: 2021.Q4
              rht.subcomp: apicast
              rht.subcomp_t: application
            annotations:
              apicast.apps.3scale.net/admin-portal-secret-resource-version: '8762134'
              prometheus.io/port: '9421'
              prometheus.io/scrape: 'true'
      

      2) When upgrading APIcast self-managed from 2.12 to 2.13 we can see:
      2.1) Deployment YAML apicast-example-apicast the following image:

                image: >-
                  registry.redhat.io/3scale-amp2/apicast-gateway-rhel8@sha256:33c614270adc42b75b60e2addf1d7176add51d1e7a3a02b8cbe94dfde196c155
      

      The image is still from 2.12 according to the catalog.

      2.2) Deployment YAML apicast-example-apicast the following selectors and template metadata:

      spec:
        replicas: 1
        selector:
          matchLabels:
            com.company: Red_Hat
            deployment: apicast-example-apicast
            rht.comp: 3scale_apicast
            rht.comp_ver: '2.12'
            rht.prod_name: Red_Hat_Integration
            rht.prod_ver: 2021.Q4
            rht.subcomp: apicast
            rht.subcomp_t: application
        template:
          metadata:
            creationTimestamp: null
            labels:
              com.company: Red_Hat
              deployment: apicast-example-apicast
              rht.comp: 3scale_apicast
              rht.comp_ver: '2.12'
              rht.prod_name: Red_Hat_Integration
              rht.prod_ver: 2021.Q4
              rht.subcomp: apicast
              rht.subcomp_t: application
            annotations:
              apicast.apps.3scale.net/admin-portal-secret-resource-version: '8426955'
              prometheus.io/port: '9421'
              prometheus.io/scrape: 'true'
      

       
      See attached the operator logs. from 2.12 to 2.13 upgrade.

      3) When deploying APIcast self-managed 2.13 as a new deployment:
      3.1) Deployment YAML apicast-example-apicast has the following image:

        image: >-
              registry.redhat.io/3scale-amp2/apicast-gateway-rhel8@sha256:8ac4274f4698f8540cba827f07e21637d516598d6b4b245bc455c91141439a24
      

      which is from 2.13 according to the catalog.

      3.2) Deployment YAML apicast-example-apicast has the following selectors and template metadata:

      spec:
        replicas: 1
        selector:
          matchLabels:
            com.company: Red_Hat
            deployment: apicast-example-apicast
            rht.comp: 3scale_apicast
            rht.comp_ver: '2.13'
            rht.prod_name: Red_Hat_Integration
            rht.prod_ver: master
            rht.subcomp: apicast
            rht.subcomp_t: application
        template:
          metadata:
            creationTimestamp: null
            labels:
              com.company: Red_Hat
              deployment: apicast-example-apicast
              rht.comp: 3scale_apicast
              rht.comp_ver: '2.13'
              rht.prod_name: Red_Hat_Integration
              rht.prod_ver: master
              rht.subcomp: apicast
              rht.subcomp_t: application
            annotations:
              apicast.apps.3scale.net/admin-portal-secret-resource-version: '8776055'
              prometheus.io/port: '9421'
              prometheus.io/scrape: 'true'
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            rhn-support-avilatus Anna Vila Tusell
            Matej Dujava Matej Dujava
            Eguzki Astiz Lezaun Eguzki Astiz Lezaun
            Votes:
            0 Vote for this issue
            Watchers:
            14 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: