Amazon S3

You can configure Amazon S3 as a source or a target.

To configure the connection details for Amazon S3 in your Micro-Integration, see Amazon S3 Connection Parameters.

You must also define at least one Micro-Integration Flow that specifies:

For a listing of available message headers, see Amazon S3 Message Headers.

Amazon S3 Connection Parameters

The following table describes the connection parameters for Amazon S3.

Field Description
Checkpoint Queue The name of the Last Value Queue to use as checkpoint storage.
Auto Create Checkpoint Queue Select to automatically create the checkpoint queue if it does not exist.

Micro-Integration Flow Parameters

You must configure the endpoint parameters for each Flow. Each Flow can have different settings, but they all share the connection details of the parent Micro-Integration.

Amazon S3 Source Parameters

The following table describes the parameters for configuring Amazon S3 as a source.

Field Description
Amazon S3 URI

The URI of the Amazon S3 data source, including the bucket name or ARN.

Format: aws2-s3://<bucketNameOrARN>

AWS Region The AWS Region, for example, us-east-1.
AWS Access Key The AWS Access Key ID to use to authenticate with the Amazon S3 service.
AWS Secret Key

The Secret Access Key associated with the Access Key ID.

Delete after read Select this option to delete the file after reading.
File Format

The format of the files coming from the Amazon S3 service

Additional Properties Additional properties for the Amazon S3 service. For more information, see Additional Source Properties.

Delimited File Configuration Properties

Field Description
Event Delimiter The delimiter used to separate the events in the file.
Field Delimiter The delimiter used to separate the fields in each event.

JSON File Configuration Properties

Field Description
JSON Path Filter Expression

A JSONPath expression used to split the JSON file into multiple messages. The default is $, which means the entire file is treated as a single message. For example, if a JSON file contains an array of objects [{"a":1}, {"a":2}], setting jsonPath to $.* generates two separate messages.

XML File Configuration Properties

Field Description
XPath Filter Expression

An XPath expression that splits the XML file into multiple messages. The default is /, which means the entire file is treated as a single message. For example, if an XML file is <root><item>1</item><item>2</item></root>, setting xPath to /root/item generates two messages.

Additional Source Properties

Option Type Default Description

autoCreateBucket

boolean

false

When true, enables the autocreation of the S3 bucket. You can also use this parameter when the moveAfterRead option is enabled to create the destinationBucket if it doesn't already exist.

delimiter

String

None

The delimiter to use to consume only objects you are interested in.

forcePathStyle

boolean

false

When true, the S3 client uses a path-style URL instead of virtual-hosted-style.

overrideEndpoint

boolean

false

When true, enables overriding the endpoint. This option must be used in combination with the uriEndpointOverride option.

policy

String

None

The policy for this queue to set in the com.amazonaws.services.s3.AmazonS3#setBucketPolicy() method.

prefix

String

None

A prefix to filter objects in the bucket. Only objects with keys starting with this prefix are consumed. If not set, all objects in the bucket are processed. For example, if prefix is inbound/, only objects in the inbound/ folder are processed.

uriEndpointOverride

String

None

The overriding URI endpoint. This option must be used in combination with the overrideEndpoint option.

customerAlgorithm

String

None

The customer algorithm to use when CustomerKey is enabled.

customerKeyId

String

None

The id of the Customer key to use when CustomerKey is enabled.

customerKeyMD5

String

None

The MD5 of Customer key to use when CustomerKey is enabled.

destinationBucket

String

None

The destination bucket where an object must be moved when moveAfterRead is set to true.

destinationBucketPrefix

String

None

The destination bucket prefix to use when an object must be moved, and moveAfterRead is set to true.

destinationBucketSuffix

String

None

The destination bucket suffix to use when an object must be moved, and moveAfterRead is set to true.

doneFileName

String

None

If provided, the Micro-Integration consumes files only if a done file exists.

fileName

String

None

The file name to get the object from the bucket.

maxConnections

int

60

The maxConnections parameter in the S3 client configuration.

maxMessagesPerPoll

int

10

