Skip to content

Commit

Permalink
doc: update details on Environment Variables format expectations.
Browse files Browse the repository at this point in the history
  • Loading branch information
credmond-git committed Feb 27, 2024
1 parent 42f9d53 commit 1590ba8
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 14 deletions.
26 changes: 13 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -709,19 +709,19 @@ If you provide 2 tags in the source, when retrieving the configuration you must


## Supported config sources
| Config Source | module | Details |
|------------------------------|----------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| ClassPathConfigSource | gestalt-core | Load a file from the java class path. Uses getResourceAsStream to find and load the InputStream. |
| EnvironmentConfigSource | gestalt-core | Loads all Environment Variables in the system, will convert them to a list of key values from the Env Map for the config loader. You can provide a prefix to only load Environment Variables with the prefix. Then you can choose to keep the prefix or remove it. |
| FileConfigSource | gestalt-core | Loads a file from the local file system. The format for the source will depend on the file extension of the file. For example if it is dev.properties, the format will be properties. Returns a InpuStream for the config loader. |
| KubernetesSecretConfigSource | gestalt-core | Specify a path to search for [kubernetes secrets](https://kubernetes.io/docs/concepts/configuration/secret/) files. The directory is scanned and each file is added to the configuration. The name of the file is treated as the key for configuration and the content of the file is the value for the configuration. |
| GCSConfigSource | [`gestalt-google`](https://search.maven.org/search?q=gestalt-google) | Load a config from Google Cloud Storage. Requires a bucketName and a objectName. A google Storage object is optional, otherwise it defaults to the default instance. |
| GitConfigSource | [`gestalt-git`](https://search.maven.org/search?q=gestalt-git) | Syncs a remote repo locally then uses the files to build a configuration. This uses jgit and supports several forms of authentication. See GitConfigSourceTest.java for examples of use. |
| MapConfigSource | gestalt-core | Allows you to pass in your own map, it will convert the map into a list of path and value for the config loader. |
| StringConfigSource | gestalt-core | Takes any string and converts it into a InputStream. You must also provide the format type so we can match it to a loader. |
| SystemPropertiesConfigSource | gestalt-core | Loads the Java System Properties and convert them to a list of key values or the config loader. |
| S3ConfigSource | [`gestalt-aws`](https://search.maven.org/search?q=gestalt-aws) | Loads a config source from AWS S3, Must include package com.github.gestalt-config:gestalt-s3:version. |
| URLConfigSource | gestalt-core | Loads a config source from a URL. |
| Config Source | module | Details |
|------------------------------|----------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| ClassPathConfigSource | gestalt-core | Load a file from the java class path. Uses getResourceAsStream to find and load the InputStream. |
| EnvironmentConfigSource | gestalt-core | Loads all Environment Variables in the system. It expects Env Vars to be in screaming snake case, and will parse the "_" as a path delimiter. will convert them to a list of key values from the Env Map for the config loader. You can provide a prefix to only load Environment Variables with the prefix. Then you can choose to keep the prefix or remove it. |
| FileConfigSource | gestalt-core | Loads a file from the local file system. The format for the source will depend on the file extension of the file. For example if it is dev.properties, the format will be properties. Returns a InpuStream for the config loader. |
| KubernetesSecretConfigSource | gestalt-core | Specify a path to search for [kubernetes secrets](https://kubernetes.io/docs/concepts/configuration/secret/) files. The directory is scanned and each file is added to the configuration. The name of the file is treated as the key for configuration and the content of the file is the value for the configuration. |
| GCSConfigSource | [`gestalt-google`](https://search.maven.org/search?q=gestalt-google) | Load a config from Google Cloud Storage. Requires a bucketName and a objectName. A google Storage object is optional, otherwise it defaults to the default instance. |
| GitConfigSource | [`gestalt-git`](https://search.maven.org/search?q=gestalt-git) | Syncs a remote repo locally then uses the files to build a configuration. This uses jgit and supports several forms of authentication. See GitConfigSourceTest.java for examples of use. |
| MapConfigSource | gestalt-core | Allows you to pass in your own map, it will convert the map into a list of path and value for the config loader. |
| StringConfigSource | gestalt-core | Takes any string and converts it into a InputStream. You must also provide the format type so we can match it to a loader. |
| SystemPropertiesConfigSource | gestalt-core | Loads the Java System Properties and convert them to a list of key values or the config loader. |
| S3ConfigSource | [`gestalt-aws`](https://search.maven.org/search?q=gestalt-aws) | Loads a config source from AWS S3, Must include package com.github.gestalt-config:gestalt-s3:version. |
| URLConfigSource | gestalt-core | Loads a config source from a URL. |


# Config Loader
Expand Down
2 changes: 1 addition & 1 deletion gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ checkStyle = "10.10.0"
jmh = "1.37"
gradleJmh = "0.7.2"
# @pin gestalt for integration tests.
gestalt = "0.24.3"
gestalt = "0.24.5"
# Gradle utility
gradleVersions = "0.51.0"
gitVersions = "3.0.0"
Expand Down

0 comments on commit 1590ba8

Please sign in to comment.