Class: AWSCDK::IoTAnalytics::CfnPipeline::LambdaProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
io_t_analytics/cfn_pipeline.rb

Overview

An activity that runs a Lambda function to modify the message.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(batch_size:, lambda_name:, name:, _next: nil) ⇒ LambdaProperty

Returns a new instance of LambdaProperty.

Parameters:

  • batch_size (Numeric)

    The number of messages passed to the Lambda function for processing.

  • lambda_name (String)

    The name of the Lambda function that is run on the message.

  • name (String)

    The name of the 'lambda' activity.

  • _next (String, nil) (defaults to: nil)

    The next activity in the pipeline.



1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
# File 'io_t_analytics/cfn_pipeline.rb', line 1032

def initialize(batch_size:, lambda_name:, name:, _next: nil)
  @batch_size = batch_size
  Jsii::Type.check_type(@batch_size, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "batchSize")
  @lambda_name = lambda_name
  Jsii::Type.check_type(@lambda_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "lambdaName")
  @name = name
  Jsii::Type.check_type(@name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "name")
  @_next = _next
  Jsii::Type.check_type(@_next, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "next") unless @_next.nil?
end

Instance Attribute Details

#_nextString? (readonly)

The next activity in the pipeline.



1064
1065
1066
# File 'io_t_analytics/cfn_pipeline.rb', line 1064

def _next
  @_next
end

#batch_sizeNumeric (readonly)

The number of messages passed to the Lambda function for processing.

The AWS Lambda function must be able to process all of these messages within five minutes, which is the maximum timeout duration for Lambda functions.



1049
1050
1051
# File 'io_t_analytics/cfn_pipeline.rb', line 1049

def batch_size
  @batch_size
end

#lambda_nameString (readonly)

The name of the Lambda function that is run on the message.



1054
1055
1056
# File 'io_t_analytics/cfn_pipeline.rb', line 1054

def lambda_name
  @lambda_name
end

#nameString (readonly)

The name of the 'lambda' activity.



1059
1060
1061
# File 'io_t_analytics/cfn_pipeline.rb', line 1059

def name
  @name
end

Class Method Details

.jsii_propertiesObject



1066
1067
1068
1069
1070
1071
1072
1073
# File 'io_t_analytics/cfn_pipeline.rb', line 1066

def self.jsii_properties
  {
    :batch_size => "batchSize",
    :lambda_name => "lambdaName",
    :name => "name",
    :_next => "next",
  }
end

Instance Method Details

#to_jsiiObject



1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
# File 'io_t_analytics/cfn_pipeline.rb', line 1075

def to_jsii
  result = {}
  result.merge!({
    "batchSize" => @batch_size,
    "lambdaName" => @lambda_name,
    "name" => @name,
    "next" => @_next,
  })
  result.compact
end