aws_sdk_batch/client/
create_scheduling_policy.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2impl super::Client {
3    /// Constructs a fluent builder for the [`CreateSchedulingPolicy`](crate::operation::create_scheduling_policy::builders::CreateSchedulingPolicyFluentBuilder) operation.
4    ///
5    /// - The fluent builder is configurable:
6    ///   - [`name(impl Into<String>)`](crate::operation::create_scheduling_policy::builders::CreateSchedulingPolicyFluentBuilder::name) / [`set_name(Option<String>)`](crate::operation::create_scheduling_policy::builders::CreateSchedulingPolicyFluentBuilder::set_name):<br>required: **true**<br><p>The name of the fair-share scheduling policy. It can be up to 128 letters long. It can contain uppercase and lowercase letters, numbers, hyphens (-), and underscores (_).</p><br>
7    ///   - [`fairshare_policy(FairsharePolicy)`](crate::operation::create_scheduling_policy::builders::CreateSchedulingPolicyFluentBuilder::fairshare_policy) / [`set_fairshare_policy(Option<FairsharePolicy>)`](crate::operation::create_scheduling_policy::builders::CreateSchedulingPolicyFluentBuilder::set_fairshare_policy):<br>required: **false**<br><p>The fair-share scheduling policy details.</p><br>
8    ///   - [`tags(impl Into<String>, impl Into<String>)`](crate::operation::create_scheduling_policy::builders::CreateSchedulingPolicyFluentBuilder::tags) / [`set_tags(Option<HashMap::<String, String>>)`](crate::operation::create_scheduling_policy::builders::CreateSchedulingPolicyFluentBuilder::set_tags):<br>required: **false**<br><p>The tags that you apply to the scheduling policy to help you categorize and organize your resources. Each tag consists of a key and an optional value. For more information, see <a href="https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html">Tagging Amazon Web Services Resources</a> in <i>Amazon Web Services General Reference</i>.</p> <p>These tags can be updated or removed using the <a href="https://docs.aws.amazon.com/batch/latest/APIReference/API_TagResource.html">TagResource</a> and <a href="https://docs.aws.amazon.com/batch/latest/APIReference/API_UntagResource.html">UntagResource</a> API operations.</p><br>
9    /// - On success, responds with [`CreateSchedulingPolicyOutput`](crate::operation::create_scheduling_policy::CreateSchedulingPolicyOutput) with field(s):
10    ///   - [`name(Option<String>)`](crate::operation::create_scheduling_policy::CreateSchedulingPolicyOutput::name): <p>The name of the scheduling policy.</p>
11    ///   - [`arn(Option<String>)`](crate::operation::create_scheduling_policy::CreateSchedulingPolicyOutput::arn): <p>The Amazon Resource Name (ARN) of the scheduling policy. The format is <code>aws:<i>Partition</i>:batch:<i>Region</i>:<i>Account</i>:scheduling-policy/<i>Name</i> </code>. For example, <code>aws:aws:batch:us-west-2:123456789012:scheduling-policy/MySchedulingPolicy</code>.</p>
12    /// - On failure, responds with [`SdkError<CreateSchedulingPolicyError>`](crate::operation::create_scheduling_policy::CreateSchedulingPolicyError)
13    pub fn create_scheduling_policy(&self) -> crate::operation::create_scheduling_policy::builders::CreateSchedulingPolicyFluentBuilder {
14        crate::operation::create_scheduling_policy::builders::CreateSchedulingPolicyFluentBuilder::new(self.handle.clone())
15    }
16}