You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cloudstack.apache.org by Charles Russell <Ch...@kisinc.net> on 2012/05/14 18:43:13 UTC

Data Dictionary

Hello,

I’m running into more and more instances where it’s required to directly interact with the Cloudstack database, and I find myself having to reverse engineer it.  So, the question is, does an up to date data dictionary exists for the Cloudstack database?

Thanks,


Charles Russell
Senior Consulting Engineer
Knowledge Information Solutions, Inc.
P:      (757)  275-7523
M:      (757) 647-6236
F:      (757) 486-2318

RE: Data Dictionary

Posted by Giles Sirett <gi...@shapeblue.com>.
+1

Kind Regards
Giles

D: 020 3603 0541 | M: 07961112055


-----Original Message-----
From: Charles Russell [mailto:Charles.Russell@kisinc.net]
Sent: 14 May 2012 17:43
To: cloudstack-dev@incubator.apache.org
Subject: Data Dictionary

Hello,

I’m running into more and more instances where it’s required to directly interact with the Cloudstack database, and I find myself having to reverse engineer it.  So, the question is, does an up to date data dictionary exists for the Cloudstack database?

Thanks,


Charles Russell
Senior Consulting Engineer
Knowledge Information Solutions, Inc.
P:      (757)  275-7523
M:      (757) 647-6236
F:      (757) 486-2318

-----
No virus found in this message.
Checked by AVG - www.avg.com
Version: 2012.0.2171 / Virus Database: 2425/4987 - Release Date: 05/09/12
ShapeBlue provides a range of strategic and technical consulting services to help IT Service Providers and enterprises to build a true IaaS compute cloud. ShapeBlue’s expertise, combined with CloudStack technology, allows IT Service providers and enterprises to deliver true, utility based, IaaS to the customer without reengineering existing physical, virtual or storage layers.

________________________________

This email and any attachments to it may be confidential and are intended solely for the use of the individual to whom it is addressed. Any views or opinions expressed are solely those of the author and do not necessarily represent those of Shape Blue Ltd. If you are not the intended recipient of this email, you must neither take any action based upon its contents, nor copy or show it to anyone. Please contact the sender if you believe you have received this email in error. Shape Blue Ltd is a company incorporated in England & Wales.

Re: Data Dictionary

Posted by Alena Prokharchyk <Al...@citrix.com>.
On 5/14/12 1:11 PM, "Charles Russell" <Ch...@kisinc.net> wrote:

>Noted,
>
>However, I didn't delete but rather marked with a now() for the removed
>field.


It can lead to NPEs on all API calls returning the objects having
references to the zone object, as by default we make an object search with
"don't include removed records" rule. Each removed zone should never have
non-removed objects referencing it.

-Alena.

