AWS Simple Queue Service Source

This page describes how to use the Amazon Web Services (AWS) Simple Queue Service (SQS) with the IntegrationSource API for Eventing in OpenShift Serverless.

OpenShift Serverless IntegrationSource is a Developer Preview feature only.

Developer Preview features are not supported with Red Hat production service level agreements (SLAs) and might not be functionally complete. Red Hat does not recommend using them in production. These features provide early access to upcoming product features, enabling customers to test functionality and provide feedback during the development process.

For more information about the support scope of Red Hat Developer Preview features, see access.redhat.com/support/offerings/devpreview/.

Amazon credentials

For connecting to AWS the IntegrationSource uses Kubernetes Secret, present in the namespace of the resource. The Secret can be created like:

$ oc -n <namespace> create secret generic my-secret --from-literal=aws.accessKey=<accessKey> --from-literal=aws.secretKey=<secretKey>

AWS SQS Source Example

Below is an IntegrationSource to receive data from AWS SQS.

apiVersion: sources.knative.dev/v1alpha1
kind: IntegrationSource
metadata:
  name: integration-source-aws-sqs
  namespace: knative-samples
spec:
  aws:
    sqs:
      arn: "arn:aws:s3:::my-queue"
      region: "eu-north-1"
    auth:
      secret:
        ref:
        name: "my-secret"
  sink:
    ref:
      apiVersion: eventing.knative.dev/v1
      kind: Broker
      name: default

Inside of the aws.sqs object we define the name of the queue (or arn) and its region. The credentials for the AWS service are referenced from the my-secret Kubernetes Secret

More details about the Apache Camel Kamelet aws-sqs-source.