[nailgun] Internal Server Error 500 is returned on an attempt to start a deployment when another 'deployment' or 'provisioning' task is active

Bug #1592309 reported by Dmitriy Kruglov
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
Fix Committed
Medium
Georgy Kibardin
Mitaka
Fix Released
Medium
Georgy Kibardin

Bug Description

Detailed bug description:
In case a 'deployment' or 'provisioning' task is in progress and an operator tries to start another deployment, this attempt is validated but the error message is too generic for the operator to understand what happened.

Steps to reproduce:
1. Create an HA env, e.g. 3 controllers + 1 compute
2. Shutdown a controller
3. Wait until the node goes offline
4. Remove the node and start deploying changes, using API call
curl -X "DELETE" http://localhost:8000/api/nodes/<NODE_ID> -H "X-Auth-Token: <AUTH_TOKEN>")
5. Do not wait for deployment end, add a new controller node and start deploying changes
> fuel --env <ENV_ID> node set --node <NODE_ID> --role controller
> fuel --env <ENV_ID> deploy-changes

Expected result: a user friendly error message is thrown giving the operator understanding of what error was made.
Actual result: a generic error message is thrown, which does not describe what happened - '500 Server Error: Internal Server Error for url: http://10.109.0.2:8000/api/v1/clusters/1/changes?dry_run=0 (Unexpected exception, please check logs)'

Description of the environment:
MOS 9.0, ISO #467.

Tags: area-python
Dmitry Pyzhov (dpyzhov)
tags: added: area-python
no longer affects: fuel/newton
Dmitry Klenov (dklenov)
Changed in fuel:
status: New → Confirmed
Changed in fuel:
assignee: Fuel Sustaining (fuel-sustaining-team) → Georgy Kibardin (gkibardin)
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-web (master)

Fix proposed to branch: master
Review: https://review.openstack.org/330945

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-web (master)

Reviewed: https://review.openstack.org/330945
Committed: https://git.openstack.org/cgit/openstack/fuel-web/commit/?id=d723ecbaa4897e68abebf103364919f0b8326ec7
Submitter: Jenkins
Branch: master

commit d723ecbaa4897e68abebf103364919f0b8326ec7
Author: Georgy Kibardin <email address hidden>
Date: Fri Jun 17 11:19:31 2016 +0300

    Business exceptions produce error code 400

    NailgunException descendants now produce http errors with code 400 and
    exception text included.

    Change-Id: Ic5d230d4a4b92228aae74161c1bcf8e14b2167f3
    Closes-Bug: #1592309

Changed in fuel:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-web (stable/mitaka)

Fix proposed to branch: stable/mitaka
Review: https://review.openstack.org/355770

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-web (stable/mitaka)

Reviewed: https://review.openstack.org/355770
Committed: https://git.openstack.org/cgit/openstack/fuel-web/commit/?id=f1124742c65d72c1a772a2a58666abd175acf8fc
Submitter: Jenkins
Branch: stable/mitaka

commit f1124742c65d72c1a772a2a58666abd175acf8fc
Author: Georgy Kibardin <email address hidden>
Date: Fri Jun 17 11:19:31 2016 +0300

    Business exceptions produce error code 400

    NailgunException descendants now produce http errors with code 400 and
    exception text included.

    Change-Id: Ic5d230d4a4b92228aae74161c1bcf8e14b2167f3
    Closes-Bug: #1592309
    (cherry picked from commit d723ecbaa4897e68abebf103364919f0b8326ec7)

tags: added: on-verification
Revision history for this message
Dmitry Belyaninov (dbelyaninov) wrote :

Verified on snapshot #171

tags: removed: on-verification
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.