>
>
>
>
>Charles Russell
>Senior Consulting Engineer
>Knowledge Information Solutions, Inc.
>Phone: (757)  275-7523
>Cell: (757) 647-6236
>Fax: (757) 486-2318
>
>-----Original Message-----
>From: Alena Prokharchyk [mailto:Alena.Prokharchyk@citrix.com]
>Sent: Monday, May 14, 2012 3:55 PM
>To: cloudstack-dev@incubator.apache.org
>Subject: Re: Data Dictionary
>
>On 5/14/12 11:09 AM, "Charles Russell" <Ch...@kisinc.net> wrote:
>
>>Well the times I've had to revert to manual editing of SQL I've
>>subsequently posted a bug as I find them.
>>
>>I had to follow the SQL  constraints and delete this zone because of this
>>error.    I successfully reversed it but it wasn't a walk in the park.
>>And as with everyone else.. It's not recommended for a production
>>system but alas, handy to have.  Thanks for the link.
>>
>>http://bugs.cloudstack.org/browse/CS-14746
>
>
>Its never a good idea to mark entry as deleted in the database as there
>are too many dependencies with other tables/data you might not be aware
>of, which can lead to all different code errors (API errors, DB upgrade
>problems, etc). And the dependencies do not always base on constrains.
>Besides, we can't fully rely on constraints to figure out the
>dependencies because sometimes they can be missing due to the bug in
>cloudStack DB schema. The official way is to use API calls (deleteZone
>for deleting the zone).
>If something can't be done using the API call, the bug should be filed.
>As the part of the bug fix cloudStack developer should provide:
>
>* the fix itself
>* the workaround for existing problematic system. The workaround should
>be well tested in house to eliminate all possible issues
>* if changes are required to be made in DB schema, it should be covered
>in DB upgrade code for the future releases.
>
>
>-Alena.
>
>
>>
>>
>>
>>
>>Charles Russell
>>Senior Consulting Engineer
>>Knowledge Information Solutions, Inc.
>>Phone: (757)  275-7523
>>Cell: (757) 647-6236
>>Fax: (757) 486-2318
>>
>>-----Original Message-----
>>From: Geoff Higginbottom [mailto:geoff.higginbottom@shapeblue.com]
>>Sent: Monday, May 14, 2012 2:05 PM
>>To: cloudstack-dev@incubator.apache.org
>>Subject: RE: Data Dictionary
>>
>>I have had to revert to manipulating things in the database on more
>>than one occasion, but only on test and POC systems, you should not go
>>near it on a live system
>>
>>-----Original Message-----
>>From: Frank Zhang [mailto:Frank.Zhang@citrix.com]
>>Sent: 14 May 2012 18:58
>>To: cloudstack-dev@incubator.apache.org
>>Subject: RE: Data Dictionary
>>
>>Though I think directly access database is not a good idea, the
>>database schema is at setup/db/create-schema.sql in source
>>
>>> -----Original Message-----
>>> From: Charles Russell [mailto:Charles.Russell@kisinc.net]
>>> Sent: Monday, May 14, 2012 9:43 AM
>>> To: cloudstack-dev@incubator.apache.org
>>> Subject: Data Dictionary
>>>
>>> Hello,
>>>
>>> I¹m running into more and more instances where it¹s required to
>>> directly interact with the Cloudstack database, and I find myself
>>> having to reverse engineer it.  So, the question is, does an up to
>>> date data dictionary exists for the Cloudstack database?
>>>
>>> Thanks,
>>>
>>>
>>> Charles Russell
>>> Senior Consulting Engineer
>>> Knowledge Information Solutions, Inc.
>>> P:      (757)  275-7523
>>> M:      (757) 647-6236
>>> F:      (757) 486-2318
>>ShapeBlue provides a range of strategic and technical consulting
>>services to help IT Service Providers and enterprises to build a true
>>IaaS compute cloud. ShapeBlue¹s expertise, combined with CloudStack
>>technology, allows IT Service providers and enterprises to deliver
>>true, utility based, IaaS to the customer without reengineering
>>existing physical, virtual or storage layers.
>>
>>________________________________
>>
>>This email and any attachments to it may be confidential and are
>>intended solely for the use of the individual to whom it is addressed.
>>Any views or opinions expressed are solely those of the author and do
>>not necessarily represent those of Shape Blue Ltd. If you are not the
>>intended recipient of this email, you must neither take any action
>>based upon its contents, nor copy or show it to anyone. Please contact
>>the sender if you believe you have received this email in error. Shape
>>Blue Ltd is a company incorporated in England & Wales.
>>
>
>
>



RE: Data Dictionary

Posted by Charles Russell <Ch...@kisinc.net>.
Noted,

However, I didn't delete but rather marked with a now() for the removed field.




Charles Russell
Senior Consulting Engineer
Knowledge Information Solutions, Inc.
Phone: (757)  275-7523
Cell: (757) 647-6236
Fax: (757) 486-2318

-----Original Message-----
From: Alena Prokharchyk [mailto:Alena.Prokharchyk@citrix.com]
Sent: Monday, May 14, 2012 3:55 PM
To: cloudstack-dev@incubator.apache.org
Subject: Re: Data Dictionary

On 5/14/12 11:09 AM, "Charles Russell" <Ch...@kisinc.net> wrote:

>Well the times I've had to revert to manual editing of SQL I've
>subsequently posted a bug as I find them.
>
>I had to follow the SQL  constraints and delete this zone because of this
>error.    I successfully reversed it but it wasn't a walk in the park.
>And as with everyone else.. It's not recommended for a production
>system but alas, handy to have.  Thanks for the link.
>
>http://bugs.cloudstack.org/browse/CS-14746


