Bug 1430795 - Automatically increase max memory if necessary in REST
Summary: Automatically increase max memory if necessary in REST
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: ovirt-engine
Classification: oVirt
Component: RestAPI
Version: 4.1.1
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ovirt-4.1.1
: 4.1.1.5
Assignee: jniederm
QA Contact: Israel Pinto
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-03-09 15:41 UTC by jniederm
Modified: 2017-04-21 09:45 UTC (History)
4 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2017-04-21 09:45:47 UTC
oVirt Team: Virt
Embargoed:
rule-engine: ovirt-4.1+
mgoldboi: exception+
rule-engine: planning_ack+
rule-engine: devel_ack+
mavital: testing_ack+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 73910 0 master MERGED restapi: Autoadjusting max memory when VM created 2017-03-13 09:47:30 UTC
oVirt gerrit 74056 0 ovirt-engine-4.1 MERGED restapi: Autoadjusting max memory when VM created 2017-03-14 14:19:33 UTC
oVirt gerrit 74143 0 ovirt-engine-4.1.1.z MERGED restapi: Autoadjusting max memory when VM created 2017-03-15 14:10:22 UTC

Description jniederm 2017-03-09 15:41:33 UTC
Description of problem:
If a VM is created using REST api and 
* max memory is not specified
* and memory is specified larger than max memory in the template
then vm creation fails. This breaks backward compatibility of engine 4.1 with 4.0.

Automatically increase max memory if memory was specified and max memory was omitted in the rest request.

Comment 1 Vladimir 2017-03-22 14:12:50 UTC
Verified on 4.1.1.5-0.1.el7

1. Created VM via REST API script without max_memory specified - max_memory was updated to 4 x memory
2. Updated every instance type memory value via REST API - max_memory was updated to 4 x memory

Comment 2 Israel Pinto 2017-03-22 14:15:14 UTC
(In reply to Vladimir from comment #1)
> Verified on 4.1.1.5-0.1.el7
> 
> 1. Created VM via REST API script without max_memory specified - max_memory
> was updated to 4 x memory
> 2. Updated every instance type memory value via REST API - max_memory was
> updated to 4 x memory

Verify base on this check.

Comment 3 Vladimir 2017-03-22 14:55:35 UTC
(In reply to Vladimir from comment #1)
> Verified on 4.1.1.5-0.1.el7
> 
> 1. Created VM via REST API script without max_memory specified - max_memory
> was updated to 4 x memory
> 2. Updated every instance type memory value via REST API - max_memory was
> updated to 4 x memory

Sorry, my mistake it doesn't work for instance types, updating instance types still produces 409 error: Memory size (10240MB) cannot exceed maximum memory size (2048MB)


Note You need to log in before you can comment on or make changes to this bug.