Bug 1398233 - You get thrown out and can't log back in, after deleting the default plan from the system
Summary: You get thrown out and can't log back in, after deleting the default plan fro...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-tripleo-ui
Version: 10.0 (Newton)
Hardware: Unspecified
OS: Unspecified
unspecified
urgent
Target Milestone: ---
: 10.0 (Newton)
Assignee: Jiri Tomasek
QA Contact: Ola Pavlenko
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-11-24 10:27 UTC by Udi Kalifon
Modified: 2017-01-12 19:16 UTC (History)
11 users (show)

Fixed In Version: openstack-tripleo-ui-1.0.5-2.el7ost
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-01-12 19:16:14 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Launchpad 1647625 0 None None None 2016-12-08 14:54:57 UTC
OpenStack gerrit 401351 0 None MERGED Fix roles listing for custom plan 2020-02-21 18:05:44 UTC

Description Udi Kalifon 2016-11-24 10:27:09 UTC
Description of problem:
I uploaded new plans and then deleted the "overcloud" plan. I was thrown out back to the login screen with this error message:

Failed to run Action
Error retrieving deployment plan: Environment not found [name=overcloud]

It's impossible to log back in - you immediately get thrown out again.


Version-Release number of selected component (if applicable):
openstack-tripleo-ui-1.0.5-1.el7ost.noarch


How reproducible:
100%


Steps to Reproduce:
1. Upload new plan(s)
2. Delete the default plan "overcloud" which came with the system
3. Switch to the deployment page


Actual results:
You get thrown out of the system and can't log back in


Expected results:
It should be possible to remove the default plan

Comment 1 Udi Kalifon 2016-11-24 10:36:41 UTC
To be able to log back in, I ran: openstack overcloud plan create overcloud

Comment 3 Florian Fuchs 2016-11-24 12:21:40 UTC
I can reproduce the bug. Applying this UI patch fixed it:

https://review.openstack.org/#/c/401351/

Comment 4 Jiri Tomasek 2016-11-24 12:33:53 UTC
I've updated https://review.openstack.org/#/c/401351/ to also fix a case when active plan got deleted.

Comment 5 Julie Pichon 2016-11-24 12:34:55 UTC
(This is the patch for fixing bug 1398205, for cross-reference).

Comment 9 Ana Krivokapic 2016-12-07 16:00:46 UTC
I can still reproduce this with the 2016-12-07.1 puddle and openstack-tripleo-ui-1.0.5-3.el7ost.noarch.

Comment 10 Jiri Tomasek 2016-12-08 12:24:09 UTC
So this should currently occur only on nodes page now. It is due to the fact that nodes page is trying to fetch Roles, and since there is no plan, it runs the Mistral action without plan specified, which in turn uses the default plan which is 'overcloud' but that one does not exist. Action will fail on that.

GUI should probably show the node tags directly rather than trying to fetch roles to get proper role name as nodes are not tied to the plan in any way.

The redirect to login is caused by how we handle redirect to login for Mistral errors. We need to improve this so that user gets redirected to login only on a specific Mistral error that resembles the 401 api response.

related upstream bug: https://bugs.launchpad.net/tripleo/+bug/1647625

Comment 13 Udi Kalifon 2017-01-05 09:58:15 UTC
I wasn't thrown out, but after logging out I could not log back in. I also couldn't re-create the default plan I deleted:

$ openstack overcloud plan create overcloud
Started Mistral Workflow. Execution ID: d8373933-b6f2-4600-84b7-bf1a175d7955
Exception creating plan: Unable to create plan. The Swift container already exists

This is from the browser's console when you try to log in after deleting the default plan:

logger.js:58 Error in LoginActions.authenticateUser 
XMLHttpRequest
onabort
:
null
onerror
:
null
onload
:
null
onloadend
:
null
onloadstart
:
null
onprogress
:
null
onreadystatechange
:
()
ontimeout
:
null
readyState
:
4
response
:
"{"error": {"message": "The request you have made requires authentication.", "code": 401, "title": "Unauthorized"}}"
responseText
:
"{"error": {"message": "The request you have made requires authentication.", "code": 401, "title": "Unauthorized"}}"
responseType
:
""
responseURL
:
"https://puma01.scl.lab.tlv.redhat.com:13000/v2.0/tokens"
responseXML
:
null
status
:
401
statusText
:
"Unauthorized"
timeout
:
0
upload
:
XMLHttpRequestUpload
withCredentials
:
false
__proto__
:
XMLHttpRequestEventTarget
error	@	logger.js:58
(anonymous function)	@	logger.js:149
dispatch	@	logger.js:142
_this3.(anonymous function)	@	logger.js:109
(anonymous function)	@	LoginActions.js:39
tryCatchReject	@	makePromise.js:845
runContinuation1	@	makePromise.js:804
Rejected.when	@	makePromise.js:625
Pending.run	@	makePromise.js:483
Scheduler._drain	@	Scheduler.js:62
Scheduler.drain	@	Scheduler.js:27
run	@	env.js:63

Comment 14 Udi Kalifon 2017-01-05 10:36:51 UTC
Please ignore my last comment, it was my fault because I was logged in to the wrong system via the GUI... The bug doesn't recreate with the latest GA bits (puddle 2016-12-22.1) so I'm marking the bug as VERIFIED.

Comment 15 Jon Schlueter 2017-01-11 19:26:24 UTC
According to our records, this should be resolved by openstack-tripleo-ui-1.0.5-3.el7ost.  This build is available now.

Comment 16 Jon Schlueter 2017-01-12 12:14:20 UTC
resetting to VERIFIED according to comment #14


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