> On April 18, 2013, 5:21 p.m., Sateesh Chodapuneedi wrote:
> > server/src/com/cloud/network/NetworkServiceImpl.java, line 1888
> > <https://reviews.apache.org/r/10005/diff/1/?file=271870#file271870line1888>
> >
> >     This code seems dueplicated because the logic to calculate reserved ip 
> > range can be used to check if there exists some ip range to be reserved or 
> > not. If the calculated range is empty then do not attempt to reserve. Code 
> > to prepare response object already had this logic. May be we have to move 
> > this to NetUtils and call that from both places.

Thanks for the comment.

I have added the logic to NetUtils.java to maker it more generic and usable.
However the response method does not need to call this boolean function, so 
making changes only in API checks.


- Saksham


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/10005/#review19396
-----------------------------------------------------------


On April 19, 2013, 9:45 a.m., Saksham Srivastava wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/10005/
> -----------------------------------------------------------
> 
> (Updated April 19, 2013, 9:45 a.m.)
> 
> 
> Review request for cloudstack, Murali Reddy and Sateesh Chodapuneedi.
> 
> 
> Description
> -------
> 
> In cases where the start ip and end ip of guest vm cidr and network cidr are 
> same, even when the cidrs appear to be different,the reservation procedure 
> should not go through and user should get a message mentioning that.
> Added extra check for the same with proper alert message.
> 
> 
> This addresses bug CLOUDSTACK-1647.
> 
> 
> Diffs
> -----
> 
>   server/src/com/cloud/network/NetworkServiceImpl.java 878d2a8 
>   utils/src/com/cloud/utils/net/NetUtils.java 5988dd5 
> 
> Diff: https://reviews.apache.org/r/10005/diff/
> 
> 
> Testing
> -------
> 
> CIDR : 10.0.144.0/20, Network CIDR : null, guestVmCidr : 10.0.151.0/20 => 
> Reservation is not applied.
> CIDR : 10.0.144.0/21, Network CIDR : 10.0.144.0/20, guestVmCidr : 
> 10.0.151.0/20 => Existing Reservation is not affected.
> 
> 
> Thanks,
> 
> Saksham Srivastava
> 
>

Reply via email to