[Engine-devel] Polling vs Pushing engine events

2013-12-17 Thread Sven Kieske
Hi,

we got the following problem:

we create / start / stop
hole vms /data centers / storage etc
(basically: everything ovirt can handle
via REST-API)

But if you want to know e.g. the status
of a vm (or anything) you need to constantly
poll the API.

This is not what we desire to do, as it
does not scale very well (e.g. polling
100 vms).

Is there a standardized way of pushing information
from the engine?


-- 
Mit freundlichen Grüßen / Regards

Sven Kieske

Systemadministrator
Mittwald CM Service GmbH & Co. KG
Königsberger Straße 6
32339 Espelkamp
T: +49-5772-293-100
F: +49-5772-293-333
https://www.mittwald.de
Geschäftsführer: Robert Meyer
St.Nr.: 331/5721/1033, USt-IdNr.: DE814773217, HRA 6640, AG Bad Oeynhausen
Komplementärin: Robert Meyer Verwaltungs GmbH, HRB 13260, AG Bad Oeynhausen
___
Engine-devel mailing list
Engine-devel@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-devel


Re: [Engine-devel] Polling vs Pushing engine events

2013-12-17 Thread Itamar Heim

On 12/17/2013 03:08 AM, Sven Kieske wrote:

Hi,

we got the following problem:

we create / start / stop
hole vms /data centers / storage etc
(basically: everything ovirt can handle
via REST-API)

But if you want to know e.g. the status
of a vm (or anything) you need to constantly
poll the API.

This is not what we desire to do, as it
does not scale very well (e.g. polling
100 vms).


well, you can search events since last event you searched for, only for 
the specific type of event you are interested in, then check which vm 
its for.




Is there a standardized way of pushing information
from the engine?




well, the notification service which sends emails on these actually 
polls for them every minute in order to send the emails.


we are discussing snmptraps here[1]
one of the options this could be implemented with is via log4j getting 
all the audit log events, then you could use any log4j appender (db 
table, jms queue, etc.)


[1] Bug 1032661 - Add SNMP trap as notification method to to 
ovirt-engine-notification

___
Engine-devel mailing list
Engine-devel@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-devel


Re: [Engine-devel] Polling vs Pushing engine events

2013-12-17 Thread Liran Zelkha
Note that you can usually get all the information you want using 1 API
call, which should still scale.
For instance, /ovirt-engine/api/vms will give you a list of all VMs and
their statuses, so you can just run an XPath and get the status of all of
them.


On Tue, Dec 17, 2013 at 10:18 AM, Itamar Heim  wrote:

> On 12/17/2013 03:08 AM, Sven Kieske wrote:
>
>> Hi,
>>
>> we got the following problem:
>>
>> we create / start / stop
>> hole vms /data centers / storage etc
>> (basically: everything ovirt can handle
>> via REST-API)
>>
>> But if you want to know e.g. the status
>> of a vm (or anything) you need to constantly
>> poll the API.
>>
>> This is not what we desire to do, as it
>> does not scale very well (e.g. polling
>> 100 vms).
>>
>
> well, you can search events since last event you searched for, only for
> the specific type of event you are interested in, then check which vm its
> for.
>
>
>> Is there a standardized way of pushing information
>> from the engine?
>>
>>
>>
> well, the notification service which sends emails on these actually polls
> for them every minute in order to send the emails.
>
> we are discussing snmptraps here[1]
> one of the options this could be implemented with is via log4j getting all
> the audit log events, then you could use any log4j appender (db table, jms
> queue, etc.)
>
> [1] Bug 1032661 - Add SNMP trap as notification method to to
> ovirt-engine-notification
> ___
> Engine-devel mailing list
> Engine-devel@ovirt.org
> http://lists.ovirt.org/mailman/listinfo/engine-devel
>
___
Engine-devel mailing list
Engine-devel@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-devel


Re: [Engine-devel] Proposal to add Juan Hernandez as maintainer to api/sdk/cli

2013-12-17 Thread Eli Mesika


- Original Message -
> From: "Michael Pasternak" 
> To: "engine-devel" , "infra" 
> Sent: Monday, December 16, 2013 5:34:36 PM
> Subject: [Engine-devel] Proposal to add Juan Hernandez as maintainer to   
> api/sdk/cli
> 
> 
> Juan has worked on oVirt for a long period of time, developing
> several features in the different areas (including api and cli),
> and obviously gained a lot of experience and knowledge,
> 
> I'd like to propose Juan as a maintainer of the  api/sdk/cli projects.

+1
well deserved 

> 
> --
> 
> Michael Pasternak
> RedHat, ENG-Virtualization R&D
> ___
> Engine-devel mailing list
> Engine-devel@ovirt.org
> http://lists.ovirt.org/mailman/listinfo/engine-devel
> 
___
Engine-devel mailing list
Engine-devel@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-devel


Re: [Engine-devel] Proposal to add Juan Hernandez as maintainer to api/sdk/cli

2013-12-17 Thread Omer Frenkel


- Original Message -
> From: "Michael Pasternak" 
> To: "engine-devel" , "infra" 
> Sent: Monday, December 16, 2013 5:34:36 PM
> Subject: Proposal to add Juan Hernandez as maintainer to api/sdk/cli
> 
> 
> Juan has worked on oVirt for a long period of time, developing
> several features in the different areas (including api and cli),
> and obviously gained a lot of experience and knowledge,
> 
> I'd like to propose Juan as a maintainer of the  api/sdk/cli projects.
> 

+1 

> --
> 
> Michael Pasternak
> RedHat, ENG-Virtualization R&D
> ___
> Infra mailing list
> in...@ovirt.org
> http://lists.ovirt.org/mailman/listinfo/infra
> 
___
Engine-devel mailing list
Engine-devel@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-devel


Re: [Engine-devel] Polling vs Pushing engine events

2013-12-17 Thread Sven Kieske
Hi,

thanks for your fast replies.

We are aware that we can poll this via API, but we don't want to poll
it, as it's not a good solution, from a design point of view.

We will maybe write a little python script, which runs on engine-node
via SDK which polls the API and let this script push the information
forward to external systems over network when a certain event occurs.

Something similar to this in oVirt would be useful.
You don't want to poll every second, or more often, for simple
events like "is the vm already up?".

This just creates unnecessary network traffic and load on the polling
system.

With this solution we can at least avoid the network traffic.

This is, why I asked for a pushing logic.

Maybe it's now more clear?

But thanks again for your help :-)

Am 17.12.2013 09:24, schrieb Liran Zelkha:
> Note that you can usually get all the information you want using 1 API
> call, which should still scale.
> For instance, /ovirt-engine/api/vms will give you a list of all VMs and
> their statuses, so you can just run an XPath and get the status of all of
> them.

-- 
Mit freundlichen Grüßen / Regards

Sven Kieske

Systemadministrator
Mittwald CM Service GmbH & Co. KG
Königsberger Straße 6
32339 Espelkamp
T: +49-5772-293-100
F: +49-5772-293-333
https://www.mittwald.de
Geschäftsführer: Robert Meyer
St.Nr.: 331/5721/1033, USt-IdNr.: DE814773217, HRA 6640, AG Bad Oeynhausen
Komplementärin: Robert Meyer Verwaltungs GmbH, HRB 13260, AG Bad Oeynhausen
___
Engine-devel mailing list
Engine-devel@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-devel


Re: [Engine-devel] Proposal to add Juan Hernandez as maintainer to api/sdk/cli

2013-12-17 Thread Yair Zaslavsky


- Original Message -
> From: "Omer Frenkel" 
> To: "Michael Pasternak" 
> Cc: "engine-devel" , "infra" 
> Sent: Tuesday, December 17, 2013 11:04:00 AM
> Subject: Re: Proposal to add Juan Hernandez as maintainer to api/sdk/cli
> 
> 
> 
> - Original Message -
> > From: "Michael Pasternak" 
> > To: "engine-devel" , "infra" 
> > Sent: Monday, December 16, 2013 5:34:36 PM
> > Subject: Proposal to add Juan Hernandez as maintainer to api/sdk/cli
> > 
> > 
> > Juan has worked on oVirt for a long period of time, developing
> > several features in the different areas (including api and cli),
> > and obviously gained a lot of experience and knowledge,
> > 
> > I'd like to propose Juan as a maintainer of the  api/sdk/cli projects.
> > 
> 

+1

> 
> > --
> > 
> > Michael Pasternak
> > RedHat, ENG-Virtualization R&D
> > ___
> > Infra mailing list
> > in...@ovirt.org
> > http://lists.ovirt.org/mailman/listinfo/infra
> > 
> ___
> Infra mailing list
> in...@ovirt.org
> http://lists.ovirt.org/mailman/listinfo/infra
> 
___
Engine-devel mailing list
Engine-devel@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-devel


Re: [Engine-devel] Polling vs Pushing engine events

2013-12-17 Thread Yaniv Dary
You can use the DWH API to check these things.
The status is sampled and stored for most entities every 1 minute by default 
(and can be set to less than that). 



Yaniv

- Original Message -
> From: "Sven Kieske" 
> To: us...@ovirt.org, engine-devel@ovirt.org
> Sent: Tuesday, December 17, 2013 10:08:11 AM
> Subject: [Engine-devel] Polling vs Pushing engine events
> 
> Hi,
> 
> we got the following problem:
> 
> we create / start / stop
> hole vms /data centers / storage etc
> (basically: everything ovirt can handle
> via REST-API)
> 
> But if you want to know e.g. the status
> of a vm (or anything) you need to constantly
> poll the API.
> 
> This is not what we desire to do, as it
> does not scale very well (e.g. polling
> 100 vms).
> 
> Is there a standardized way of pushing information
> from the engine?
> 
> 
> --
> Mit freundlichen Grüßen / Regards
> 
> Sven Kieske
> 
> Systemadministrator
> Mittwald CM Service GmbH & Co. KG
> Königsberger Straße 6
> 32339 Espelkamp
> T: +49-5772-293-100
> F: +49-5772-293-333
> https://www.mittwald.de
> Geschäftsführer: Robert Meyer
> St.Nr.: 331/5721/1033, USt-IdNr.: DE814773217, HRA 6640, AG Bad Oeynhausen
> Komplementärin: Robert Meyer Verwaltungs GmbH, HRB 13260, AG Bad Oeynhausen
> ___
> Engine-devel mailing list
> Engine-devel@ovirt.org
> http://lists.ovirt.org/mailman/listinfo/engine-devel
>
___
Engine-devel mailing list
Engine-devel@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-devel


Re: [Engine-devel] GUI widget for adding/removing entries

2013-12-17 Thread Lior Vernia
Last patches were recently merged to the master branch; many thanks to
Tomas, Vojtech and Gilad for taking the time to review them (weren't
easy to review).

The following widgets now all use the same underlying widget:
* VM interfaces in add/edit VM dialog.
* Profiles in add/edit network dialog.
* Device custom properties in add/edit vNIC profile dialog.
* Custom properties in add/edit VM dialog.
* Custom properties in add/edit cluster dialog.
* Custom properties in add/edit cluster policy dialog.
* Custom properties in VM run once dialog.

I did my best to avoid regressions, but please let me know if any of
these seem to malfunction all of a sudden.

Yours, Lior.