The maximum number of messages as a limit to poll at each polling. The default value is 10. Use 0 or a negative number to set it as unlimited.

moveAfterRead

boolean

false

When true, moves objects from S3 bucket to a different bucket after they have been retrieved. To accomplish the operation, the destinationBucket option must be set. The copy bucket operation is only performed if the Exchange is committed. If a rollback occurs, the object is not moved.

removePrefixOnMove

boolean

false

When true, removes the prefix from the object key when moving it to the destination bucket.

batchMessageNumber

int

10

The number of messages composing a batch in streaming upload mode.

batchSize

int

1000000

The batch size (in bytes) in streaming upload mode.

bufferSize

int

1000000

The buffer size (in bytes) in streaming upload mode.

deleteAfterWrite

boolean

false

When true, deletes the file object after the S3 file has been uploaded.

keyName

String

None

The key name for an element in the bucket through endpoint parameter.

streamingUploadMode

boolean

false

When true, the upload to bucket is done in streaming.

streamingUploadTimeout

long

None

When streaming upload mode is true, this option sets the timeout to complete upload.

awsKMSKeyId

String

None

The id of KMS key to use when KMS is enabled.

conditionalWritesEnabled

boolean

false

When true, uploads the object only if the object key name does not already exist in the bucket specified.

useAwsKMS

boolean

false

When true, KMS must be used.

useCustomerKey

boolean

false

When true, Customer Key must be used.

useSSES3

boolean

false

When true, SSE S3 must be used.

proxyHost

String

None

The proxy host when instantiating the SQS client.

proxyPort

Integer

None

A proxy port to be used inside the client definition.

proxyProtocol

Protocol

HTTPS

The proxy protocol to use instantiating the S3 client. Set to one of:

  • HTTP

  • HTTPS

backoffErrorThreshold

int

None

The number of subsequent error polls that must occur before the backoffMultiplier is triggered. Error polls are polls that fail because of an error.

backoffIdleThreshold

int

None

The number of subsequent idle polls that must occur before the backoffMultiplier is triggered.

backoffMultiplier

int

None

A multiplier that allows the scheduled polling to back off if there has been a number of subsequent idle polls or errors in a row. The multiplier represents the number of polls that are skipped before the next actual attempt occurs. When you use this option, you must also configure backoffIdleThreshold and/or backoffErrorThreshold.

delay

long

500

The number of milliseconds before the next poll.

greedy

boolean

false

When true, scheduled polling runs again immediately if the previous poll retrieved one or more messages.

initialDelay

long

1000

The number of milliseconds before the first poll starts.

repeatCount

long

0

The maximum number of times the scheduler fires. For example, if you set this parameter to 1, the scheduler fires only once. If you set it to 5, the scheduler fires five times. A value of zero or a negative value means the scheduler fires indefinitely.

startScheduler

boolean

true

When true, the scheduler is auto started.

useFixedDelay

boolean

true

When true, fixed delay is used. When false, fixed rate is used. See ScheduledExecutorService in the JDK for details.

profileCredentialsName

String

None

The profile name when using a profile credentials provider.

sessionToken

String

None

The Amazon AWS Session Token used when the user must assume an IAM role.

trustAllCertificates

boolean

false

When true, all certificates are trusted when overriding the endpoint.

useDefaultCredentialsProvider

boolean

false

When true, the S3 client expects to load credentials through a default credentials provider.

useProfileCredentialsProvider

boolean

false

When true, the S3 client expects to load credentials through a profile credentials provider.

useSessionCredentials

boolean

false

When true, the S3 client expects to use Session Credentials (useful when the user must assume an IAM role for doing operations in S3).

Amazon S3 Target Parameters

The following table describes the parameters for configuring Amazon S3 as a target.

Field Description
AWS S3 URI The URI of the AWS S3 bucket where files are stored. Format: aws2-s3://<bucketNameOrARN>
AWS Region The AWS Region, for example, us-east-1.
AWS Access Key The AWS Access Key ID for authenticating with AWS.
AWS Secret Key The Secret Access Key associated with the Access Key ID.
Auto Create Bucket Select to automatically create the target bucket if it does not already exist. The default is false.
Max Records The maximum number of records aggregated into a single file before it is flushed to the bucket. The default is 10000.
Timeout (ms) The maximum time, in milliseconds, to wait before flushing an incomplete aggregation to the bucket. The default is 60000.
File Format

