[openstack-dev] [Glance] Replacing Glance DB code to Oslo DB code.

Flavio Percoco flavio at redhat.com
Fri Aug 16 16:16:27 UTC 2013

On 16/08/13 11:42 -0400, Monty Taylor wrote:
>On 08/16/2013 09:31 AM, Victor Sergeyev wrote:
>> Hello All.
>> Glance cores (Mark Washenberger, Flavio Percoco, Iccha Sethi) have some
>> questions about Oslo DB code, and why is it so important to use it
>> instead of custom implementation and so on. As there were a lot of
>> questions it was really hard to answer on all this questions in IRC. So
>> we decided that mailing list is better place for such things.
>There is another main point - which is at the last summit, we talked
>about various legit database things that need to be done to support CD
>and rolling deploys. The list is not small, and it's a task that's
>important. Needing to implement it in all of the projects separately is
>kind of an issue, whereas if the projects are all using the database the
>same way, then the database team can engineer the same mechanisms for
>doing rolling schema changes, and then operators can have a consistent
>expectation when they're running a cloud.

Just to be clear, AFAIK, the concerns were around how / when to migrate
Glance and not about why we should share database code.

>> List of main questions:
>> 1. What includes oslo DB code?
>> 2. Why is it safe to replace custom implementation by Oslo DB code?
>> 3. Why oslo DB code is better than custom implementation?
>> 4. Why oslo DB code won’t slow up project development progress?
>> 5. What we are going actually to do in Glance?
>> 6. What is the current status?
>> Answers:
>> 1. What includes oslo DB code?
>> Currently Oslo code improves different aspects around DB:
>> -- Work with SQLAlchemy models, engine and session
>> -- Lot of tools for work with SQLAlchemy
>> -- Work with unique keys
>> -- Base test case for work with database
>> -- Test migrations against different backends
>> -- Sync DB Models with actual schemas in DB (add test that they are
>> equivalent)
>> 2. Why is it safe to replace custom implementation by Oslo DB code?
>> Oslo module, as base openstack module, takes care about code quality.
>> Usually, common code more readable (most of flake8 checks enabled in
>> Oslo) and have better test coverage.  Also it was tested in different
>> use-cases (in production also) in an other projects so bugs in Oslo code
>> were already fixed. So we can be sure, that we use high-quality code.

This is the point I was most worried about - and I'm still are. The
migration to Oslo's db code started a bit late in Glance and no code
has been merged yet. As for Glance, there still seems to be a lot of
work ahead on this matter.

That being said, thanks a lot for the email and for explaining all
those details.

Flavio Percoco

More information about the OpenStack-dev mailing list