Its never a good idea to mark entry as deleted in the database as there are too many dependencies with other tables/data you might not be aware of, which can lead to all different code errors (API errors, DB upgrade problems, etc). And the dependencies do not always base on constrains.
Besides, we can't fully rely on constraints to figure out the dependencies because sometimes they can be missing due to the bug in cloudStack DB schema. The official way is to use API calls (deleteZone for deleting the zone).
If something can't be done using the API call, the bug should be filed. As the part of the bug fix cloudStack developer should provide:

* the fix itself
* the workaround for existing problematic system. The workaround should be well tested in house to eliminate all possible issues
* if changes are required to be made in DB schema, it should be covered in DB upgrade code for the future releases.


-Alena.


>
>
>
>
>Charles Russell
>Senior Consulting Engineer
>Knowledge Information Solutions, Inc.
>Phone: (757)  275-7523
>Cell: (757) 647-6236
>Fax: (757) 486-2318
>
>-----Original Message-----
>From: Geoff Higginbottom [mailto:geoff.higginbottom@shapeblue.com]
>Sent: Monday, May 14, 2012 2:05 PM
>To: cloudstack-dev@incubator.apache.org
>Subject: RE: Data Dictionary
>
>I have had to revert to manipulating things in the database on more
>than one occasion, but only on test and POC systems, you should not go
>near it on a live system
>
>-----Original Message-----
>From: Frank Zhang [mailto:Frank.Zhang@citrix.com]
>Sent: 14 May 2012 18:58
>To: cloudstack-dev@incubator.apache.org
>Subject: RE: Data Dictionary
>
>Though I think directly access database is not a good idea, the
>database schema is at setup/db/create-schema.sql in source
>
>> -----Original Message-----
>> From: Charles Russell [mailto:Charles.Russell@kisinc.net]
>> Sent: Monday, May 14, 2012 9:43 AM
>> To: cloudstack-dev@incubator.apache.org
>> Subject: Data Dictionary
>>
>> Hello,
>>
>> I¹m running into more and more instances where it¹s required to
>> directly interact with the Cloudstack database, and I find myself
>> having to reverse engineer it.  So, the question is, does an up to
>> date data dictionary exists for the Cloudstack database?
>>
>> Thanks,
>>
>>
>> Charles Russell
>> Senior Consulting Engineer
>> Knowledge Information Solutions, Inc.
>> P:      (757)  275-7523
>> M:      (757) 647-6236
>> F:      (757) 486-2318
>ShapeBlue provides a range of strategic and technical consulting
>services to help IT Service Providers and enterprises to build a true
>IaaS compute cloud. ShapeBlue¹s expertise, combined with CloudStack
>technology, allows IT Service providers and enterprises to deliver
>true, utility based, IaaS to the customer without reengineering
>existing physical, virtual or storage layers.
>
>________________________________
>
>This email and any attachments to it may be confidential and are
>intended solely for the use of the individual to whom it is addressed.
>Any views or opinions expressed are solely those of the author and do
>not necessarily represent those of Shape Blue Ltd. If you are not the
>intended recipient of this email, you must neither take any action
>based upon its contents, nor copy or show it to anyone. Please contact
>the sender if you believe you have received this email in error. Shape
>Blue Ltd is a company incorporated in England & Wales.
>



RE: Data Dictionary

Posted by Kevin Kluge <Ke...@citrix.com>.
Yes please, keep filing the bugs!   A lot of work went into 3.0.x to fix the most common cases of "X does not work so I need to go edit the db".  We have to keep rooting out these problems.

-kevin