The output file format used when writing records to the target bucket. The default is JSONL.

Additional Properties Additional target endpoint query parameters for Amazon S3, specified as key-value pairs. For more information, see Additional Target Properties.

JSONL File Format Options

Field Description
Expression Template The template used to build the target file name. The default is ${uuid}.jsonl.

XML File Format Options

Field Description
Expression Template The template used to build the target file name. The default is ${uuid}.xml.
XML Root Tag The XML root element tag name that wraps all events in the batch. The default is root.
Prepend to File A string to prepend to the beginning of each output file, for example an XML declaration. This is applied only once, when the file is created.

Parquet File Format Options

Field Description
Expression Template The template used to build the target file name. The default is ${uuid}.parquet.
Max Size (Bytes) The maximum aggregated size, in bytes, before a file is flushed. The default is 52428800.
Avro Schema File

The Avro schema file used when writing Parquet output. If you do not set this option, the Micro-Integration writes each message unmodified as a string in a data field, with a timestamp field set to the time the message was processed, in epoch milliseconds. The payload must be valid JSON.

CSV File Format Options

Field Description
Expression Template The template used to build the target file name. The default is ${uuid}.csv.
Contains Headers When selected, incoming CSV messages carry their own header as the first line, which is stripped before merging with other messages. The default is false.
Prepend to File A string to prepend to the beginning of each output file, for example a header line. This is applied only once, when the file is created.

Additional Target Properties

Field Description
keyName The key name to use for the target object, overriding the name otherwise generated from the destination path.
forcePathStyle When true, the client uses path-style URLs instead of virtual-hosted-style URLs. Useful for S3-compatible storage services that don't support virtual-hosted-style addressing. The default is false.
multiPartUpload When true, files are uploaded using S3 multipart upload. The part size is controlled by partSize. The default is false.
partSize The part size, in bytes, used when multiPartUpload is true. Minimum 5 MB (AWS requirement). The default is 26214400 (25 MB).
streamingUploadMode When true, files are uploaded to the bucket in streaming mode rather than as a single buffered upload. Related fields: streamingUploadTimeout, batchMessageNumber, batchSize, bufferSize. The default is false.
streamingUploadTimeout The timeout, in milliseconds, to complete the upload when streamingUploadMode is true.
batchMessageNumber The number of messages composing a batch when streamingUploadMode is true. The default is 10.
batchSize The batch size, in bytes, when streamingUploadMode is true. The default is 1000000 (1 MB).
bufferSize The buffer size, in bytes, when streamingUploadMode is true. The default is 1000000 (1 MB).
delimiter The delimiter used to group object keys when listing objects in the bucket.
overrideEndpoint When true, enables overriding the endpoint. You must use this option together with uriEndpointOverride. The default is false.
policy The policy to apply to the bucket by using the com.amazonaws.services.s3.AmazonS3#setBucketPolicy() method.
prefix A prefix to filter objects in the bucket.
uriEndpointOverride The URI of the endpoint to use instead of the default endpoint. You must use this option together with overrideEndpoint.
customerAlgorithm The encryption algorithm for the customer-provided key. Use this option when useCustomerKey is true.
customerKeyId The ID of the customer-provided encryption key. Use this option when useCustomerKey is true.
customerKeyMD5 The MD5 hash of the customer-provided encryption key. Use this option when useCustomerKey is true.
deleteAfterWrite When true, deletes the file object after the S3 file has been uploaded. The default is false.
restartingPolicy The restarting policy to use when streamingUploadMode is true. One of override or lastPart. The default is override.
awsKMSKeyId The ID of the AWS Key Management Service (KMS) key. Use this option when useAwsKMS is true.
conditionalWritesEnabled When true, uploads the object only if an object with the same key name does not already exist in the bucket. The default is false.
useAwsKMS When true, encrypts uploaded objects with AWS KMS. The default is false.
useCustomerKey When true, encrypts uploaded objects with a customer-provided key. The default is false.
useSSES3 When true, encrypts uploaded objects with Amazon S3-managed keys (SSE-S3). The default is false.
proxyHost The hostname of the proxy server that the S3 client uses.
proxyPort The port of the proxy server that the S3 client uses.
proxyProtocol The proxy protocol to use when instantiating the S3 client. One of HTTP or HTTPS. The default is HTTPS.
profileCredentialsName The profile name to use when useProfileCredentialsProvider is true.
sessionToken The AWS session token to use when you must assume an IAM role.
trustAllCertificates When true, the S3 client trusts all certificates when you override the endpoint. The default is false.
useDefaultCredentialsProvider When true, the S3 client loads credentials through the default credentials provider. The default is false.
useProfileCredentialsProvider When true, the S3 client loads credentials through a profile credentials provider. The default is false.
useSessionCredentials When true, the S3 client uses session credentials. Use this option when you must assume an IAM role to perform S3 operations. The default is false.
lazyStartProducer When true, the target is not started until the first message is processed. Use this to allow the Micro-Integration to start even if the target would otherwise fail to start. The default is false.

