You can click button "Stop Tests" many times and it's behaviour is strange

Bug #1384260 reported by Anastasia Palkina
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
Fix Released
Medium
Fuel UI Team

Bug Description

"build_id": "2014-10-22_00-01-06",
"ostf_sha": "de177931b53fbe9655502b73d03910b8118e25f1",
"build_number": "36",
"auth_required": true,
"api": "1.0",
"nailgun_sha": "f4bf25da24c4e5b0d9eb86493945200deba3d92e",
"production": "docker",
"fuelmain_sha": "dab17913263bbea7e9a3b55de8a0f3af5ac0e3e2",
"astute_sha": "6a11a7c481d116e6cfdb422fab1d4bbb29cbea1c",
"feature_groups": ["mirantis"], "release": "6.0", "release_versions": {"2014.2-6.0": {"VERSION": {"build_id": "2014-10-22_00-01-06", "ostf_sha": "de177931b53fbe9655502b73d03910b8118e25f1", "build_number": "36", "api": "1.0", "nailgun_sha": "f4bf25da24c4e5b0d9eb86493945200deba3d92e", "production": "docker", "fuelmain_sha": "dab17913263bbea7e9a3b55de8a0f3af5ac0e3e2", "astute_sha": "6a11a7c481d116e6cfdb422fab1d4bbb29cbea1c", "feature_groups": ["mirantis"], "release": "6.0", "fuellib_sha": "af2bf11d4a3a075fa4e9fa9b7b7209af29498a46"}}},
"fuellib_sha": "af2bf11d4a3a075fa4e9fa9b7b7209af29498a46"

1. Deploy any environment
2. Open Health Check tab
3. Start Sanity tests
4. Click button "Stop tests"
5. Button has a strange behaviour and you can click it many times (see video)

Revision history for this message
Anastasia Palkina (apalkina) wrote :
Changed in fuel:
assignee: Fuel UI Team (fuel-ui) → Alexandra Morozova (astepanchuk)
Revision history for this message
Matthew Mosesohn (raytrac3r) wrote :

It resets to let you start tests again after about a minute. After any individual test, the button never resets back on its own.

Changed in fuel:
status: New → Confirmed
Revision history for this message
Alexandra Morozova (astepanchuk) wrote :

This strange behavior seems to be cased by backed. Need assistance from OSTF team. Added a small fix https://review.openstack.org/#/c/130837

Changed in fuel:
status: Confirmed → In Progress
Revision history for this message
Dima Shulyak (dshulyak) wrote :

Please attach diagnostic snapshot or paste with error message.

Changed in fuel:
status: In Progress → Incomplete
Changed in fuel:
assignee: Alexandra Morozova (astepanchuk) → Anastasia Palkina (apalkina)
Revision history for this message
Anastasia Palkina (apalkina) wrote :

I did "Stop Tests" for cluster #2

[root@fuel ~]# fuel node
id | status | name | cluster | ip | mac | roles | pending_roles | online
---|----------|------------------|---------|-------------|-------------------|---------------------------|---------------|-------
1 | ready | Untitled (86:fc) | 1 | 10.20.0.3 | 08:00:27:10:86:fc | ceph-osd, controller | | True
10 | ready | Untitled (b3:11) | 1 | 10.20.0.7 | 08:00:27:99:b3:11 | ceph-osd, compute | | True
3 | ready | Untitled (ca:83) | 1 | 10.20.0.5 | 08:00:27:e5:ca:83 | mongo | | True
4 | ready | Untitled (0b:4f) | 1 | 10.20.0.6 | 08:00:27:eb:0b:4f | mongo | | True
2 | ready | Untitled (0e:25) | 1 | 10.20.0.4 | 08:00:27:bd:0e:25 | ceph-osd, cinder | | True
8 | ready | Untitled (71:fc) | 2 | 10.20.0.11 | 42:c1:11:89:19:49 | ceph-osd | | True
5 | ready | Untitled (a0:bf) | 2 | 10.20.0.8 | 66:d6:c9:5e:f4:4f | controller, mongo | | True
6 | ready | Untitled (26:02) | 2 | 10.20.0.9 | 72:da:41:59:2f:4d | ceph-osd, cinder, compute | | True
7 | ready | Untitled (65:47) | 2 | 10.20.0.10 | de:d1:9d:ca:95:49 | cinder, mongo | | True
9 | discover | Untitled (87:71) | None | 10.20.0.132 | 08:00:27:1c:87:71 | | | True

