File Coverage

blib/lib/Paws/ECS/CreateService.pm
Criterion Covered Total %
statement 6 6 100.0
branch n/a
condition n/a
subroutine 2 2 100.0
pod n/a
total 8 8 100.0


line stmt bran cond sub pod time code
1              
2             package Paws::ECS::CreateService;
3 1     1   295 use Moose;
  1         3  
  1         4  
4             has ClientToken => (is => 'ro', isa => 'Str', traits => ['NameInRequest'], request_name => 'clientToken' );
5             has Cluster => (is => 'ro', isa => 'Str', traits => ['NameInRequest'], request_name => 'cluster' );
6             has DeploymentConfiguration => (is => 'ro', isa => 'Paws::ECS::DeploymentConfiguration', traits => ['NameInRequest'], request_name => 'deploymentConfiguration' );
7             has DesiredCount => (is => 'ro', isa => 'Int', traits => ['NameInRequest'], request_name => 'desiredCount' , required => 1);
8             has LoadBalancers => (is => 'ro', isa => 'ArrayRef[Paws::ECS::LoadBalancer]', traits => ['NameInRequest'], request_name => 'loadBalancers' );
9             has PlacementConstraints => (is => 'ro', isa => 'ArrayRef[Paws::ECS::PlacementConstraint]', traits => ['NameInRequest'], request_name => 'placementConstraints' );
10             has PlacementStrategy => (is => 'ro', isa => 'ArrayRef[Paws::ECS::PlacementStrategy]', traits => ['NameInRequest'], request_name => 'placementStrategy' );
11             has Role => (is => 'ro', isa => 'Str', traits => ['NameInRequest'], request_name => 'role' );
12             has ServiceName => (is => 'ro', isa => 'Str', traits => ['NameInRequest'], request_name => 'serviceName' , required => 1);
13             has TaskDefinition => (is => 'ro', isa => 'Str', traits => ['NameInRequest'], request_name => 'taskDefinition' , required => 1);
14              
15 1     1   5394 use MooseX::ClassAttribute;
  1         2  
  1         7  
16              
17             class_has _api_call => (isa => 'Str', is => 'ro', default => 'CreateService');
18             class_has _returns => (isa => 'Str', is => 'ro', default => 'Paws::ECS::CreateServiceResponse');
19             class_has _result_key => (isa => 'Str', is => 'ro');
20             1;
21              
22             ### main pod documentation begin ###
23              
24             =head1 NAME
25              
26             Paws::ECS::CreateService - Arguments for method CreateService on Paws::ECS
27              
28             =head1 DESCRIPTION
29              
30             This class represents the parameters used for calling the method CreateService on the
31             Amazon EC2 Container Service service. Use the attributes of this class
32             as arguments to method CreateService.
33              
34             You shouldn't make instances of this class. Each attribute should be used as a named argument in the call to CreateService.
35              
36             As an example:
37              
38             $service_obj->CreateService(Att1 => $value1, Att2 => $value2, ...);
39              
40             Values for attributes that are native types (Int, String, Float, etc) can passed as-is (scalar values). Values for complex Types (objects) can be passed as a HashRef. The keys and values of the hashref will be used to instance the underlying object.
41              
42             =head1 ATTRIBUTES
43              
44              
45             =head2 ClientToken => Str
46              
47             Unique, case-sensitive identifier you provide to ensure the idempotency
48             of the request. Up to 32 ASCII characters are allowed.
49              
50              
51              
52             =head2 Cluster => Str
53              
54             The short name or full Amazon Resource Name (ARN) of the cluster on
55             which to run your service. If you do not specify a cluster, the default
56             cluster is assumed.
57              
58              
59              
60             =head2 DeploymentConfiguration => L<Paws::ECS::DeploymentConfiguration>
61              
62             Optional deployment parameters that control how many tasks run during
63             the deployment and the ordering of stopping and starting tasks.
64              
65              
66              
67             =head2 B<REQUIRED> DesiredCount => Int
68              
69             The number of instantiations of the specified task definition to place
70             and keep running on your cluster.
71              
72              
73              
74             =head2 LoadBalancers => ArrayRef[L<Paws::ECS::LoadBalancer>]
75              
76             A load balancer object representing the load balancer to use with your
77             service. Currently, you are limited to one load balancer or target
78             group per service. After you create a service, the load balancer name
79             or target group ARN, container name, and container port specified in
80             the service definition are immutable.
81              
82             For Classic Load Balancers, this object must contain the load balancer
83             name, the container name (as it appears in a container definition), and
84             the container port to access from the load balancer. When a task from
85             this service is placed on a container instance, the container instance
86             is registered with the load balancer specified here.
87              
88             For Application Load Balancers and Network Load Balancers, this object
89             must contain the load balancer target group ARN, the container name (as
90             it appears in a container definition), and the container port to access
91             from the load balancer. When a task from this service is placed on a
92             container instance, the container instance and port combination is
93             registered as a target in the target group specified here.
94              
95              
96              
97             =head2 PlacementConstraints => ArrayRef[L<Paws::ECS::PlacementConstraint>]
98              
99             An array of placement constraint objects to use for tasks in your
100             service. You can specify a maximum of 10 constraints per task (this
101             limit includes constraints in the task definition and those specified
102             at run time).
103              
104              
105              
106             =head2 PlacementStrategy => ArrayRef[L<Paws::ECS::PlacementStrategy>]
107              
108             The placement strategy objects to use for tasks in your service. You
109             can specify a maximum of 5 strategy rules per service.
110              
111              
112              
113             =head2 Role => Str
114              
115             The name or full Amazon Resource Name (ARN) of the IAM role that allows
116             Amazon ECS to make calls to your load balancer on your behalf. This
117             parameter is required if you are using a load balancer with your
118             service. If you specify the C<role> parameter, you must also specify a
119             load balancer object with the C<loadBalancers> parameter.
120              
121             If your specified role has a path other than C</>, then you must either
122             specify the full role ARN (this is recommended) or prefix the role name
123             with the path. For example, if a role with the name C<bar> has a path
124             of C</foo/> then you would specify C</foo/bar> as the role name. For
125             more information, see Friendly Names and Paths in the I<IAM User
126             Guide>.
127              
128              
129              
130             =head2 B<REQUIRED> ServiceName => Str
131              
132             The name of your service. Up to 255 letters (uppercase and lowercase),
133             numbers, hyphens, and underscores are allowed. Service names must be
134             unique within a cluster, but you can have similarly named services in
135             multiple clusters within a region or across multiple regions.
136              
137              
138              
139             =head2 B<REQUIRED> TaskDefinition => Str
140              
141             The C<family> and C<revision> (C<family:revision>) or full Amazon
142             Resource Name (ARN) of the task definition to run in your service. If a
143             C<revision> is not specified, the latest C<ACTIVE> revision is used.
144              
145              
146              
147              
148             =head1 SEE ALSO
149              
150             This class forms part of L<Paws>, documenting arguments for method CreateService in L<Paws::ECS>
151              
152             =head1 BUGS and CONTRIBUTIONS
153              
154             The source code is located here: https://github.com/pplu/aws-sdk-perl
155              
156             Please report bugs to: https://github.com/pplu/aws-sdk-perl/issues
157              
158             =cut
159