> -----Original Message-----
> From: Charles Russell [mailto:Charles.Russell@kisinc.net]
> Sent: Monday, May 14, 2012 11:10 AM
> To: cloudstack-dev@incubator.apache.org
> Subject: RE: Data Dictionary
> 
> Well the times I've had to revert to manual editing of SQL I've subsequently
> posted a bug as I find them.
> 
> I had to follow the SQL  constraints and delete this zone because of this error.
> I successfully reversed it but it wasn't a walk in the park.   And as with
> everyone else.. It's not recommended for a production system but alas,
> handy to have.  Thanks for the link.
> 
> http://bugs.cloudstack.org/browse/CS-14746
> 
> 
> 
> 
> Charles Russell
> Senior Consulting Engineer
> Knowledge Information Solutions, Inc.
> Phone: (757)  275-7523
> Cell: (757) 647-6236
> Fax: (757) 486-2318
> 
> -----Original Message-----
> From: Geoff Higginbottom [mailto:geoff.higginbottom@shapeblue.com]
> Sent: Monday, May 14, 2012 2:05 PM
> To: cloudstack-dev@incubator.apache.org
> Subject: RE: Data Dictionary
> 
> I have had to revert to manipulating things in the database on more than one
> occasion, but only on test and POC systems, you should not go near it on a
> live system
> 
> -----Original Message-----
> From: Frank Zhang [mailto:Frank.Zhang@citrix.com]
> Sent: 14 May 2012 18:58
> To: cloudstack-dev@incubator.apache.org
> Subject: RE: Data Dictionary
> 
> Though I think directly access database is not a good idea, the database
> schema is at setup/db/create-schema.sql in source
> 
> > -----Original Message-----
> > From: Charles Russell [mailto:Charles.Russell@kisinc.net]
> > Sent: Monday, May 14, 2012 9:43 AM
> > To: cloudstack-dev@incubator.apache.org
> > Subject: Data Dictionary
> >
> > Hello,
> >
> > I’m running into more and more instances where it’s required to
> > directly interact with the Cloudstack database, and I find myself
> > having to reverse engineer it.  So, the question is, does an up to
> > date data dictionary exists for the Cloudstack database?
> >
> > Thanks,
> >
> >
> > Charles Russell
> > Senior Consulting Engineer
> > Knowledge Information Solutions, Inc.
> > P:      (757)  275-7523
> > M:      (757) 647-6236
> > F:      (757) 486-2318
> ShapeBlue provides a range of strategic and technical consulting services to
> help IT Service Providers and enterprises to build a true IaaS compute cloud.
> ShapeBlue’s expertise, combined with CloudStack technology, allows IT
> Service providers and enterprises to deliver true, utility based, IaaS to the
> customer without reengineering existing physical, virtual or storage layers.
> 
> ________________________________
> 
> This email and any attachments to it may be confidential and are intended
> solely for the use of the individual to whom it is addressed. Any views or
> opinions expressed are solely those of the author and do not necessarily
> represent those of Shape Blue Ltd. If you are not the intended recipient of
> this email, you must neither take any action based upon its contents, nor
> copy or show it to anyone. Please contact the sender if you believe you have
> received this email in error. Shape Blue Ltd is a company incorporated in
> England & Wales.

Re: Data Dictionary

Posted by Alena Prokharchyk <Al...@citrix.com>.
On 5/14/12 11:09 AM, "Charles Russell" <Ch...@kisinc.net> wrote:

>Well the times I've had to revert to manual editing of SQL I've
>subsequently posted a bug as I find them.
>
>I had to follow the SQL  constraints and delete this zone because of this
>error.    I successfully reversed it but it wasn't a walk in the park.
>And as with everyone else.. It's not recommended for a production system
>but alas, handy to have.  Thanks for the link.
>
>http://bugs.cloudstack.org/browse/CS-14746


Its never a good idea to mark entry as deleted in the database as there
are too many dependencies with other tables/data you might not be aware
of, which can lead to all different code errors (API errors, DB upgrade
problems, etc). And the dependencies do not always base on constrains.
Besides, we can't fully rely on constraints to figure out the dependencies
because sometimes they can be missing due to the bug in cloudStack DB
schema. The official way is to use API calls (deleteZone for deleting the
zone). 
If something can't be done using the API call, the bug should be filed. As
the part of the bug fix cloudStack developer should provide:

* the fix itself
* the workaround for existing problematic system. The workaround should be
well tested in house to eliminate all possible issues
* if changes are required to be made in DB schema, it should be covered in
DB upgrade code for the future releases.


