Class: AWSCDK::OpenSearchService::NodeOptions

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
open_search_service/node_options.rb

Overview

Configuration for node options in OpenSearch domain.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(node_config:, node_type:) ⇒ NodeOptions

Returns a new instance of NodeOptions.

Parameters:



9
10
11
12
13
14
# File 'open_search_service/node_options.rb', line 9

def initialize(node_config:, node_type:)
  @node_config = node_config.is_a?(Hash) ? ::AWSCDK::OpenSearchService::NodeConfig.new(**node_config.transform_keys(&:to_sym)) : node_config
  Jsii::Type.check_type(@node_config, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3Nfb3BlbnNlYXJjaHNlcnZpY2UuTm9kZUNvbmZpZyJ9")), "nodeConfig")
  @node_type = node_type
  Jsii::Type.check_type(@node_type, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3Nfb3BlbnNlYXJjaHNlcnZpY2UuTm9kZVR5cGUifQ==")), "nodeType")
end

Instance Attribute Details

#node_configAWSCDK::OpenSearchService::NodeConfig (readonly)

Configuration for the node type.



19
20
21
# File 'open_search_service/node_options.rb', line 19

def node_config
  @node_config
end

#node_typeAWSCDK::OpenSearchService::NodeType (readonly)

The type of node.

Currently only 'coordinator' is supported.



25
26
27
# File 'open_search_service/node_options.rb', line 25

def node_type
  @node_type
end

Class Method Details

.jsii_propertiesObject



27
28
29
30
31
32
# File 'open_search_service/node_options.rb', line 27

def self.jsii_properties
  {
    :node_config => "nodeConfig",
    :node_type => "nodeType",
  }
end

Instance Method Details

#to_jsiiObject



34
35
36
37
38
39
40
41
# File 'open_search_service/node_options.rb', line 34

def to_jsii
  result = {}
  result.merge!({
    "nodeConfig" => @node_config,
    "nodeType" => @node_type,
  })
  result.compact
end