Documentation ¶
Index ¶
- Constants
- Variables
- func GetDefaultAWSConfig() *aws.Config
- func GetQueueURL(ctx context.Context, logger log.Log, queueName string, sqsClient *sqs.Client) (*string, error)
- func NewKMSClientWithConfig(awsConfig aws.Config) *kms.Client
- func NewS3ClientWithConfig(awsConfig aws.Config) *s3.Client
- func NewSNSClientWithConfig(awsConfig *aws.Config) *sns.Client
- func NewSQSClientWithConfig(awsConfig aws.Config) *sqs.Client
- func NewSecretManagerClientWithSession(awsConfig aws.Config) *secretsmanager.Client
- func SetDefaultAWSConfig(defaultConfig aws.Config, t Tracer)
- type BatchQueueMessage
- type KMS
- type PIITempFile
- type S3
- func (s *S3) GetFile(ctx context.Context, s3Bucket, s3Key, localFilePath string) error
- func (s *S3) GetObject(ctx context.Context, s3Bucket, s3Key string) (*s3.GetObjectOutput, error)
- func (s *S3) PresignGetObject(ctx context.Context, s3Bucket, s3Key string, expireTimeInSeconds int64) (*v4.PresignedHTTPRequest, error)
- func (s *S3) PresignPutObject(ctx context.Context, s3Bucket, s3Key string, expireTimeInSeconds int64) (*v4.PresignedHTTPRequest, error)
- func (s *S3) PutFile(ctx context.Context, s3Bucket, s3Key, localFilPath string) (*s3.PutObjectOutput, error)
- func (s *S3) PutObject(ctx context.Context, s3Bucket, s3Key string, body io.Reader, mimeType string, ...) (*s3.PutObjectOutput, error)
- type S3Crypto
- func (s *S3Crypto) GetFile(ctx context.Context, s3Bucket, s3Key, localFilePath string) error
- func (s *S3Crypto) GetFileCache(ctx context.Context, s3Bucket, s3Key, tempPathPart string) (*PIITempFile, error)
- func (s *S3Crypto) GetObject(ctx context.Context, s3Bucket, s3Key string) ([]byte, error)
- func (s *S3Crypto) PutFile(ctx context.Context, s3Bucket, s3Key, localFilPath string) error
- func (s *S3Crypto) PutObject(ctx context.Context, s3Bucket, s3Key string, body io.Reader, mimeType string) error
- type SNS
- type SQS
- func (s *SQS) DeleteMessage(ctx context.Context, receiptHandler *string) (*sqs.DeleteMessageOutput, error)
- func (s *SQS) DeleteMessageBatch(ctx context.Context, receiptHandlerMap map[string]*string) (*sqs.DeleteMessageBatchOutput, error)
- func (s *SQS) GenerateAttribute(ctx context.Context, attribute map[string]any) map[string]types.MessageAttributeValue
- func (s *SQS) IsFIFO() bool
- func (s *SQS) ReceiveMessage(ctx context.Context, timeoutInSeconds int32, maxNumberOfMessages int32, ...) (*sqs.ReceiveMessageOutput, error)
- func (s *SQS) SendMessage(ctx context.Context, message *utils.Message, attribute map[string]any, ...) (*sqs.SendMessageOutput, error)
- func (s *SQS) SendMessageBatch(ctx context.Context, messageList []*BatchQueueMessage, delayInSeconds int32) (*sqs.SendMessageBatchOutput, error)
- func (s *SQS) SendMessageFIFO(ctx context.Context, message *utils.Message, attribute map[string]any, ...) (*sqs.SendMessageOutput, error)
- type SecretManager
- type Tracer
Constants ¶
View Source
const ( ConstMetadataKMSARN = "x-kms-arn" ConstMetadataEncryptionAlgorithm = "x-encryption-algorithm" ConstMetadataContentKey = "x-content-key" ConstEncryptionAlgorithm = "AES-GCM-256" )
Variables ¶
View Source
var DefaultMaxMessages int64 = 10
View Source
var ErrTooManyMessageToDelete = fmt.Errorf("too many message in receiptHandlerMap(should be less that 10)")
Functions ¶
func GetDefaultAWSConfig ¶
func GetQueueURL ¶
func NewSecretManagerClientWithSession ¶
func NewSecretManagerClientWithSession(awsConfig aws.Config) *secretsmanager.Client
func SetDefaultAWSConfig ¶
Types ¶
type BatchQueueMessage ¶
type PIITempFile ¶
type PIITempFile struct { Request *v4.PresignedHTTPRequest `json:"req"` ExpiresAt time.Time `json:"expiresAt"` ContentType *string `json:"contentType"` }
type S3 ¶
type S3 struct { *s3.Client *s3.PresignClient // contains filtered or unexported fields }
func GetDefaultS3Client ¶
func (*S3) PresignGetObject ¶
func (*S3) PresignPutObject ¶
type S3Crypto ¶
type S3Crypto struct { *S3 // contains filtered or unexported fields }
func (*S3Crypto) GetFileCache ¶
type SQS ¶
func (*SQS) DeleteMessage ¶
func (*SQS) DeleteMessageBatch ¶
func (*SQS) GenerateAttribute ¶
func (*SQS) ReceiveMessage ¶
func (*SQS) SendMessage ¶
func (*SQS) SendMessageBatch ¶
func (s *SQS) SendMessageBatch(ctx context.Context, messageList []*BatchQueueMessage, delayInSeconds int32) (*sqs.SendMessageBatchOutput, error)
type SecretManager ¶
type SecretManager struct { *secretsmanager.Client // contains filtered or unexported fields }
func GetDefaultSecretManagerClient ¶
func GetDefaultSecretManagerClient(logger log.Log) *SecretManager
func NewSecretManagerClient ¶
func NewSecretManagerClient(logger log.Log, client *secretsmanager.Client) *SecretManager
Click to show internal directories.
Click to hide internal directories.