3.9.1. Create flavor with rxtx_factor

 
MethodURIDescription
POST/v2/{tenant_id}/flavors

Creates a flavor. Includes the rxtx_factor extended attribute.

Normal response codes: 200

 3.9.1.1. Request

This table shows the URI parameters for the create flavor with rxtx_factor request:

NameTypeDescription

{tenant_id}

​String

The ID for the tenant or account in a multi-tenancy cloud.

 

Example 3.77. Create flavor with rxtx_factor: JSON request

{
    "flavor": {
        "name": "flavortest",
        "ram": 1024,
        "vcpus": 2,
        "disk": 10,
        "id": "100",
        "rxtx_factor": 2.0
    }
}

 

Example 3.78. Create flavor with rxtx_factor: XML request

<?xml version="1.0" encoding="UTF-8"?>
<flavor xmlns="http://docs.openstack.org/compute/api/v1.1"
    xmlns:OS-FLV-EXT-DATA="http://docs.openstack.org/compute/ext/flavor_extra_data/api/v1.1"
    name="flavortest"
    ram="1024"
    vcpus="2"
    disk="10"
    id="100"
    rxtx_factor="2.0" />

This operation does not require a request body.

 3.9.1.2. Response

 

Example 3.79. Create flavor with rxtx_factor: JSON response

{
    "flavor": {
        "disk": 10,
        "id": "100",
        "links": [
            {
                "href": "http://openstack.example.com/v2/openstack/flavors/100",
                "rel": "self"
            },
            {
                "href": "http://openstack.example.com/openstack/flavors/100",
                "rel": "bookmark"
            }
        ],
        "name": "flavortest",
        "ram": 1024,
        "rxtx_factor": 2.0,
        "vcpus": 2
    }
}

 

Example 3.80. Create flavor with rxtx_factor: XML response

<?xml version='1.0' encoding='UTF-8'?>
<flavor xmlns:atom="http://www.w3.org/2005/Atom" xmlns="http://docs.openstack.org/compute/api/v1.1" disk="10" vcpus="2" ram="1024" name="flavortest" id="100" rxtx_factor="2.0">
  <atom:link href="http://openstack.example.com/v2/openstack/flavors/100" rel="self"/>
  <atom:link href="http://openstack.example.com/openstack/flavors/100" rel="bookmark"/>
</flavor>

This operation does not return a response body.

Questions? Discuss on ask.openstack.org
Found an error? Report a bug against this page


loading table of contents...