Skip to content

Commit

Permalink
Comment Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
strawgate committed May 24, 2024
1 parent 282619b commit 5346107
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions x-pack/filebeat/input/awss3/input.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,9 +81,8 @@ func newInput(config config, store beater.StateStore) (*s3Input, error) {

// For backwards compat:
// If the endpoint does not start with S3, we will use the endpoint resolver to all SDK requests through this endpoint
// If the endpoint does start with S3, we will use the default resolver which can replace s3 with the service name
// If the endpoint does start with S3, we will use the default resolver which can replace s3 with the desired service name like sqs

// Get the resolver from the endpoint url
awsConfig.EndpointResolverWithOptions = awssdk.EndpointResolverWithOptionsFunc(func(service, region string, options ...interface{}) (awssdk.Endpoint, error) {
return awssdk.Endpoint{
PartitionID: "aws",
Expand Down Expand Up @@ -336,6 +335,7 @@ var errBadQueueURL = errors.New("QueueURL is not in format: https://sqs.{REGION_

func getRegionFromQueueURL(queueURL string, endpoint, defaultRegion string) (region string, err error) {
// get region from queueURL
// Example for custom domain queue: https://sqs.us-east-1.abc.xyz/12345678912/test-s3-logs
// Example for sqs queue: https://sqs.us-east-1.amazonaws.com/12345678912/test-s3-logs
// Example for vpce: https://vpce-test.sqs.us-east-1.vpce.amazonaws.com/12345678912/sqs-queue
u, err := url.Parse(queueURL)
Expand Down

0 comments on commit 5346107

Please sign in to comment.