search for: event_messag

Displaying 3 results from an estimated 3 matches for "event_messag".

Did you mean: event_message
2017 May 17
2
Callback re-registration after libvirtd restart
...ode to listen for lifecycle events: func event_listen() { log.Printf("event_listen %s", conf.Libvirt.LocalUrl) hv, err := libvirt.NewConnect(conf.Libvirt.LocalUrl) lifecycleCallback := func(c *libvirt.Connect, d *libvirt.Domain, event *libvirt.DomainEventLifecycle) { event_message(c, d, "lifecycle", event) } _, err = hv.DomainEventLifecycleRegister(nil, lifecycleCallback) if err != nil { log.Printf("unable to register event callback") return } log.Printf("Libvirt event listener started") go func() {...
2017 May 17
0
Re: Callback re-registration after libvirtd restart
...> func event_listen() { > log.Printf("event_listen %s", conf.Libvirt.LocalUrl) > hv, err := libvirt.NewConnect(conf.Libvirt.LocalUrl) > > lifecycleCallback := func(c *libvirt.Connect, d *libvirt.Domain, event > *libvirt.DomainEventLifecycle) { > event_message(c, d, "lifecycle", event) > } > > _, err = hv.DomainEventLifecycleRegister(nil, lifecycleCallback) > if err != nil { > log.Printf("unable to register event callback") > return > } > > log.Printf("Libvirt even...
2017 May 17
2
Re: Callback re-registration after libvirtd restart
...> log.Printf("event_listen %s", conf.Libvirt.LocalUrl) > > hv, err := libvirt.NewConnect(conf.Libvirt.LocalUrl) > > > > lifecycleCallback := func(c *libvirt.Connect, d *libvirt.Domain, > event > > *libvirt.DomainEventLifecycle) { > > event_message(c, d, "lifecycle", event) > > } > > > > _, err = hv.DomainEventLifecycleRegister(nil, lifecycleCallback) > > if err != nil { > > log.Printf("unable to register event callback") > > return > > } > >...