Uploaded image for project: 'OpenShift Bugs'
  1. OpenShift Bugs
  2. OCPBUGS-34322

ignoring telemetry event was not displayed even telemeter client is disabled and debug is on

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Do
    • Icon: Minor Minor
    • None
    • 4.16
    • Dev Console
    • None
    • No
    • Rejected
    • False
    • Hide

      None

      Show
      None
    • Release Note Not Required
    • In Progress

      Description of problem:

      according to code https://github.com/openshift/console/blob/master/frontend/packages/console-telemetry-plugin/src/listeners/segment.ts#L114-L124     
      it seems the message `console-telemetry-plugin: telemetry disabled - ignoring telemetry event:xxxx` should be shown when telemetry is disabled and debug is on

      Version-Release number of selected component (if applicable):

      4.16.0-0.nightly-2024-05-21-221942    

      How reproducible:

       Always   

      Steps to Reproduce:

      1. disable telemeter client and turn on telemetry debug
      $ cat ~/test-files/disable-telemeter.yaml 
      apiVersion: v1
      kind: ConfigMap
      metadata:
        name: cluster-monitoring-config
        namespace: openshift-monitoring
      data:
        config.yaml: |
          telemeterClient:
            enabled: false
      $ oc create -f ~/test-files/disable-telemeter.yaml
      $ oc get cm cluster-monitoring-config -n openshift-monitoring -o yaml
      apiVersion: v1
      data:
        config.yaml: |
          telemeterClient:
            enabled: false
      kind: ConfigMap
      metadata:
        creationTimestamp: "2024-05-23T07:08:35Z"
        name: cluster-monitoring-config
        namespace: openshift-monitoring
        resourceVersion: "166718"
        uid: a4469ec8-1d2a-474f-b476-b9bc223ff252
      
      $ oc get cm console-config -n openshift-console -o yaml | grep telemetry -A10
          telemetry:
            CLUSTER_ID: 67a00652-90b8-4e9b-9c8f-d5444979d996
            DEBUG: "true"
            SEGMENT_API_HOST: console.redhat.com/connections/api/v1
            SEGMENT_JS_HOST: console.redhat.com/connections/cdn
            SEGMENT_PUBLIC_API_KEY: BnuS1RP39EmLQjP21ko67oDjhbl9zpNU
            TELEMETER_CLIENT_DISABLED: "true"
      kind: ConfigMap
      
      2. open console URL and inspect window.SERVER_FLAGS.telemetry values
      CLUSTER_ID: "67a00652-90b8-4e9b-9c8f-d5444979d996"
      DEBUG: "true"
      SEGMENT_API_HOST: "console.redhat.com/connections/api/v1"
      SEGMENT_JS_HOST: "console.redhat.com/connections/cdn"
      SEGMENT_PUBLIC_API_KEY: "BnuS1RP39EmLQjP21ko67oDjhbl9zpNU"
      TELEMETER_CLIENT_DISABLED: "true"
      3. turn on browser 'Debug' level logs and check the logs 

      Actual results:

      we can only see `console-telemetry-plugin: received telemetry event:  xxx` messages    

      Expected results:

      since telemeter client is disabled and telemetry debug is on, we should show `console-telemetry-plugin: telemetry disabled - ignoring telemetry event: xxxxx` message    

      Additional info:

          

              cjerolim Christoph Jerolimov
              rhn-support-yapei YaDan Pei
              YaDan Pei YaDan Pei
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: