These are chat archives for spring-cloud/spring-cloud

12th
Jan 2018
Stephen Gream
@ThreeToes
Jan 12 2018 14:29
Alright more dumb questions
I'm trying to use ribbon to do some client side load balancing, it looks like the eureka server is returning the wrong hostname
Rather than returning the service hostname, it will return its own but the correct port
Dave Syer
@dsyer
Jan 12 2018 14:31
Probably messed up the instance config?
Stephen Gream
@ThreeToes
Jan 12 2018 14:31
Quite possibly, here's what I've got in the clients
eureka:
  instance:
    hostname: ${EUREKA_HOST:localhost}
    port: ${EUREKA_PORT:8095}
    prefer-ip-address: true
  client:
    serviceUrl:
      defaultZone: http://${eureka.instance.hostname}:${eureka.instance.port}/eureka/
Is that default zone right?
Dave Syer
@dsyer
Jan 12 2018 14:32
So you explicitly have the same hostname for the instance and the eureka service
I expect that one of them is wrong
Stephen Gream
@ThreeToes
Jan 12 2018 14:32
I've only ever done this with something running on localhost, so I have no idea what to do when distributing it across containers
Dave Syer
@dsyer
Jan 12 2018 14:33
The instance hostname is the address the service wants to be called on
Stephen Gream
@ThreeToes
Jan 12 2018 14:33
Ahhhh
Ok, thanks
Slowly getting there