Amazon.Batch.AmazonBatchClient.CreateComputeEnvironment C# (CSharp) Method

CreateComputeEnvironment() public method

Creates an AWS Batch compute environment. You can create MANAGED or UNMANAGEDcompute environments.

In a managed compute environment, AWS Batch manages the compute resources within the environment, based on the compute resources that you specify. Instances launched into a managed compute environment use the latest Amazon ECS-optimized AMI. You can choose to use Amazon EC2 On-Demand instances in your managed compute environment, or you can use Amazon EC2 Spot instances that only launch when the Spot bid price is below a specified percentage of the On-Demand price.

In an unmanaged compute environment, you can manage your own compute resources. This provides more compute resource configuration options, such as using a custom AMI, but you must ensure that your AMI meets the Amazon ECS container instance AMI specification. For more information, see Container Instance AMIs in the Amazon EC2 Container Service Developer Guide. After you have created your unmanaged compute environment, you can use the DescribeComputeEnvironments operation to find the Amazon ECS cluster that is associated with it and then manually launch your container instances into that Amazon ECS cluster. For more information, see Launching an Amazon ECS Container Instance in the Amazon EC2 Container Service Developer Guide.

/// These errors are usually caused by a client action, such as using an action or resource /// on behalf of a user that doesn't have permission to use the action or resource, or /// specifying an identifier that is not valid. /// /// These errors are usually caused by a server issue. ///
public CreateComputeEnvironment ( CreateComputeEnvironmentRequest request ) : CreateComputeEnvironmentResponse
request Amazon.Batch.Model.CreateComputeEnvironmentRequest Container for the necessary parameters to execute the CreateComputeEnvironment service method.
return Amazon.Batch.Model.CreateComputeEnvironmentResponse
        public CreateComputeEnvironmentResponse CreateComputeEnvironment(CreateComputeEnvironmentRequest request)
        {
            var marshaller = new CreateComputeEnvironmentRequestMarshaller();
            var unmarshaller = CreateComputeEnvironmentResponseUnmarshaller.Instance;

            return Invoke<CreateComputeEnvironmentRequest,CreateComputeEnvironmentResponse>(request, marshaller, unmarshaller);
        }