Got none with improper name when querying resource provider list
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Invalid
|
Undecided
|
Unassigned |
Bug Description
Description
===========
I created one resource provider with name that included some special symbols,
like '$', '@' at etc. Then i queried RP list with the name for filtering,
and it returned none.
Steps to reproduce
==================
* POST http://
{
"name": "RP_test-
}
* GET http://
{
"resource_
}
Expected result
===============
Validate 'name' when creating RP with strict rules.
Actual result
=============
Only check if string.
"name": {
"type": "string",
},
Environment
===========
1. nova version
[root@controller nova]# git log
commit 50d402821be7476
Author: Matt Riedemann <email address hidden>
Date: Wed Feb 8 10:23:14 2017 -0500
Consider startup scenario in _get_compute_
2. Which hypervisor did you use?
devstack + libvirt + kvm
At least as written, there appears to be no problem here: you're passing a URL without encoding the parameters. The unicode you've used in the name parameter needs to be encoded. Once done the URL will look like:
/placement/ resource_ providers? name=RP_ test-dks% EF%BC%9F% 23%EF%BF% A5%40%EF% BC%81%23% 23k
at which point the results will include the created resource provider.