Changed in fuel:
assignee: Anastasia Palkina (apalkina) → Alexandra Morozova (astepanchuk)
Changed in fuel:
status: Incomplete → Confirmed
assignee: Alexandra Morozova (astepanchuk) → Dima Shulyak (dshulyak)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to fuel-web (master)

Reviewed: https://review.openstack.org/130837
Committed: https://git.openstack.org/cgit/stackforge/fuel-web/commit/?id=43f2ccb201a43985a7d073f6889ab586f6b93b8f
Submitter: Jenkins
Branch: master

commit 43f2ccb201a43985a7d073f6889ab586f6b93b8f
Author: Alexandra Morozova <email address hidden>
Date: Fri Oct 24 17:58:14 2014 +0200

    Added error server response handling on Healthcheck tab

    Related-bug: #1384260

    Change-Id: Iade29275b9f569f05313633c10128be325df0c71

Dima Shulyak (dshulyak)
Changed in fuel:
assignee: Dima Shulyak (dshulyak) → Fuel Python Team (fuel-python)
milestone: 6.0 → 6.1
tags: added: ostf
Dmitry Pyzhov (dpyzhov)
tags: added: module-ostf
removed: ostf ui
Dmitry Pyzhov (dpyzhov)
tags: added: ui
Dmitry Pyzhov (dpyzhov)
Changed in fuel:
milestone: 6.1 → 7.0
tags: added: qa-agree-7.0
tags: removed: ui
tags: added: ui
tags: removed: module-ostf
tags: added: module-astute
removed: ui
Revision history for this message
Vladimir Sharshov (vsharshov) wrote :

UX problem. Do not affect deployment. Moving to 8.0

Also i think that problem between UI and module-nailgun.

Changed in fuel:
status: Confirmed → Won't Fix
tags: added: module-nailgun ostf ui
removed: module-astute
Dmitry Pyzhov (dpyzhov)
Changed in fuel:
milestone: 7.0 → 8.0
status: Won't Fix → Confirmed
no longer affects: fuel/8.0.x
Dmitry Pyzhov (dpyzhov)
tags: added: area-python
Changed in fuel:
milestone: 8.0 → 9.0
Revision history for this message
Krzysztof Szukiełojć (kszukielojc) wrote :

It looks like this. UI asks backend to stop and changes the icon to "run". After that it asks for the status and recives "running" for at least part of the tests. Which make it change to icon "stop". After few more minutes it recives status with all tests finished and it changes icon to "run".
For me it seems that UI doesn't understand state between "run" and "stop" like "pending" and expects backend to give "stopped" for all test right after it was asked to stop.

Revision history for this message
Vitaly Kramskikh (vkramskikh) wrote :

Can UI somehow determine this "pending" state using current API output?

Revision history for this message
Valentin Kaplov (vkaplov) wrote :

Backend doesn't send 'pending' state. There are two states from backend: 'running' and 'finished'.
Looks like cause of issue in request
PUT ostf/testruns
[{"id":1, "status":"stopped"}]

UI switches button icon from "Stop" to "Run" right after request and before the response. After 200ms UI gets response from backend like this:
[{"status": "running", "tests": ....}]
and switches button icon back from "Run" to "Stop".

So need to switch button icon after getting response only if in response 'status' == 'finished'.

Changed in fuel:
assignee: Fuel Python Team (fuel-python) → Fuel UI Team (fuel-ui)
Changed in fuel:
assignee: Fuel UI Team (fuel-ui) → Alexandra Morozova (astepanchuk)
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/271293

Changed in fuel:
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-web (master)

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

commit 78e3382e11cb32b31263a6a89c672bea155ba2c2
Author: Alexandra Morozova <email address hidden>
Date: Tue Jan 26 10:42:45 2016 +0100

    Fix for "Stop tests" button incorrect behavior

    due to immediate response from server after stopping OSTF tests
    returns 'stopped' state for testruns and the next polled
    responses return 'running' state for testruns up to the
    moment the tests are actually stopped, - added check for 'stopped' and
    'running' testruns state and also
    added 'stoppingTestsInProgress' state in order to
    disable 'stop tests' button until testruns are finished

    Closes-bug: #1384260
    Change-Id: I008aa9c0fe2f419e7eb4c63fc14678f8c324fd8b

Changed in fuel:
status: In Progress → Fix Committed
tags: added: area-ostf
removed: ostf
tags: added: on-verification
Revision history for this message
Grigory Mikhailov (gmikhailov) wrote :

Seems like "Stop tests" button behavior is not worked properly.
User can stop Sanity tests (or any other) but once. Next time "Stop" button will be anavailable.

Steps to reproduce:
1. Deploy any environment
2. Open Health Check tab
3. Start Sanity tests
4. Click button "Stop tests"
5. Start Sanity tests again (or any other tests)
6. Click button "Stop tests"

Expected result:
"Stop tests" button available and stop tests execution.

Actual result:
"Stop tests" button unavailable. User can not stop tests execution more than one time.

Screenshots and snapshot in attach.

[root@nailgun ~]# shotgun2 short-report
cat /etc/fuel_build_id: 509
cat /etc/fuel_build_number: 509
cat /etc/fuel_release: 9.0
cat /etc/fuel_openstack_version: mitaka-9.0
rpm -qa | egrep 'fuel|astute|network-checker|nailgun|packetary|shotgun':
 fuel-release-9.0.0-1.mos6349.noarch
 fuel-misc-9.0.0-1.mos8460.noarch
 python-packetary-9.0.0-1.mos140.noarch
 fuel-bootstrap-cli-9.0.0-1.mos285.noarch
 fuel-migrate-9.0.0-1.mos8460.noarch
 rubygem-astute-9.0.0-1.mos750.noarch
 fuel-mirror-9.0.0-1.mos140.noarch
 shotgun-9.0.0-1.mos90.noarch
 fuel-openstack-metadata-9.0.0-1.mos8743.noarch
 fuel-notify-9.0.0-1.mos8460.noarch
 nailgun-mcagents-9.0.0-1.mos750.noarch
 python-fuelclient-9.0.0-1.mos325.noarch
 fuel-9.0.0-1.mos6349.noarch
 fuel-utils-9.0.0-1.mos8460.noarch
 fuel-setup-9.0.0-1.mos6349.noarch
 fuel-provisioning-scripts-9.0.0-1.mos8743.noarch
 fuel-library9.0-9.0.0-1.mos8460.noarch
 network-checker-9.0.0-1.mos74.x86_64
 fuel-agent-9.0.0-1.mos285.noarch
 fuel-ui-9.0.0-1.mos2717.noarch
 fuel-ostf-9.0.0-1.mos936.noarch
 fuelmenu-9.0.0-1.mos274.noarch
 fuel-nailgun-9.0.0-1.mos8743.noarch

Revision history for this message
Grigory Mikhailov (gmikhailov) wrote :
Revision history for this message
Grigory Mikhailov (gmikhailov) wrote :
Revision history for this message
Grigory Mikhailov (gmikhailov) wrote :
Revision history for this message
Grigory Mikhailov (gmikhailov) wrote :
Changed in fuel:
status: Fix Committed → Confirmed
tags: removed: on-verification
Changed in fuel:
assignee: Alexandra Morozova (astepanchuk) → Fuel UI Team (fuel-ui)
Revision history for this message
Grigory Mikhailov (gmikhailov) wrote :

Seems like initial bug was fixed.
Another new bug exists, will create another.

Changed in fuel:
status: Confirmed → Fix Released
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.