Bug 1005770 - The values of gear's uuid and _id in group_instances are different after migration
Summary: The values of gear's uuid and _id in group_instances are different after migr...
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: OpenShift Online
Classification: Red Hat
Component: Pod
Version: 2.x
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: ---
Assignee: Clayton Coleman
QA Contact: libra bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-09-09 11:35 UTC by Jianwei Hou
Modified: 2015-05-15 00:20 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-09-09 21:34:08 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Jianwei Hou 2013-09-09 11:35:37 UTC
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.rhcloud.com/~/git/jenkins1.git/
  SSH:     5049404018f711e396e622000aee8a99.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 21:34:08 UTC
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.