Troubleshooting

The following troubleshooting tips might help you to resolve issues with this Micro-Integration. If problems persist, contact Solace.

Startup Fails: Bucket Not Found

If the Micro-Integration logs a NoSuchBucket error or a similar "bucket does not exist" message when starting:

  • As a target, verify that the bucket specified in AWS S3 URI exists in the configured AWS Region, or set Auto Create Bucket to true so the target bucket is created automatically.

  • As a source, verify that the bucket name portion of AWS S3 URI refers to a bucket that exists.

  • Confirm that the configured AWS Region matches the region the bucket was created in. AWS S3 bucket lookups fail if the region doesn't match, even if the bucket name is correct.

403 Forbidden: Insufficient IAM Permissions

If messages are routed to the dead message queue (DMQ) with an AccessDenied error, or the logs show a 403 Forbidden response from AWS S3:

  • As a target, verify that the IAM identity for AWS Access Key has s3:PutObject permission on the target bucket (and s3:CreateBucket if Auto Create Bucket is enabled).

  • As a source, verify that the IAM identity has s3:GetObject and s3:ListBucket permission on the source bucket.

  • Check that AWS Access Key and AWS Secret Key haven't been rotated or revoked in AWS IAM.

  • Confirm that no bucket policy or Service Control Policy (SCP) on the AWS account explicitly denies the action.

Connection Refused: Event Broker Unreachable

If the Micro-Integration reports a connection error, or the Flow stops processing messages:

  • Verify that the event broker service messaging service associated with the Micro-Integration is running.

  • Verify that the Message VPN used by the Micro-Integration is not shut down.

  • If problems persist, contact Solace.

Parquet Schema Mismatch

If messages are rejected and then redelivered or moved to the DMQ when File Format is set to PARQUET:

  • If you configured Avro Schema File, verify that the message payload contains all fields required by the schema, and that each field's type (for example, string versus integer) matches the schema definition. The Micro-Integration does not coerce mismatched types.

  • Verify that field names in the message payload match the schema's field names exactly, including case.

  • If you did not configure Avro Schema File, the payload must be valid JSON. The Micro-Integration stores it unmodified as a string in a data field.

Inspecting Failed Messages in the DMQ

If Flow DMQ is enabled and messages are being routed there, you can browse the DMQ directly on the event broker to inspect the failed message payload and standard message properties (such as delivery count). For more information, see Viewing Endpoint Messaging Data.

For general information about when messages are routed to the DMQ and how retry interacts with it, see Error Handling for Micro-Integration Flows.

File Format Issues

If files written by the target are not in the expected format, or aggregated files are flushed more or less often than expected:

  • Verify that File Format and its related options are configured correctly.

  • Review the Max Records, Max Size (Bytes), and Timeout (ms) settings.

Error Output and Logging

Review the Micro-Integration logs for error messages indicating connection, authentication, or permission failures.