-Alena.


>
>
>
>
>Charles Russell
>Senior Consulting Engineer
>Knowledge Information Solutions, Inc.
>Phone: (757)  275-7523
>Cell: (757) 647-6236
>Fax: (757) 486-2318
>
>-----Original Message-----
>From: Geoff Higginbottom [mailto:geoff.higginbottom@shapeblue.com]
>Sent: Monday, May 14, 2012 2:05 PM
>To: cloudstack-dev@incubator.apache.org
>Subject: RE: Data Dictionary
>
>I have had to revert to manipulating things in the database on more than
>one occasion, but only on test and POC systems, you should not go near it
>on a live system
>
>-----Original Message-----
>From: Frank Zhang [mailto:Frank.Zhang@citrix.com]
>Sent: 14 May 2012 18:58
>To: cloudstack-dev@incubator.apache.org
>Subject: RE: Data Dictionary
>
>Though I think directly access database is not a good idea, the database
>schema is at setup/db/create-schema.sql in source
>
>> -----Original Message-----
>> From: Charles Russell [mailto:Charles.Russell@kisinc.net]
>> Sent: Monday, May 14, 2012 9:43 AM
>> To: cloudstack-dev@incubator.apache.org
>> Subject: Data Dictionary
>>
>> Hello,
>>
>> I¹m running into more and more instances where it¹s required to
>> directly interact with the Cloudstack database, and I find myself
>> having to reverse engineer it.  So, the question is, does an up to
>> date data dictionary exists for the Cloudstack database?
>>
>> Thanks,
>>
>>
>> Charles Russell
>> Senior Consulting Engineer
>> Knowledge Information Solutions, Inc.
>> P:      (757)  275-7523
>> M:      (757) 647-6236
>> F:      (757) 486-2318
>ShapeBlue provides a range of strategic and technical consulting services
>to help IT Service Providers and enterprises to build a true IaaS compute
>cloud. ShapeBlue¹s expertise, combined with CloudStack technology, allows
>IT Service providers and enterprises to deliver true, utility based, IaaS
>to the customer without reengineering existing physical, virtual or
>storage layers.
>
>________________________________
>
>This email and any attachments to it may be confidential and are intended
>solely for the use of the individual to whom it is addressed. Any views
>or opinions expressed are solely those of the author and do not
>necessarily represent those of Shape Blue Ltd. If you are not the
>intended recipient of this email, you must neither take any action based
>upon its contents, nor copy or show it to anyone. Please contact the
>sender if you believe you have received this email in error. Shape Blue
>Ltd is a company incorporated in England & Wales.
>



RE: Data Dictionary

Posted by Charles Russell <Ch...@kisinc.net>.
Well the times I've had to revert to manual editing of SQL I've subsequently posted a bug as I find them.

I had to follow the SQL  constraints and delete this zone because of this error.    I successfully reversed it but it wasn't a walk in the park.   And as with everyone else.. It's not recommended for a production system but alas, handy to have.  Thanks for the link.

http://bugs.cloudstack.org/browse/CS-14746




Charles Russell
Senior Consulting Engineer
Knowledge Information Solutions, Inc.
Phone: (757)  275-7523
Cell: (757) 647-6236
Fax: (757) 486-2318

-----Original Message-----
From: Geoff Higginbottom [mailto:geoff.higginbottom@shapeblue.com]
Sent: Monday, May 14, 2012 2:05 PM
To: cloudstack-dev@incubator.apache.org
Subject: RE: Data Dictionary

I have had to revert to manipulating things in the database on more than one occasion, but only on test and POC systems, you should not go near it on a live system

-----Original Message-----
From: Frank Zhang [mailto:Frank.Zhang@citrix.com]
Sent: 14 May 2012 18:58
To: cloudstack-dev@incubator.apache.org
Subject: RE: Data Dictionary

Though I think directly access database is not a good idea, the database schema is at setup/db/create-schema.sql in source

