Class: AWSCDK::Events::CfnEndpoint::FailoverConfigProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
events/cfn_endpoint.rb

Overview

The failover configuration for an endpoint.

This includes what triggers failover and what happens when it's triggered.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(primary:, secondary:) ⇒ FailoverConfigProperty

Returns a new instance of FailoverConfigProperty.

Parameters:



670
671
672
673
674
675
# File 'events/cfn_endpoint.rb', line 670

def initialize(primary:, secondary:)
  @primary = primary.is_a?(Hash) ? ::AWSCDK::Events::CfnEndpoint::PrimaryProperty.new(**primary.transform_keys(&:to_sym)) : primary
  Jsii::Type.check_type(@primary, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19ldmVudHMuQ2ZuRW5kcG9pbnQuUHJpbWFyeVByb3BlcnR5In1dfX0=")), "primary")
  @secondary = secondary.is_a?(Hash) ? ::AWSCDK::Events::CfnEndpoint::SecondaryProperty.new(**secondary.transform_keys(&:to_sym)) : secondary
  Jsii::Type.check_type(@secondary, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19ldmVudHMuQ2ZuRW5kcG9pbnQuU2Vjb25kYXJ5UHJvcGVydHkifV19fQ==")), "secondary")
end

Instance Attribute Details

#secondaryAWSCDK::IResolvable, AWSCDK::Events::CfnEndpoint::SecondaryProperty (readonly)

The Region that events are routed to when failover is triggered or event replication is enabled.



686
687
688
# File 'events/cfn_endpoint.rb', line 686

def secondary
  @secondary
end

Class Method Details

.jsii_propertiesObject



688
689
690
691
692
693
# File 'events/cfn_endpoint.rb', line 688

def self.jsii_properties
  {
    :primary => "primary",
    :secondary => "secondary",
  }
end

Instance Method Details

#to_jsiiObject



695
696
697
698
699
700
701
702
# File 'events/cfn_endpoint.rb', line 695

def to_jsii
  result = {}
  result.merge!({
    "primary" => @primary,
    "secondary" => @secondary,
  })
  result.compact
end