Documentation
¶
Index ¶
- Constants
- Variables
- func BackendConfigGetter(e config.ExtraConfig) interface{}
- func NewAwsAppInstance(port int, appName string, instanceMeta *ec2metadata.EC2Metadata) (*fargo.Instance, error)
- func NewLocalAppInstance(port int, appName string) (*fargo.Instance, error)
- type BackendExtraConfig
- type EurekaClient
- type EurekaConfig
- type EurekaSubscriber
Constants ¶
View Source
const BACKEND_EUREKA_APP_NAME = "eureka_app_name"
View Source
const BackendNamespace = "github.com/schibsted/krakend-eureka"
Namespace is the key to use to store and access the custom config data
View Source
const POLL_INTERVAL = 30 // seconds
Variables ¶
View Source
var DefaultBackendExtraConfig = BackendExtraConfig{EurekaAppName: ""}
View Source
var EmptyBackendExtraConfig = BackendExtraConfig{}
Functions ¶
func BackendConfigGetter ¶
func BackendConfigGetter(e config.ExtraConfig) interface{}
func NewAwsAppInstance ¶
func NewAwsAppInstance(port int, appName string, instanceMeta *ec2metadata.EC2Metadata) (*fargo.Instance, error)
Types ¶
type BackendExtraConfig ¶
type BackendExtraConfig struct {
EurekaAppName string
}
func GetBackendExtraConfig ¶
func GetBackendExtraConfig(e *config.Backend) BackendExtraConfig
func NewBackendExtraConfigFromMap ¶
func NewBackendExtraConfigFromMap(data map[string]interface{}) BackendExtraConfig
func (BackendExtraConfig) AsMap ¶
func (e BackendExtraConfig) AsMap() map[string]interface{}
type EurekaClient ¶
type EurekaClient interface { EnableInstance() NewSubscriber(subscriber sd.SubscriberFactory) sd.SubscriberFactory }
func NewFargoEurekaClient ¶
type EurekaConfig ¶
type EurekaSubscriber ¶
type EurekaSubscriber struct {
// contains filtered or unexported fields
}
func (EurekaSubscriber) Hosts ¶
func (e EurekaSubscriber) Hosts() ([]string, error)
Click to show internal directories.
Click to hide internal directories.