> -----Original Message-----
> From: Charles Russell [mailto:Charles.Russell@kisinc.net]
> Sent: Monday, May 14, 2012 9:43 AM
> To: cloudstack-dev@incubator.apache.org
> Subject: Data Dictionary
>
> Hello,
>
> I’m running into more and more instances where it’s required to
> directly interact with the Cloudstack database, and I find myself
> having to reverse engineer it.  So, the question is, does an up to
> date data dictionary exists for the Cloudstack database?
>
> Thanks,
>
>
> Charles Russell
> Senior Consulting Engineer
> Knowledge Information Solutions, Inc.
> P:      (757)  275-7523
> M:      (757) 647-6236
> F:      (757) 486-2318
ShapeBlue provides a range of strategic and technical consulting services to help IT Service Providers and enterprises to build a true IaaS compute cloud. ShapeBlue’s expertise, combined with CloudStack technology, allows IT Service providers and enterprises to deliver true, utility based, IaaS to the customer without reengineering existing physical, virtual or storage layers.

________________________________

This email and any attachments to it may be confidential and are intended solely for the use of the individual to whom it is addressed. Any views or opinions expressed are solely those of the author and do not necessarily represent those of Shape Blue Ltd. If you are not the intended recipient of this email, you must neither take any action based upon its contents, nor copy or show it to anyone. Please contact the sender if you believe you have received this email in error. Shape Blue Ltd is a company incorporated in England & Wales.

RE: Data Dictionary

Posted by Geoff Higginbottom <ge...@shapeblue.com>.
I have had to revert to manipulating things in the database on more than one occasion, but only on test and POC systems, you should not go near it on a live system

-----Original Message-----
From: Frank Zhang [mailto:Frank.Zhang@citrix.com]
Sent: 14 May 2012 18:58
To: cloudstack-dev@incubator.apache.org
Subject: RE: Data Dictionary

Though I think directly access database is not a good idea, the database schema is at setup/db/create-schema.sql in source

> -----Original Message-----
> From: Charles Russell [mailto:Charles.Russell@kisinc.net]
> Sent: Monday, May 14, 2012 9:43 AM
> To: cloudstack-dev@incubator.apache.org
> Subject: Data Dictionary
>
> Hello,
>
> I’m running into more and more instances where it’s required to
> directly interact with the Cloudstack database, and I find myself
> having to reverse engineer it.  So, the question is, does an up to
> date data dictionary exists for the Cloudstack database?
>
> Thanks,
>
>
> Charles Russell
> Senior Consulting Engineer
> Knowledge Information Solutions, Inc.
> P:      (757)  275-7523
> M:      (757) 647-6236
> F:      (757) 486-2318
ShapeBlue provides a range of strategic and technical consulting services to help IT Service Providers and enterprises to build a true IaaS compute cloud. ShapeBlue’s expertise, combined with CloudStack technology, allows IT Service providers and enterprises to deliver true, utility based, IaaS to the customer without reengineering existing physical, virtual or storage layers.

________________________________

This email and any attachments to it may be confidential and are intended solely for the use of the individual to whom it is addressed. Any views or opinions expressed are solely those of the author and do not necessarily represent those of Shape Blue Ltd. If you are not the intended recipient of this email, you must neither take any action based upon its contents, nor copy or show it to anyone. Please contact the sender if you believe you have received this email in error. Shape Blue Ltd is a company incorporated in England & Wales.

RE: Data Dictionary

Posted by Frank Zhang <Fr...@citrix.com>.
Though I think directly access database is not a good idea, the database schema is at setup/db/create-schema.sql in source

> -----Original Message-----
> From: Charles Russell [mailto:Charles.Russell@kisinc.net]
> Sent: Monday, May 14, 2012 9:43 AM
> To: cloudstack-dev@incubator.apache.org
> Subject: Data Dictionary
> 
> Hello,
> 
> I’m running into more and more instances where it’s required to directly
> interact with the Cloudstack database, and I find myself having to reverse
> engineer it.  So, the question is, does an up to date data dictionary exists for
> the Cloudstack database?
> 
> Thanks,
> 
> 
> Charles Russell
> Senior Consulting Engineer
> Knowledge Information Solutions, Inc.
> P:      (757)  275-7523
> M:      (757) 647-6236
> F:      (757) 486-2318