This service will be undergoing maintenance at 00:00 UTC, 2017-10-23 It is expected to last about 30 minutes
Bug 1470010 - Replicaset page displays wrong deployment if matchLabels covers other deployment's
Replicaset page displays wrong deployment if matchLabels covers other deploym...
Status: CLOSED CURRENTRELEASE
Product: OpenShift Container Platform
Classification: Red Hat
Component: Management Console (Show other bugs)
3.6.0
Unspecified Unspecified
medium Severity medium
: ---
: ---
Assigned To: Samuel Padgett
XiaochuanWang
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2017-07-12 05:17 EDT by Xingxing Xia
Modified: 2017-08-16 15 EDT (History)
8 users (show)

See Also:
Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2017-07-24 07:56:08 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Wrong-deployment-on-replicaset-page (91.84 KB, image/png)
2017-07-12 05:27 EDT, Xingxing Xia
no flags Details

  None (edit)
Description Xingxing Xia 2017-07-12 05:17:08 EDT
Description of problem:
Replicaset page displays wrong deployment if matchLabels covers other deployment's

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

How reproducible:
Always

Steps to Reproduce:
1. Create project xxia-proj1 and new-app with the template
$ oc new-app -f https://raw.githubusercontent.com/openshift/ansible-service-broker/ff0ca33/templates/deploy-ansible-service-broker.template.yaml

Note:
This is latest file of "master" as of bug report. This file includes:
deployment/asb which defines yaml as below:
    selector:
      matchLabels:
        app: ansible-service-broker

deployment/etcd which defines yaml as below:
    selector:
      matchLabels:
        app: ansible-service-broker  # note, here covers selector in above deployment asb
        service: etcd

2. On web console overview, click "#1" of deployment etcd

3. As comparison, create another project xxia-proj2,
download above yaml file, modify it by adding one
line "service: asb" for the "matchLabels" of deployment/asb,
then new-app with the modified yaml and check step 2.

Actual results:
2. It jumps to replicaset page of deployment/ectd, the url is correct.
But the page has some wrong places:
the breadcrumb link is shown wrongly as: Deployments >> asb >> #1
"Details" tab wrongly shows: Deployments  asb

3. The wrong places are gone.

Expected results:
2. Should fix the wrong places

Additional info:
Comment 1 Xingxing Xia 2017-07-12 05:21:23 EDT
Per step 3, maybe the template file should be fixed too: https://raw.githubusercontent.com/openshift/ansible-service-broker/master/templates/deploy-ansible-service-broker.template.yaml
So CC'ing default Dev/QA of bug component "Service Broker" to make them know.
Comment 2 Xingxing Xia 2017-07-12 05:27 EDT
Created attachment 1296807 [details]
Wrong-deployment-on-replicaset-page
Comment 4 openshift-github-bot 2017-07-12 10:32:50 EDT
Commit pushed to master at https://github.com/openshift/origin-web-console

https://github.com/openshift/origin-web-console/commit/14f91eb0364490ccae3a02fb371e078fd8f3bd3a
Bug 1470010 - Use owner references to find deployment on replica set page

- Avoids a problem where the label selector from another deployment
  might match a replica set, showing the wrong deployment link on the
  browse replica set page.
- Fixes a bug where an old replica set that becomes active while the
  user is on the page cannot be scaled. (This can happen if an old
  replica set revision is reused because it matches the current
  deployment spec.)

Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1470010
Comment 6 Xingxing Xia 2017-07-24 05:33:31 EDT
Verified in openshift v3.6.152.0-1. With original steps, now in step 2, replicaset page of deployment/ectd shows correct deployment name etcd.

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