[Openstack] object-oriented design in nova--room for improvement?

Joshua Harlow harlowja at yahoo-inc.com
Thu Aug 22 17:31:02 UTC 2013

I think that would make sense to. Would u want to try to prototype some
code that might do this.

That might help the nova core people see what your idea is.

Although maybe they should chime in also (since I'm not sure if any other
similar efforts are underway).

On 8/22/13 9:39 AM, "Chris Friesen" <chris.friesen at windriver.com> wrote:

>On 08/21/2013 09:04 PM, Joshua Harlow wrote:
>> There is always room for improvement I hope ;)
>> +openstack-dev (I think where u wanted this to go).
>> A question, are u thinking about organizing the 'metadata' associated
>> resources?
>> If so it might be interesting to see if there could be a grand
>> around something like 'ResourceTracker' & 'Stats' that exposes
>> (different types) via an API that all the other classes could use? Is
>> inline of what u are thinking?? Sort of like a resource + metadata
>> 'database' that everyone uses (and accesses and updates via a single set
>> of APIs).
>In my experience it's often a good thing to try and minimize the number
>of places that know about the details of something since it reduces the
>chances of cut/paste errors or someone changing one area of code but
>missing another area.  Right now there are a lot of places that know
>exactly what resources are exported by the compute node.
>It seems like it should be possible to have a base class for "resource
>exported by the compute node" that could be subclassed for each separate
>resource.  Most places in the code that care about that sort of thing
>could iterate over the set of resources and call appropriate member
>functions on them.  That way they would no longer need hardcoded
>knowledge of the exported resources.
>Adding a new resource would likely be simpler too, since most of the
>stuff required would be in one place.

More information about the Openstack mailing list