incubator-cloudstack-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chip Childers <chip.child...@sungard.com>
Subject Re: git commit: refs/heads/4.1 - CLOUDSTACK-1451 Pass randomly generated UUID instead of empty string when create internal account as a part of project creation. Otherwise entityexistsexception would happen when attempt to create more than 1 project in the s
Date Thu, 07 Mar 2013 19:34:02 GMT
Hi Alena!

Thanks for the fix, but can you please follow the workflow for 4.1 
agreed to here:  http://markmail.org/message/uuffaapkhcothzcj

Thanks!

On Thu, Mar 07, 2013 at 07:29:53PM +0000, alena1108@apache.org wrote:
> Updated Branches:
>   refs/heads/4.1 e942df93e -> 45c51d1fd
> 
> 
> CLOUDSTACK-1451 Pass randomly generated UUID instead of empty string when create internal
account as a part of project creation. Otherwise entityexistsexception would happen when attempt
to create more than 1 project in the system
> 
> 
> Project: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/repo
> Commit: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/commit/45c51d1f
> Tree: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/tree/45c51d1f
> Diff: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/diff/45c51d1f
> 
> Branch: refs/heads/4.1
> Commit: 45c51d1fdd2b726245075f75fd8bf6ebce506787
> Parents: e942df9
> Author: Alena Prokharchyk <alena.prokharchyk@citrix.com>
> Authored: Thu Mar 7 11:21:59 2013 -0800
> Committer: Alena Prokharchyk <alena.prokharchyk@citrix.com>
> Committed: Thu Mar 7 11:23:40 2013 -0800
> 
> ----------------------------------------------------------------------
>  .../src/com/cloud/projects/ProjectManagerImpl.java |    3 ++-
>  1 files changed, 2 insertions(+), 1 deletions(-)
> ----------------------------------------------------------------------
> 
> 
> http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/45c51d1f/server/src/com/cloud/projects/ProjectManagerImpl.java
> ----------------------------------------------------------------------
> diff --git a/server/src/com/cloud/projects/ProjectManagerImpl.java b/server/src/com/cloud/projects/ProjectManagerImpl.java
> index 45a9a24..33feb5d 100755
> --- a/server/src/com/cloud/projects/ProjectManagerImpl.java
> +++ b/server/src/com/cloud/projects/ProjectManagerImpl.java
> @@ -23,6 +23,7 @@ import java.util.Map;
>  import java.util.Properties;
>  import java.util.Random;
>  import java.util.TimeZone;
> +import java.util.UUID;
>  import java.util.concurrent.Executors;
>  import java.util.concurrent.ScheduledExecutorService;
>  import java.util.concurrent.TimeUnit;
> @@ -204,7 +205,7 @@ public class ProjectManagerImpl extends ManagerBase implements ProjectManager
{
>          StringBuilder acctNm = new StringBuilder("PrjAcct-");
>          acctNm.append(name).append("-").append(owner.getDomainId());
>  
> -        Account projectAccount = _accountMgr.createAccount(acctNm.toString(), Account.ACCOUNT_TYPE_PROJECT,
domainId, null, null, "", 0);
> +        Account projectAccount = _accountMgr.createAccount(acctNm.toString(), Account.ACCOUNT_TYPE_PROJECT,
domainId, null, null, UUID.randomUUID().toString(), 0);
>  
>          Project project = _projectDao.persist(new ProjectVO(name, displayText, owner.getDomainId(),
projectAccount.getId()));
>  
> 
> 

Mime
View raw message