configuration

package
v0.0.0-...-f5406f0 Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2024 License: Apache-2.0 Imports: 7 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Load

func Load[T any](location string) (config T, err error)

loads config from json in location and used environment variables (e.g KafkaUrl --> KAFKA_URL)

Types

type Config

type Config struct {
	DeviceRepositoryUrl                  string `json:"device_repository_url"`
	SmartServiceRepositoryUrl            string `json:"smart_service_repository_url"`
	CamundaUrl                           string `json:"camunda_url" config:"secret"`
	CamundaWorkerId                      string `json:"camunda_worker_id"`
	CamundaWorkerTopic                   string `json:"camunda_worker_topic"`
	CamundaLockDurationInMs              int64  `json:"camunda_lock_duration_in_ms"`
	CamundaWorkerWaitDurationInMs        int64  `json:"camunda_worker_wait_duration_in_ms"`
	CamundaFetchMaxTasks                 int64  `json:"camunda_fetch_max_tasks"`
	AuthEndpoint                         string `json:"auth_endpoint"`
	AuthClientId                         string `json:"auth_client_id" config:"secret"`
	AuthClientSecret                     string `json:"auth_client_secret" config:"secret"`
	TokenCacheDefaultExpirationInSeconds int    `json:"token_cache_default_expiration_in_seconds"`
}

func LoadLibConfig

func LoadLibConfig(location string) (config Config, err error)

Jump to

Keyboard shortcuts

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