Updated Branches:
  refs/heads/ui-vpc-redesign cb31791ad -> 59a99848b

When UUID field is null for existing records, set it to id

Conflicts:
        server/src/com/cloud/uuididentity/dao/IdentityDaoImpl.java


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/26cefdcf
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/26cefdcf
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/26cefdcf

Branch: refs/heads/ui-vpc-redesign
Commit: 26cefdcfac42f94ff8ba831e3e40e50a81e43f52
Parents: edb2f3d
Author: Alena Prokharchyk <[email protected]>
Authored: Tue Oct 2 18:53:12 2012 -0700
Committer: Alena Prokharchyk <[email protected]>
Committed: Tue May 14 15:11:41 2013 -0700

----------------------------------------------------------------------
 .../cloud/uuididentity/dao/IdentityDaoImpl.java    |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/26cefdcf/server/src/com/cloud/uuididentity/dao/IdentityDaoImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/uuididentity/dao/IdentityDaoImpl.java 
b/server/src/com/cloud/uuididentity/dao/IdentityDaoImpl.java
index 7be63ba..c6fd8c1 100644
--- a/server/src/com/cloud/uuididentity/dao/IdentityDaoImpl.java
+++ b/server/src/com/cloud/uuididentity/dao/IdentityDaoImpl.java
@@ -21,7 +21,6 @@ import java.sql.ResultSet;
 import java.sql.SQLException;
 import java.util.ArrayList;
 import java.util.List;
-import java.util.UUID;
 
 import javax.ejb.Local;
 
@@ -235,8 +234,9 @@ public class IdentityDaoImpl extends 
GenericDaoBase<IdentityVO, Long> implements
             String.format("UPDATE `%s` SET uuid=? WHERE id=?", tableName)
         );
         
-        pstmtUpdate.setString(1, UUID.randomUUID().toString());
+        pstmtUpdate.setString(1, String.valueOf(id));
         pstmtUpdate.setLong(2, id);
         pstmtUpdate.executeUpdate();
     }
 }
+

Reply via email to