blib/lib/Paws/EMR/PutAutoScalingPolicy.pm untested

filter: Statementstmt 0.0% 0 / 12 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 2 Podpod n/a totaltotal 0.0% 0 / 14 CC 1 SCAR 6.9
CC
1
Cov
0%
BEGIN
2.0
BEGIN
2.0
CRAP 2.0
1  
2 package Paws::EMR::PutAutoScalingPolicy;
3 use Moose;
4 has AutoScalingPolicy => (is => 'ro', isa => 'Paws::EMR::AutoScalingPolicy', required => 1);
5 has ClusterId => (is => 'ro', isa => 'Str', required => 1);
6 has InstanceGroupId => (is => 'ro', isa => 'Str', required => 1);
7  
8 use MooseX::ClassAttribute;
9  
10 class_has _api_call => (isa => 'Str', is => 'ro', default => 'PutAutoScalingPolicy');
11 class_has _returns => (isa => 'Str', is => 'ro', default => 'Paws::EMR::PutAutoScalingPolicyOutput');
12 class_has _result_key => (isa => 'Str', is => 'ro');
13 1;
14  
15 ### main pod documentation begin ###
16  
17 =head1 NAME
18  
19 Paws::EMR::PutAutoScalingPolicy - Arguments for method PutAutoScalingPolicy on L<Paws::EMR>
20  
21 =head1 DESCRIPTION
22  
23 This class represents the parameters used for calling the method PutAutoScalingPolicy on the
24 L<Amazon Elastic MapReduce|Paws::EMR> service. Use the attributes of this class
25 as arguments to method PutAutoScalingPolicy.
26  
27 You shouldn't make instances of this class. Each attribute should be used as a named argument in the call to PutAutoScalingPolicy.
28  
29 =head1 SYNOPSIS
30  
31 my $elasticmapreduce = Paws->service('EMR');
32 my $PutAutoScalingPolicyOutput = $elasticmapreduce->PutAutoScalingPolicy(
33 AutoScalingPolicy => {
34 Constraints => {
35 MaxCapacity => 1,
36 MinCapacity => 1,
37  
38 },
39 Rules => [
40 {
41 Action => {
42 SimpleScalingPolicyConfiguration => {
43 ScalingAdjustment => 1,
44 AdjustmentType => 'CHANGE_IN_CAPACITY'
45 , # values: CHANGE_IN_CAPACITY, PERCENT_CHANGE_IN_CAPACITY, EXACT_CAPACITY; OPTIONAL
46 CoolDown => 1,
47 },
48 Market => 'ON_DEMAND', # values: ON_DEMAND, SPOT; OPTIONAL
49 },
50 Name => 'MyString',
51 Trigger => {
52 CloudWatchAlarmDefinition => {
53 ComparisonOperator => 'GREATER_THAN_OR_EQUAL'
54 , # values: GREATER_THAN_OR_EQUAL, GREATER_THAN, LESS_THAN, LESS_THAN_OR_EQUAL
55 MetricName => 'MyString',
56 Period => 1,
57 Threshold => 1,
58 Dimensions => [
59 {
60 Key => 'MyString',
61 Value => 'MyString',
62 },
63 ...
64 ], # OPTIONAL
65 EvaluationPeriods => 1,
66 Namespace => 'MyString',
67 Statistic => 'SAMPLE_COUNT'
68 , # values: SAMPLE_COUNT, AVERAGE, SUM, MINIMUM, MAXIMUM; OPTIONAL
69 Unit => 'NONE'
70 , # values: NONE, SECONDS, MICRO_SECONDS, MILLI_SECONDS, BYTES, KILO_BYTES, MEGA_BYTES, GIGA_BYTES, TERA_BYTES, BITS, KILO_BITS, MEGA_BITS, GIGA_BITS, TERA_BITS, PERCENT, COUNT, BYTES_PER_SECOND, KILO_BYTES_PER_SECOND, MEGA_BYTES_PER_SECOND, GIGA_BYTES_PER_SECOND, TERA_BYTES_PER_SECOND, BITS_PER_SECOND, KILO_BITS_PER_SECOND, MEGA_BITS_PER_SECOND, GIGA_BITS_PER_SECOND, TERA_BITS_PER_SECOND, COUNT_PER_SECOND; OPTIONAL
71 },
72  
73 },
74 Description => 'MyString',
75 },
76 ...
77 ],
78  
79 },
80 ClusterId => 'MyClusterId',
81 InstanceGroupId => 'MyInstanceGroupId',
82  
83 );
84  
85 # Results:
86 my $AutoScalingPolicy = $PutAutoScalingPolicyOutput->AutoScalingPolicy;
87 my $ClusterArn = $PutAutoScalingPolicyOutput->ClusterArn;
88 my $ClusterId = $PutAutoScalingPolicyOutput->ClusterId;
89 my $InstanceGroupId = $PutAutoScalingPolicyOutput->InstanceGroupId;
90  
91 # Returns a L<Paws::EMR::PutAutoScalingPolicyOutput> object.
92  
93 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.
94 For the AWS API documentation, see L<https://docs.aws.amazon.com/goto/WebAPI/elasticmapreduce/PutAutoScalingPolicy>
95  
96 =head1 ATTRIBUTES
97  
98  
99 =head2 B<REQUIRED> AutoScalingPolicy => L<Paws::EMR::AutoScalingPolicy>
100  
101 Specifies the definition of the automatic scaling policy.
102  
103  
104  
105 =head2 B<REQUIRED> ClusterId => Str
106  
107 Specifies the ID of a cluster. The instance group to which the
108 automatic scaling policy is applied is within this cluster.
109  
110  
111  
112 =head2 B<REQUIRED> InstanceGroupId => Str
113  
114 Specifies the ID of the instance group to which the automatic scaling
115 policy is applied.
116  
117  
118  
119  
120 =head1 SEE ALSO
121  
122 This class forms part of L<Paws>, documenting arguments for method PutAutoScalingPolicy in L<Paws::EMR>
123  
124 =head1 BUGS and CONTRIBUTIONS
125  
126 The source code is located here: L<https://github.com/pplu/aws-sdk-perl>
127  
128 Please report bugs to: L<https://github.com/pplu/aws-sdk-perl/issues>
129  
130 =cut
131