incubator-cloudstack-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Animesh Chaturvedi <animesh.chaturv...@citrix.com>
Subject RE: Review Request: (CLOUDSTACK-1088) EnableStaticNat error will clear the data in database
Date Tue, 12 Feb 2013 07:12:21 GMT
Prasanna

Can you review the updated patch and if it looks good apply it to master and close the item

Thanks
Animesh

> -----Original Message-----
> From: Wei Zhou [mailto:noreply@reviews.apache.org] On Behalf Of Wei Zhou
> Sent: Monday, February 11, 2013 2:10 AM
> To: Prasanna Santhanam; Jessica Wang; Chiradeep Vittal
> Cc: cloudstack; Wei Zhou
> Subject: Re: Review Request: (CLOUDSTACK-1088) EnableStaticNat error will
> clear the data in database
> 
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/9254/
> -----------------------------------------------------------
> 
> (Updated Feb. 11, 2013, 10:10 a.m.)
> 
> 
> Review request for cloudstack, Prasanna Santhanam, Jessica Wang, and
> Chiradeep Vittal.
> 
> 
> Changes
> -------
> 
> The patch applies on master.
> 
> 
> Description
> -------
> 
> The issue occur in two conditions
> (1) If I use two sessions or browsers to EnableStaticNat on CloudStack UI. one is
> successful, the other is failed. However, there is no ip in database.
> (2) If I use API call EnableStaticNat several times The first time succeed, the
> second failed, the third succeed. the result is success-fail-success-fail-success-
> fail, which it is not correct.
> 
> This is because the improperly use of result boolean flag in
> com.cloud.network.rules.RulesManagerImpl.enableStaticNat(long, long, long,
> boolean), the table user_ip_address(one_to_one_nat , vm_id) will set to (0,null)
> when the operation failed.
> 
> For this issue, I add a new flag "updated" to describe whether the table
> user_ip_address in database has been changed..
> 
> 
> This addresses bug CLOUDSTACK-1088.
> 
> 
> Diffs (updated)
> -----
> 
>   server/src/com/cloud/network/rules/RulesManagerImpl.java 0a00d22
> 
> Diff: https://reviews.apache.org/r/9254/diff/
> 
> 
> Testing
> -------
> 
> Test in following operations
> (1) assign a ip to a vm several times.
> (2) assign two ip to a vm
> (3) assign a ip to two vms
> It works well.
> 
> 
> Thanks,
> 
> Wei Zhou

Mime
View raw message