'Create a custom ZFSSA schema.'

def create_schema(self, schema):

    base = '/api/storage/v1/schema'
    svc = ('%(base)s/%(prop)s' % {'base': base, 'prop': schema['property']})
    ret = self.rclient.get(svc)
    if (ret.status == restclient.Status.OK):
        LOG.warning('Property    %s    already    exists.', schema['property'])
        return
    ret = self.rclient.post(base, schema)
    if (ret.status != restclient.Status.CREATED):
        exception_msg = (_('Error    Creating    Property:    %(property)s    Type:    %(type)s    Description:    %(description)s    Return    code:    %(ret.status)d    Message:    %(ret.data)s.') % {'property': schema['property'], 'type': schema['type'], 'description': schema['description'], 'ret.status': ret.status, 'ret.data': ret.data})
        LOG.error(exception_msg)
        raise exception.VolumeBackendAPIException(data=exception_msg)
