ruby_aem_aws 4.0.1 → 4.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c2a546dfd7569267610268825135bca1ba3b628eaca9f895c3b140d5ddd1f03d
4
- data.tar.gz: 137a9a0f1d781fc530f472965afeb0217539d4a59a6d6838516f72da8951562a
3
+ metadata.gz: 1756ce4e7ac4e7b4ce39714c8c71933c1fbbf686999e7844a547270e0563e114
4
+ data.tar.gz: aa5cb197ebcfd76bf6e0ca8910b18e0f475cdfc8570947cbe95c76022ec43ba6
5
5
  SHA512:
6
- metadata.gz: bc39e1bc235c9ce8d04a779498a8cf853bc56064a199330f3d61fdf35e8928bdd95787cd3cdab35ca8612eeef4bc019350a4bef9b4205b9fef575c1bed84c4d8
7
- data.tar.gz: 0d4d65ace8930a3f1ceda1580ef2aba839d766a52ed16ba9fbf32d2bbe5ae9c179b8845bd44b4921be7c82e62fe77207796b648c407afcdf77a0a1facb480761
6
+ metadata.gz: 8b0d1c7c1dc981a2233bdbe1c4bc75182027ba562d92999a7e77d14c3ac6cd92f14d081ac28ee56914ebcb3b733cea1a038b8657372762e175e255a2cf7ced98
7
+ data.tar.gz: 6bcfd6e7d69a8f9230ecec7c88253b04c3c88bb6545418043d42238d54cfe5b96533765180b43dbd755e7658fa8b19f1ff0bb722ab98145a7f5526682ae99756
data/conf/gem.yaml CHANGED
@@ -1,2 +1,2 @@
1
1
  ---
2
- version: 4.0.1
2
+ version: 4.0.3
@@ -14,7 +14,6 @@
14
14
 
15
15
  require_relative '../component/author_dispatcher'
16
16
  require_relative '../component/author'
17
- require_relative '../component/chaos_monkey'
18
17
  require_relative '../component/orchestrator'
19
18
  require_relative '../component/publish_dispatcher'
20
19
  require_relative '../component/publish'
@@ -83,11 +82,6 @@ module RubyAemAws
83
82
  RubyAemAws::Component::Author.new(@stack_prefix, @author_aws_clients)
84
83
  end
85
84
 
86
- # @return new RubyAemAws::Component::ChaosMonkey instance
87
- def chaos_monkey
88
- RubyAemAws::Component::ChaosMonkey.new(@stack_prefix, @aem_java_aws_clients)
89
- end
90
-
91
85
  # @return new RubyAemAws::Component::Orchestrator instance
92
86
  def orchestrator
93
87
  RubyAemAws::Component::Orchestrator.new(@stack_prefix, @aem_java_aws_clients)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby_aem_aws
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.1
4
+ version: 4.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Shine Solutions
@@ -13,16 +13,16 @@ dependencies:
13
13
  name: aws-sdk-autoscaling
14
14
  requirement: !ruby/object:Gem::Requirement
15
15
  requirements:
16
- - - '='
16
+ - - ">="
17
17
  - !ruby/object:Gem::Version
18
- version: 1.168.0
18
+ version: 1.92.0
19
19
  type: :runtime
20
20
  prerelease: false
21
21
  version_requirements: !ruby/object:Gem::Requirement
22
22
  requirements:
23
- - - '='
23
+ - - ">="
24
24
  - !ruby/object:Gem::Version
25
- version: 1.168.0
25
+ version: 1.92.0
26
26
  - !ruby/object:Gem::Dependency
27
27
  name: aws-sdk-cloudformation
28
28
  requirement: !ruby/object:Gem::Requirement
@@ -111,16 +111,16 @@ dependencies:
111
111
  name: aws-sdk-sns
112
112
  requirement: !ruby/object:Gem::Requirement
113
113
  requirements:
114
- - - '='
114
+ - - ">="
115
115
  - !ruby/object:Gem::Version
116
- version: 1.121.0
116
+ version: 1.70.0
117
117
  type: :runtime
118
118
  prerelease: false
119
119
  version_requirements: !ruby/object:Gem::Requirement
120
120
  requirements:
