Commit 5166994f by Spencer Gibb

add documentation for ribbon.eureka.enabled

fixes gh-325
parent ce6d286d
...@@ -650,6 +650,18 @@ stores: ...@@ -650,6 +650,18 @@ stores:
listOfServers: example.com,google.com listOfServers: example.com,google.com
---- ----
=== Example: Disable Eureka use in Ribbon
Setting the property `ribbon.eureka.enabled = false` will explicitly
disable the use of Eureka in Ribbon.
.application.yml
----
ribbon:
eureka:
enabled: false
----
=== Using the Ribbon API Directly === Using the Ribbon API Directly
You can also use the `LoadBalancerClient` directly. Example: You can also use the `LoadBalancerClient` directly. Example:
...@@ -838,18 +850,24 @@ The location of the backend can be specified as either a "serviceId" ...@@ -838,18 +850,24 @@ The location of the backend can be specified as either a "serviceId"
---- ----
These simple url-routes doesn't get executed as HystrixCommand nor can you loadbalance multiple url with Ribbon. These simple url-routes doesn't get executed as HystrixCommand nor can you loadbalance multiple url with Ribbon.
To achieve this specify a service-route and configure a Ribbon client for the serviceId, e.g. To achieve this specify a service-route and configure a Ribbon client for the
serviceId (this currently requires disabling Eureka support in Ribbon:
see <<spring-cloud-ribbon-without-eureka,above for more information>>), e.g.
.application.yml .application.yml
[source,yaml] [source,yaml]
---- ----
zuul: zuul:
routes: routes:
users: users:
path: /myusers/** path: /myusers/**
serviceId: users serviceId: users
users: ribbon:
eureka:
enabled: false
users:
ribbon: ribbon:
listOfServers: example.com,google.com listOfServers: example.com,google.com
---- ----
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment