openstack.blockstorage.QosV3
Explore with Pulumi AI
Manages a V3 block storage Quality-Of-Servirce (qos) resource within OpenStack.
Note: This usually requires admin privileges.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as openstack from "@pulumi/openstack";
const qos = new openstack.blockstorage.QosV3("qos", {
name: "foo",
consumer: "back-end",
specs: {
read_iops_sec: "40000",
write_iops_sec: "40000",
},
});
import pulumi
import pulumi_openstack as openstack
qos = openstack.blockstorage.QosV3("qos",
name="foo",
consumer="back-end",
specs={
"read_iops_sec": "40000",
"write_iops_sec": "40000",
})
package main
import (
"github.com/pulumi/pulumi-openstack/sdk/v5/go/openstack/blockstorage"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := blockstorage.NewQosV3(ctx, "qos", &blockstorage.QosV3Args{
Name: pulumi.String("foo"),
Consumer: pulumi.String("back-end"),
Specs: pulumi.StringMap{
"read_iops_sec": pulumi.String("40000"),
"write_iops_sec": pulumi.String("40000"),
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using OpenStack = Pulumi.OpenStack;
return await Deployment.RunAsync(() =>
{
var qos = new OpenStack.BlockStorage.QosV3("qos", new()
{
Name = "foo",
Consumer = "back-end",
Specs =
{
{ "read_iops_sec", "40000" },
{ "write_iops_sec", "40000" },
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.openstack.blockstorage.QosV3;
import com.pulumi.openstack.blockstorage.QosV3Args;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var qos = new QosV3("qos", QosV3Args.builder()
.name("foo")
.consumer("back-end")
.specs(Map.ofEntries(
Map.entry("read_iops_sec", "40000"),
Map.entry("write_iops_sec", "40000")
))
.build());
}
}
resources:
qos:
type: openstack:blockstorage:QosV3
properties:
name: foo
consumer: back-end
specs:
read_iops_sec: '40000'
write_iops_sec: '40000'
Create QosV3 Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new QosV3(name: string, args?: QosV3Args, opts?: CustomResourceOptions);
@overload
def QosV3(resource_name: str,
args: Optional[QosV3Args] = None,
opts: Optional[ResourceOptions] = None)
@overload
def QosV3(resource_name: str,
opts: Optional[ResourceOptions] = None,
consumer: Optional[str] = None,
name: Optional[str] = None,
region: Optional[str] = None,
specs: Optional[Mapping[str, str]] = None)
func NewQosV3(ctx *Context, name string, args *QosV3Args, opts ...ResourceOption) (*QosV3, error)
public QosV3(string name, QosV3Args? args = null, CustomResourceOptions? opts = null)
type: openstack:blockstorage:QosV3
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args QosV3Args
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args QosV3Args
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args QosV3Args
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args QosV3Args
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args QosV3Args
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var qosV3Resource = new OpenStack.BlockStorage.QosV3("qosV3Resource", new()
{
Consumer = "string",
Name = "string",
Region = "string",
Specs =
{
{ "string", "string" },
},
});
example, err := blockstorage.NewQosV3(ctx, "qosV3Resource", &blockstorage.QosV3Args{
Consumer: pulumi.String("string"),
Name: pulumi.String("string"),
Region: pulumi.String("string"),
Specs: pulumi.StringMap{
"string": pulumi.String("string"),
},
})
var qosV3Resource = new QosV3("qosV3Resource", QosV3Args.builder()
.consumer("string")
.name("string")
.region("string")
.specs(Map.of("string", "string"))
.build());
qos_v3_resource = openstack.blockstorage.QosV3("qosV3Resource",
consumer="string",
name="string",
region="string",
specs={
"string": "string",
})
const qosV3Resource = new openstack.blockstorage.QosV3("qosV3Resource", {
consumer: "string",
name: "string",
region: "string",
specs: {
string: "string",
},
});
type: openstack:blockstorage:QosV3
properties:
consumer: string
name: string
region: string
specs:
string: string
QosV3 Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The QosV3 resource accepts the following input properties:
- Consumer string
- The consumer of qos. Can be one of
front-end
,back-end
orboth
. Changing this updates theconsumer
of an existing qos. - Name string
- Name of the qos. Changing this creates a new qos.
- Region string
- The region in which to create the qos. If omitted,
the
region
argument of the provider is used. Changing this creates a new qos. - Specs Dictionary<string, string>
- Key/Value pairs of specs for the qos.
- Consumer string
- The consumer of qos. Can be one of
front-end
,back-end
orboth
. Changing this updates theconsumer
of an existing qos. - Name string
- Name of the qos. Changing this creates a new qos.
- Region string
- The region in which to create the qos. If omitted,
the
region
argument of the provider is used. Changing this creates a new qos. - Specs map[string]string
- Key/Value pairs of specs for the qos.
- consumer String
- The consumer of qos. Can be one of
front-end
,back-end
orboth
. Changing this updates theconsumer
of an existing qos. - name String
- Name of the qos. Changing this creates a new qos.
- region String
- The region in which to create the qos. If omitted,
the
region
argument of the provider is used. Changing this creates a new qos. - specs Map<String,String>
- Key/Value pairs of specs for the qos.
- consumer string
- The consumer of qos. Can be one of
front-end
,back-end
orboth
. Changing this updates theconsumer
of an existing qos. - name string
- Name of the qos. Changing this creates a new qos.
- region string
- The region in which to create the qos. If omitted,
the
region
argument of the provider is used. Changing this creates a new qos. - specs {[key: string]: string}
- Key/Value pairs of specs for the qos.
- consumer str
- The consumer of qos. Can be one of
front-end
,back-end
orboth
. Changing this updates theconsumer
of an existing qos. - name str
- Name of the qos. Changing this creates a new qos.
- region str
- The region in which to create the qos. If omitted,
the
region
argument of the provider is used. Changing this creates a new qos. - specs Mapping[str, str]
- Key/Value pairs of specs for the qos.
- consumer String
- The consumer of qos. Can be one of
front-end
,back-end
orboth
. Changing this updates theconsumer
of an existing qos. - name String
- Name of the qos. Changing this creates a new qos.
- region String
- The region in which to create the qos. If omitted,
the
region
argument of the provider is used. Changing this creates a new qos. - specs Map<String>
- Key/Value pairs of specs for the qos.
Outputs
All input properties are implicitly available as output properties. Additionally, the QosV3 resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing QosV3 Resource
Get an existing QosV3 resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: QosV3State, opts?: CustomResourceOptions): QosV3
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
consumer: Optional[str] = None,
name: Optional[str] = None,
region: Optional[str] = None,
specs: Optional[Mapping[str, str]] = None) -> QosV3
func GetQosV3(ctx *Context, name string, id IDInput, state *QosV3State, opts ...ResourceOption) (*QosV3, error)
public static QosV3 Get(string name, Input<string> id, QosV3State? state, CustomResourceOptions? opts = null)
public static QosV3 get(String name, Output<String> id, QosV3State state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Consumer string
- The consumer of qos. Can be one of
front-end
,back-end
orboth
. Changing this updates theconsumer
of an existing qos. - Name string
- Name of the qos. Changing this creates a new qos.
- Region string
- The region in which to create the qos. If omitted,
the
region
argument of the provider is used. Changing this creates a new qos. - Specs Dictionary<string, string>
- Key/Value pairs of specs for the qos.
- Consumer string
- The consumer of qos. Can be one of
front-end
,back-end
orboth
. Changing this updates theconsumer
of an existing qos. - Name string
- Name of the qos. Changing this creates a new qos.
- Region string
- The region in which to create the qos. If omitted,
the
region
argument of the provider is used. Changing this creates a new qos. - Specs map[string]string
- Key/Value pairs of specs for the qos.
- consumer String
- The consumer of qos. Can be one of
front-end
,back-end
orboth
. Changing this updates theconsumer
of an existing qos. - name String
- Name of the qos. Changing this creates a new qos.
- region String
- The region in which to create the qos. If omitted,
the
region
argument of the provider is used. Changing this creates a new qos. - specs Map<String,String>
- Key/Value pairs of specs for the qos.
- consumer string
- The consumer of qos. Can be one of
front-end
,back-end
orboth
. Changing this updates theconsumer
of an existing qos. - name string
- Name of the qos. Changing this creates a new qos.
- region string
- The region in which to create the qos. If omitted,
the
region
argument of the provider is used. Changing this creates a new qos. - specs {[key: string]: string}
- Key/Value pairs of specs for the qos.
- consumer str
- The consumer of qos. Can be one of
front-end
,back-end
orboth
. Changing this updates theconsumer
of an existing qos. - name str
- Name of the qos. Changing this creates a new qos.
- region str
- The region in which to create the qos. If omitted,
the
region
argument of the provider is used. Changing this creates a new qos. - specs Mapping[str, str]
- Key/Value pairs of specs for the qos.
- consumer String
- The consumer of qos. Can be one of
front-end
,back-end
orboth
. Changing this updates theconsumer
of an existing qos. - name String
- Name of the qos. Changing this creates a new qos.
- region String
- The region in which to create the qos. If omitted,
the
region
argument of the provider is used. Changing this creates a new qos. - specs Map<String>
- Key/Value pairs of specs for the qos.
Import
Qos can be imported using the qos_id
, e.g.
$ pulumi import openstack:blockstorage/qosV3:QosV3 qos 941793f0-0a34-4bc4-b72e-a6326ae58283
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- OpenStack pulumi/pulumi-openstack
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
openstack
Terraform Provider.