blib/lib/Paws/Batch/ResourceRequirement.pm untested

filter: Statementstmt 0.0% 0 / 7 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 1 Podpod n/a totaltotal 0.0% 0 / 8 CC 1 SCAR 6.9
CC
1
Cov
0%
BEGIN
2.0
CRAP 2.0
1 # Generated by default/object.tt
2 package Paws::Batch::ResourceRequirement;
3 use Moose;
4 has Type => (is => 'ro', isa => 'Str', request_name => 'type', traits => ['NameInRequest'], required => 1);
5 has Value => (is => 'ro', isa => 'Str', request_name => 'value', traits => ['NameInRequest'], required => 1);
6  
7 1;
8  
9 ### main pod documentation begin ###
10  
11 =head1 NAME
12  
13 Paws::Batch::ResourceRequirement
14  
15 =head1 USAGE
16  
17 This class represents one of two things:
18  
19 =head3 Arguments in a call to a service
20  
21 Use the attributes of this class as arguments to methods. You shouldn't make instances of this class.
22 Each attribute should be used as a named argument in the calls that expect this type of object.
23  
24 As an example, if Att1 is expected to be a Paws::Batch::ResourceRequirement object:
25  
26 $service_obj->Method(Att1 => { Type => $value, ..., Value => $value });
27  
28 =head3 Results returned from an API call
29  
30 Use accessors for each attribute. If Att1 is expected to be an Paws::Batch::ResourceRequirement object:
31  
32 $result = $service_obj->Method(...);
33 $result->Att1->Type
34  
35 =head1 DESCRIPTION
36  
37 The type and amount of a resource to assign to a container. The
38 supported resources include C<GPU>, C<MEMORY>, and C<VCPU>.
39  
40 =head1 ATTRIBUTES
41  
42  
43 =head2 B<REQUIRED> Type => Str
44  
45 The type of resource to assign to a container. The supported resources
46 include C<GPU>, C<MEMORY>, and C<VCPU>.
47  
48  
49 =head2 B<REQUIRED> Value => Str
50  
51 The quantity of the specified resource to reserve for the container.
52 The values vary based on the C<type> specified.
53  
54 =over
55  
56 =item type="GPU"
57  
58 The number of physical GPUs to reserve for the container. The number of
59 GPUs reserved for all containers in a job shouldn't exceed the number
60 of available GPUs on the compute resource that the job is launched on.
61  
62 GPUs are not available for jobs running on Fargate resources.
63  
64 =item type="MEMORY"
65  
66 The memory hard limit (in MiB) present to the container. This parameter
67 is supported for jobs running on EC2 resources. If your container
68 attempts to exceed the memory specified, the container is terminated.
69 This parameter maps to C<Memory> in the Create a container
70 (https://docs.docker.com/engine/api/v1.23/#create-a-container) section
71 of the Docker Remote API (https://docs.docker.com/engine/api/v1.23/)
72 and the C<--memory> option to docker run
73 (https://docs.docker.com/engine/reference/run/). You must specify at
74 least 4 MiB of memory for a job. This is required but can be specified
75 in several places for multi-node parallel (MNP) jobs. It must be
76 specified for each node at least once. This parameter maps to C<Memory>
77 in the Create a container
78 (https://docs.docker.com/engine/api/v1.23/#create-a-container) section
79 of the Docker Remote API (https://docs.docker.com/engine/api/v1.23/)
80 and the C<--memory> option to docker run
81 (https://docs.docker.com/engine/reference/run/).
82  
83 If you're trying to maximize your resource utilization by providing
84 your jobs as much memory as possible for a particular instance type,
85 see Memory Management
86 (https://docs.aws.amazon.com/batch/latest/userguide/memory-management.html)
87 in the I<AWS Batch User Guide>.
88  
89 For jobs running on Fargate resources, then C<value> is the hard limit
90 (in MiB), and must match one of the supported values and the C<VCPU>
91 values must be one of the values supported for that memory value.
92  
93 =over
94  
95 =item value = 512
96  
97 C<VCPU> = 0.25
98  
99 =item value = 1024
100  
101 C<VCPU> = 0.25 or 0.5
102  
103 =item value = 2048
104  
105 C<VCPU> = 0.25, 0.5, or 1
106  
107 =item value = 3072
108  
109 C<VCPU> = 0.5, or 1
110  
111 =item value = 4096
112  
113 C<VCPU> = 0.5, 1, or 2
114  
115 =item value = 5120, 6144, or 7168
116  
117 C<VCPU> = 1 or 2
118  
119 =item value = 8192
120  
121 C<VCPU> = 1, 2, or 4
122  
123 =item value = 9216, 10240, 11264, 12288, 13312, 14336, 15360, or 16384
124  
125 C<VCPU> = 2 or 4
126  
127 =item value = 17408, 18432, 19456, 20480, 21504, 22528, 23552, 24576,
128 25600, 26624, 27648, 28672, 29696, or 30720
129  
130 C<VCPU> = 4
131  
132 =back
133  
134 =item type="VCPU"
135  
136 The number of vCPUs reserved for the container. This parameter maps to
137 C<CpuShares> in the Create a container
138 (https://docs.docker.com/engine/api/v1.23/#create-a-container) section
139 of the Docker Remote API (https://docs.docker.com/engine/api/v1.23/)
140 and the C<--cpu-shares> option to docker run
141 (https://docs.docker.com/engine/reference/run/). Each vCPU is
142 equivalent to 1,024 CPU shares. For EC2 resources, you must specify at
143 least one vCPU. This is required but can be specified in several
144 places; it must be specified for each node at least once.
145  
146 For jobs running on Fargate resources, then C<value> must match one of
147 the supported values and the C<MEMORY> values must be one of the values
148 supported for that VCPU value. The supported values are 0.25, 0.5, 1,
149 2, and 4
150  
151 =over
152  
153 =item value = 0.25
154  
155 C<MEMORY> = 512, 1024, or 2048
156  
157 =item value = 0.5
158  
159 C<MEMORY> = 1024, 2048, 3072, or 4096
160  
161 =item value = 1
162  
163 C<MEMORY> = 2048, 3072, 4096, 5120, 6144, 7168, or 8192
164  
165 =item value = 2
166  
167 C<MEMORY> = 4096, 5120, 6144, 7168, 8192, 9216, 10240, 11264, 12288,
168 13312, 14336, 15360, or 16384
169  
170 =item value = 4
171  
172 C<MEMORY> = 8192, 9216, 10240, 11264, 12288, 13312, 14336, 15360,
173 16384, 17408, 18432, 19456, 20480, 21504, 22528, 23552, 24576, 25600,
174 26624, 27648, 28672, 29696, or 30720
175  
176 =back
177  
178 =back
179  
180  
181  
182  
183 =head1 SEE ALSO
184  
185 This class forms part of L<Paws>, describing an object used in L<Paws::Batch>
186  
187 =head1 BUGS and CONTRIBUTIONS
188  
189 The source code is located here: L<https://github.com/pplu/aws-sdk-perl>
190  
191 Please report bugs to: L<https://github.com/pplu/aws-sdk-perl/issues>
192  
193 =cut
194