121
- - - '='
121
+ - - ">="
122
122
  - !ruby/object:Gem::Version
123
- version: 1.121.0
123
+ version: 1.70.0
124
124
  - !ruby/object:Gem::Dependency
125
125
  name: aws-sdk-s3
126
126
  requirement: !ruby/object:Gem::Requirement
@@ -219,7 +219,6 @@ files:
219
219
  - lib/ruby_aem_aws/component/author_primary.rb
220
220
  - lib/ruby_aem_aws/component/author_publish_dispatcher.rb
221
221
  - lib/ruby_aem_aws/component/author_standby.rb
222
- - lib/ruby_aem_aws/component/chaos_monkey.rb
223
222
  - lib/ruby_aem_aws/component/component_descriptor.rb
224
223
  - lib/ruby_aem_aws/component/orchestrator.rb
225
224
  - lib/ruby_aem_aws/component/preview_publish.rb
@@ -1,79 +0,0 @@
1
- # Copyright 2018-2021 Shine Solutions Group
2
- #
3
- # Licensed under the Apache License, Version 2.0 (the "License");
4
- # you may not use this file except in compliance with the License.
5
- # You may obtain a copy of the License at
6
- #
7
- # http://www.apache.org/licenses/LICENSE-2.0
8
- #
9
- # Unless required by applicable law or agreed to in writing, software
10
- # distributed under the License is distributed on an "AS IS" BASIS,
11
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
- # See the License for the specific language governing permissions and
13
- # limitations under the License.
14
-
15
- require_relative '../abstract/grouped_component'
16
- require_relative '../abstract/snapshot'
17
- require_relative '../constants'
18
- require_relative '../mixins/healthy_resource_verifier'
19
- require_relative '../mixins/metric_verifier'
20
- require_relative '../mixins/snapshot_verifier'
21
-
22
- module RubyAemAws
23
- module Component
24
- # Interface to the AWS instance running the ChaosMonkey component of a full-set AEM stack.
25
- class ChaosMonkey
26
- attr_reader :descriptor, :ec2_resource, :asg_client, :cloud_watch_client, :cloud_watch_log_client
27
-
28
- include AbstractGroupedComponent
29
- include AbstractSnapshot
30
- include HealthyResourceVerifier
31
- include MetricVerifier
32
- include SnapshotVerifier
33
-
34
- EC2_COMPONENT = 'chaos-monkey'.freeze
35
- EC2_NAME = 'AEM Chaos Monkey'.freeze
36
-
37
- # @param stack_prefix AWS tag: StackPrefix
38
- # @param params Array of AWS Clients and Resource connections:
39
- # - AutoScalingClient: AWS AutoScalingGroup Client.
40
- # - CloudWatchClient: AWS Cloudwatch Client.
41
- # - CloudWatchLogsClient: AWS Cloudwatch Logs Client.
42
- # - Ec2Resource: AWS EC2 Resource connection.
43
- # @return new RubyAemAws::FullSet::ChaosMonkey
44
- def initialize(stack_prefix, params)
45
- @descriptor = ComponentDescriptor.new(stack_prefix,
46
- EC2Descriptor.new(EC2_COMPONENT, EC2_NAME))
47
- @asg_client = params[:AutoScalingClient]
48
- @cloud_watch_client = params[:CloudWatchClient]
49
- @cloud_watch_log_client = params[:CloudWatchLogsClient]
50
- @ec2_resource = params[:Ec2Resource]
51
- end
52
-
53
- def terminate_all_instances
54
- get_all_instances.each do |i|
55
- next if i.nil? || i.state.code != Constants::INSTANCE_STATE_CODE_RUNNING
56
-
57
- i.terminate
58
- i.wait_until_terminated
59
- end
60
- end
61
-
62
- def terminate_random_instance
63
- instance = get_random_instance
64
- instance.terminate
65
- instance.wait_until_terminated
66
- end
67
-
68
- def get_tags
69
- tags = []
70
- get_all_instances.each do |i|
71
- next if i.nil? || i.state.code != Constants::INSTANCE_STATE_CODE_RUNNING
72
-
73
- tags.push(i.tags)
74
- end
75
- tags
76
- end
77
- end
78
- end
79
- end