Documentation ¶
Index ¶
- Variables
- func LoadEnv(cli *cli.Context) error
- func NewEnvExpandedReader(origin io.Reader) io.Reader
- type Config
- type Consumer
- type EventBus
- type Health
- type Instance
- type JWT
- type LoadBalancing
- type Persistence
- type PersistenceDriver
- type Providers
- type RegisterHTTP
- type RegisterNATS
- type Stream
- type Test
- type TransportProvider
- type Transports
- type Users
Constants ¶
This section is empty.
Variables ¶
View Source
var ( Path string Port int )
Functions ¶
Types ¶
type Config ¶
type Config struct { Name string `yaml:"name"` BaseURL string `yaml:"baseUrl"` JWT JWT `yaml:"jwt"` Transports Transports `yaml:"transports"` Persistence Persistence `yaml:"persistence"` EventBus EventBus `yaml:"eventBus"` Providers Providers `yaml:"providers"` Test Test `yaml:"test"` }
func LoadConfig ¶
type Consumer ¶
type Consumer struct { Name string Stream string Config json.RawMessage }
func (*Consumer) UnmarshalYAML ¶
type EventBus ¶
type EventBus struct { Provider TransportProvider Users Users }
func (*EventBus) UnmarshalYAML ¶
type Instance ¶ added in v1.0.6
type JWT ¶
type JWT struct { Secret string Timeout time.Duration Refresh struct { Enabled bool Maximum time.Duration } }
func (*JWT) UnmarshalYAML ¶
type LoadBalancing ¶ added in v1.0.6
type LoadBalancing struct {
Enabled bool `yaml:"enabled"`
}
type Persistence ¶ added in v1.0.3
type Persistence struct { Driver PersistenceDriver Name string Host string Port int Username string Password string InMem bool }
func (*Persistence) UnmarshalYAML ¶ added in v1.0.3
func (p *Persistence) UnmarshalYAML(value *yaml.Node) error
type PersistenceDriver ¶ added in v1.0.3
type PersistenceDriver int
const ( SQLite PersistenceDriver = iota BadgerDB InMem )
func ParsePersistenceDriver ¶ added in v1.0.3
func ParsePersistenceDriver(driver string) (PersistenceDriver, error)
func (PersistenceDriver) String ¶ added in v1.0.3
func (driver PersistenceDriver) String() string
type RegisterHTTP ¶ added in v1.0.6
func (*RegisterHTTP) UnmarshalYAML ¶ added in v1.0.6
func (r *RegisterHTTP) UnmarshalYAML(value *yaml.Node) error
type RegisterNATS ¶ added in v1.0.6
type Stream ¶
type Stream struct { Name string Config json.RawMessage }
func (*Stream) UnmarshalYAML ¶
type TransportProvider ¶
type TransportProvider int
const NATS TransportProvider = iota
func ParseTransportProvider ¶
func ParseTransportProvider(provider string) (TransportProvider, error)
func (TransportProvider) String ¶ added in v1.0.3
func (p TransportProvider) String() string
type Transports ¶ added in v1.0.6
type Transports struct { HTTP RegisterHTTP `yaml:"http"` NATS RegisterNATS `yaml:"nats"` LoadBalancing LoadBalancing `yaml:"loadBalancing"` }
Click to show internal directories.
Click to hide internal directories.