- java.lang.Object
-
- org.github.gestalt.config.aws.s3.S3ConfigSource
-
- All Implemented Interfaces:
org.github.gestalt.config.source.ConfigSource
public final class S3ConfigSource extends java.lang.Object implements org.github.gestalt.config.source.ConfigSourceLoads a file from S3.
-
-
Constructor Summary
Constructors Constructor Description S3ConfigSource(software.amazon.awssdk.services.s3.S3Client s3, java.lang.String bucketName, java.lang.String keyName)Constructor for S3ConfigSource.S3ConfigSource(software.amazon.awssdk.services.s3.S3Client s3, java.lang.String bucketName, java.lang.String keyName, org.github.gestalt.config.tag.Tags tags)Deprecated, for removal: This API element is subject to removal in a future version.Tags should be added via the builder.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object o)java.lang.Stringformat()org.github.gestalt.config.tag.TagsgetTags()inthashCode()booleanhasList()booleanhasStream()java.util.UUIDid()java.util.List<org.github.gestalt.config.utils.Pair<java.lang.String,java.lang.String>>loadList()java.io.InputStreamloadStream()java.lang.Stringname()
-
-
-
Constructor Detail
-
S3ConfigSource
public S3ConfigSource(software.amazon.awssdk.services.s3.S3Client s3, java.lang.String bucketName, java.lang.String keyName) throws org.github.gestalt.config.exceptions.GestaltExceptionConstructor for S3ConfigSource.- Parameters:
s3- S3 clientbucketName- name of the S3 bucketkeyName- name of the S3 key- Throws:
org.github.gestalt.config.exceptions.GestaltException- any exceptions thrown
-
S3ConfigSource
@Deprecated(since="0.26.0", forRemoval=true) public S3ConfigSource(software.amazon.awssdk.services.s3.S3Client s3, java.lang.String bucketName, java.lang.String keyName, org.github.gestalt.config.tag.Tags tags) throws org.github.gestalt.config.exceptions.GestaltExceptionDeprecated, for removal: This API element is subject to removal in a future version.Tags should be added via the builder. Storage of the tags have been moved toConfigSourcePackage.getTags().Constructor for S3ConfigSource.- Parameters:
s3- S3 clientbucketName- name of the S3 bucketkeyName- name of the S3 keytags- tags associated with the source- Throws:
org.github.gestalt.config.exceptions.GestaltException- any exceptions thrown
-
-
Method Detail
-
hasStream
public boolean hasStream()
- Specified by:
hasStreamin interfaceorg.github.gestalt.config.source.ConfigSource
-
loadStream
public java.io.InputStream loadStream() throws org.github.gestalt.config.exceptions.GestaltException- Specified by:
loadStreamin interfaceorg.github.gestalt.config.source.ConfigSource- Throws:
org.github.gestalt.config.exceptions.GestaltException
-
hasList
public boolean hasList()
- Specified by:
hasListin interfaceorg.github.gestalt.config.source.ConfigSource
-
loadList
public java.util.List<org.github.gestalt.config.utils.Pair<java.lang.String,java.lang.String>> loadList() throws org.github.gestalt.config.exceptions.GestaltException- Specified by:
loadListin interfaceorg.github.gestalt.config.source.ConfigSource- Throws:
org.github.gestalt.config.exceptions.GestaltException
-
format
public java.lang.String format()
- Specified by:
formatin interfaceorg.github.gestalt.config.source.ConfigSource
-
name
public java.lang.String name()
- Specified by:
namein interfaceorg.github.gestalt.config.source.ConfigSource
-
id
public java.util.UUID id()
- Specified by:
idin interfaceorg.github.gestalt.config.source.ConfigSource
-
getTags
public org.github.gestalt.config.tag.Tags getTags()
- Specified by:
getTagsin interfaceorg.github.gestalt.config.source.ConfigSource
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
-