Versions in this module Expand all Collapse all v0 v0.2.9 Feb 25, 2020 v0.2.8 Feb 25, 2020 v0.2.7 Feb 25, 2020 Changes in this version + func GetHostnameByIP(ip string) (hostname string) type AppInfo + IPAddress string v0.2.6 Feb 21, 2020 Changes in this version + func GetLocalIPS() (ips []string) v0.2.5 Jan 15, 2020 Changes in this version + var RETRIES = 3 + func NowStr() string v0.2.4 Dec 17, 2019 v0.2.3 Dec 16, 2019 v0.2.2 Dec 16, 2019 Changes in this version type AppInfo + LogLevel zerolog.Level v0.2.1 Dec 16, 2019 v0.2.0 Dec 3, 2019 Changes in this version + const ADDED + const Amazon + const DELETED + const MODIFIED + const MyOwn + const Netflix + func GetLocalIP() string + func NewServiceCache(timeout time.Duration) *serviceCache + type ActionType string + type AppInfo struct + AppID string + EurekaURL string + HostName string + InstanceID string + Password string + Port int + UserName string + type Application struct + Instance []Instance + Name string + type Applications struct + Application []Application + AppsHashCode string + VersionDelta string + type Client struct + AppInfo AppInfo + Instance Instance + func New(appInfo *AppInfo) (*Client, error) + func (c *Client) Deregister() error + func (c *Client) Do(r *http.Request) (*http.Response, error) + func (c *Client) GetAppInstanceByID(appID string, instanceID string) (Instance, error) + func (c *Client) GetAppInstanceSVip(svips string) (Applications, error) + func (c *Client) GetAppInstanceVip(vip string) (Applications, error) + func (c *Client) GetAppInstances(appID string) (Application, error) + func (c *Client) GetApps() (Applications, error) + func (c *Client) GetOwnAppInstance() (Instance, error) + func (c *Client) GetOwnAppInstances() (Application, error) + func (c *Client) Register() error + func (c *Client) Request(req *http.Request) (*http.Response, error) + func (c *Client) RoundTrip(r *http.Request) (*http.Response, error) + func (c *Client) StartHeartbeat() error + func (c *Client) StopHeartbeat() + func (c *Client) UpdateOwnAppInstanceMetadata(value map[string]string) error + func (c *Client) UpdateOwnAppInstanceStatus(status InstanceStatus) error + type CustomError string + const ErrorNotFoundService + func (c CustomError) Error() string + func (c CustomError) Wrap(b error) error + type DataCenterInfo struct + Class string + Name string + type DataCenterInfoName string + type Instance struct + ActionType ActionType + App string + CountryId int + DataCenterInfo DataCenterInfo + HealthCheckUrl string + HomePageUrl string + HostName string + InstanceID string + IpAddr string + IsCoordinatingDiscoveryServer bool + LastDirtyTimestamp int64 + LastUpdatedTimestamp int64 + LeaseInfo LeaseInfo + Metadata interface{} + Overriddenstatus InstanceStatus + Port Port + SecurePort Port + SecureVipAddress string + Sid string + Status InstanceStatus + StatusPageUrl string + VipAddress string + type InstanceStatus string + const DOWN + const OUT_OF_SERVICE + const STARTING + const UNKNOWN + const UP + type LeaseInfo struct + DurationInSecs int + EvictionTimestamp int64 + LastRenewalTimestamp int64 + RegistrationTimestamp int64 + RenewalIntervalInSecs int + ServiceUpTimestamp int64 + type MaxRetriesExceeded struct + Description string + MaxRetries int + func (err MaxRetriesExceeded) Error() string + type Port struct + Enabled bool + Value int