yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #54247
[Bug 1606431] [NEW] Flavor create and update with service_profiles is not working properly
Public bug reported:
1. When creating a new Flavor with service_profiles, is not working
properly due the it showing empty service_profiles, I entered the
correct UUID of service_profiles, however the UUID of service_profiles
is empty.
2. And another happened when I try to update the existing of Flavor by
inserting the UUID of service_profiles, the 500 Internal Server Error
occured.
Here are my log from the first one (Creating new Falvor with
service_profiles) and then the second one (Update Existing Flavor by
Inserting service_profiles)
----------------------------
Creating a new Flavor with service_profiles
Request Command :
vagrant@ubuntu:~$ curl -g -i -X POST http://192.168.122.139:9696/v2.0/flavors -H "X-Auth-Token: $TOKEN" -d '{"flavor": {"service_type":"LOADBALANCER","enabled":"true"n$
HTTP/1.1 201 Created
Content-Type: application/json
Content-Length: 173
X-Openstack-Request-Id: req-6f3047a4-07e9-4dbe-b22a-b61ba167f705
Date: Mon, 25 Jul 2016 16:12:41 GMT
{"flavor": {"description": "", "enabled": true, "service_profiles": [],
"service_type": "LOADBALANCER", "id":
"79eaa203-5913-41b0-92c5-d6c2a0211a9c", "name": "flavor-test"}}
-----------------------------
Update Existing Flavor By Inserting service_profiles
Request Command :
vagrant@ubuntu:~$ curl -g -i -X PUT http://192.168.122.139:9696/v2.0/flavors/79eaa203-5913-41b0-92c5-d6c2a0211a9c -H "X-Auth-Token: $TOKEN" -d '{"flavor": {"enabled":"$
HTTP/1.1 500 Internal Server Error
Content-Type: application/json
Content-Length: 150
X-Openstack-Request-Id: req-d8581b95-a798-4d83-9980-414892553cd3
Date: Mon, 25 Jul 2016 17:18:56 GMT
2016-07-25 17:18:56.650 24207 DEBUG neutron.api.v2.base [req-b42a4171-1c3d-4e67-a375-c5ce7c08546b e01bc3eadeb045edb02fc6b2af4b5d49 867929bfedca4a719e17a7f3293845de ---] Request body: {u'flavor': {u'service_profiles': [u'8e843ed6-cbd0-4ede-b765-d98e765f1135'], u'enabled': u'false'}} prepare_request_body /opt/stack/neutron/neutron/api/v2/base.py:649
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource [req-b42a4171-1c3d-4e67-a375-c5ce7c08546b e01bc3eadeb045edb02fc6b2af4b5d49 867929bfedca4a719e17a7f3293845de- - -] update failed: No details.
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource Traceback (most recent call last):
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/opt/stack/neutron/neutron/api/v2/resource.py", line 79, in resource
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource result = method(request=request, **args)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/opt/stack/neutron/neutron/api/v2/base.py", line 571, in update
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource return self._update(request, id, body, **kwargs)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/oslo_db/api.py", line 148, in wrapper
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource ectxt.value = e.inner_exc
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/oslo_utils/excutils.py", line 220, in __exit__
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource self.force_reraise()
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/oslo_utils/excutils.py", line 196, in force_reraise
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource six.reraise(self.type_, self.value, self.tb)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/oslo_db/api.py", line 138, in wrapper
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource return f(*args, **kwargs)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/opt/stack/neutron/neutron/api/v2/base.py", line 617, in _update
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource obj = obj_updater(request.context, id, **kwargs)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/opt/stack/neutron/neutron/db/flavors_db.py", line 142, in update_flavor
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource fl_db.update(fl)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/oslo_db/sqlalchemy/models.py", line 94, in update
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource setattr(self, k, v)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/sqlalchemy/orm/attributes.py", line 224, in __set__
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource instance_dict(instance), value, None)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/sqlalchemy/orm/attributes.py", line 1027, in set
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource lambda adapter, i: adapter.adapt_like_to_iterable(i))
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/sqlalchemy/orm/attributes.py", line 1062, in _set_iterable
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource collections.bulk_replace(new_values, old_collection, new_collection)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/sqlalchemy/orm/collections.py", line 791, in bulk_replace
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource new_adapter.append_with_event(member)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/sqlalchemy/orm/collections.py", line 654, in append_with_event
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource self._data()._sa_appender(item, _sa_initiator=initiator)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/sqlalchemy/orm/collections.py", line 1073, in append
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource item = __set(self, item, _sa_initiator)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/sqlalchemy/orm/collections.py", line 1045, in __set
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource item = executor.fire_append_event(item, _sa_initiator)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/sqlalchemy/orm/collections.py", line 717, in fire_append_event
** Affects: neutron
Importance: Undecided
Assignee: Rahmad Ade Putra (leksokmy)
Status: New
** Tags removed: flavor
** Changed in: neutron
Assignee: (unassigned) => Rahmad Ade Putra (leksokmy)
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/1606431
Title:
Flavor create and update with service_profiles is not working properly
Status in neutron:
New
Bug description:
1. When creating a new Flavor with service_profiles, is not working
properly due the it showing empty service_profiles, I entered the
correct UUID of service_profiles, however the UUID of service_profiles
is empty.
2. And another happened when I try to update the existing of Flavor by
inserting the UUID of service_profiles, the 500 Internal Server Error
occured.
Here are my log from the first one (Creating new Falvor with
service_profiles) and then the second one (Update Existing Flavor by
Inserting service_profiles)
----------------------------
Creating a new Flavor with service_profiles
Request Command :
vagrant@ubuntu:~$ curl -g -i -X POST http://192.168.122.139:9696/v2.0/flavors -H "X-Auth-Token: $TOKEN" -d '{"flavor": {"service_type":"LOADBALANCER","enabled":"true"n$
HTTP/1.1 201 Created
Content-Type: application/json
Content-Length: 173
X-Openstack-Request-Id: req-6f3047a4-07e9-4dbe-b22a-b61ba167f705
Date: Mon, 25 Jul 2016 16:12:41 GMT
{"flavor": {"description": "", "enabled": true, "service_profiles":
[], "service_type": "LOADBALANCER", "id":
"79eaa203-5913-41b0-92c5-d6c2a0211a9c", "name": "flavor-test"}}
-----------------------------
Update Existing Flavor By Inserting service_profiles
Request Command :
vagrant@ubuntu:~$ curl -g -i -X PUT http://192.168.122.139:9696/v2.0/flavors/79eaa203-5913-41b0-92c5-d6c2a0211a9c -H "X-Auth-Token: $TOKEN" -d '{"flavor": {"enabled":"$
HTTP/1.1 500 Internal Server Error
Content-Type: application/json
Content-Length: 150
X-Openstack-Request-Id: req-d8581b95-a798-4d83-9980-414892553cd3
Date: Mon, 25 Jul 2016 17:18:56 GMT
2016-07-25 17:18:56.650 24207 DEBUG neutron.api.v2.base [req-b42a4171-1c3d-4e67-a375-c5ce7c08546b e01bc3eadeb045edb02fc6b2af4b5d49 867929bfedca4a719e17a7f3293845de ---] Request body: {u'flavor': {u'service_profiles': [u'8e843ed6-cbd0-4ede-b765-d98e765f1135'], u'enabled': u'false'}} prepare_request_body /opt/stack/neutron/neutron/api/v2/base.py:649
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource [req-b42a4171-1c3d-4e67-a375-c5ce7c08546b e01bc3eadeb045edb02fc6b2af4b5d49 867929bfedca4a719e17a7f3293845de- - -] update failed: No details.
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource Traceback (most recent call last):
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/opt/stack/neutron/neutron/api/v2/resource.py", line 79, in resource
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource result = method(request=request, **args)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/opt/stack/neutron/neutron/api/v2/base.py", line 571, in update
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource return self._update(request, id, body, **kwargs)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/oslo_db/api.py", line 148, in wrapper
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource ectxt.value = e.inner_exc
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/oslo_utils/excutils.py", line 220, in __exit__
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource self.force_reraise()
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/oslo_utils/excutils.py", line 196, in force_reraise
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource six.reraise(self.type_, self.value, self.tb)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/oslo_db/api.py", line 138, in wrapper
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource return f(*args, **kwargs)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/opt/stack/neutron/neutron/api/v2/base.py", line 617, in _update
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource obj = obj_updater(request.context, id, **kwargs)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/opt/stack/neutron/neutron/db/flavors_db.py", line 142, in update_flavor
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource fl_db.update(fl)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/oslo_db/sqlalchemy/models.py", line 94, in update
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource setattr(self, k, v)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/sqlalchemy/orm/attributes.py", line 224, in __set__
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource instance_dict(instance), value, None)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/sqlalchemy/orm/attributes.py", line 1027, in set
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource lambda adapter, i: adapter.adapt_like_to_iterable(i))
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/sqlalchemy/orm/attributes.py", line 1062, in _set_iterable
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource collections.bulk_replace(new_values, old_collection, new_collection)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/sqlalchemy/orm/collections.py", line 791, in bulk_replace
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource new_adapter.append_with_event(member)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/sqlalchemy/orm/collections.py", line 654, in append_with_event
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource self._data()._sa_appender(item, _sa_initiator=initiator)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/sqlalchemy/orm/collections.py", line 1073, in append
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource item = __set(self, item, _sa_initiator)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/sqlalchemy/orm/collections.py", line 1045, in __set
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource item = executor.fire_append_event(item, _sa_initiator)
2016-07-25 17:18:56.674 24207 ERROR neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/sqlalchemy/orm/collections.py", line 717, in fire_append_event
To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/1606431/+subscriptions
Follow ups