Change in ovirt-engine-sdk[sdk_4.1]: Add support for custom headers and query parameters

From Ondra Machacek <omachace@redhat.com>:
Ondra Machacek has submitted this change and it was merged. Change subject: Add support for custom headers and query parameters ...................................................................... Add support for custom headers and query parameters Currently there is no way to send to the server custom headers or query parameters. This patch adds support for that. For example, if the caller, for whatever the reason, needs to send the 'My: myvalue' header and the 'your=yourvalue' query parameter to the request to add a virtual machine, it can be done as follows: # Get the reference to the service that managse the collection # of virtual machines: vms_service = connection.system_service().vms_service() # Add the virtual machine, with a custom query and header vms_service.add( types.Vm(), headers={'my': 'value'}, query={'your': 'value'}, ) Change-Id: I27ca5f421215da1d920474445be08746248e4aed Signed-off-by: Ondra Machacek <omachace@redhat.com> Signed-off-by: Juan Hernandez <juan.hernandez@redhat.com> (cherry picked from commit 5f518c2992d2c9f7bf29e62f4df6aae2be26d3f2) --- M generator/src/main/java/org/ovirt/sdk/python/ServicesGenerator.java M sdk/tests/server.py M sdk/tests/test_vm_service.py 3 files changed, 124 insertions(+), 14 deletions(-) Approvals: Ondra Machacek: Verified; Looks good to me, approved Jenkins CI: Passed CI tests -- To view, visit https://gerrit.ovirt.org/73041 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: merged Gerrit-Change-Id: I27ca5f421215da1d920474445be08746248e4aed Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine-sdk Gerrit-Branch: sdk_4.1 Gerrit-Owner: Ondra Machacek <omachace@redhat.com> Gerrit-Reviewer: Jenkins CI Gerrit-Reviewer: Ondra Machacek <omachace@redhat.com> Gerrit-Reviewer: gerrit-hooks <automation@ovirt.org>
participants (1)
-
Code Review