On 05/24/2016 12:55 PM, Samuel Henrique De Oliveira Guimaraes wrote:
-----Original Message-----
From: Aline Manera [mailto:alinefm@linux.vnet.ibm.com]
Sent: terça-feira, 24 de maio de 2016 11:40
To: Samuel Henrique De Oliveira Guimaraes <samuel.guimaraes(a)eldorado.org.br>;
sguimaraes943(a)gmail.com; Kimchi Devel <kimchi-devel(a)ovirt.org>
Subject: Re: [Kimchi-devel] [PATCH v4] [Kimchi] Storage Volume management
On 05/24/2016 10:27 AM, Samuel Henrique De Oliveira Guimaraes wrote:
> -----Original Message-----
> From: kimchi-devel-bounces(a)ovirt.org
> [mailto:kimchi-devel-bounces@ovirt.org] On Behalf Of Aline Manera
> Sent: segunda-feira, 23 de maio de 2016 17:41
> To: sguimaraes943(a)gmail.com; Kimchi Devel <kimchi-devel(a)ovirt.org>
> Subject: Re: [Kimchi-devel] [PATCH v4] [Kimchi] Storage Volume
> management
>
> Hi Samuel,
>
> Some comments:
>
> 1. When I switch to the "Gallery view" I can see all volumes selected
> and after one second, they are deselected
>
> Hi. I tried to reproduce this here but it is working fine. Tested with Firefox and
Chrome and watched for DOM changes and after a minute the checkboxes were still selected.
Even If I run an asynchronous task in another Storage Pool it won't change the volumes
in another Storage Pool.
I am saying, when you are in the storage volumes list view without any storage volume
selected and switch to the gallery view, all the storage volumes appear selected for a
second and then the page is refreshed to deselect all them.
Do you mean that black border that appears for a brief second? This is not happening on
Chrome but Firefox and IE indeed have this problem. I suspect it is because of the
border-color transition to "transparent", as Chrome supports RGBA while Firefox
and IE only supports RGB for transitions.
Yeap! It is exactly what I am seeing there.
> 2. When you select multiple volumes to perform an action, there
is no feedback to user that an operation will be done on those selected volumes.
> I can select others, deselect the ones I have selected before and so. We
should block the volume selected, add a loading icon, for example, and a mark check when
the operation is completed.
>
> I think my machine is running these tasks too fast so that's why I didn't
foresaw this as a requirement. I'll disable the checkboxes and add the spinner icon.
>
> 3. Usually we don't use success messages on Wok and its plugins. Any reason to
add them now?
>
> I've added some to System Services and OVS Bridges there was no feedback to the
user pointing a change in the tables or that an action was being performed but with
multiple selection sometimes it may render multiple messages in the area so I'll
remove them.
>
> 4. The message are duplicated. I can see 2 messages when trying to delete multiple
items "Volume selected were deleted" + "Volume X was successfully
deleted".
>
> See above.
>
> 5. The same messages for delete operation are shown when I wipe volumes.
>
> See above.
>
> 6. The wipe operation will change the allocation value and so it must be updated in
the volume box.
>
> You mean the Storage Pool line in the parent table? Once the wipe process is
completed the line is updated with 0.0B in the allocated column, however the parent %Used
and Allocated columns are not refreshed. Are these two the only fields that should be
updated? Should it be done for Clone and Delete as well?
I was talking about the storage volume settings. When I do wipe multiple volumes, only
one of them get the settings updated.
I've selected five different .qcow files and wiped them. According to chrome the list
refreshed 6 times, the last time when the selectedVolumes array is empty. For large files
displaying in MB when I wipe them, they immediately turn the "allocated" column
to 0.0B but If I choose to wipe a file in KB, the allocation and capacity has the same
value:
Before:
{
"allocation":131072,
"isvalid":false,
"capacity":127314,
"name":"0003-WOK-Deleting-unecessary-files-conflicting-with-new-u.patch",
"format":"raw",
"has_permission":true,
"path":"/root/Downloads/0003-WOK-Deleting-unecessary-files-conflicting-with-new-u.patch",
"used_by":[],
"type":"file"
},
After:
{
"allocation":131072,
"isvalid":true,
"capacity":131072,
"name":"0003-WOK-Deleting-unecessary-files-conflicting-with-new-u.patch",
"format":"raw",
"has_permission":true,
"path":"/root/Downloads/0003-WOK-Deleting-unecessary-files-conflicting-with-new-u.patch",
"used_by":[],
"type":"file"
}
They keep the same value for allocation and capacity.
With a large qcow file:
Before:
{
"allocation":1014439936,
"isvalid":true,
"capacity":8589934592,
"name":"2c2f4ef0-7ce0-4aad-b6c8-b891d21fbf40-0.qcow2",
"format":"qcow2",
"has_permission":true,
"path":"/var/lib/libvirt/images/2c2f4ef0-7ce0-4aad-b6c8-b891d21fbf40-0.qcow2",
"used_by":[
"vm1"
],
"type":"file"
}
After:
{
"allocation":0,
"isvalid":true,
"capacity":1014497280,
"name":"2c2f4ef0-7ce0-4aad-b6c8-b891d21fbf40-0.qcow2",
"format":"raw",
"has_permission":true,
"path":"/var/lib/libvirt/images/2c2f4ef0-7ce0-4aad-b6c8-b891d21fbf40-0.qcow2",
"used_by":[],
"type":"file"
}
Note that the wiped volume capacity has a little bit more of its previous allocation. Is
it correct?
About what you said, I agree we should update the storage pool settings as new volumes or
deleting volumes may change the storage pool allocation. I think only %used and allocated
must be updated.
Ok, will create a new function to replace the old values.
> 7. The scroll bar should only scroll the volumes. It is hard to get back all time to
have the Actions menu available.
>
> I'm ok with this for the list view appending a scrollbar on the "table"
element but with the Gallery view I think it looks odd. See attached screenshots.
IMO It is OK for me on both views (list and gallery).
Do you have any other idea to have the same behavior on gallery view which does not look
odd as you said?
I was trying to attach the scrollbar on the same position as it is today but this
doesn't work well with just CSS, I would have to write some lines in JS to keep this
parallax effect. I'll keep the same as the screenshots but with different max-height
values for list view and gallery view and the scrollbar attached to the tables.
If you could not find any other solution, I think we can go on how you
did in the screenshots you sent.
> I think that is all from my side.
>
> Regards,
> Aline Manera
>
> On 05/23/2016 12:46 PM, sguimaraes943(a)gmail.com wrote:
>> From: Samuel Guimarães <sguimaraes943(a)gmail.com>
>>
>> This patch adds Storage Volume management functions Wipe, Clone, Resize and
Delete with multiple selection. It also includes a filter input for each Storage Pool and
Gallery View for Storage Volumes.
>>
>> Changes from [RFC] version:
>>
>> v1:
>> - HTML and CSS
>>
>> v2:
>> - Delete and Wipe with multi-selection
>> - Confirm messages with list of selected volumes when wiping or deleting
volumes (requires SCSS/CSS patch sent to Wok)
>> - Filter working
>> - Removed "Add Volume" link from Storage Pool action button
>> - Added "Add Volume" to Volume box action button
>>
>> v3:
>> - Clone function working with multiple selection
>> - Progress bar working for clone and create volume
>> - Temporary volume added to the volumes when cloning
>> - Seamless refresh on the volumes once each task is finished
>> - Fixed issue when list wouldn't refresh when all volumes are removed
from the storage pool.
>>
>> v4:
>> - Prevent scroll when Drop-down in volumes list is clicked
>> - Dropdown is not clipped from volumes list when there's only one or two
items on the list
>> - Added Media Queries for small screen resolutions
>>
>> Samuel Guimarães (1):
>> Storage Volume management
>>
>> model/storagevolumes.py | 2 +-
>> ui/css/kimchi.css | 369 ++++++++++++++--
>> ui/css/src/modules/_storage.scss | 347 ++++++++++++---
>> ui/js/src/kimchi.api.js | 50 +++
>> ui/js/src/kimchi.storage_main.js | 465
+++++++++++++++++----
>> ui/js/src/kimchi.storagepool_add_volume_main.js | 2 +-
>> ui/js/src/kimchi.storagepool_resize_volume_main.js | 59 +++
>> ui/pages/i18n.json.tmpl | 6 +
>> ui/pages/storagepool-resize-volume.html.tmpl | 51 +++
>> ui/pages/tabs/storage.html.tmpl | 155 +++----
>> 10 files changed, 1249 insertions(+), 257 deletions(-)
>> create mode 100644 ui/js/src/kimchi.storagepool_resize_volume_main.js
>> create mode 100644 ui/pages/storagepool-resize-volume.html.tmpl
>>
> _______________________________________________
> Kimchi-devel mailing list
> Kimchi-devel(a)ovirt.org
>
http://lists.ovirt.org/mailman/listinfo/kimchi-devel