Send data to Amazon SQS
Most recent version: v1.0.0
Overview
The following article outlines a basic data flow from Onum to Amazon SQS.
Amazon SQS (Simple Queue Service) is a fully managed message queuing service that enables asynchronous communication between different parts of a distributed system. It allows developers to send, store, and retrieve messages without needing to manage the underlying queue infrastructure.
Prerequisites
You will need an IAM User, role or group with the correct permissions to access and manage SQS.
Amazon SQS Setup
Go to IAM (Identity and Access Management) to manage users, groups, roles and permissions.
Under Permissions Policies, make sure you have assigned the policy AmazonSQSFullAccess to give full access to SQS resources. Alternatively, if you have custom permissions, go to Policies - Create Policy and in the JSON tab, paste your custom JSON e.g.
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow"
"Action": [
"kinesis:CreateStream",
"kinesis:DescribeStream",
"kinesis:PutRecord"
],
"Resource": "*"
}
]
} Download the Access Key ID and Secret Access Key — you’ll need these later.
Onum setup
Log in to your Onum tenant and click Data Sinks> New Data sink.
Double-click the Amazon SQS Sink.


Enter a Name for the new Data Sink. Optionally, add a Description and some Tags to identify the Sink.


Decide whether or not to include this Data sink info in the metrics and graphs of the Home area.


Choose the Key format for the name of the objects:
The prefix used to organize your S3 data.
Partition by indicates the frequency with which to generate a new S3 object e.g. every year, month, day hour, minute. If left blank, the value used will be the Max object size / Input size entered in the Data sink configuration.


In the AWS authentication section, enter the Region* of your AWS console, found in your General purpose buckets area, next to the name.

Select the Access Key ID from your Secrets or click New secret to generate a new one.
The Access Key ID is found in the IAM Dashboard of the AWS Management Console.
In the left panel, click on Users.
Select your IAM user.
Under the Security Credentials tab, scroll to Access Keys, and you will find existing Access Key IDs (but not the secret access key).
Select the Secret Access Key from your Secrets or click New secret to generate a new one.
Under Access keys, you can see your Access Key IDs, but AWS will not show the Secret Access Key. You must have it saved somewhere. If you don't have the secret key saved, you need to create a new one.


Click New secret to create a new one:
Give the secret a Name.
Turn off the Expiration date option.
Click Add new value and paste the secret corresponding to the JWT token you generated before. Remember that the token will be added in the Zscaler configuration.
Click Save.


Learn more about secrets in Onum in this article.
Set the Bulk configuration parameter to true if you want to allow bulk sending. Configure the following parameters:
Event time limit* - Time in seconds to wait before sending the batch. The default value is
1, and the minimum is0.Trigger conditions
Number of events* - Maximum number of events to send in a single batch. The maximum and default value is
10.Event size* - Maximum limit of the batch size in bytes. The maximum and default value is
262144. The minimum value is1.


In the Other section
If you have non-default URL that directs API requests to a specific Kinesis service endpoint, enter it here in the Custom endpoint.
Specify Delay seconds length of time, in seconds, for which to delay a specific message. The minimum value is
1and the maximum value is900.


Click Create data sink when complete.
Your new Data sink will appear in the Data sinks area list.
Pipeline configuration
When it comes to using this Data sink in a Pipeline, you must configure the following output parameters. To do it, simply click the Data sink on the canvas and select Configuration.
Output configuration
Message*
Select the field that contains the message. The data type must be string.
Queue configuration
Standard
Queue name*: The URL of your existing Amazon SQS queue to send the data to. To get it:
Go to the AWS Management Console.
In the Search Bar, type
SQSand click on Simple Queue Service (SQS).Click on Queues in the left panel.
Locate your queue from the list and click it.
The Queue URL will be displayed in the table under URL.
This is the correct format: sqs.region.localhost/awsaccountnumber/storedinenvvar
FIFO
Queue name*: The URL of your existing Amazon SQS queue to send the data to. To get it:
Go to the AWS Management Console.
In the Search Bar, type
SQSand click on Simple Queue Service (SQS).Click on Queues in the left panel.
Locate your queue from the list and click it.
The Queue URL will be displayed in the table under URL.
This is the correct format:
sqs.region.localhost/awsaccountnumber/storedinenvvar
Message group ID*: Select an incoming field to serve as the message group ID.
Send message deduplication: Toggle ON to enable message deduplication and configure the following fields
InEventField: choose the incoming field for the message deduplication ID.
Message content hash: when content-based deduplication is enabled, the message deduplication ID is optional.


Click Save to save your configuration.
Last updated
Was this helpful?

