[openstack-dev] [Nova][Glance] Support of v1 and v2 glance APIs in Nova

Eddie Sheffield eddie.sheffield at rackspace.com
Mon Oct 28 15:13:31 UTC 2013


So...I've been working on this some more and hit a bit of a snag. The Glanceclient change was easy, but I see now that doing this in nova will require a pretty huge change in the way things work. Currently, the API version is grabbed from the config value, the appropriate driver is instantiated, and calls go through that. The problem comes in that the actually glance server isn't communicated with until very late in the process. Nothing "sees" the servers at the level where the driver is determined. Also there isn't a single glance server but a list of them, and in the even of certain communication failures the list is cycled through until success or a number of retries has passed.

So to change this to auto configuring will require turning this upside down, cycling through the servers at a higher level, choosing the appropriate driver for that server, and handling retries at that same level.

Doable, but a much larger task than I first was thinking.

Also, I don't really want the added overhead of getting the api versions before every call, so I'm thinking that going through the list of servers at startup and discovering the versions then and caching that somehow would be helpful as well.

Thoughts?

Eddie

-----Original Message-----
From: "Russell Bryant" <rbryant at redhat.com>
Sent: Thursday, October 17, 2013 4:38pm
To: openstack-dev at lists.openstack.org
Subject: Re: [openstack-dev] [Nova][Glance] Support of v1 and v2 glance APIs in Nova

On 10/17/2013 03:12 PM, Eddie Sheffield wrote:
> I don't oppose having the version autodiscovered. But I do feel the option should be available to override if desired. I've had many problems with over the years with autoconfiguring systems not doing what I need to be willing to depend on them 100% without a manual override available if at all possible. I'm thinking particularly for testing or upgrade evaluation scenarios. For example, you want to turn on v2 in glance and evaluate it for a bit before committing to using it for all of your nova nodes.
> 
> The current patch also had a couple of comments from Dan Prince and Chris Behrens early on when this was brought up there supporting the use of a config value.
> 
> From the implementation side of things, to do this properly would require some changes to the glanceclient to allow querying of available versions. Lacking that ability currently is one reason this is currently a config value. Once the client supports this, the nova side change would likely be quite small.
> 
> Might I propose a compromise?
> 
> 1) For the VERY short term, keep the config value and get the change otherwise reviewed and hopefully accepted.
> 
> 2) Immediately file two blueprints:
>    - python-glanceclient - expose a way to discover available versions
>    - nova - depends on the glanceclient bp and allowing autodiscovery of glance version
>             and making the config value optional (tho not deprecated / removed)

Supporting both seems reasonable.  At least then *most* people don't
need to worry about it and it "just works", but the override is there if
necessary, since multiple people seem to be expressing a desire to have
it available.

Can we just do this all at once?  Adding this to glanceclient doesn't
seem like a huge task.

-- 
Russell Bryant

_______________________________________________
OpenStack-dev mailing list
OpenStack-dev at lists.openstack.org
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev





More information about the OpenStack-dev mailing list