Module: AWSCDK::Scheduler::IScheduleGroup
- Includes:
- IResource, Interfaces::AWSScheduler::IScheduleGroupRef
- Included in:
- ScheduleGroup
- Defined in:
- scheduler/i_schedule_group.rb
Overview
Interface representing a created or an imported ScheduleGroup.
Class Method Summary collapse
Instance Method Summary collapse
-
#apply_removal_policy(policy) ⇒ void
Apply the given removal policy to this resource.
-
#env ⇒ AWSCDK::Interfaces::ResourceEnvironment
The environment this resource belongs to.
-
#grant(grantee, *actions) ⇒ AWSCDK::IAM::Grant
Grant the indicated permissions on this group to the given principal.
-
#grant_delete_schedules(identity) ⇒ AWSCDK::IAM::Grant
Grant delete schedule permission for schedules in this group to the given principal.
-
#grant_read_schedules(identity) ⇒ AWSCDK::IAM::Grant
Grant list and get schedule permissions for schedules in this group to the given principal.
-
#grant_write_schedules(identity) ⇒ AWSCDK::IAM::Grant
Grant create and update schedule permissions for schedules in this group to the given principal.
-
#metric(metric_name, props = nil) ⇒ AWSCDK::CloudWatch::Metric
Return the given named metric for this group schedules.
-
#metric_attempts(props = nil) ⇒ AWSCDK::CloudWatch::Metric
Metric for all invocation attempts.
-
#metric_dropped(props = nil) ⇒ AWSCDK::CloudWatch::Metric
Metric for dropped invocations when EventBridge Scheduler stops attempting to invoke the target after a schedule's retry policy has been exhausted.
-
#metric_failed_to_be_sent_to_dlq(error_code = nil, props = nil) ⇒ AWSCDK::CloudWatch::Metric
Metric for failed invocations that also failed to deliver to DLQ.
-
#metric_sent_to_dlq(props = nil) ⇒ AWSCDK::CloudWatch::Metric
Metric for invocations delivered to the DLQ.
-
#metric_sent_to_dlq_truncated(props = nil) ⇒ AWSCDK::CloudWatch::Metric
Metric for delivery of failed invocations to DLQ when the payload of the event sent to the DLQ exceeds the maximum size allowed by Amazon SQS.
-
#metric_target_errors(props = nil) ⇒ AWSCDK::CloudWatch::Metric
Emitted when the target returns an exception after EventBridge Scheduler calls the target API.
-
#metric_target_throttled(props = nil) ⇒ AWSCDK::CloudWatch::Metric
Metric for invocation failures due to API throttling by the target.
-
#metric_throttled(props = nil) ⇒ AWSCDK::CloudWatch::Metric
Metric for the number of invocations that were throttled because it exceeds your service quotas.
-
#node ⇒ Constructs::Node
The tree node.
-
#schedule_group_arn ⇒ String
The arn of the schedule group.
-
#schedule_group_name ⇒ String
The name of the schedule group.
-
#schedule_group_ref ⇒ AWSCDK::Interfaces::AWSScheduler::ScheduleGroupReference
A reference to a ScheduleGroup resource.
-
#stack ⇒ AWSCDK::Stack
The stack in which this resource is defined.
-
#with(*mixins) ⇒ Constructs::IConstruct
Applies one or more mixins to this construct.
Class Method Details
.jsii_overridable_methods ⇒ Object
234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 |
# File 'scheduler/i_schedule_group.rb', line 234 def self.jsii_overridable_methods { :node => { kind: :property, name: "node", is_optional: false }, :env => { kind: :property, name: "env", is_optional: false }, :stack => { kind: :property, name: "stack", is_optional: false }, :schedule_group_ref => { kind: :property, name: "scheduleGroupRef", is_optional: false }, :schedule_group_arn => { kind: :property, name: "scheduleGroupArn", is_optional: false }, :schedule_group_name => { kind: :property, name: "scheduleGroupName", is_optional: false }, :with => { kind: :method, name: "with", is_optional: false }, :apply_removal_policy => { kind: :method, name: "applyRemovalPolicy", is_optional: false }, :grant => { kind: :method, name: "grant", is_optional: false }, :grant_delete_schedules => { kind: :method, name: "grantDeleteSchedules", is_optional: false }, :grant_read_schedules => { kind: :method, name: "grantReadSchedules", is_optional: false }, :grant_write_schedules => { kind: :method, name: "grantWriteSchedules", is_optional: false }, :metric => { kind: :method, name: "metric", is_optional: false }, :metric_attempts => { kind: :method, name: "metricAttempts", is_optional: false }, :metric_dropped => { kind: :method, name: "metricDropped", is_optional: false }, :metric_failed_to_be_sent_to_dlq => { kind: :method, name: "metricFailedToBeSentToDLQ", is_optional: false }, :metric_sent_to_dlq => { kind: :method, name: "metricSentToDLQ", is_optional: false }, :metric_sent_to_dlq_truncated => { kind: :method, name: "metricSentToDLQTruncated", is_optional: false }, :metric_target_errors => { kind: :method, name: "metricTargetErrors", is_optional: false }, :metric_target_throttled => { kind: :method, name: "metricTargetThrottled", is_optional: false }, :metric_throttled => { kind: :method, name: "metricThrottled", is_optional: false }, } end |
Instance Method Details
#apply_removal_policy(policy) ⇒ void
This method returns an undefined value.
Apply the given removal policy to this resource.
The Removal Policy controls what happens to this resource when it stops being managed by CloudFormation, either because you've removed it from the CDK application or because you've made a change that requires the resource to be replaced.
The resource can be deleted (RemovalPolicy.DESTROY), or left in your AWS
account for data recovery and cleanup later (RemovalPolicy.RETAIN).
85 86 87 88 |
# File 'scheduler/i_schedule_group.rb', line 85 def apply_removal_policy(policy) Jsii::Type.check_type(policy, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5SZW1vdmFsUG9saWN5In0=")), "policy") jsii_call_method("applyRemovalPolicy", [policy]) end |
#env ⇒ AWSCDK::Interfaces::ResourceEnvironment
The environment this resource belongs to.
For resources that are created and managed in a Stack (those created by
creating new class instances like new Role(), new Bucket(), etc.), this
is always the same as the environment of the stack they belong to.
For referenced resources (those obtained from referencing methods like
Role.fromRoleArn(), Bucket.fromBucketName(), etc.), they might be
different than the stack they were imported into.
27 28 29 |
# File 'scheduler/i_schedule_group.rb', line 27 def env() jsii_get_property("env") end |
#grant(grantee, *actions) ⇒ AWSCDK::IAM::Grant
Grant the indicated permissions on this group to the given principal.
95 96 97 98 99 100 101 |
# File 'scheduler/i_schedule_group.rb', line 95 def grant(grantee, *actions) Jsii::Type.check_type(grantee, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfaWFtLklHcmFudGFibGUifQ==")), "grantee") actions.each_with_index do |item, index| Jsii::Type.check_type(item, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "actions[#{index}]") end jsii_call_method("grant", [grantee, *actions]) end |
#grant_delete_schedules(identity) ⇒ AWSCDK::IAM::Grant
Grant delete schedule permission for schedules in this group to the given principal.
107 108 109 110 |
# File 'scheduler/i_schedule_group.rb', line 107 def grant_delete_schedules(identity) Jsii::Type.check_type(identity, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfaWFtLklHcmFudGFibGUifQ==")), "identity") jsii_call_method("grantDeleteSchedules", [identity]) end |
#grant_read_schedules(identity) ⇒ AWSCDK::IAM::Grant
Grant list and get schedule permissions for schedules in this group to the given principal.
116 117 118 119 |
# File 'scheduler/i_schedule_group.rb', line 116 def grant_read_schedules(identity) Jsii::Type.check_type(identity, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfaWFtLklHcmFudGFibGUifQ==")), "identity") jsii_call_method("grantReadSchedules", [identity]) end |
#grant_write_schedules(identity) ⇒ AWSCDK::IAM::Grant
Grant create and update schedule permissions for schedules in this group to the given principal.
125 126 127 128 |
# File 'scheduler/i_schedule_group.rb', line 125 def grant_write_schedules(identity) Jsii::Type.check_type(identity, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfaWFtLklHcmFudGFibGUifQ==")), "identity") jsii_call_method("grantWriteSchedules", [identity]) end |
#metric(metric_name, props = nil) ⇒ AWSCDK::CloudWatch::Metric
Default: - sum over 5 minutes
Return the given named metric for this group schedules.
136 137 138 139 140 141 |
# File 'scheduler/i_schedule_group.rb', line 136 def metric(metric_name, props = nil) Jsii::Type.check_type(metric_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "metricName") props = props.is_a?(Hash) ? ::AWSCDK::CloudWatch::MetricOptions.new(**props.transform_keys(&:to_sym)) : props Jsii::Type.check_type(props, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfY2xvdWR3YXRjaC5NZXRyaWNPcHRpb25zIn0=")), "props") unless props.nil? jsii_call_method("metric", [metric_name, props]) end |
#metric_attempts(props = nil) ⇒ AWSCDK::CloudWatch::Metric
Default: - sum over 5 minutes
Metric for all invocation attempts.
148 149 150 151 152 |
# File 'scheduler/i_schedule_group.rb', line 148 def metric_attempts(props = nil) props = props.is_a?(Hash) ? ::AWSCDK::CloudWatch::MetricOptions.new(**props.transform_keys(&:to_sym)) : props Jsii::Type.check_type(props, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfY2xvdWR3YXRjaC5NZXRyaWNPcHRpb25zIn0=")), "props") unless props.nil? jsii_call_method("metricAttempts", [props]) end |
#metric_dropped(props = nil) ⇒ AWSCDK::CloudWatch::Metric
Default: - sum over 5 minutes
Metric for dropped invocations when EventBridge Scheduler stops attempting to invoke the target after a schedule's retry policy has been exhausted.
159 160 161 162 163 |
# File 'scheduler/i_schedule_group.rb', line 159 def metric_dropped(props = nil) props = props.is_a?(Hash) ? ::AWSCDK::CloudWatch::MetricOptions.new(**props.transform_keys(&:to_sym)) : props Jsii::Type.check_type(props, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfY2xvdWR3YXRjaC5NZXRyaWNPcHRpb25zIn0=")), "props") unless props.nil? jsii_call_method("metricDropped", [props]) end |
#metric_failed_to_be_sent_to_dlq(error_code = nil, props = nil) ⇒ AWSCDK::CloudWatch::Metric
Default: - sum over 5 minutes
Metric for failed invocations that also failed to deliver to DLQ.
171 172 173 174 175 176 |
# File 'scheduler/i_schedule_group.rb', line 171 def metric_failed_to_be_sent_to_dlq(error_code = nil, props = nil) Jsii::Type.check_type(error_code, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "errorCode") unless error_code.nil? props = props.is_a?(Hash) ? ::AWSCDK::CloudWatch::MetricOptions.new(**props.transform_keys(&:to_sym)) : props Jsii::Type.check_type(props, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfY2xvdWR3YXRjaC5NZXRyaWNPcHRpb25zIn0=")), "props") unless props.nil? jsii_call_method("metricFailedToBeSentToDLQ", [error_code, props]) end |
#metric_sent_to_dlq(props = nil) ⇒ AWSCDK::CloudWatch::Metric
Default: - sum over 5 minutes
Metric for invocations delivered to the DLQ.
183 184 185 186 187 |
# File 'scheduler/i_schedule_group.rb', line 183 def metric_sent_to_dlq(props = nil) props = props.is_a?(Hash) ? ::AWSCDK::CloudWatch::MetricOptions.new(**props.transform_keys(&:to_sym)) : props Jsii::Type.check_type(props, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfY2xvdWR3YXRjaC5NZXRyaWNPcHRpb25zIn0=")), "props") unless props.nil? jsii_call_method("metricSentToDLQ", [props]) end |
#metric_sent_to_dlq_truncated(props = nil) ⇒ AWSCDK::CloudWatch::Metric
Default: - sum over 5 minutes
Metric for delivery of failed invocations to DLQ when the payload of the event sent to the DLQ exceeds the maximum size allowed by Amazon SQS.
194 195 196 197 198 |
# File 'scheduler/i_schedule_group.rb', line 194 def metric_sent_to_dlq_truncated(props = nil) props = props.is_a?(Hash) ? ::AWSCDK::CloudWatch::MetricOptions.new(**props.transform_keys(&:to_sym)) : props Jsii::Type.check_type(props, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfY2xvdWR3YXRjaC5NZXRyaWNPcHRpb25zIn0=")), "props") unless props.nil? jsii_call_method("metricSentToDLQTruncated", [props]) end |
#metric_target_errors(props = nil) ⇒ AWSCDK::CloudWatch::Metric
Default: - sum over 5 minutes
Emitted when the target returns an exception after EventBridge Scheduler calls the target API.
205 206 207 208 209 |
# File 'scheduler/i_schedule_group.rb', line 205 def metric_target_errors(props = nil) props = props.is_a?(Hash) ? ::AWSCDK::CloudWatch::MetricOptions.new(**props.transform_keys(&:to_sym)) : props Jsii::Type.check_type(props, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfY2xvdWR3YXRjaC5NZXRyaWNPcHRpb25zIn0=")), "props") unless props.nil? jsii_call_method("metricTargetErrors", [props]) end |
#metric_target_throttled(props = nil) ⇒ AWSCDK::CloudWatch::Metric
Default: - sum over 5 minutes
Metric for invocation failures due to API throttling by the target.
216 217 218 219 220 |
# File 'scheduler/i_schedule_group.rb', line 216 def metric_target_throttled(props = nil) props = props.is_a?(Hash) ? ::AWSCDK::CloudWatch::MetricOptions.new(**props.transform_keys(&:to_sym)) : props Jsii::Type.check_type(props, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfY2xvdWR3YXRjaC5NZXRyaWNPcHRpb25zIn0=")), "props") unless props.nil? jsii_call_method("metricTargetThrottled", [props]) end |
#metric_throttled(props = nil) ⇒ AWSCDK::CloudWatch::Metric
Default: - sum over 5 minutes
Metric for the number of invocations that were throttled because it exceeds your service quotas.
228 229 230 231 232 |
# File 'scheduler/i_schedule_group.rb', line 228 def metric_throttled(props = nil) props = props.is_a?(Hash) ? ::AWSCDK::CloudWatch::MetricOptions.new(**props.transform_keys(&:to_sym)) : props Jsii::Type.check_type(props, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfY2xvdWR3YXRjaC5NZXRyaWNPcHRpb25zIn0=")), "props") unless props.nil? jsii_call_method("metricThrottled", [props]) end |
#node ⇒ Constructs::Node
The tree node.
12 13 14 |
# File 'scheduler/i_schedule_group.rb', line 12 def node() jsii_get_property("node") end |
#schedule_group_arn ⇒ String
The arn of the schedule group.
48 49 50 |
# File 'scheduler/i_schedule_group.rb', line 48 def schedule_group_arn() jsii_get_property("scheduleGroupArn") end |
#schedule_group_name ⇒ String
The name of the schedule group.
55 56 57 |
# File 'scheduler/i_schedule_group.rb', line 55 def schedule_group_name() jsii_get_property("scheduleGroupName") end |
#schedule_group_ref ⇒ AWSCDK::Interfaces::AWSScheduler::ScheduleGroupReference
A reference to a ScheduleGroup resource.
41 42 43 |
# File 'scheduler/i_schedule_group.rb', line 41 def schedule_group_ref() jsii_get_property("scheduleGroupRef") end |
#stack ⇒ AWSCDK::Stack
The stack in which this resource is defined.
34 35 36 |
# File 'scheduler/i_schedule_group.rb', line 34 def stack() jsii_get_property("stack") end |
#with(*mixins) ⇒ Constructs::IConstruct
Applies one or more mixins to this construct.
Mixins are applied in order. The list of constructs is captured at the start of the call, so constructs added by a mixin will not be visited.
66 67 68 69 70 71 |
# File 'scheduler/i_schedule_group.rb', line 66 def with(*mixins) mixins.each_with_index do |item, index| Jsii::Type.check_type(item, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJjb25zdHJ1Y3RzLklNaXhpbiJ9")), "mixins[#{index}]") end jsii_call_method("with", [*mixins]) end |