Skip to content

Commit

Permalink
feat(lambda): additional properties for stream event source mappings (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
jaredstehler committed Aug 2, 2021
1 parent ba0ce69 commit 884ce57
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@

package com.netflix.spinnaker.clouddriver.lambda.deploy.description;

import com.amazonaws.services.lambda.model.DestinationConfig;
import lombok.Data;
import lombok.EqualsAndHashCode;

Expand All @@ -25,8 +26,15 @@ public class UpsertLambdaFunctionEventMappingDescription extends AbstractLambdaF
String functionName;
String qualifier;
Integer batchsize = 1;
Boolean bisectBatchOnError = null;
Integer maxBatchingWindowSecs = null;
Integer maxRecordAgeSecs = null;
Integer maxRetryAttempts = null;
Integer parallelizationFactor = null;
Integer tumblingWindowSecs = null;
Boolean enabled = false;
String eventSourceArn = null;
String uuid = null;
String startingPosition = null;
DestinationConfig destinationConfig = null;
}
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,13 @@ private UpdateEventSourceMappingResult updateEventSourceMappingResult(LambdaFunc
new UpdateEventSourceMappingRequest()
.withFunctionName(cache.getFunctionArn())
.withBatchSize(description.getBatchsize())
.withBisectBatchOnFunctionError(description.getBisectBatchOnError())
.withMaximumBatchingWindowInSeconds(description.getMaxBatchingWindowSecs())
.withMaximumRecordAgeInSeconds(description.getMaxRecordAgeSecs())
.withMaximumRetryAttempts(description.getMaxRetryAttempts())
.withParallelizationFactor(description.getParallelizationFactor())
.withTumblingWindowInSeconds(description.getTumblingWindowSecs())
.withDestinationConfig(description.getDestinationConfig())
.withEnabled(description.getEnabled())
.withUUID(description.getUuid());

Expand All @@ -88,6 +95,13 @@ private CreateEventSourceMappingResult createEventSourceMapping(LambdaFunction c
new CreateEventSourceMappingRequest()
.withFunctionName(cache.getFunctionArn())
.withBatchSize(description.getBatchsize())
.withBisectBatchOnFunctionError(description.getBisectBatchOnError())
.withMaximumBatchingWindowInSeconds(description.getMaxBatchingWindowSecs())
.withMaximumRecordAgeInSeconds(description.getMaxRecordAgeSecs())
.withMaximumRetryAttempts(description.getMaxRetryAttempts())
.withParallelizationFactor(description.getParallelizationFactor())
.withTumblingWindowInSeconds(description.getTumblingWindowSecs())
.withDestinationConfig(description.getDestinationConfig())
.withEnabled(description.getEnabled())
.withStartingPosition(description.getStartingPosition())
.withEventSourceArn(description.getEventSourceArn());
Expand Down

0 comments on commit 884ce57

Please sign in to comment.