[PATCH] docs/COLO-FT.txt: Drop deprecated 'props' from object-add in COLO docs

Rao, Lei posted 1 patch 2 years, 5 months ago
Test checkpatch passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/1637209041-15080-1-git-send-email-lei.rao@intel.com
Maintainers: Hailiang Zhang <zhang.zhanghailiang@huawei.com>
docs/COLO-FT.txt | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
[PATCH] docs/COLO-FT.txt: Drop deprecated 'props' from object-add in COLO docs
Posted by Rao, Lei 2 years, 5 months ago
From: "Rao, Lei" <lei.rao@intel.com>

With the removal of deprecated 'props' from object-add in the commit of
"50243407457a9fb0ed17b9a9ba9fc9aee09495b1", we also should update COLO's
documents.

Signed-off-by: Lei Rao <lei.rao@intel.com>
---
 docs/COLO-FT.txt | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/docs/COLO-FT.txt b/docs/COLO-FT.txt
index 8d6d53a..fd5ffcc 100644
--- a/docs/COLO-FT.txt
+++ b/docs/COLO-FT.txt
@@ -289,11 +289,11 @@ Wait until disk is synced, then:
 {'execute': 'human-monitor-command', 'arguments':{ 'command-line': 'drive_add -n buddy driver=replication,mode=primary,file.driver=nbd,file.host=127.0.0.2,file.port=9999,file.export=parent0,node-name=replication0'}}
 {'execute': 'x-blockdev-change', 'arguments':{ 'parent': 'colo-disk0', 'node': 'replication0' } }
 
