Documentation
¶
Index ¶
Constants ¶
View Source
const ( // the api key can reside in the url parameter 'key' // maps to config value 'key' UrlKey = iota + 1 // the api key can reside in the header 'x-api-key' // maps to config value 'header' HeaderKey // the api key can reside in either of the two // maps to config value 'both' URLKeyAndHeaderKey )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APICfg ¶
type APICfg struct {
// values
BindIP string
Port int
ZooHosts []string
KafkaZnode string //The Zookeeper znode used by Kafka
StoreHost string
StoreDB string
Cert string
CertKey string
CertificateAuthoritiesDir string
ResAuth bool
ServiceToken string
LogLevel string
// Proxy Hostname represents the FQDN of the a potential proxy/load balancer that might be
// serving requests in front of the ams instance
ProxyHostname string
PushEnabled bool
// Whether or not it should communicate over tls with the push server
PushTlsEnabled bool
// Push server endpoint
PushServerHost string
// Push server port
PushServerPort int
// If tls is enabled, whether or not it should verify the push server's certificate
VerifyPushServer bool
// The token that corresponds to the registered push worker user
PushWorkerToken string
// Logging output(console,file,syslog etc)
LogFacilities []string
// contains filtered or unexported fields
}
APICfg holds kafka configuration
func (*APICfg) AuthOption ¶
func (cfg *APICfg) AuthOption() AuthOption
AuthOption returns the value of the config for auth_option
func (*APICfg) GetBrokerInfo ¶
GetBrokerInfo is a wrapper over GetZooList which retrieves broker information from zookeeper
func (*APICfg) GetZooList ¶
GetZooList gets broker list from zookeeper
func (*APICfg) LoadCAs ¶
LoadCAs builds the CA chain using pem files from the specified directory in the cfg
func (*APICfg) LoadStrJSON ¶
LoadStrJSON Loads configuration from a JSON string
type AuthOption ¶
type AuthOption int
AuthOption defines how the service will handle authentication/authorization KEY, HEADER or BOTH are the available values for where the auth token should reside
func (AuthOption) String ¶
func (a AuthOption) String() string
String representation of the iota auth option
Click to show internal directories.
Click to hide internal directories.