All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.burkard.cdk.services.lambda.eventsources.SqsEventSource.scala Maven / Gradle / Ivy

The newest version!
package io.burkard.cdk.services.lambda.eventsources

@SuppressWarnings(Array("org.wartremover.warts.DefaultArguments", "org.wartremover.warts.Null", "DisableSyntax.null"))
object SqsEventSource {

  def apply(
    queue: software.amazon.awscdk.services.sqs.IQueue,
    enabled: Option[Boolean] = None,
    batchSize: Option[Number] = None,
    maxBatchingWindow: Option[software.amazon.awscdk.Duration] = None,
    reportBatchItemFailures: Option[Boolean] = None
  ): software.amazon.awscdk.services.lambda.eventsources.SqsEventSource =
    software.amazon.awscdk.services.lambda.eventsources.SqsEventSource.Builder
      .create(queue)
      .enabled(enabled.map(Boolean.box).orNull)
      .batchSize(batchSize.orNull)
      .maxBatchingWindow(maxBatchingWindow.orNull)
      .reportBatchItemFailures(reportBatchItemFailures.map(Boolean.box).orNull)
      .build()
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy