Tomas Jelinek has posted comments on this change.
Change subject: webadmin: Disable new Pools popup when no Templates are
available
......................................................................
Patch Set 2:
(1 comment)
....................................................
File
frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/vms/NewPoolModelBehavior.java
Line 79: }
Line 80:
Line 81: @Override
Line 82: protected void templateValidate() {
Line 83: AsyncDataProvider.getAllVmTemplates(new AsyncQuery(getModel(),
new INewAsyncCallback() {
well, first of all AFAIK we are not moving to REST from 3.4 - at least not
entirely. Best what we can hope in is a POC on a simple entity like bookmarks -
but there is a loooong journey even to achieve that.
It is an open question how we are going to use the REST. If we decided to use
the REST in a very "clean" way, you are right, there is no other way. But in
practice it is far from being decided how we are going to use it. There are
challenges like:
- showing the e.g. VM with it's cluster and DC name on VM tab. But to do this
we would have to query the server for each cluster and DC for each VM (in worst
case 200 additional server calls each 5 secs).
- the problem you have here (you need one boolean and to have this you download
all the templates (BTW currently also with associated entities like disks))
...and some more...
There are several approaches to solve this and other issues and it is not yet
decided how to proceed. So until it is decided we don't really know how to make
the migration path easier so I would go with the most "correct" approach and
later adapt it during the migration to REST.
Long story short - I'm still for a separate query :)
Line 84: @Override
Line 85: public void onSuccess(Object model, Object returnValue) {
Line 86: List<VmTemplate> templates = (List<VmTemplate>)
returnValue;
Line 87: if(templates.size() <= 1) {
--
To view, visit http://gerrit.ovirt.org/21579
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Iacb121d2e89922b04b8331db92e437cefc8b6b5c
Gerrit-PatchSet: 2
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Kobi Ianko <[email protected]>
Gerrit-Reviewer: Kobi Ianko <[email protected]>
Gerrit-Reviewer: Tomas Jelinek <[email protected]>
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches