[libvirt] [PATCH] qemu: Set operation on completed migration job

Jiri Denemark posted 1 patch 6 years, 10 months ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/libvirt tags/patchew/9123ff7083978ec66c57740a93aeca3c24e32faf.1496664600.git.jdenemar@redhat.com
src/qemu/qemu_migration_cookie.c | 4 ++++
1 file changed, 4 insertions(+)
[libvirt] [PATCH] qemu: Set operation on completed migration job
Posted by Jiri Denemark 6 years, 10 months ago
Without this patch libvirt would just report the operation of a
completed job as "unknown" instead of "incoming migration".

https://bugzilla.redhat.com/show_bug.cgi?id=1457052

Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
---
 src/qemu/qemu_migration_cookie.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/qemu/qemu_migration_cookie.c b/src/qemu/qemu_migration_cookie.c
index 12887892d..559b1f0c1 100644
--- a/src/qemu/qemu_migration_cookie.c
+++ b/src/qemu/qemu_migration_cookie.c
@@ -1292,6 +1292,7 @@ qemuMigrationEatCookie(virQEMUDriverPtr driver,
                        int cookieinlen,
                        unsigned int flags)
 {
+    qemuDomainObjPrivatePtr priv = dom->privateData;
     qemuMigrationCookiePtr mig = NULL;
 
     /* Parse & validate incoming cookie (if any) */
@@ -1340,6 +1341,9 @@ qemuMigrationEatCookie(virQEMUDriverPtr driver,
         }
     }
 
+    if (flags & QEMU_MIGRATION_COOKIE_STATS && mig->jobInfo)
+        mig->jobInfo->operation = priv->job.current->operation;
+
     return mig;
 
  error:
-- 
2.13.0

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
Re: [libvirt] [PATCH] qemu: Set operation on completed migration job
Posted by Peter Krempa 6 years, 10 months ago
On Mon, Jun 05, 2017 at 14:10:00 +0200, Jiri Denemark wrote:
> Without this patch libvirt would just report the operation of a
> completed job as "unknown" instead of "incoming migration".
> 
> https://bugzilla.redhat.com/show_bug.cgi?id=1457052
> 
> Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
> ---

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