File tree Expand file tree Collapse file tree 3 files changed +5
-0
lines changed
Expand file tree Collapse file tree 3 files changed +5
-0
lines changed Original file line number Diff line number Diff line change 11* .test
22eureka
33.vagrant /
4+ .idea /
Original file line number Diff line number Diff line change @@ -803,6 +803,9 @@ func (e *EurekaConnection) HeartBeatInstance(ins *Instance) error {
803803}
804804
805805func (i * Instance ) Id () string {
806+ if i .InstanceId != "" {
807+ return i .InstanceId
808+ }
806809 if i .UniqueID != nil {
807810 return i .UniqueID (* i )
808811 }
Original file line number Diff line number Diff line change @@ -77,6 +77,7 @@ type RegisterInstanceJson struct {
7777
7878// Instance [de]serializeable [to|from] Eureka [XML|JSON].
7979type Instance struct {
80+ InstanceId string `xml:"instanceId" json:"instanceId"`
8081 HostName string `xml:"hostName" json:"hostName"`
8182 App string `xml:"app" json:"app"`
8283 IPAddr string `xml:"ipAddr" json:"ipAddr"`
You can’t perform that action at this time.
0 commit comments