mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-07-31 22:33:53 -06:00
qapi/block-core: deprecate some block-job- APIs
For change, pause, resume, complete, dismiss and finalize actions corresponding job- and block-job commands are almost equal. The difference is in find_block_job_locked() vs find_job_locked() functions. What's different? 1. find_block_job_locked() checks whether the found job is a block-job. This is OK when moving to more generic API, no needs to document this change. 2. find_block_job_locked() reports DeviceNotActive on failure, when find_job_locked() reports GenericError. So, let's document this difference in deprecated.txt. Still, for dismiss and finalize errors are not documented at all, so be silent in deprecated.txt as well. ACKed-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru> Message-ID: <20250409084232.28201-3-vsementsov@yandex-team.ru>
This commit is contained in:
parent
da17dd5c5e
commit
b836bf2ab6
2 changed files with 61 additions and 0 deletions
|
@ -148,6 +148,37 @@ options are removed in favor of using explicit ``blockdev-create`` and
|
||||||
``blockdev-add`` calls. See :doc:`/interop/live-block-operations` for
|
``blockdev-add`` calls. See :doc:`/interop/live-block-operations` for
|
||||||
details.
|
details.
|
||||||
|
|
||||||
|
``block-job-pause`` (since 10.1)
|
||||||
|
''''''''''''''''''''''''''''''''
|
||||||
|
|
||||||
|
Use ``job-pause`` instead. The only difference is that ``job-pause``
|
||||||
|
always reports GenericError on failure when ``block-job-pause`` reports
|
||||||
|
DeviceNotActive when block-job is not found.
|
||||||
|
|
||||||
|
``block-job-resume`` (since 10.1)
|
||||||
|
'''''''''''''''''''''''''''''''''
|
||||||
|
|
||||||
|
Use ``job-resume`` instead. The only difference is that ``job-resume``
|
||||||
|
always reports GenericError on failure when ``block-job-resume`` reports
|
||||||
|
DeviceNotActive when block-job is not found.
|
||||||
|
|
||||||
|
``block-job-complete`` (since 10.1)
|
||||||
|
'''''''''''''''''''''''''''''''''''
|
||||||
|
|
||||||
|
Use ``job-complete`` instead. The only difference is that ``job-complete``
|
||||||
|
always reports GenericError on failure when ``block-job-complete`` reports
|
||||||
|
DeviceNotActive when block-job is not found.
|
||||||
|
|
||||||
|
``block-job-dismiss`` (since 10.1)
|
||||||
|
''''''''''''''''''''''''''''''''''
|
||||||
|
|
||||||
|
Use ``job-dismiss`` instead.
|
||||||
|
|
||||||
|
``block-job-finalize`` (since 10.1)
|
||||||
|
'''''''''''''''''''''''''''''''''''
|
||||||
|
|
||||||
|
Use ``job-finalize`` instead.
|
||||||
|
|
||||||
``query-migrationthreads`` (since 9.2)
|
``query-migrationthreads`` (since 9.2)
|
||||||
''''''''''''''''''''''''''''''''''''''
|
''''''''''''''''''''''''''''''''''''''
|
||||||
|
|
||||||
|
|
|
@ -2969,6 +2969,11 @@
|
||||||
# the name of the parameter), but since QEMU 2.7 it can have other
|
# the name of the parameter), but since QEMU 2.7 it can have other
|
||||||
# values.
|
# values.
|
||||||
#
|
#
|
||||||
|
# Features:
|
||||||
|
#
|
||||||
|
# @deprecated: This command is deprecated. Use @job-pause
|
||||||
|
# instead.
|
||||||
|
#
|
||||||
# Errors:
|
# Errors:
|
||||||
# - If no background operation is active on this device,
|
# - If no background operation is active on this device,
|
||||||
# DeviceNotActive
|
# DeviceNotActive
|
||||||
|
@ -2976,6 +2981,7 @@
|
||||||
# Since: 1.3
|
# Since: 1.3
|
||||||
##
|
##
|
||||||
{ 'command': 'block-job-pause', 'data': { 'device': 'str' },
|
{ 'command': 'block-job-pause', 'data': { 'device': 'str' },
|
||||||
|
'features': ['deprecated'],
|
||||||
'allow-preconfig': true }
|
'allow-preconfig': true }
|
||||||
|
|
||||||
##
|
##
|
||||||
|
@ -2992,6 +2998,11 @@
|
||||||
# the name of the parameter), but since QEMU 2.7 it can have other
|
# the name of the parameter), but since QEMU 2.7 it can have other
|
||||||
# values.
|
# values.
|
||||||
#
|
#
|
||||||
|
# Features:
|
||||||
|
#
|
||||||
|
# @deprecated: This command is deprecated. Use @job-resume
|
||||||
|
# instead.
|
||||||
|
#
|
||||||
# Errors:
|
# Errors:
|
||||||
# - If no background operation is active on this device,
|
# - If no background operation is active on this device,
|
||||||
# DeviceNotActive
|
# DeviceNotActive
|
||||||
|
@ -2999,6 +3010,7 @@
|
||||||
# Since: 1.3
|
# Since: 1.3
|
||||||
##
|
##
|
||||||
{ 'command': 'block-job-resume', 'data': { 'device': 'str' },
|
{ 'command': 'block-job-resume', 'data': { 'device': 'str' },
|
||||||
|
'features': ['deprecated'],
|
||||||
'allow-preconfig': true }
|
'allow-preconfig': true }
|
||||||
|
|
||||||
##
|
##
|
||||||
|
@ -3026,6 +3038,11 @@
|
||||||
# the name of the parameter), but since QEMU 2.7 it can have other
|
# the name of the parameter), but since QEMU 2.7 it can have other
|
||||||
# values.
|
# values.
|
||||||
#
|
#
|
||||||
|
# Features:
|
||||||
|
#
|
||||||
|
# @deprecated: This command is deprecated. Use @job-complete
|
||||||
|
# instead.
|
||||||
|
#
|
||||||
# Errors:
|
# Errors:
|
||||||
# - If no background operation is active on this device,
|
# - If no background operation is active on this device,
|
||||||
# DeviceNotActive
|
# DeviceNotActive
|
||||||
|
@ -3033,6 +3050,7 @@
|
||||||
# Since: 1.3
|
# Since: 1.3
|
||||||
##
|
##
|
||||||
{ 'command': 'block-job-complete', 'data': { 'device': 'str' },
|
{ 'command': 'block-job-complete', 'data': { 'device': 'str' },
|
||||||
|
'features': ['deprecated'],
|
||||||
'allow-preconfig': true }
|
'allow-preconfig': true }
|
||||||
|
|
||||||
##
|
##
|
||||||
|
@ -3053,9 +3071,15 @@
|
||||||
#
|
#
|
||||||
# @id: The job identifier.
|
# @id: The job identifier.
|
||||||
#
|
#
|
||||||
|
# Features:
|
||||||
|
#
|
||||||
|
# @deprecated: This command is deprecated. Use @job-dismiss
|
||||||
|
# instead.
|
||||||
|
#
|
||||||
# Since: 2.12
|
# Since: 2.12
|
||||||
##
|
##
|
||||||
{ 'command': 'block-job-dismiss', 'data': { 'id': 'str' },
|
{ 'command': 'block-job-dismiss', 'data': { 'id': 'str' },
|
||||||
|
'features': ['deprecated'],
|
||||||
'allow-preconfig': true }
|
'allow-preconfig': true }
|
||||||
|
|
||||||
##
|
##
|
||||||
|
@ -3075,9 +3099,15 @@
|
||||||
#
|
#
|
||||||
# @id: The job identifier.
|
# @id: The job identifier.
|
||||||
#
|
#
|
||||||
|
# Features:
|
||||||
|
#
|
||||||
|
# @deprecated: This command is deprecated. Use @job-finalize
|
||||||
|
# instead.
|
||||||
|
#
|
||||||
# Since: 2.12
|
# Since: 2.12
|
||||||
##
|
##
|
||||||
{ 'command': 'block-job-finalize', 'data': { 'id': 'str' },
|
{ 'command': 'block-job-finalize', 'data': { 'id': 'str' },
|
||||||
|
'features': ['deprecated'],
|
||||||
'allow-preconfig': true }
|
'allow-preconfig': true }
|
||||||
|
|
||||||
##
|
##
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue