Merge pull request #2189 from lavalamp/fix

Add self links to objects sent down the watch channel.
This commit is contained in:
Clayton Coleman
2014-11-06 12:57:07 -05:00
5 changed files with 85 additions and 22 deletions

View File

@@ -50,7 +50,7 @@ func GetReference(obj runtime.Object) (*ObjectReference, error) {
}
version := versionFromSelfLink.FindStringSubmatch(meta.SelfLink())
if len(version) < 2 {
return nil, fmt.Errorf("unexpected self link format: %v", meta.SelfLink())
return nil, fmt.Errorf("unexpected self link format: '%v'; got version '%v'", meta.SelfLink(), version)
}
return &ObjectReference{
Kind: kind,