Bug 1879882

Summary: [MTC] Migration analytic data are wrong after the migration controller is deleted
Product: Migration Toolkit for Containers Reporter: Sergio <sregidor>
Component: GeneralAssignee: Jason Montleon <jmontleo>
Status: CLOSED ERRATA QA Contact: Xin jiang <xjiang>
Severity: medium Docs Contact: Avital Pinnick <apinnick>
Priority: unspecified    
Version: 1.3.0CC: chezhang, ernelson, jmatthew, jmontleo, pvauter, rjohnson, rpattath, whu, xjiang
Target Milestone: ---   
Target Release: 1.3.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-09-30 18:43:07 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Sergio 2020-09-17 09:28:11 UTC
Description of problem:
When the migration controller pod is deleted, and it is recreated again, the data in the MigAnalytic resources is corrupted.

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

How reproducible:
Always

Steps to Reproduce:
1. Create an application in a namespace

oc new-project bztest
oc new-app mysql-persistent

2. Create a migration plan with name "bztest" for this namespace

3. Check the analytic data for this migration plan

$ oc get miganalytic bztest
NAME     READY   PLAN     PROGRESS   RESOURCES   IMAGES   IMAGESIZE   PVS   PVCAPACITY
bztest   True    bztest   100        53          0        0           1     1Gi

4. Delete the migration controller pod

$ oc delete pods -l control-plane

5. Wait until the pod is created again

$ oc get pods -l control-plane
NAME                                    READY   STATUS    RESTARTS   AGE
migration-controller-59f565d48d-s5rvk   2/2     Running   0          29s



Actual results:
The analytic data has been corrupted, and every time we reset the controller, new data is added to the existing anaylytic.


$ oc get miganalytic bztest
NAME     READY   PLAN     PROGRESS   RESOURCES   IMAGES   IMAGESIZE   PVS   PVCAPACITY
bztest   True    bztest   100        112         0        0           2     2Gi



Expected results:
The analytic data should be the right one after the migrationcontroller is restarted


Additional info:

Comment 1 Jason Montleon 2020-09-17 12:32:43 UTC
https://github.com/konveyor/mig-controller/pull/668

Comment 5 Xin jiang 2020-09-23 14:36:17 UTC
verified with MTC 1.3.0.

Comment 9 errata-xmlrpc 2020-09-30 18:43:07 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 (Migration Toolkit for Containers (MTC) Tool image release advisory 1.3.0), 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:4148