Documentation ¶
Index ¶
Constants ¶
const DefaultConfigFile string = "./weaviate.conf.json"
DefaultConfigFile is the default file when no config file is provided
const DefaultEnvironment string = "development"
DefaultEnvironment is the default env when no env is provided
Variables ¶
This section is empty.
Functions ¶
func GetConfigOptionGroup ¶
func GetConfigOptionGroup() *swag.CommandLineOptionsGroup
GetConfigOptionGroup creates a option group for swagger
Types ¶
type ConfigStore ¶
type Contextionary ¶
type Database ¶
type Database struct { Name string `json:"name"` DatabaseConfig interface{} `json:"database_config"` }
Database is the outline of the database
type Development ¶
type Development struct {
ExternalInstances []Instance `json:"external_instances"`
}
Development is the outline of (temporary) config variables Note: the purpose is that these variables will be moved somewhere else in time
type Environment ¶
type Environment struct { Name string `json:"name"` Database Database `json:"database"` Schemas Schemas `json:"schemas"` Broker Broker `json:"broker"` Network *Network `json:"network"` Limit int64 `json:"limit"` Debug bool `json:"debug"` Development Development `json:"development"` Contextionary Contextionary `json:"contextionary"` ConfigStore ConfigStore `json:"configuration_storage"` }
Environment outline of the environment inside the config file
type File ¶
type File struct {
Environments []Environment `json:"environments"`
}
File gives the outline of the config file
type Flags ¶
type Flags struct { ConfigSection string `long:"config" description:"the section inside the config file that has to be used"` ConfigFile string `long:"config-file" description:"path to config file (default: ./weaviate.conf.json)"` }
Flags are input options
type Instance ¶
type Instance struct { URL string `json:"url"` APIKey string `json:"api_key"` APIToken string `json:"api_token"` }
Instance is the outline for an external instance whereto crossreferences can be resolved
type WeaviateConfig ¶
type WeaviateConfig struct { Environment Environment Hostname string Scheme string }
WeaviateConfig represents the used schema's
func (*WeaviateConfig) GetHostAddress ¶
func (f *WeaviateConfig) GetHostAddress() string
GetHostAddress from config locations
func (*WeaviateConfig) GetInstance ¶
func (f *WeaviateConfig) GetInstance(hostname string) (instance Instance, err error)
GetInstance from config
func (*WeaviateConfig) LoadConfig ¶
func (f *WeaviateConfig) LoadConfig(flags *swag.CommandLineOptionsGroup, m *messages.Messaging) error
LoadConfig from config locations