Use common db code from oslo

Registered by Boris Pavlovic

All work around session, sqlalchemy engines, wrappers and etc is in oslo.

1) Sync from oslo this code
2) Use oslo code instead of old glance implementation.
2.a) work with sqlalchemy session and engines is common part of all project
2.b) sqlalchemy migration utils, that could help us to provide unique constraints and shadow tables.

Blueprint information

Status:
Started
Approver:
None
Priority:
High
Drafter:
Boris Pavlovic
Direction:
Approved
Assignee:
Boris Pavlovic
Definition:
Approved
Series goal:
Accepted for future
Implementation:
Needs Code Review
Milestone target:
milestone icon ongoing
Started by
Boris Pavlovic

Related branches

Sprints

Whiteboard

Gerrit topic: https://review.openstack.org/#q,topic:bp/use-oslo-common-db-code,n,z

Addressed by: https://review.openstack.org/31068
    Sync oslo db and sqlalchemy code

Is this something we want for Havana? I think there are plenty of *new* things happening in this release and most of them are related to making glance a first-citizen in OS deployments. I like the idea of syncing with Oslo's code but I think this blueprint should wait until the Ith release so we have enough time to focus on this release's goal.
-- flaper87

Yes I want this in havana, because it will allow us to use:
1) db-archiving
2) unique constraints
3) better db wrappers
3) test migrations with real data on all backends (there are some problems that we would like to solve also)
4) and removes tons of duplicated code

So unifying code in such way we allow us to integrate new db features from nova very fast into cinder and glance.

Sorry for wait, I stick with pci passthrough in nova, and also waiting some db code from oslo.
-- boris-42

I'm marking this as ongoing rather than next, because I think it will probably be a multi-stage process of adopting different components
from oslo. This change in milestone targeting does not block any patchset from landing when it is ready. --markwash

Gerrit topic: https://review.openstack.org/#q,topic:bp/db-use-oslo-common-code,n,z

Addressed by: https://review.openstack.org/36207
    WIP Use oslo.db code

Addressed by: https://review.openstack.org/37196
    Migrate sqlalchemy utils from Oslo

Addressed by: https://review.openstack.org/43277
    Renamed DB uniques due to common name convention

Addressed by: https://review.openstack.org/51829
    Use common db model class from Oslo

Addressed by: https://review.openstack.org/57697
    Solve the possible race condition in migration 012

Addressed by: https://review.openstack.org/57698
    Fixed quotes in _assert_tables() method

Addressed by: https://review.openstack.org/57969
    Use common db migrations module from Oslo

Addressed by: https://review.openstack.org/65643
    Use migration tests from common Oslo code

Will this be completed once https://review.openstack.org/#/c/43277/ is merged?

Gerrit topic: https://review.openstack.org/#q,topic:If969134ff7062712559acf4b1ff2d204887e353c,n,z

Addressed by: https://review.openstack.org/75917
    Sync common db code from Oslo

Addressed by: https://review.openstack.org/78655
    Add common context module

I guess some more requirements have shown up here? Seems its not going to fit into icehouse-rc1 in a timely fashion after all :-(
--markwash

Boris, what is the current state of this blueprint?
-- viktors

(?)

Work Items

Dependency tree

* Blueprints in grey have been implemented.

This blueprint contains Public information 
Everyone can see this information.

Subscribers

No subscribers.