Skip to content
  • Markus Armbruster's avatar
    db291641
    qapi: Implement deprecated-input=reject for QMP command arguments · db291641
    Markus Armbruster authored
    
    
    This policy rejects deprecated input, and thus permits "testing the
    future".  Implement it for QMP command arguments: reject commands with
    deprecated ones.  Example: when QEMU is run with -compat
    deprecated-input=reject, then
    
        {"execute": "eject", "arguments": {"device": "cd"}}
    
    fails like this
    
        {"error": {"class": "GenericError", "desc": "Deprecated parameter 'device' disabled by policy"}}
    
    When the deprecated parameter is removed, the error will change to
    
        {"error": {"class": "GenericError", "desc": "Parameter 'device' is unexpected"}}
    
    Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
    Reviewed-by: default avatarEric Blake <eblake@redhat.com>
    Message-Id: <20210318155519.1224118-11-armbru@redhat.com>
    db291641
    qapi: Implement deprecated-input=reject for QMP command arguments
    Markus Armbruster authored
    
    
    This policy rejects deprecated input, and thus permits "testing the
    future".  Implement it for QMP command arguments: reject commands with
    deprecated ones.  Example: when QEMU is run with -compat
    deprecated-input=reject, then
    
        {"execute": "eject", "arguments": {"device": "cd"}}
    
    fails like this
    
        {"error": {"class": "GenericError", "desc": "Deprecated parameter 'device' disabled by policy"}}
    
    When the deprecated parameter is removed, the error will change to
    
        {"error": {"class": "GenericError", "desc": "Parameter 'device' is unexpected"}}
    
    Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
    Reviewed-by: default avatarEric Blake <eblake@redhat.com>
    Message-Id: <20210318155519.1224118-11-armbru@redhat.com>
Loading