s3provider

package module
v0.116.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 17, 2024 License: Apache-2.0 Imports: 10 Imported by: 4

README

Summary

This package provides a ConfigMapProvider implementation for Amazon S3 (s3provider) that allows the Collector the ability to load configuration by fetching and reading config objects stored in Amazon S3.

How it works

  • It will be called by ConfigMapResolver to load configuration for the Collector.
  • By giving a config URI starting with prefix s3://, this s3provider will be used to download config objects from the given S3 URIs, and then use the downloaded configuration during Collector initialization.

Expected URI format:

  • s3://[BUCKET].s3.[REGION].amazonaws.com/[KEY]

Prerequistes:

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New deprecated

func New() confmap.Provider

New returns a new confmap.Provider that reads the configuration from a file.

This Provider supports "s3" scheme, and can be called with a "uri" that follows:

s3-uri : s3://[BUCKET].s3.[REGION].amazonaws.com/[KEY]

One example for s3-uri be like: s3://doc-example-bucket.s3.us-west-2.amazonaws.com/photos/puppy.jpg References: https://docs.aws.amazon.com/AmazonS3/latest/userguide/bucketnamingrules.html

Examples: `s3://DOC-EXAMPLE-BUCKET.s3.us-west-2.amazonaws.com/photos/puppy.jpg` - (unix, windows)

Deprecated: [v0.100.0] Use NewFactory() instead.

func NewFactory added in v0.100.0

func NewFactory() confmap.ProviderFactory

NewFactory returns a new confmap.ProviderFactory that creates a confmap.Provider which reads configuration from a file obtained from an s3 bucket.

This Provider supports "s3" scheme, and can be called with a "uri" that follows:

s3-uri : s3://[BUCKET].s3.[REGION].amazonaws.com/[KEY]

One example for s3-uri be like: s3://doc-example-bucket.s3.us-west-2.amazonaws.com/photos/puppy.jpg References: https://docs.aws.amazon.com/AmazonS3/latest/userguide/bucketnamingrules.html

Examples: `s3://DOC-EXAMPLE-BUCKET.s3.us-west-2.amazonaws.com/photos/puppy.jpg` - (unix, windows)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL