hudl / fargo

Golang client for Netflix Eureka
MIT License
132 stars 53 forks source link

EurekaConnection is missing the function in the latest tag 1.3.1 #68

Open vijaych1209 opened 6 years ago

vijaych1209 commented 6 years ago

With go get in my project I am using the eureka connection to look up GetInstancesByVIPAddress. Its missing in the latest tag pulled by dep though. Should I not be using GetInstancesByVIPAddress. Also Since I couldnt see the loadbalance implementation of returning a single load balanced instance when multiples are registered, I am currently using the shuffle with GetInstancesByVIPAddress. Is that the correct approach?

seh commented 6 years ago

I see (*EurekaConnection).GetInstancesByVIPAddress is still present in file net.go.

As for your second question, I can't figure out what you're asking. Are you wondering whether you need to shuffle the sequence returned by GetInstancesByVIPAddress? You can use the Shuffled and ShuffledWith functions to request that GetInstancesByVIPAddress do the shuffling for you. If you don't shuffle it, you get them in the order sent by the server, which, if I recall correctly, is stable. It's the Eureka client library that does the shuffling.