placement/nova/db/sqlalchemy/api_migrations
Jay Pipes 7aa0052a5b placement: use separate tables for projects/users
We were a bit naughty in Iecbe0eb5717afb0b13ca90d4868a3ca5f9e8902b in
that we didn't normalize the storage of Keystone project and user
identifiers in the API DB's new consumers table. This means that we
will use a whole lot more storage for what ends up being very
repetitive data.

This patch changes the consumers DB table schema's project_id and
user_id columns from VARCHAR(255) to INT data type. This should result
in significantly faster queries for usage information since 9X the
index records can fit into a single index block in memory (36-byte
UUIDs stored in VARCHAR(255) versus 4-byte integers. The more index
records we can fit into a single page of memory, the faster both scans
and seeks will be.

Let's address this now before anything uses the consumers table.

Change-Id: I1b7357739f2a7e55c55d3acb9bd604731c4a2b32
blueprint: placement-project-user
2017-06-07 16:00:28 +00:00
..
migrate_repo placement: use separate tables for projects/users 2017-06-07 16:00:28 +00:00
__init__.py Add second migrate_repo for cells v2 database migrations 2015-03-03 15:41:40 -05:00