Bug 2211057 - Templates Catalog shows Default Templates incorrectly
Summary: Templates Catalog shows Default Templates incorrectly
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Container Native Virtualization (CNV)
Classification: Red Hat
Component: User Experience
Version: 4.13.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
: 4.14.0
Assignee: Hilda Stastna
QA Contact: Guohua Ouyang
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-05-30 11:31 UTC by Hilda Stastna
Modified: 2023-11-08 14:06 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-11-08 14:05:49 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Correct number of default templates in Templates list (161.63 KB, image/png)
2023-05-30 11:31 UTC, Hilda Stastna
no flags Details
Incorrect number of templates showed in Templates Catalog (214.39 KB, image/png)
2023-05-30 11:31 UTC, Hilda Stastna
no flags Details
Changing Default template to Templates can cause confusion (28.69 KB, image/png)
2023-06-19 11:32 UTC, Hilda Stastna
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Github kubevirt-ui kubevirt-plugin pull 1375 0 None open Bug 2211057: Display only Default templates in Catalog 2023-06-28 13:51:43 UTC
Red Hat Issue Tracker CNV-29281 0 None None None 2023-05-30 11:33:12 UTC
Red Hat Product Errata RHSA-2023:6817 0 None None None 2023-11-08 14:06:05 UTC

Description Hilda Stastna 2023-05-30 11:31:18 UTC
Created attachment 1967855 [details]
Correct number of default templates in Templates list

Description of problem:
Templates Catalog page does not show default templates correctly,
it shows some extra template(s) that should not be there, if the user creates some templates.

Version-Release number of selected component (if applicable):
4.13

How reproducible:
always

Steps to Reproduce:
1. Access Virtualization > Templates
2. Create a very simple template named "example" from the default yaml
3. Filter templates list to show only "Default Templates"
4. Now compare the result with Templates Catalog page, after clicking on "Default Templates"

Actual results:
The template "example" is present among "Default Templates" in Templates Catalog
page, which is wrong. It is not a default template. Also the number of items shows
there is one extra template, comparing to the list of "Default Templates" in Templates list,
which shows the templates correctly.

Expected results:
Only default templates are present in the Templates Catalog page, when displaying
"Default Templates".

Additional info:
Note that a template created from a "default" yaml is NOT a default template. 
The "default templates" are only Red Hat ones (a.k.a templates present in the Templates list
from the "beginning" of using OpenShift Virtualization, by default, not those that are
created by the user later).

Choose "All Projects" to correctly see all the templates, to correctly compare the number of templates in both pages.

Comment 2 Guohua Ouyang 2023-05-30 12:10:44 UTC
We definitely need to show user created templates in the catalog when it's opened.
The "Default Templates" means default-os-variant in common-templates, in catalog, we need to show both default-os-variant templates and user created templates, maybe we should change the term "Default Templates" in catalog.

