Class: AWSCDK::DynamoDB::CfnTable::ProvisionedThroughputProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
dynamo_db/cfn_table.rb

Overview

Throughput for the specified table, which consists of values for ReadCapacityUnits and WriteCapacityUnits .

For more information about the contents of a provisioned throughput structure, see Amazon DynamoDB Table ProvisionedThroughput .

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(read_capacity_units:, write_capacity_units:) ⇒ ProvisionedThroughputProperty

Returns a new instance of ProvisionedThroughputProperty.

Parameters:

  • read_capacity_units (Numeric)

    The maximum number of strongly consistent reads consumed per second before DynamoDB returns a ThrottlingException .

  • write_capacity_units (Numeric)

    The maximum number of writes consumed per second before DynamoDB returns a ThrottlingException .



1483
1484
1485
1486
1487
1488
# File 'dynamo_db/cfn_table.rb', line 1483

def initialize(read_capacity_units:, write_capacity_units:)
  @read_capacity_units = read_capacity_units
  Jsii::Type.check_type(@read_capacity_units, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "readCapacityUnits")
  @write_capacity_units = write_capacity_units
  Jsii::Type.check_type(@write_capacity_units, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "writeCapacityUnits")
end

Instance Attribute Details

#read_capacity_unitsNumeric (readonly)

The maximum number of strongly consistent reads consumed per second before DynamoDB returns a ThrottlingException .

For more information, see Specifying Read and Write Requirements in the Amazon DynamoDB Developer Guide .

If read/write capacity mode is PAY_PER_REQUEST the value is set to 0.



1498
1499
1500
# File 'dynamo_db/cfn_table.rb', line 1498

def read_capacity_units
  @read_capacity_units
end

#write_capacity_unitsNumeric (readonly)

The maximum number of writes consumed per second before DynamoDB returns a ThrottlingException .

For more information, see Specifying Read and Write Requirements in the Amazon DynamoDB Developer Guide .

If read/write capacity mode is PAY_PER_REQUEST the value is set to 0.



1507
1508
1509
# File 'dynamo_db/cfn_table.rb', line 1507

def write_capacity_units
  @write_capacity_units
end

Class Method Details

.jsii_propertiesObject



1509
1510
1511
1512
1513
1514
# File 'dynamo_db/cfn_table.rb', line 1509

def self.jsii_properties
  {
    :read_capacity_units => "readCapacityUnits",
    :write_capacity_units => "writeCapacityUnits",
  }
end

Instance Method Details

#to_jsiiObject



1516
1517
1518
1519
1520
1521
1522
1523
# File 'dynamo_db/cfn_table.rb', line 1516

def to_jsii
  result = {}
  result.merge!({
    "readCapacityUnits" => @read_capacity_units,
    "writeCapacityUnits" => @write_capacity_units,
  })
  result.compact
end