Bug 1872620 - Network chart tooltip with empty named network interface in annotation display wrong color in pod page
Summary: Network chart tooltip with empty named network interface in annotation displa...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Management Console
Version: 4.6
Hardware: Unspecified
OS: Unspecified
medium
low
Target Milestone: ---
: 4.6.0
Assignee: Rastislav Wagner
QA Contact: Yanping Zhang
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-08-26 08:33 UTC by XiaochuanWang
Modified: 2020-10-27 16:34 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-10-27 16:34:19 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
issue screenshot (46.88 KB, image/png)
2020-08-26 08:33 UTC, XiaochuanWang
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Github openshift console pull 6775 0 None closed Bug 1872620: Support unnamed interface in pod network charts 2020-10-06 01:58:56 UTC
Red Hat Product Errata RHBA-2020:4196 0 None None None 2020-10-27 16:34:33 UTC

Description XiaochuanWang 2020-08-26 08:33:23 UTC
Created attachment 1712647 [details]
issue screenshot

Description of problem:
Create Pod using annotation contains empty named network interface, the chart color and value does not match.

Version-Release number of selected component (if applicable):
4.6.0-0.nightly-2020-08-25-204643

How reproducible:
Always

Steps to Reproduce:
1. Create a cni NetworkAttachmentDefinition for a project:
apiVersion: "k8s.cni.cncf.io/v1"
kind: NetworkAttachmentDefinition
metadata:
  name: ipvlan-host-local
spec:
  config: '{
        "cniVersion": "0.3.1",
      "name": "ipvlan-host-local",
      "master": "ens5",
      "type": "ipvlan",
      "ipam": {
             "type": "host-local",
             "subnet": "22.2.2.0/24"
}
}'

2. Create a pod:
apiVersion: v1
kind: Pod
metadata:
  name: pod-ipvlan-host-local
  annotations:
    k8s.v1.cni.cncf.io/networks: ipvlan-host-local
spec:
  containers:
  - name: pod-name
    image: quay.io/openshifttest/multus-pod@sha256:48da37205f9b43424e0983d4c5e7e07f77b7ba1504bbe35e2f264c75dcb4cd15

3. Check the annotation for the pod which contains empty value here: 
$oc get pod pod-ipvlan-host-local -o json|jq .metadata.annotations

annotations:
    k8s.v1.cni.cncf.io/network-status: |-
      [{
          "name": ""


Actual results:
The Network Output chart has wrong tooltip interface hightlight color. (please check the screenshot. Color for interface with name value is yellow which is the Total, it should be blue according to the chart)

Expected results:
There should show either 2 interfaces and tooltip match values independently and correctly, or only one interface to show the correct tooltip color with matched value in chart.

Additional info:

Comment 1 Robb Hamilton 2020-08-26 13:19:13 UTC
Reassiging to Rastislav as he recently changed the charts in https://github.com/openshift/console/pull/6031

Comment 5 Yanping Zhang 2020-10-09 07:04:29 UTC
Checked on ocp 4.6 cluster with payload 4.6.0-0.nightly-2020-10-08-182439.
Steps to verify:
1. Create a cni NetworkAttachmentDefinition for a project:
apiVersion: "k8s.cni.cncf.io/v1"
kind: NetworkAttachmentDefinition
metadata:
  name: ipvlan-host-local
spec:
  config: '{
        "cniVersion": "0.3.1",
      "name": "ipvlan-host-local",
      "master": "ens5",
      "type": "ipvlan",
      "ipam": {
             "type": "host-local",
             "subnet": "22.2.2.0/24"
}
}'

2. Create a pod:
apiVersion: v1
kind: Pod
metadata:
  name: pod-ipvlan-host-local
  annotations:
    k8s.v1.cni.cncf.io/networks: ipvlan-host-local
spec:
  containers:
  - name: pod-name
    image: quay.io/openshifttest/multus-pod@sha256:48da37205f9b43424e0983d4c5e7e07f77b7ba1504bbe35e2f264c75dcb4cd15

3. Check the annotation for the pod which contains empty value here: 
$oc get pod pod-ipvlan-host-local -o json|jq .metadata.annotations

annotations:
    k8s.v1.cni.cncf.io/network-status: |-
      [{
          "name": ""


Check charts on the pod detail page, for network in/out chart, there are yellow and blue lines showing data for two interfaces. Data and colors in tooltip match with interfaces.
The bug is fixed.

Comment 7 errata-xmlrpc 2020-10-27 16:34:19 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (OpenShift Container Platform 4.6 GA Images), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2020:4196


Note You need to log in before you can comment on or make changes to this bug.