Comment 3 Hilda Stastna 2023-05-30 12:24:08 UTC
(In reply to Guohua Ouyang from comment #2)
> We definitely need to show user created templates in the catalog when it's
> opened.
> The "Default Templates" means default-os-variant in common-templates, in
> catalog, we need to show both default-os-variant templates and user created
> templates, maybe we should change the term "Default Templates" in catalog.

If we want to show both default-os-variant templates and user created templates in catalog for "Default Templates",
we definitely need to change the name of the term we use, because it is inconsistent with what the user can see
in Templates list when showing just "Default Templates" (= common templates).

Comment 4 Hilda Stastna 2023-06-05 11:52:10 UTC
Hi Avital,

what do you think about this issue? What would you suggest? Thanks in advance!

Comment 5 Avital Pinnick 2023-06-07 09:17:49 UTC
Hilda, I assume that you are asking me about the terminology in the UI. I checked our documentation (https://docs.openshift.com/container-platform/4.13/virt/vm_templates/virt-creating-vm-template.html) and the terminology is very inconsistent:
----
The Templates page displays four types of virtual machine templates:
    * Red Hat Supported templates are fully supported by Red Hat.
    * User Supported templates are Red Hat Supported templates that were cloned and created by users.
    * Red Hat Provided templates have limited support from Red Hat.
    * User Provided templates are Red Hat Provided templates that were cloned and created by users.
----
I'm not sure we still have a distinction between "Supported" and "Provided", so those terms should probably be removed from the docs.

Re: default templates. The term "default" might not be clear to users. I suggest calling them "Red Hat templates" unless there is a good reason not to. (Note that "templates" should be lower case.) 

Re: user-created templates. This term sounds strange to me because the user is not creating a template but cloning a Red Hat template and then customizing it. Suggestion: "Customized templates". You could also call them "User-customized templates", but I think that "user" is unnecessary. A template can only be customized by a user.

> If we want to show both default-os-variant templates and user created templates in catalog for "Default Templates",
we definitely need to change the name of the term we use, because it is inconsistent with what the user can see
in Templates list when showing just "Default Templates" (= common templates).

I am not sure I understand what you mean. Are you saying that you want the UI to have a term that covers both Red Hat templates and user-customized templates (UI text)? Or are you saying that you want the "Default Templates" to show only the Red Hat templates (bug fix)? If you want a term for all templates in the UI, "Templates" would be the simplest solution.

Comment 6 Hilda Stastna 2023-06-07 11:46:58 UTC
Hi Avital,

the bug in the UI is that the user does not see the same set of templates when filtering templates by "Default Templates" in the templates list vs. when clicking on "Default Templates" in Catalog.
This is obviously not good, confusing. I am not sure we need to change naming of all the VM template types. The problem is only with "Default Templates". Anyway I do agree that the doc is inconsistent.
This is why I am asking you about your opinion. 

Unfortunately, I am not sure what is the solution because there are more ways how to solve this problem: to change the terminology for "Default Templates" in Catalog,
to stop displaying some templates that are being displayed in Catalog or maybe to work with UX to change the UI more significant way: maybe to add another section with another name to Catalog?
We need to make sure what exactly the term means, the term we decide to use in Catalog.

Guohua is saying:
"We definitely need to show user created templates in the catalog when it's opened.
The "Default Templates" means default-os-variant in common-templates, in catalog, we need to show both default-os-variant templates and user created templates, maybe we should change the term "Default Templates" in catalog."

So maybe we just need to decide how this set of templates we name. Note that with this change, we still will have "Default Templates" in templates list. If "Default Templates" is not clear to users,
then we probably need to change this term, too, but not calling 2 sets of templates the same name, sets that are not the same.

Comment 7 Hilda Stastna 2023-06-19 11:27:48 UTC
Avital,

we cannot change "Default templates" to "Templates" in Catalog. The user would see "Templates" and "All templates" in the page.
What could they think of this? See the attachment and you will realize why this is the problem. Thanks.

Comment 8 Hilda Stastna 2023-06-19 11:31:44 UTC
Correction: I meant "Templates" and "All items". It's confusing to see this in the UI, so we cannot use simple suggested term "Templates" in our UI.
We need something else, something more to provide to the user to let them know which items/templates they can see when clicking on this or that link in Catalog.

Comment 10 Avital Pinnick 2023-06-19 13:37:39 UTC
(In reply to Hilda Stastna from comment #8)
> Correction: I meant "Templates" and "All items". It's confusing to see this
> in the UI, so we cannot use simple suggested term "Templates" in our UI.
> We need something else, something more to provide to the user to let them
> know which items/templates they can see when clicking on this or that link
> in Catalog.

I see what you mean. What about "Red Hat templates" or "Provided templates"?

Comment 11 Hilda Stastna 2023-06-19 13:56:38 UTC
(In reply to Avital Pinnick from comment #10)
> (In reply to Hilda Stastna from comment #8)
> > Correction: I meant "Templates" and "All items". It's confusing to see this
> > in the UI, so we cannot use simple suggested term "Templates" in our UI.
> > We need something else, something more to provide to the user to let them
> > know which items/templates they can see when clicking on this or that link
> > in Catalog.
> 
> I see what you mean. What about "Red Hat templates" or "Provided templates"?

I don't think it's appropriate, according to what was mentioned in Comment 2.

Comment 12 Yifat Menchik 2023-06-20 11:03:30 UTC
Just to clarify a bit about the terminology:
Default templates mean the recommended setting per each OS that Red Hat provides.
Common templates mean the templates that Red Hat provides.
Customized templates mean the templates that the user provides.

Comment 13 Yifat Menchik 2023-06-20 15:22:36 UTC
I am wondering if we should keep the distinction between:
- All items
- Default templates 

Maybe it can be simplified by having it all under one title: "Templates" and then enable filtering options next to the [] Boot source available, 
for example: 
[] Default templates + explanation "templates with recommended settings per each OS that Red Hat provides"
[] Common templates + explanation "templates provided by Red Hat and automatically updated"
[] Custom templates + explanation "templates customized by the user" 

WDYT @rsdeor @apinnick @hstastna

Comment 14 Ronen 2023-06-25 12:53:58 UTC
The issue we have is that when cloning an existing template (default or non-default), the template will show up as a default template in the catalog even if "default-os-variant" does not exist.
We need to fix the filter.

Comment 15 Hilda Stastna 2023-06-26 09:48:32 UTC
So from what I understand, we don't need to rename anything, just really to show
default templates when user displays "Default Templates" in Catalog,
as it was originally mentioned in the description of this bug.

One more question: Avital, Yifat, shouldn't we better use the sentence case "Default templates"? 
Or is "Default Templates" some kind of exception and so it is the correct one? Thanks!

Comment 16 Yifat Menchik 2023-06-26 13:29:24 UTC
@hstastna I think it should be "Default templates", as @apinnick mentioned in comment #5 "Note that "templates" should be lower case".

Comment 17 Avital Pinnick 2023-07-03 10:34:40 UTC
Hilda, "Default templates" is the correct capitalization.

Comment 18 Guohua Ouyang 2023-07-12 08:58:37 UTC
(In reply to Ronen from comment #14)
> The issue we have is that when cloning an existing template (default or
> non-default), the template will show up as a default template in the catalog
> even if "default-os-variant" does not exist.
> We need to fix the filter.

Hi Ronen,
With this change, it becomes hard for user to filter out their own templates, which can be a big problem in my opinion?
Could you please review this again?

Thanks

Comment 19 Ronen 2023-07-19 10:13:33 UTC
I think that what we might be missing is the ability to better filter templates.
The option to filter templates per namespace is already there, so if customers that use custom templates will put them in another namespace, they will be able to easily find them.

We may consider adding the option to filter by "Red Hat templates" and "User templates" to the "Default templates" and "All items" filter, but we need to see if this will not overload the filter.
I think this is more an RFE than a bug (unless this is a regression)

Comment 20 Guohua Ouyang 2023-07-25 05:19:37 UTC
I think it's better to add an option "User templates" along with the "All items" and "Default templates", so it will look like:

- All items
- Default templates
- User templates

Opened an issue: https://issues.redhat.com/browse/CNV-31327

Comment 21 Guohua Ouyang 2023-07-25 05:20:37 UTC
Move the issue to verified as the original issue is fixed

Comment 23 errata-xmlrpc 2023-11-08 14:05:49 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Important: OpenShift Virtualization 4.14.0 Images security and bug fix update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2023:6817


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