CS-15459: fixed listTags for userVms
Project: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/commit/ec26e836 Tree: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/tree/ec26e836 Diff: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/diff/ec26e836 Branch: refs/heads/vpc Commit: ec26e836fc45ff96899bb419f5e77b3a104c3eef Parents: 7acf858 Author: Alena Prokharchyk <[email protected]> Authored: Thu Jul 5 18:33:23 2012 -0700 Committer: Alena Prokharchyk <[email protected]> Committed: Fri Jul 6 11:43:31 2012 -0700 ---------------------------------------------------------------------- .../com/cloud/tags/TaggedResourceManagerImpl.java | 10 +++++----- 1 files changed, 5 insertions(+), 5 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/ec26e836/server/src/com/cloud/tags/TaggedResourceManagerImpl.java ---------------------------------------------------------------------- diff --git a/server/src/com/cloud/tags/TaggedResourceManagerImpl.java b/server/src/com/cloud/tags/TaggedResourceManagerImpl.java index 075ca48..bfadb78 100644 --- a/server/src/com/cloud/tags/TaggedResourceManagerImpl.java +++ b/server/src/com/cloud/tags/TaggedResourceManagerImpl.java @@ -282,14 +282,14 @@ public class TaggedResourceManagerImpl implements TaggedResourceService, Manager if (tableName == null) { throw new InvalidParameterValueException("Unable to find resource of type " + resourceType + " in the database"); } - identiyUUId = _identityDao.getIdentityUuid(tableName, resourceId); - if (identiyUUId != null) { - break; - } + + claz = claz.getSuperclass(); + if (claz == Object.class) { + identiyUUId = _identityDao.getIdentityUuid(tableName, resourceId); + } } catch (Exception ex) { //do nothing here, it might mean uuid field is missing and we have to search further } - claz = claz.getSuperclass(); } if (identiyUUId == null) {
