[openstack-dev] [OpenStack-dev][Fuel][Plugin]

Julia Aranovich jkirnosova at mirantis.com
Fri Oct 21 09:19:40 UTC 2016


Hi Nidhi,

This implemented https://blueprints.launchpad.net/fuel/+spec/dynamic-fields
blueprint provided an ability to use "text_list" and "textarea_list" UI
control types.
They are suitable for settings where the value is a list of strings.
These controls represent on UI a list of single or multiline text inputs
with +/- buttons to add/remove an additional element:

My Setting      value1 +/-
                       value2 +/-
                       value3 +/-
(the result value for the setting "My Setting" is ['value1', 'value2',
'value3']).


If I understand your case properly, you need something like dynamic groups
of inputs of different type.
This is still not supported by Fuel UI. The implementation does not look
simple, it requires changing of data structure in settings yaml, adding a
new level of nesting. There is a need to think thoroughly about the
details: how to organize such a setting yaml structure, how to declare a
set of inputs in such a group, how inputs should be aligned in the group
(horizontally/vertically), etc.

For now, I would suggest the following ways of how to organize your plugin
settings:

1) use text_list/textarea_list controls for each field from a group that
represents storage backend configuration:

Field1  value_for_backend_1 +/-
            value_for_backend_2 +/-
            value_for_backend_3 +/-

Field2  value_for_backend_1 +/-
            value_for_backend_2 +/-
            value_for_backend_3 +/-

Field3  value_for_backend_1 +/-
            value_for_backend_2 +/-
            value_for_backend_3 +/-

2) use text_list/textarea_list controls to configure a list of storage
backends by declaring their settings as a single comma-separated string:

Backends Settings    comma_separated_settings_for_backend_1 +/-
                    comma_separated_settings_for_backend_2 +/-
                                  comma_separated_settings_for_backend_3 +/-

>From my point of view, the first version looks more clear. Will it
suit your case, Nidhi?


Best regards,
Julia

On Fri, Oct 21, 2016 at 8:17 AM <nidhi.hada at wipro.com> wrote:

> Hi All,
>
>
> This is regarding an info required for fuel plugin development.
>
> We are working on Fuel Cinder Plugin where we require to
>
> configure multiple 'n' number of backends of storage vendor ,
>
> in one go, from Fuel UI screen. where 'n' will be known at run time.
>
>
> Its like from UI, I can configure a set of fields, [field1, field2,
> field3]
>
> for one backend and if user ask to configure 'n' backends then same
>
> set of fields to be asked repeatedly.
>
>
> I have found some similar provision was planned in
>
> https://blueprints.launchpad.net/fuel/+spec/dynamic-fields
>
>
> But when i see implementation
> https://review.openstack.org/#/q/topic:bp/dynamic-fields,n,z
>
> which implements new type as text_list and textarea_list ..
>
> which is capability to add multiple lines of text in single field..
>
>
> It does not look like same as aim of BP, where acceptance criteria for BP
> is
>
> "Enable text and textarea field types to be extended - where a plugin user
> is able to toggle the visibility of additional fields with +/- signs and
> the data provided is used by plugin"
>
>
> Kindly correct my understanding if its wrong, do we have capability to add
> a text field by pressing +/- ?
>
> What capability do we have with Fuel UI to add fields dynamically today ?
>
>
> I have read
> https://openstack.nimeyo.com/44264/openstack-dev-fuel-interaction-between-fuel-plugin-and-fuel
>
> [openstack-dev] [Fuel] interaction between fuel-plugin and fuel-UI -
> OpenStack Mailing List Archive
> <https://openstack.nimeyo.com/44264/openstack-dev-fuel-interaction-between-fuel-plugin-and-fuel>
> openstack.nimeyo.com
> Hi all, I am working on two plugins for fuel : logrotate and cinder-netapp
> (to add ... /lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
>
> where suggestions are made to use restrictions to hide display components.
>
>
> Another suggestion is to use comma separated values.
>
>
> But its an year back post, do we have a better solution today ?
>
>
> Will be helpful if someone can suggest how do we achieve it in fuel UI.
>
>
>
> Thanks
>
> Nidhi
>
>
>
>
>
>
>
> The information contained in this electronic message and any attachments
> to this message are intended for the exclusive use of the addressee(s) and
> may contain proprietary, confidential or privileged information. If you are
> not the intended recipient, you should not disseminate, distribute or copy
> this e-mail. Please notify the sender immediately and destroy all copies of
> this message and any attachments. WARNING: Computer viruses can be
> transmitted via email. The recipient should check this email and any
> attachments for the presence of viruses. The company accepts no liability
> for any damage caused by any virus transmitted by this email.
> www.wipro.com
> __________________________________________________________________________
> OpenStack Development Mailing List (not for usage questions)
> Unsubscribe: OpenStack-dev-request at lists.openstack.org?subject:unsubscribe
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20161021/1848bace/attachment.html>


More information about the OpenStack-dev mailing list