-{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-mirror', 'id': 'm0', 'props': { 'netdev': 'hn0', 'queue': 'tx', 'outdev': 'mirror0' } } }
-{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-redirector', 'id': 'redire0', 'props': { 'netdev': 'hn0', 'queue': 'rx', 'indev': 'compare_out' } } }
-{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-redirector', 'id': 'redire1', 'props': { 'netdev': 'hn0', 'queue': 'rx', 'outdev': 'compare0' } } }
+{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-mirror', 'id': 'm0', 'netdev': 'hn0', 'queue': 'tx', 'outdev': 'mirror0' } }
+{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-redirector', 'id': 'redire0', 'netdev': 'hn0', 'queue': 'rx', 'indev': 'compare_out' } }
+{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-redirector', 'id': 'redire1', 'netdev': 'hn0', 'queue': 'rx', 'outdev': 'compare0' } }
 {'execute': 'object-add', 'arguments':{ 'qom-type': 'iothread', 'id': 'iothread1' } }
-{'execute': 'object-add', 'arguments':{ 'qom-type': 'colo-compare', 'id': 'comp0', 'props': { 'primary_in': 'compare0-0', 'secondary_in': 'compare1', 'outdev': 'compare_out0', 'iothread': 'iothread1' } } }
+{'execute': 'object-add', 'arguments':{ 'qom-type': 'colo-compare', 'id': 'comp0', 'primary_in': 'compare0-0', 'secondary_in': 'compare1', 'outdev': 'compare_out0', 'iothread': 'iothread1' } }
 
 {'execute': 'migrate-set-capabilities', 'arguments':{ 'capabilities': [ {'capability': 'x-colo', 'state': true } ] } }
 {'execute': 'migrate', 'arguments':{ 'uri': 'tcp:127.0.0.2:9998' } }
@@ -318,11 +318,11 @@ Wait until disk is synced, then:
 {'execute': 'human-monitor-command', 'arguments':{ 'command-line': 'drive_add -n buddy driver=replication,mode=primary,file.driver=nbd,file.host=127.0.0.1,file.port=9999,file.export=parent0,node-name=replication0'}}
 {'execute': 'x-blockdev-change', 'arguments':{ 'parent': 'colo-disk0', 'node': 'replication0' } }
 
-{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-mirror', 'id': 'm0', 'props': { 'insert': 'before', 'position': 'id=rew0', 'netdev': 'hn0', 'queue': 'tx', 'outdev': 'mirror0' } } }
-{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-redirector', 'id': 'redire0', 'props': { 'insert': 'before', 'position': 'id=rew0', 'netdev': 'hn0', 'queue': 'rx', 'indev': 'compare_out' } } }
-{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-redirector', 'id': 'redire1', 'props': { 'insert': 'before', 'position': 'id=rew0', 'netdev': 'hn0', 'queue': 'rx', 'outdev': 'compare0' } } }
+{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-mirror', 'id': 'm0', 'insert': 'before', 'position': 'id=rew0', 'netdev': 'hn0', 'queue': 'tx', 'outdev': 'mirror0' } }
+{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-redirector', 'id': 'redire0', 'insert': 'before', 'position': 'id=rew0', 'netdev': 'hn0', 'queue': 'rx', 'indev': 'compare_out' } }
+{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-redirector', 'id': 'redire1', 'insert': 'before', 'position': 'id=rew0', 'netdev': 'hn0', 'queue': 'rx', 'outdev': 'compare0' } }
 {'execute': 'object-add', 'arguments':{ 'qom-type': 'iothread', 'id': 'iothread1' } }
-{'execute': 'object-add', 'arguments':{ 'qom-type': 'colo-compare', 'id': 'comp0', 'props': { 'primary_in': 'compare0-0', 'secondary_in': 'compare1', 'outdev': 'compare_out0', 'iothread': 'iothread1' } } }
+{'execute': 'object-add', 'arguments':{ 'qom-type': 'colo-compare', 'id': 'comp0', 'primary_in': 'compare0-0', 'secondary_in': 'compare1', 'outdev': 'compare_out0', 'iothread': 'iothread1' } }
 
 {'execute': 'migrate-set-capabilities', 'arguments':{ 'capabilities': [ {'capability': 'x-colo', 'state': true } ] } }
 {'execute': 'migrate', 'arguments':{ 'uri': 'tcp:127.0.0.1:9998' } }
-- 
1.8.3.1


RE: [PATCH] docs/COLO-FT.txt: Drop deprecated 'props' from object-add in COLO docs
Posted by Zhang, Chen 2 years, 5 months ago

> -----Original Message-----
> From: Rao, Lei <lei.rao@intel.com>
> Sent: Thursday, November 18, 2021 12:17 PM
> To: Zhang, Chen <chen.zhang@intel.com>;
> zhang.zhanghailiang@huawei.com; quintela@redhat.com;
> dgilbert@redhat.com
> Cc: qemu-trivial@nongnu.org; qemu-devel@nongnu.org; Rao, Lei
> <lei.rao@intel.com>
> Subject: [PATCH] docs/COLO-FT.txt: Drop deprecated 'props' from object-
> add in COLO docs
> 
> From: "Rao, Lei" <lei.rao@intel.com>
> 
> With the removal of deprecated 'props' from object-add in the commit of
> "50243407457a9fb0ed17b9a9ba9fc9aee09495b1", we also should update
> COLO's documents.
> 
> Signed-off-by: Lei Rao <lei.rao@intel.com>

Looks good to me.

Reviewed-by: Zhang Chen <chen.zhang@intel.com>

> ---
>  docs/COLO-FT.txt | 16 ++++++++--------
>  1 file changed, 8 insertions(+), 8 deletions(-)
> 
> diff --git a/docs/COLO-FT.txt b/docs/COLO-FT.txt index 8d6d53a..fd5ffcc
> 100644
> --- a/docs/COLO-FT.txt
> +++ b/docs/COLO-FT.txt
> @@ -289,11 +289,11 @@ Wait until disk is synced, then:
>  {'execute': 'human-monitor-command', 'arguments':{ 'command-line':
> 'drive_add -n buddy
> driver=replication,mode=primary,file.driver=nbd,file.host=127.0.0.2,file.port
> =9999,file.export=parent0,node-name=replication0'}}
>  {'execute': 'x-blockdev-change', 'arguments':{ 'parent': 'colo-disk0', 'node':
> 'replication0' } }
> 
> -{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-mirror', 'id': 'm0',
> 'props': { 'netdev': 'hn0', 'queue': 'tx', 'outdev': 'mirror0' } } }
> -{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-redirector', 'id':
> 'redire0', 'props': { 'netdev': 'hn0', 'queue': 'rx', 'indev': 'compare_out' } } }
> -{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-redirector', 'id':
> 'redire1', 'props': { 'netdev': 'hn0', 'queue': 'rx', 'outdev': 'compare0' } } }
> +{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-mirror',
> +'id': 'm0', 'netdev': 'hn0', 'queue': 'tx', 'outdev': 'mirror0' } }
> +{'execute': 'object-add', 'arguments':{ 'qom-type':
> +'filter-redirector', 'id': 'redire0', 'netdev': 'hn0', 'queue': 'rx',
> +'indev': 'compare_out' } }
> +{'execute': 'object-add', 'arguments':{ 'qom-type':
> +'filter-redirector', 'id': 'redire1', 'netdev': 'hn0', 'queue': 'rx',
> +'outdev': 'compare0' } }
>  {'execute': 'object-add', 'arguments':{ 'qom-type': 'iothread', 'id':
> 'iothread1' } }
> -{'execute': 'object-add', 'arguments':{ 'qom-type': 'colo-compare', 'id':
> 'comp0', 'props': { 'primary_in': 'compare0-0', 'secondary_in': 'compare1',
> 'outdev': 'compare_out0', 'iothread': 'iothread1' } } }
> +{'execute': 'object-add', 'arguments':{ 'qom-type': 'colo-compare',
> +'id': 'comp0', 'primary_in': 'compare0-0', 'secondary_in': 'compare1',
> +'outdev': 'compare_out0', 'iothread': 'iothread1' } }
> 
>  {'execute': 'migrate-set-capabilities', 'arguments':{ 'capabilities': [ {'capability':
> 'x-colo', 'state': true } ] } }
>  {'execute': 'migrate', 'arguments':{ 'uri': 'tcp:127.0.0.2:9998' } } @@ -318,11
> +318,11 @@ Wait until disk is synced, then:
>  {'execute': 'human-monitor-command', 'arguments':{ 'command-line':
> 'drive_add -n buddy
> driver=replication,mode=primary,file.driver=nbd,file.host=127.0.0.1,file.port
> =9999,file.export=parent0,node-name=replication0'}}
>  {'execute': 'x-blockdev-change', 'arguments':{ 'parent': 'colo-disk0', 'node':
> 'replication0' } }
> 
> -{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-mirror', 'id': 'm0',
> 'props': { 'insert': 'before', 'position': 'id=rew0', 'netdev': 'hn0', 'queue': 'tx',
> 'outdev': 'mirror0' } } }
> -{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-redirector', 'id':
> 'redire0', 'props': { 'insert': 'before', 'position': 'id=rew0', 'netdev': 'hn0',
> 'queue': 'rx', 'indev': 'compare_out' } } }
> -{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-redirector', 'id':
> 'redire1', 'props': { 'insert': 'before', 'position': 'id=rew0', 'netdev': 'hn0',
> 'queue': 'rx', 'outdev': 'compare0' } } }
> +{'execute': 'object-add', 'arguments':{ 'qom-type': 'filter-mirror',
> +'id': 'm0', 'insert': 'before', 'position': 'id=rew0', 'netdev': 'hn0',
> +'queue': 'tx', 'outdev': 'mirror0' } }
> +{'execute': 'object-add', 'arguments':{ 'qom-type':
> +'filter-redirector', 'id': 'redire0', 'insert': 'before', 'position':
> +'id=rew0', 'netdev': 'hn0', 'queue': 'rx', 'indev': 'compare_out' } }
> +{'execute': 'object-add', 'arguments':{ 'qom-type':
> +'filter-redirector', 'id': 'redire1', 'insert': 'before', 'position':
> +'id=rew0', 'netdev': 'hn0', 'queue': 'rx', 'outdev': 'compare0' } }
>  {'execute': 'object-add', 'arguments':{ 'qom-type': 'iothread', 'id':
> 'iothread1' } }
> -{'execute': 'object-add', 'arguments':{ 'qom-type': 'colo-compare', 'id':
> 'comp0', 'props': { 'primary_in': 'compare0-0', 'secondary_in': 'compare1',
> 'outdev': 'compare_out0', 'iothread': 'iothread1' } } }
> +{'execute': 'object-add', 'arguments':{ 'qom-type': 'colo-compare',
> +'id': 'comp0', 'primary_in': 'compare0-0', 'secondary_in': 'compare1',
> +'outdev': 'compare_out0', 'iothread': 'iothread1' } }
> 
>  {'execute': 'migrate-set-capabilities', 'arguments':{ 'capabilities': [ {'capability':
> 'x-colo', 'state': true } ] } }
>  {'execute': 'migrate', 'arguments':{ 'uri': 'tcp:127.0.0.1:9998' } }
> --
> 1.8.3.1


Re: [PATCH] docs/COLO-FT.txt: Drop deprecated 'props' from object-add in COLO docs
Posted by Markus Armbruster 2 years, 5 months ago
"Rao, Lei" <lei.rao@intel.com> writes:

> From: "Rao, Lei" <lei.rao@intel.com>
>
> With the removal of deprecated 'props' from object-add in the commit of
> "50243407457a9fb0ed17b9a9ba9fc9aee09495b1", we also should update COLO's
> documents.

We should've done this right when we deprecated it.  Not your fault, and
better late than never.

Recommend to quote commits like

    in commit 5024340745 "qapi/qom: Drop deprecated 'props' from
    object-add" (v6.0.0)

I have

    [alias]
            whatis = "!f() { git --no-pager show -s --pretty=\"tformat:%h \"%s\" (`git dc $1 | sed 's/~.*//;s/%/%%/g'`, %cd)\" --date=short $1; }; f"

in my ~/.gitconfig, so I can run

    $ git whatis 50243407457a9fb0ed17b9a9ba9fc9aee09495b1
    5024340745 qapi/qom: Drop deprecated 'props' from object-add (v6.0.0-rc0, 2021-03-19)

> Signed-off-by: Lei Rao <lei.rao@intel.com>

Reviewed-by: Markus Armbruster <armbru@redhat.com>

Same issue in docs/system/authz.rst, docs/throttle.txt, and
docs/tools/qemu-nbd.rst.  Care to fix it there as well?

Also...

> ---
>  docs/COLO-FT.txt | 16 ++++++++--------
>  1 file changed, 8 insertions(+), 8 deletions(-)
>
> diff --git a/docs/COLO-FT.txt b/docs/COLO-FT.txt
> index 8d6d53a..fd5ffcc 100644
> --- a/docs/COLO-FT.txt
> +++ b/docs/COLO-FT.txt
> @@ -289,11 +289,11 @@ Wait until disk is synced, then:
>  {'execute': 'human-monitor-command', 'arguments':{ 'command-line': 'drive_add -n buddy driver=replication,mode=primary,file.driver=nbd,file.host=127.0.0.2,file.port=9999,file.export=parent0,node-name=replication0'}}
>  {'execute': 'x-blockdev-change', 'arguments':{ 'parent': 'colo-disk0', 'node': 'replication0' } }
>  

... I'd like us to use double quotes in examples, not single quotes.
QMP supports single quotes as an extension over JSON.  Best to avoid it.
Separate patch, of course.

Same in docs/block-replication.txt.

[...]


RE: [PATCH] docs/COLO-FT.txt: Drop deprecated 'props' from object-add in COLO docs
Posted by Rao, Lei 2 years, 5 months ago
OK,all files you mentioned will be modified in the next patch.

Thanks,
Lei.

-----Original Message-----
From: Markus Armbruster <armbru@redhat.com> 
Sent: Thursday, November 18, 2021 2:50 PM
To: Rao, Lei <lei.rao@intel.com>
Cc: Zhang, Chen <chen.zhang@intel.com>; zhang.zhanghailiang@huawei.com; quintela@redhat.com; dgilbert@redhat.com; qemu-trivial@nongnu.org; qemu-devel@nongnu.org
Subject: Re: [PATCH] docs/COLO-FT.txt: Drop deprecated 'props' from object-add in COLO docs

"Rao, Lei" <lei.rao@intel.com> writes:

> From: "Rao, Lei" <lei.rao@intel.com>
>
> With the removal of deprecated 'props' from object-add in the commit 
> of "50243407457a9fb0ed17b9a9ba9fc9aee09495b1", we also should update 
> COLO's documents.

We should've done this right when we deprecated it.  Not your fault, and better late than never.

Recommend to quote commits like

    in commit 5024340745 "qapi/qom: Drop deprecated 'props' from
    object-add" (v6.0.0)

I have

    [alias]
            whatis = "!f() { git --no-pager show -s --pretty=\"tformat:%h \"%s\" (`git dc $1 | sed 's/~.*//;s/%/%%/g'`, %cd)\" --date=short $1; }; f"

in my ~/.gitconfig, so I can run

    $ git whatis 50243407457a9fb0ed17b9a9ba9fc9aee09495b1
    5024340745 qapi/qom: Drop deprecated 'props' from object-add (v6.0.0-rc0, 2021-03-19)

> Signed-off-by: Lei Rao <lei.rao@intel.com>

Reviewed-by: Markus Armbruster <armbru@redhat.com>

Same issue in docs/system/authz.rst, docs/throttle.txt, and docs/tools/qemu-nbd.rst.  Care to fix it there as well?

Also...

> ---
>  docs/COLO-FT.txt | 16 ++++++++--------
>  1 file changed, 8 insertions(+), 8 deletions(-)
>
> diff --git a/docs/COLO-FT.txt b/docs/COLO-FT.txt index 
> 8d6d53a..fd5ffcc 100644
> --- a/docs/COLO-FT.txt
> +++ b/docs/COLO-FT.txt
> @@ -289,11 +289,11 @@ Wait until disk is synced, then:
>  {'execute': 'human-monitor-command', 'arguments':{ 'command-line': 
> 'drive_add -n buddy 
> driver=replication,mode=primary,file.driver=nbd,file.host=127.0.0.2,fi
> le.port=9999,file.export=parent0,node-name=replication0'}}
>  {'execute': 'x-blockdev-change', 'arguments':{ 'parent': 
> 'colo-disk0', 'node': 'replication0' } }
>  

... I'd like us to use double quotes in examples, not single quotes.
QMP supports single quotes as an extension over JSON.  Best to avoid it.
Separate patch, of course.

Same in docs/block-replication.txt.

[...]