Bug 1005770 - The values of gear's uuid and _id in group_instances are different after migration
The values of gear's uuid and _id in group_instances are different after migr...
Status: CLOSED NOTABUG
Product: OpenShift Online
Classification: Red Hat
Component: Pod (Show other bugs)
2.x
Unspecified Unspecified
medium Severity medium
: ---
: ---
Assigned To: Clayton Coleman
libra bugs
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-09-09 07:35 EDT by Jianwei Hou
Modified: 2015-05-14 20:20 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-09-09 17:34: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)

  None (edit)
Description Jianwei Hou 2013-09-09 07:35:37 EDT
Description of problem:
After migration, retrieve app info with rhc app-show, found that the app's uuid is different from its gear's uuid displayed in ssh connection url, eg:
jenkins1 @ http://jenkins1-migration1.dev.rhcloud.com/ (uuid: 522d31f74f96a84b15000006)
---------------------------------------------------------------------------------------
  Domain:  migration1
  Created: 10:27 AM
  Gears:   1 (defaults to small)
  Git URL: ssh://5049404018f711e396e622000aee8a99@jenkins1-migration1.dev.rhcloud.com/~/git/jenkins1.git/
  SSH:     5049404018f711e396e622000aee8a99@jenkins1-migration1.dev.rhcloud.com

  jenkins-1 (Jenkins Server)
  --------------------------
    Gears: 1 small

app uuid is 522d31f74f96a84b15000006
SSH connection url shows the gear's uuid is 5049404018f711e396e622000aee8a99
The two uuids are different

Version-Release number of selected component (if applicable):
After migration on devenv_3758

How reproducible:
Always

Steps to Reproduce:
1. Create application on devenv-stage_465
2. Upgrade to latest(devenv_3758) and migrate
/usr/bin/rhc-admin-migrate-datastore --non-compatible --version 2.0.32
oo-admin-upgrade upgrade-node --version 2.0.33 --ignore-cartridge-version
3. Clear broker cache
4. Query an application from mongo
db.applications.findOne({"name":"jenkins1"})


Actual results:
After step 4: the _id is different from uuid in group_instances, and the uuid(5049404018f711e396e622000aee8a99) doesn't make any sense for it's not being used. I've tried to reproduce on a fresh devenv_3758 instance, the _id and uuid fields have the same value. I'm opening this bug since I found this issue only after migration. Not knowing it will cause any problems yet.
<snip>
"group_instances" : [
		{
			"_id" : ObjectId("522d31f74f96a84b15000011"),
			"gears" : [
				{
					"_id" : ObjectId("522d31f74f96a84b15000006"),
					"app_dns" : true,
					"host_singletons" : true,
					"name" : "jenkins1",
					"quarantined" : false,
					"server_identity" : "ip-10-238-138-153",
					"sparse_carts" : [ ],
					"uid" : null,
					"uuid" : "5049404018f711e396e622000aee8a99"
				}
			]
		}
	],

</snip>

Expected results:
_id and uuid should be the same.

Additional info:
Comment 1 Clayton Coleman 2013-09-09 17:34:08 EDT
The _id and uuid being different is not a bug - the broker specifically creates those with different values for test purposes in the devenv.  UUID is what is used to talk to the nodes (it's the value of the gear id on each node) whereas _id is an internal value used for cross linking.  In production, new gears are always created with _id == uuid.

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