cloudstack-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Koushik Das <>
Subject Re: [PROPOSAL] List VM API enhancement
Date Fri, 07 Feb 2014 19:19:37 GMT
I looked at and see the following.
Prachi, Are you referring to this or anything else?

    public long getEntityOwnerId() {
        // no owner is needed for list command
        return 0;

On 08-Feb-2014, at 12:02 AM, Prachi Damle <<>>

Yes, agree to this as well.
Accordingly we need to handle the getEntityOwnerId() dependency.

-----Original Message-----
From: Alex Huang [<>]
Sent: Friday, February 07, 2014 10:06 AM
Subject: RE: [PROPOSAL] List VM API enhancement

+1 It's confusing to have id and ids all over the place.  We should just say all ids can come
in arrays by default.


-----Original Message-----
From: Min Chen [<>]
Sent: Friday, February 7, 2014 9:56 AM
Subject: Re: [PROPOSAL] List VM API enhancement

Hi Koushik,

I agree with the idea of supporting multiple IDs. But I may not like
the idea of introducing another different query parameter "ids" for this purpose.
Why cannot we just change current "id" parameter to take a list of values?
This way, user will not need to use two different parameters for
single or multiple cases. Maintaining two different parameters for
similar purpose is error-prone. If you look at Amazon EC2 api, you
will notice that they are also using the similar convention, id parameter can be one or more.


On 2/6/14 3:24 AM, "Koushik Das" <<>>

Yes it will be like a findByIds() and the one id case is just a
special case for this.

On 06-Feb-2014, at 4:24 PM, Daan Hoogland <<>>

looks nice, it will be backed by the current query for one id? or
will you write a findByIds()?

On Thu, Feb 6, 2014 at 9:35 AM, Abhinandan Prateek
<<>> wrote:
+1, The listVM call is one of the most resource intensive call.
to optimise it are welcome.

On 06/02/14 2:01 pm, "Koushik Das" <<>>

Currently list VM can only be called using a single VM ID. So if
there is  a need to query a set of VMs using ID then either
multiple list VM calls  need to be made or all VMs needs to be
fetched and then do a client side  filtering. Both approaches are
sub-optimal - the former results in  multiple queries to database
and the latter will be an overkill if you  need a small subset
from a very large number of VMs.

The proposal is to have an additional parameter to specify a list
of VM  IDs for which the data needs to be fetched. Using this the
required VMs  can be queried in an efficient manner. With the new
parameter the syntax  would look like



The new 'ids' parameter will be mutually exclusive with the
existing 'id'

Let me know if there are any concerns/comments.



  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message