[libvirt] [PATCH 00/14] introduce virDomainSetLifecycleAction() API

Pavel Hrdina posted 14 patches 6 years, 6 months ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/libvirt tags/patchew/cover.1508151955.git.phrdina@redhat.com
docs/formatdomain.html.in        |   6 +++
include/libvirt/libvirt-domain.h |  28 ++++++++++
src/conf/domain_conf.c           |  84 ++++++++++++++++++++++++-----
src/conf/domain_conf.h           |  26 ++-------
src/driver-hypervisor.h          |   7 +++
src/libvirt-domain.c             |  60 +++++++++++++++++++++
src/libvirt_private.syms         |   7 ++-
src/libvirt_public.syms          |   5 ++
src/libxl/libxl_conf.c           |  43 ++++-----------
src/libxl/libxl_domain.c         |  40 +++++++-------
src/lxc/lxc_native.c             |   6 +--
src/qemu/qemu_command.c          |  93 +++++++++++++-------------------
src/qemu/qemu_command.h          |  11 +---
src/qemu/qemu_domain.c           |  40 ++++++++++++++
src/qemu/qemu_domain.h           |   9 ++++
src/qemu/qemu_driver.c           | 112 +++++++++++++++++++++++++++++++++++----
src/qemu/qemu_migration.c        |   7 ++-
src/qemu/qemu_migration_cookie.c |  25 ++++++++-
src/qemu/qemu_migration_cookie.h |   5 ++
src/qemu/qemu_parse_command.c    |   8 +--
src/qemu/qemu_process.c          |  53 ++++++++++++------
src/remote/remote_driver.c       |   1 +
src/remote/remote_protocol.x     |  14 ++++-
src/test/test_driver.c           |   8 +--
src/vmx/vmx.c                    |   6 +--
src/vz/vz_sdk.c                  |  12 ++---
src/xenapi/xenapi_utils.c        |  40 +++++++-------
src/xenapi/xenapi_utils.h        |   4 +-
src/xenconfig/xen_common.c       |  12 ++---
src/xenconfig/xen_sxpr.c         |  18 +++----
tests/qemuxml2xmltest.c          |   3 +-
tools/virsh-domain.c             | 102 +++++++++++++++++++++++++++++++++++
tools/virsh.pod                  |   7 +++
33 files changed, 658 insertions(+), 244 deletions(-)
[libvirt] [PATCH 00/14] introduce virDomainSetLifecycleAction() API
Posted by Pavel Hrdina 6 years, 6 months ago
Pavel Hrdina (14):
  conf: rename lifecycle enum values to correspond with typedef keyword
  conf: rename virDomainLifecycleAction enum functions
  conf: introduce virDomainLifecycle enum to list all lifecycle types
  conf: merge virDomainLifecycleCrashAction with
    virDomainLifecycleAction
  qemu: pass virDomainObjPtr to qemuBuildCommandLine
  qemu: pass priv data to qemuBuildMonitorCommandLine
  qemu: pass priv data to qemuBuildPMCommandLine
  qemu: pass priv data to qemuBuildMasterKeyCommandLine
  qemu: pass priv data instead of qemuCaps and autoNodeset
  lib: introduce virDomainSetLifecycleAction() API
  virsh: introduce set-lifecycle-action command
  qemu: move detection whether to use -no-reboot to qemu_domain
  qemu: send allowReboot in migration cookie
  qemu: implement virDomainSetLifecycleAction() API

 docs/formatdomain.html.in        |   6 +++
 include/libvirt/libvirt-domain.h |  28 ++++++++++
 src/conf/domain_conf.c           |  84 ++++++++++++++++++++++++-----
 src/conf/domain_conf.h           |  26 ++-------
 src/driver-hypervisor.h          |   7 +++
 src/libvirt-domain.c             |  60 +++++++++++++++++++++
 src/libvirt_private.syms         |   7 ++-
 src/libvirt_public.syms          |   5 ++
 src/libxl/libxl_conf.c           |  43 ++++-----------
 src/libxl/libxl_domain.c         |  40 +++++++-------
 src/lxc/lxc_native.c             |   6 +--
 src/qemu/qemu_command.c          |  93 +++++++++++++-------------------
 src/qemu/qemu_command.h          |  11 +---
 src/qemu/qemu_domain.c           |  40 ++++++++++++++
 src/qemu/qemu_domain.h           |   9 ++++
 src/qemu/qemu_driver.c           | 112 +++++++++++++++++++++++++++++++++++----
 src/qemu/qemu_migration.c        |   7 ++-
 src/qemu/qemu_migration_cookie.c |  25 ++++++++-
 src/qemu/qemu_migration_cookie.h |   5 ++
 src/qemu/qemu_parse_command.c    |   8 +--
 src/qemu/qemu_process.c          |  53 ++++++++++++------
 src/remote/remote_driver.c       |   1 +
 src/remote/remote_protocol.x     |  14 ++++-
 src/test/test_driver.c           |   8 +--
 src/vmx/vmx.c                    |   6 +--
 src/vz/vz_sdk.c                  |  12 ++---
 src/xenapi/xenapi_utils.c        |  40 +++++++-------
 src/xenapi/xenapi_utils.h        |   4 +-
 src/xenconfig/xen_common.c       |  12 ++---
 src/xenconfig/xen_sxpr.c         |  18 +++----
 tests/qemuxml2xmltest.c          |   3 +-
 tools/virsh-domain.c             | 102 +++++++++++++++++++++++++++++++++++
 tools/virsh.pod                  |   7 +++
 33 files changed, 658 insertions(+), 244 deletions(-)

-- 
2.13.6

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
Re: [libvirt] [PATCH 00/14] introduce virDomainSetLifecycleAction() API
Posted by John Ferlan 6 years, 6 months ago

On 10/16/2017 07:06 AM, Pavel Hrdina wrote:
> Pavel Hrdina (14):
>   conf: rename lifecycle enum values to correspond with typedef keyword
>   conf: rename virDomainLifecycleAction enum functions
>   conf: introduce virDomainLifecycle enum to list all lifecycle types
>   conf: merge virDomainLifecycleCrashAction with
>     virDomainLifecycleAction
>   qemu: pass virDomainObjPtr to qemuBuildCommandLine
>   qemu: pass priv data to qemuBuildMonitorCommandLine
>   qemu: pass priv data to qemuBuildPMCommandLine
>   qemu: pass priv data to qemuBuildMasterKeyCommandLine
>   qemu: pass priv data instead of qemuCaps and autoNodeset
>   lib: introduce virDomainSetLifecycleAction() API
>   virsh: introduce set-lifecycle-action command
>   qemu: move detection whether to use -no-reboot to qemu_domain
>   qemu: send allowReboot in migration cookie
>   qemu: implement virDomainSetLifecycleAction() API
> 
>  docs/formatdomain.html.in        |   6 +++
>  include/libvirt/libvirt-domain.h |  28 ++++++++++
>  src/conf/domain_conf.c           |  84 ++++++++++++++++++++++++-----
>  src/conf/domain_conf.h           |  26 ++-------
>  src/driver-hypervisor.h          |   7 +++
>  src/libvirt-domain.c             |  60 +++++++++++++++++++++
>  src/libvirt_private.syms         |   7 ++-
>  src/libvirt_public.syms          |   5 ++
>  src/libxl/libxl_conf.c           |  43 ++++-----------
>  src/libxl/libxl_domain.c         |  40 +++++++-------
>  src/lxc/lxc_native.c             |   6 +--
>  src/qemu/qemu_command.c          |  93 +++++++++++++-------------------
>  src/qemu/qemu_command.h          |  11 +---
>  src/qemu/qemu_domain.c           |  40 ++++++++++++++
>  src/qemu/qemu_domain.h           |   9 ++++
>  src/qemu/qemu_driver.c           | 112 +++++++++++++++++++++++++++++++++++----
>  src/qemu/qemu_migration.c        |   7 ++-
>  src/qemu/qemu_migration_cookie.c |  25 ++++++++-
>  src/qemu/qemu_migration_cookie.h |   5 ++
>  src/qemu/qemu_parse_command.c    |   8 +--
>  src/qemu/qemu_process.c          |  53 ++++++++++++------
>  src/remote/remote_driver.c       |   1 +
>  src/remote/remote_protocol.x     |  14 ++++-
>  src/test/test_driver.c           |   8 +--
>  src/vmx/vmx.c                    |   6 +--
>  src/vz/vz_sdk.c                  |  12 ++---
>  src/xenapi/xenapi_utils.c        |  40 +++++++-------
>  src/xenapi/xenapi_utils.h        |   4 +-
>  src/xenconfig/xen_common.c       |  12 ++---
>  src/xenconfig/xen_sxpr.c         |  18 +++----
>  tests/qemuxml2xmltest.c          |   3 +-
>  tools/virsh-domain.c             | 102 +++++++++++++++++++++++++++++++++++
>  tools/virsh.pod                  |   7 +++
>  33 files changed, 658 insertions(+), 244 deletions(-)
> 

FYI: The complete series doesn't pass make check:

make  check-local
make[3]: Entering directory '/home/jferlan/git/libvirt.work/src'
  GEN      remote_protocol-struct
--- remote_protocol-structs	2017-10-17 15:55:01.279467242 -0400
+++ remote_protocol-struct-t3	2017-10-18 09:59:23.818661775 -0400
@@ -2865,6 +2865,12 @@
         uint64_t                   threshold;
         u_int                      flags;
 };
+struct remote_domain_set_lifecycle_action_args {
+        remote_nonnull_domain      dom;
+        u_int                      type;
+        u_int                      action;
+        u_int                      flags;
+};
 enum remote_procedure {
         REMOTE_PROC_CONNECT_OPEN = 1,
         REMOTE_PROC_CONNECT_CLOSE = 2,
@@ -3255,4 +3261,5 @@
         REMOTE_PROC_DOMAIN_MIGRATE_GET_MAX_DOWNTIME = 387,
         REMOTE_PROC_DOMAIN_MANAGED_SAVE_GET_XML_DESC = 388,
         REMOTE_PROC_DOMAIN_MANAGED_SAVE_DEFINE_XML = 389,
+        REMOTE_PROC_DOMAIN_SET_LIFECYCLE_ACTION = 390,
 };

John

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
Re: [libvirt] [PATCH 00/14] introduce virDomainSetLifecycleAction() API
Posted by Pavel Hrdina 6 years, 6 months ago
On Wed, Oct 18, 2017 at 09:59:46AM -0400, John Ferlan wrote:
> 
> 
> On 10/16/2017 07:06 AM, Pavel Hrdina wrote:
> > Pavel Hrdina (14):
> >   conf: rename lifecycle enum values to correspond with typedef keyword
> >   conf: rename virDomainLifecycleAction enum functions
> >   conf: introduce virDomainLifecycle enum to list all lifecycle types
> >   conf: merge virDomainLifecycleCrashAction with
> >     virDomainLifecycleAction
> >   qemu: pass virDomainObjPtr to qemuBuildCommandLine
> >   qemu: pass priv data to qemuBuildMonitorCommandLine
> >   qemu: pass priv data to qemuBuildPMCommandLine
> >   qemu: pass priv data to qemuBuildMasterKeyCommandLine
> >   qemu: pass priv data instead of qemuCaps and autoNodeset
> >   lib: introduce virDomainSetLifecycleAction() API
> >   virsh: introduce set-lifecycle-action command
> >   qemu: move detection whether to use -no-reboot to qemu_domain
> >   qemu: send allowReboot in migration cookie
> >   qemu: implement virDomainSetLifecycleAction() API
> > 
> >  docs/formatdomain.html.in        |   6 +++
> >  include/libvirt/libvirt-domain.h |  28 ++++++++++
> >  src/conf/domain_conf.c           |  84 ++++++++++++++++++++++++-----
> >  src/conf/domain_conf.h           |  26 ++-------
> >  src/driver-hypervisor.h          |   7 +++
> >  src/libvirt-domain.c             |  60 +++++++++++++++++++++
> >  src/libvirt_private.syms         |   7 ++-
> >  src/libvirt_public.syms          |   5 ++
> >  src/libxl/libxl_conf.c           |  43 ++++-----------
> >  src/libxl/libxl_domain.c         |  40 +++++++-------
> >  src/lxc/lxc_native.c             |   6 +--
> >  src/qemu/qemu_command.c          |  93 +++++++++++++-------------------
> >  src/qemu/qemu_command.h          |  11 +---
> >  src/qemu/qemu_domain.c           |  40 ++++++++++++++
> >  src/qemu/qemu_domain.h           |   9 ++++
> >  src/qemu/qemu_driver.c           | 112 +++++++++++++++++++++++++++++++++++----
> >  src/qemu/qemu_migration.c        |   7 ++-
> >  src/qemu/qemu_migration_cookie.c |  25 ++++++++-
> >  src/qemu/qemu_migration_cookie.h |   5 ++
> >  src/qemu/qemu_parse_command.c    |   8 +--
> >  src/qemu/qemu_process.c          |  53 ++++++++++++------
> >  src/remote/remote_driver.c       |   1 +
> >  src/remote/remote_protocol.x     |  14 ++++-
> >  src/test/test_driver.c           |   8 +--
> >  src/vmx/vmx.c                    |   6 +--
> >  src/vz/vz_sdk.c                  |  12 ++---
> >  src/xenapi/xenapi_utils.c        |  40 +++++++-------
> >  src/xenapi/xenapi_utils.h        |   4 +-
> >  src/xenconfig/xen_common.c       |  12 ++---
> >  src/xenconfig/xen_sxpr.c         |  18 +++----
> >  tests/qemuxml2xmltest.c          |   3 +-
> >  tools/virsh-domain.c             | 102 +++++++++++++++++++++++++++++++++++
> >  tools/virsh.pod                  |   7 +++
> >  33 files changed, 658 insertions(+), 244 deletions(-)
> > 
> 
> FYI: The complete series doesn't pass make check:
> 
> make  check-local
> make[3]: Entering directory '/home/jferlan/git/libvirt.work/src'
>   GEN      remote_protocol-struct
> --- remote_protocol-structs	2017-10-17 15:55:01.279467242 -0400
> +++ remote_protocol-struct-t3	2017-10-18 09:59:23.818661775 -0400
> @@ -2865,6 +2865,12 @@
>          uint64_t                   threshold;
>          u_int                      flags;
>  };
> +struct remote_domain_set_lifecycle_action_args {
> +        remote_nonnull_domain      dom;
> +        u_int                      type;
> +        u_int                      action;
> +        u_int                      flags;
> +};
>  enum remote_procedure {
>          REMOTE_PROC_CONNECT_OPEN = 1,
>          REMOTE_PROC_CONNECT_CLOSE = 2,
> @@ -3255,4 +3261,5 @@
>          REMOTE_PROC_DOMAIN_MIGRATE_GET_MAX_DOWNTIME = 387,
>          REMOTE_PROC_DOMAIN_MANAGED_SAVE_GET_XML_DESC = 388,
>          REMOTE_PROC_DOMAIN_MANAGED_SAVE_DEFINE_XML = 389,
> +        REMOTE_PROC_DOMAIN_SET_LIFECYCLE_ACTION = 390,
>  };

Interesting is that it worked for me even without this.  I'll squash it
into the patch "lib: introduce virDomainSetLifecycleAction() API".

I'm missing pdwtags so this check was skipped.

Thanks

Pavel

> 
> John
> 
> --
> libvir-list mailing list
> libvir-list@redhat.com
> https://www.redhat.com/mailman/listinfo/libvir-list
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
Re: [libvirt] [PATCH 00/14] introduce virDomainSetLifecycleAction() API
Posted by John Ferlan 6 years, 6 months ago

On 10/16/2017 07:06 AM, Pavel Hrdina wrote:
> Pavel Hrdina (14):
>   conf: rename lifecycle enum values to correspond with typedef keyword
>   conf: rename virDomainLifecycleAction enum functions
>   conf: introduce virDomainLifecycle enum to list all lifecycle types
>   conf: merge virDomainLifecycleCrashAction with
>     virDomainLifecycleAction
>   qemu: pass virDomainObjPtr to qemuBuildCommandLine
>   qemu: pass priv data to qemuBuildMonitorCommandLine
>   qemu: pass priv data to qemuBuildPMCommandLine
>   qemu: pass priv data to qemuBuildMasterKeyCommandLine
>   qemu: pass priv data instead of qemuCaps and autoNodeset
>   lib: introduce virDomainSetLifecycleAction() API
>   virsh: introduce set-lifecycle-action command
>   qemu: move detection whether to use -no-reboot to qemu_domain
>   qemu: send allowReboot in migration cookie
>   qemu: implement virDomainSetLifecycleAction() API
> 
>  docs/formatdomain.html.in        |   6 +++
>  include/libvirt/libvirt-domain.h |  28 ++++++++++
>  src/conf/domain_conf.c           |  84 ++++++++++++++++++++++++-----
>  src/conf/domain_conf.h           |  26 ++-------
>  src/driver-hypervisor.h          |   7 +++
>  src/libvirt-domain.c             |  60 +++++++++++++++++++++
>  src/libvirt_private.syms         |   7 ++-
>  src/libvirt_public.syms          |   5 ++
>  src/libxl/libxl_conf.c           |  43 ++++-----------
>  src/libxl/libxl_domain.c         |  40 +++++++-------
>  src/lxc/lxc_native.c             |   6 +--
>  src/qemu/qemu_command.c          |  93 +++++++++++++-------------------
>  src/qemu/qemu_command.h          |  11 +---
>  src/qemu/qemu_domain.c           |  40 ++++++++++++++
>  src/qemu/qemu_domain.h           |   9 ++++
>  src/qemu/qemu_driver.c           | 112 +++++++++++++++++++++++++++++++++++----
>  src/qemu/qemu_migration.c        |   7 ++-
>  src/qemu/qemu_migration_cookie.c |  25 ++++++++-
>  src/qemu/qemu_migration_cookie.h |   5 ++
>  src/qemu/qemu_parse_command.c    |   8 +--
>  src/qemu/qemu_process.c          |  53 ++++++++++++------
>  src/remote/remote_driver.c       |   1 +
>  src/remote/remote_protocol.x     |  14 ++++-
>  src/test/test_driver.c           |   8 +--
>  src/vmx/vmx.c                    |   6 +--
>  src/vz/vz_sdk.c                  |  12 ++---
>  src/xenapi/xenapi_utils.c        |  40 +++++++-------
>  src/xenapi/xenapi_utils.h        |   4 +-
>  src/xenconfig/xen_common.c       |  12 ++---
>  src/xenconfig/xen_sxpr.c         |  18 +++----
>  tests/qemuxml2xmltest.c          |   3 +-
>  tools/virsh-domain.c             | 102 +++++++++++++++++++++++++++++++++++
>  tools/virsh.pod                  |   7 +++
>  33 files changed, 658 insertions(+), 244 deletions(-)
> 

Reviewed-by: John Ferlan <jferlan@redhat.com>
(series)

As long as you take care of the couple things I noted.

John

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
Re: [libvirt] [PATCH 00/14] introduce virDomainSetLifecycleAction() API
Posted by Pavel Hrdina 6 years, 6 months ago
On Wed, Oct 18, 2017 at 04:39:10PM -0400, John Ferlan wrote:
> 
> 
> On 10/16/2017 07:06 AM, Pavel Hrdina wrote:
> > Pavel Hrdina (14):
> >   conf: rename lifecycle enum values to correspond with typedef keyword
> >   conf: rename virDomainLifecycleAction enum functions
> >   conf: introduce virDomainLifecycle enum to list all lifecycle types
> >   conf: merge virDomainLifecycleCrashAction with
> >     virDomainLifecycleAction
> >   qemu: pass virDomainObjPtr to qemuBuildCommandLine
> >   qemu: pass priv data to qemuBuildMonitorCommandLine
> >   qemu: pass priv data to qemuBuildPMCommandLine
> >   qemu: pass priv data to qemuBuildMasterKeyCommandLine
> >   qemu: pass priv data instead of qemuCaps and autoNodeset
> >   lib: introduce virDomainSetLifecycleAction() API
> >   virsh: introduce set-lifecycle-action command
> >   qemu: move detection whether to use -no-reboot to qemu_domain
> >   qemu: send allowReboot in migration cookie
> >   qemu: implement virDomainSetLifecycleAction() API
> > 
> >  docs/formatdomain.html.in        |   6 +++
> >  include/libvirt/libvirt-domain.h |  28 ++++++++++
> >  src/conf/domain_conf.c           |  84 ++++++++++++++++++++++++-----
> >  src/conf/domain_conf.h           |  26 ++-------
> >  src/driver-hypervisor.h          |   7 +++
> >  src/libvirt-domain.c             |  60 +++++++++++++++++++++
> >  src/libvirt_private.syms         |   7 ++-
> >  src/libvirt_public.syms          |   5 ++
> >  src/libxl/libxl_conf.c           |  43 ++++-----------
> >  src/libxl/libxl_domain.c         |  40 +++++++-------
> >  src/lxc/lxc_native.c             |   6 +--
> >  src/qemu/qemu_command.c          |  93 +++++++++++++-------------------
> >  src/qemu/qemu_command.h          |  11 +---
> >  src/qemu/qemu_domain.c           |  40 ++++++++++++++
> >  src/qemu/qemu_domain.h           |   9 ++++
> >  src/qemu/qemu_driver.c           | 112 +++++++++++++++++++++++++++++++++++----
> >  src/qemu/qemu_migration.c        |   7 ++-
> >  src/qemu/qemu_migration_cookie.c |  25 ++++++++-
> >  src/qemu/qemu_migration_cookie.h |   5 ++
> >  src/qemu/qemu_parse_command.c    |   8 +--
> >  src/qemu/qemu_process.c          |  53 ++++++++++++------
> >  src/remote/remote_driver.c       |   1 +
> >  src/remote/remote_protocol.x     |  14 ++++-
> >  src/test/test_driver.c           |   8 +--
> >  src/vmx/vmx.c                    |   6 +--
> >  src/vz/vz_sdk.c                  |  12 ++---
> >  src/xenapi/xenapi_utils.c        |  40 +++++++-------
> >  src/xenapi/xenapi_utils.h        |   4 +-
> >  src/xenconfig/xen_common.c       |  12 ++---
> >  src/xenconfig/xen_sxpr.c         |  18 +++----
> >  tests/qemuxml2xmltest.c          |   3 +-
> >  tools/virsh-domain.c             | 102 +++++++++++++++++++++++++++++++++++
> >  tools/virsh.pod                  |   7 +++
> >  33 files changed, 658 insertions(+), 244 deletions(-)
> > 
> 
> Reviewed-by: John Ferlan <jferlan@redhat.com>
> (series)
> 
> As long as you take care of the couple things I noted.

Thanks for review, I've fixed the issues and pushed it.

Pavel
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list