Fix assignment KVS backend to not use identity

The assignment KVS backend was using the identity API. This change
makes it so that the KVS backend does not use the identity API.

The assignment KVS backend was using the identity API to:

a) Store the user's projects.

The user's projects were also kept in the metadata. So the KVS
backend was changed to use the metadata rather than the user data.

a) Determine if the ID in the metadata was for a user or group.

The metadata for users and groups was split into separate keys.
Metadata for users is now prefixed with `metadata_user-` and
`metadata-groups-` is used for groups.

bp no-check-id

Change-Id: I5cc01d203d12b15575b72ad57aa3820d1d36d09f
Move filter_limit_query out of sql.Base

With the change to use oslo's db.sqlalchemy.sessions, the
sql.Base class isn't doing enough to justify its continued
existence.

This change is moving the filter_limit_query and related internal
members out of sql.Base to regular functions in the sql module.

Part of bp use-common-oslo-db-code

Change-Id: Ia4f05e5a81ded7e3543e16ecf93260680351f1e4
Implement mechanism to provide non-expiring keys in KVS

This patchset implements the ability to define non-expiring keys
for dogpile.cache backends. The non-expiring keys are relevant
in the case of drivers that can automatically remove keys after
a given time (e.g. memcache). This new non-expiring-key
functionality is currently only implemented for the provided
memcached backend.

bp: dogpile-kvs-backends
Change-Id: I7e25e0049e5b8697c5cb67272b660519c3c3305e
Merge "Implement mechanism to provide non-expiring keys in KVS"
Merge "Fix assignment KVS backend to not use identity"
Merge "Move filter_limit_query out of sql.Base"