On 10/10/13 16:01, Einav Cohen wrote:
> see attached: AFAIK, there are three types of adding-and-removing widget in 
> the application:
> 
> (1) the one that exists in the customs properties section as well as the 
> cluster policy.
> in this widget:
> - the "+" and "-" buttons appear on every row.
> - row is "identified" by a selected item from a drop down.
> - input controls in row: drop-down and text box (that appears upon selection 
> of a non-empty value in the drop-down)
> 
> (2) the one that exists in the vNICs assignment part of the General section 
> in the New VM dialog.
> in this widget:
> - the "+" appears only in the last row, "-" appears in all lines but the last 
> row.
> - row is "identified" by (what seems to be a) read-only label (I assume that 
> this widget is 
> built to be initially loaded to already contain a number of rows, as opposed 
> to (1), which 
> typically starts with no rows / initial "empty" row.
> - input controls in row: drop-down
> 
> (3) the one that exists in the vNIC profiles section in the Add/Edit Network 
> dialog
> in this widget:
> - the "+" and "-" buttons appear on every row.
> - row is "identified" by a free-text string.
> - input controls in row: text-box, check-box and drop-down.
> 
> so there are differences between the widgets other than the "+" and "-" 
> buttons.
> however, from ux perspective, it is important to keep the look-and-feel of 
> all of them consistent.
> 
> technically (code-wise), I am not sure how easy it is to merge the three, due 
> to the differences.
> we can maybe think of creating a general adding-and-removing-entries widget, 
> which can support 
> "ordered" and "non-ordered" flavors (which will affect the "+"/"-" buttons 
> appearance / exact 
> behavior), and it will contain a collection of "abstract" row-widgets (and we 
> will have several 
> implementations of row-widgets for each needed functionality [(1), (2), (3)] 
> with exact appearance / 
> input controls / behavior/etc.), which may need to support a certain api 
> (e.g. isRowEmpty(), get/set
> Identifier(), etc.) in order to communicate appropriately with its "parent" 
> adding-and-removing-entries 
> widget.
> 
> thoughts?
> 
> - Original Message -
>> From: "Lior Vernia" 
>> To: "Itamar Heim" 
>> Cc: "engine-devel" 
>> Sent: Thursday, October 10, 2013 4:44:47 AM
>> Subject: Re: [Engine-devel] GUI widget for adding/removing entries
>>
>> To my knowledge, such a widget existed only in two other places: custom
>> properties and vNIC profiles in add/edit network dialog. In both of them
>> the order wasn't important, in which case the new widget is probably
>> preferable. If it is indeed preferable (Einav? Malini?), I could do some
>> refactoring to have both of them use it.
>>
>> On 10/10/13 09:02, Itamar Heim wrote:
>>> On 10/10/2013 10:59 AM, Lior Vernia wrote:


 On 09/10/13 23:34, Itamar Heim wrote:
> On 10/09/2013 03:32 PM, Lior Vernia wrote:
>> Of course, my bad. Attached is a screenshot of the add/edit VM dialog,
>> note the vNIC part on the bottom half of the dialog.
>
> how is it different from the custom properties one?
>

 Design-wise, there are a couple of small differences. There's only one
 button next to each row, plus if it's the last row or minus otherwise
 (so items can only be added at the end, as I replied to Malini order
 hasn't been important so far). A row appears as disabled until it is
 edited, and a disabled row is ignored when the view is flushed back to
 the model (e.g. when the user presses OK in the dialog).

 Code-wise, it's constructed to be reusable, which the custom properties
 widget wasn't :)
>>>
>>> could we converge on one of them though?
>>>

>>
>> On 09/10/13 13:24, Einav Cohen wrote:
>>> Hi Lior - can you please provide a screen-shot, so we will know which
>>> widget
>>> you are referring to?
>>> will make it easier for people to decide if and where to use this
>>> widget.
>>>
>>> Many thanks!
>>>
>>> 
>>> Regards,
>>> Einav
>>>
>>> - Original Message -
 From: "Lior Vernia" 
 To: "engine-devel" 
 Sent: Wednesday, October 9, 2013 4:34:29 AM
 Subject: [Engine-devel] GUI widget for add

Re: [Engine-devel] GUI widget for adding/removing entries

2013-12-17 Thread Einav Cohen
Thank you Lior (and reviewers) for your efforts - they are highly appreciated!


Regards,
Einav

- Original Message -
> From: "Lior Vernia" 
> To: "Einav Cohen" 
> Cc: "engine-devel" 
> Sent: Tuesday, December 17, 2013 7:20:18 AM
> Subject: Re: [Engine-devel] GUI widget for adding/removing entries
> 
> Last patches were recently merged to the master branch; many thanks to
> Tomas, Vojtech and Gilad for taking the time to review them (weren't
> easy to review).
> 
> The following widgets now all use the same underlying widget:
> * VM interfaces in add/edit VM dialog.
> * Profiles in add/edit network dialog.
> * Device custom properties in add/edit vNIC profile dialog.
> * Custom properties in add/edit VM dialog.
> * Custom properties in add/edit cluster dialog.
> * Custom properties in add/edit cluster policy dialog.
> * Custom properties in VM run once dialog.
> 
> I did my best to avoid regressions, but please let me know if any of
> these seem to malfunction all of a sudden.
> 
> Yours, Lior.
> 
> On 10/10/13 16:01, Einav Cohen wrote:
> > see attached: AFAIK, there are three types of adding-and-removing widget in
> > the application:
> > 
> > (1) the one that exists in the customs properties section as well as the
> > cluster policy.
> > in this widget:
> > - the "+" and "-" buttons appear on every row.
> > - row is "identified" by a selected item from a drop down.
> > - input controls in row: drop-down and text box (that appears upon
> > selection of a non-empty value in the drop-down)
> > 
> > (2) the one that exists in the vNICs assignment part of the General section
> > in the New VM dialog.
> > in this widget:
> > - the "+" appears only in the last row, "-" appears in all lines but the
> > last row.
> > - row is "identified" by (what seems to be a) read-only label (I assume
> > that this widget is
> > built to be initially loaded to already contain a number of rows, as
> > opposed to (1), which
> > typically starts with no rows / initial "empty" row.
> > - input controls in row: drop-down
> > 
> > (3) the one that exists in the vNIC profiles section in the Add/Edit
> > Network dialog
> > in this widget:
> > - the "+" and "-" buttons appear on every row.
> > - row is "identified" by a free-text string.
> > - input controls in row: text-box, check-box and drop-down.
> > 
> > so there are differences between the widgets other than the "+" and "-"
> > buttons.
> > however, from ux perspective, it is important to keep the look-and-feel of
> > all of them consistent.
> > 
> > technically (code-wise), I am not sure how easy it is to merge the three,
> > due to the differences.
> > we can maybe think of creating a general adding-and-removing-entries
> > widget, which can support
> > "ordered" and "non-ordered" flavors (which will affect the "+"/"-" buttons
> > appearance / exact
> > behavior), and it will contain a collection of "abstract" row-widgets (and
> > we will have several
> > implementations of row-widgets for each needed functionality [(1), (2),
> > (3)] with exact appearance /
> > input controls / behavior/etc.), which may need to support a certain api
> > (e.g. isRowEmpty(), get/set
> > Identifier(), etc.) in order to communicate appropriately with its "parent"
> > adding-and-removing-entries
> > widget.
> > 
> > thoughts?
> > 
> > - Original Message -
> >> From: "Lior Vernia" 
> >> To: "Itamar Heim" 
> >> Cc: "engine-devel" 
> >> Sent: Thursday, October 10, 2013 4:44:47 AM
> >> Subject: Re: [Engine-devel] GUI widget for adding/removing entries
> >>
> >> To my knowledge, such a widget existed only in two other places: custom
> >> properties and vNIC profiles in add/edit network dialog. In both of them
> >> the order wasn't important, in which case the new widget is probably
> >> preferable. If it is indeed preferable (Einav? Malini?), I could do some
> >> refactoring to have both of them use it.
> >>
> >> On 10/10/13 09:02, Itamar Heim wrote:
> >>> On 10/10/2013 10:59 AM, Lior Vernia wrote:
> 
> 
>  On 09/10/13 23:34, Itamar Heim wrote:
> > On 10/09/2013 03:32 PM, Lior Vernia wrote:
> >> Of course, my bad. Attached is a screenshot of the add/edit VM dialog,
> >> note the vNIC part on the bottom half of the dialog.
> >
> > how is it different from the custom properties one?
> >
> 
>  Design-wise, there are a couple of small differences. There's only one
>  button next to each row, plus if it's the last row or minus otherwise
>  (so items can only be added at the end, as I replied to Malini order
>  hasn't been important so far). A row appears as disabled until it is
>  edited, and a disabled row is ignored when the view is flushed back to
>  the model (e.g. when the user presses OK in the dialog).
> 
>  Code-wise, it's constructed to be reusable, which the custom properties
>  widget wasn't :)
> >>>
> >>> could we converge on one of them though?
> >>>
> 
> >>
> >> On 09/10/13 13:24, Einav C

[Engine-devel] [jenkins] Request to be able to create jobs for jsonrpc project

2013-12-17 Thread Piotr Kliczewski
I am working on new project vdsm-jsonrpc-java which is async client
library using json which
will be used for communication between engine and vdsm. I would like
to create jenkins jobs for
this project but have no account nor authority to do so.

Can you please +1 my request?

Thanks,
Piotr
___
Engine-devel mailing list
Engine-devel@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-devel


Re: [Engine-devel] Proposal to add Juan Hernandez as maintainer to api/sdk/cli

2013-12-17 Thread Sahina Bose


On 12/16/2013 09:04 PM, Michael Pasternak wrote:

Juan has worked on oVirt for a long period of time, developing
several features in the different areas (including api and cli),
and obviously gained a lot of experience and knowledge,

I'd like to propose Juan as a maintainer of the  api/sdk/cli projects.



+1
___
Engine-devel mailing list
Engine-devel@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-devel