cloudstack-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Amogh Vasekar" <amogh.vase...@citrix.com>
Subject Re: Review Request 12976: Remove duplicate row from guest_os table
Date Sat, 27 Jul 2013 19:08:44 GMT


> On July 26, 2013, 11:51 p.m., Alena Prokharchyk wrote:
> > We can't just remove the row w/o making sure its not being referenced by existing
resources. So putting "DELETE IGNORE FROM `cloud`.`guest_os` where id=206" is not enough.
You can go 2 ways:
> > 
> > #1 - don't insert the record to the DB if it already exists (if upgraded from 3.0.x)
during 41-42 upgrade.
> > 
> > #2 - transfer all the records referencing guest os id=206, to use the guest_os inserted
as a part of 41-42 upgrade.

Thanks Alena for reviewing.

The understanding was that the row with id=206 was not being referenced elsewhere. Nonetheless,
I have added UPDATE statements for tables that might reference guest_os.id directly.

#1 wasnt feasible since the new row is being referenced directly with the new id in guest_os_hypervisor
table.


- Amogh


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


On July 26, 2013, 6:22 p.m., Amogh Vasekar wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/12976/
> -----------------------------------------------------------
> 
> (Updated July 26, 2013, 6:22 p.m.)
> 
> 
> Review request for cloudstack, Alena Prokharchyk and Venkata Siva Vijayendra Bhamidipati.
> 
> 
> Bugs: https://issues.apache.org/jira/browse/CLOUDSTACK-3647
> 
> 
> Repository: cloudstack-git
> 
> 
> Description
> -------
> 
> Remove duplicate row (id=206) from table guest_os.
> Decided to remove instead of checking for duplicates on insertion since :
> 1. The new row is referenced by id=166 elsewhere in the DB
> 2. Old row with id=206 is not referenced in DB 
> 
> 
> Diffs
> -----
> 
>   setup/db/db/schema-410to420.sql 82ca403 
> 
> Diff: https://reviews.apache.org/r/12976/diff/
> 
> 
> Testing
> -------
> 
> Local environment
> 
> 
> Thanks,
> 
> Amogh Vasekar
> 
>


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message