Bug 1042959 - [RFE][oslo]: Add API input validation utility for openstack common
Summary: [RFE][oslo]: Add API input validation utility for openstack common
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: RFEs
Version: unspecified
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: ---
Assignee: RHOS Maint
QA Contact:
URL: https://blueprints.launchpad.net/oslo...
Whiteboard: upstream_milestone_none upstream_stat...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-12-13 16:47 UTC by RHOS Integration
Modified: 2015-03-19 17:18 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Enhancement
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-03-19 17:18:18 UTC
Target Upstream Version:


Attachments (Terms of Use)

Description RHOS Integration 2013-12-13 16:47:46 UTC
Cloned from launchpad blueprint https://blueprints.launchpad.net/oslo/+spec/api-validation-utility.

Description:

This is a feature request to enable openstack-common code in oslo to perform common input validations 
across Openstack API.

Most of the validation of create resource API are scattered and duplicated, across Nova, Keystone, Cinder, Glance. Due to this, there is a lot of inconsistency in how the APIs respond to similar classes of input.

Refer: https://docs.google.com/file/d/0BwufSlaYow2GUUZJVlJYVGM2VVU/edit?usp=sharing

A utility in Oslo will enable common validation tasks such as:
* checking input length (based on min and max values)
* checking input well-formedness (say, based on an expected regex), 
* raise appropriate exceptions wherever needed

This could go into a separate module like openstack/common/validation_utils.py

Also refer the discussion on Bug https://bugs.launchpad.net/nova/+bug/1206396

Specification URL (additional information):

None


Note You need to log in before you can comment on or make changes to this bug.