databroker server backend config (#1127)

* config,docs: add databroker storage backend configuration

* cache: allow configuring which backend storage to use

Currently supported types are "memory", "redis".
This commit is contained in:
Cuong Manh Le 2020-07-23 10:42:43 +07:00 committed by GitHub
parent c9182f757e
commit 1640151bc1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 99 additions and 6 deletions

View file

@ -813,6 +813,27 @@ For an example implementation, the in-memory database used by the cache service
- [pkg/databroker/memory](https://github.com/pomerium/pomerium/tree/master/pkg/databroker/memory)
### Data Broker Storage Type
- Environmental Variable: `DATABROKER_STORAGE_TYPE`
- Config File Key: `databroker_storage_type`
- Type: `string`
- Optional
- Example: `redis`
- Default: `memory`
The backend storage that databroker server will use, available types: `memory`, `redis`.
### Data Broker Storage Connection String
- Environmental Variable: `DATABROKER_STORAGE_CONNECTION_STRING`
- Config File Key: `databroker_storage_connection_string`
- Type: `string`
- **Required** when storage type is `redis`
- Example: `":6379"`
The connection string that server will use to connect to storage backend.
## Policy
- Environmental Variable: `POLICY`