Cross-plugin display restrictions for some plugins prevent Settings tab from opening

Bug #1538617 reported by Dmitriy Kruglov on 2016-01-27
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
Medium
Fuel Plugins Bugs

Bug Description

The following plugins have display restrictions due to their dependencies on other plugins:
- fuel-plugin-detach-keystone (depends on fuel-plugin-detach-database one)
- fuel-plugin-zabbix-snmptrapd (depends on fuel-plugin-external-zabbix one)
- fuel-plugin-zabbix-monitoring-emc (depends on fuel-plugin-zabbix-snmptrapd one)
- fuel-plugin-zabbix-monitoring-extreme-networks (depends on fuel-plugin-zabbix-snmptrapd one)

Currently display restriction for these plugins is defined in a way that will prevent Settings tab from rendering, if the corresponding plugin-dependecy is not already installed.

Steps to reproduce:
1 On Fuel master install a plugin (from the above mentioned list), but not install the dependency
2 In Fuel UI create an environment, navigate to Settings tab

Expected result: Settings tab is opened, on Other section the plugin is displayed as disabled (plugin selection checkbox is inactive) and has a yellow triangle with a pop-up warning
Actual result: Settings tab is not rendered, the following js error can be observed via browser devtools "Uncaught TypeError: Value of settings:detach-database.metadata.enabled is undefined. Set options.strict to false to allow undefined values."

=========

The RC is likely that the condition restriction (defined in environment_config.yaml file) tries to evaluate a non-existing key of plugin metadata (due to the specified plugin is not installed) e.g.

    restrictions:
      - condition: "settings:detach-database.metadata.enabled == false"
        message: "Detach Database plugin should be installed and enabled."

However the following condition works well (and this is how it is documented in Fuel plugins wiki):

    restrictions:
      - condition: "settings:detach-database == null or settings:detach-database.metadata.enabled == false"
        strict: false
        message: "Detach Database plugin should be installed and enabled."

description: updated

Which MOS release is this bug about?

Dmitriy Kruglov (dkruglov) wrote :

It was reproduced on MOS 8.0, build 481.
Particularly against detach-keystone plugin as it has the updated metadata.yaml, with the appropriate openstack release - liberty-8.0.
Other mentioned plugins should have the described behavior on the corresponding MOS releases, mentioned in their metadata.yaml.

are these plugins compatible with 8.0? I've only seen the 7.0 ones.

Dmitriy Kruglov (dkruglov) wrote :

As there is no 8.0 officially yet we cannot say that any plugin is compatible with it.
At least detach-keystone one is installable out-of-box on 8.0 dev ISOs at the moment, it has liberty-8.0 in his releases list.

I'm not familiar with plugins release cycle - i see for example that for Zabbix plugins there is a PROD ticket that will result in producing 8.0 compatible plugins. Should we wait for this ticket (or similar for other plugins) to move to 'in qa' state before raising issues against it? (and postpone the current one)

Dmitry, please see the page (sorry, it is available only for Mirantis enginers now):
https://mirantis.jira.com/wiki/display/PROD/Plugin+Source+of+Truth+-+8.0+plugins

Dmitriy,

we don't have any GA plugins compatible with 8.0 MOS yet because we need to wait till 8.0 GA is out and then validate/test.
I suppose, we can:
1) try reproducing this bug with 8.0 build of the Fuel Plugins under development for 8.0 now (e.g. DVS plus smth else)
2) try reproducing once they're ready-to-go (shortly before 8.0 GA).

does this seem reasonable for you?

Dmitriy Kruglov (dkruglov) wrote :

Thank you for the update, Irina. I see the point now.

I suppose the 2nd option would be better, i.e. continue with the issue once plugins with the described restriction are 8.0 ready.

Fixes committed for review for the 3 Zabbix plugins

Changed in fuel:
status: New → In Progress
Changed in fuel:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers