From 83ad91f9900f658ab7c86c438a1d0fc1f0ea7480 Mon Sep 17 00:00:00 2001 From: buildmaster Date: Mon, 25 Nov 2019 19:35:11 +0000 Subject: [PATCH] Sync docs from master to gh-pages --- reference/html/index.html | 62 +++++++++++++++++++----- reference/html/spring-cloud-commons.html | 62 +++++++++++++++++++----- 2 files changed, 98 insertions(+), 26 deletions(-) diff --git a/reference/html/index.html b/reference/html/index.html index 3036a0db..7f9b9bb7 100644 --- a/reference/html/index.html +++ b/reference/html/index.html @@ -157,7 +157,13 @@ $(addBlockSwitches);
  • 3. Spring Cloud LoadBalancer @@ -1346,22 +1352,50 @@ in the following sections:

    3.2. Spring Cloud LoadBalancer Caching

    -

    Apart from the basic ServiceInstanceListSupplier implementation that retrieves instances -via DiscoveryClient each time it has to choose an instance, we provide a Caffeine-backed -implementation. -To make use of it, you need to have com.github.ben-manes.caffeine:caffeine in the classpath. -The default setup includes expireAfterWrite set to 30 seconds and records set to soft references.

    +

    Apart from the basic ServiceInstanceListSupplier implementation that retrieves instances via DiscoveryClient each time it has to choose an instance, we provide two caching implementations.

    +
    +
    +

    3.2.1. Caffeine-backed LoadBalancer Cache Implementation

    +
    +

    If you have com.github.ben-manes.caffeine:caffeine in the classpath, Caffeine-based implementation will be used. +See the LoadBalancerCacheConfiguration section for information on how to configure it.

    -

    You can set your own TTL value (the time after write after which entries should be expired), expressed as Duration, by passing a String compliant with the Spring Boot String to Duration converter syntax. -as the value of spring.cloud.loadbalancer.cache.ttl property.

    -
    -
    -

    You can also override the default Caffeine Cache setup for the LoadBalancer by passing your own Caffeine Specification +

    If you are using Caffeine, you can also override the default Caffeine Cache setup for the LoadBalancer by passing your own Caffeine Specification in the spring.cloud.loadbalancer.cache.caffeine.spec property.

    -

    WARN: Passing your own Caffeine specification will override any other LoadBalancerCache settings, including TTL.

    +

    WARN: Passing your own Caffeine specification will override any other LoadBalancerCache settings, including General LoadBalancer Cache Configuration fields, such as ttl and capacity.

    +
    +
    +
    +

    3.2.2. Default LoadBalancer Cache Implementation

    +
    +

    If you do not have Caffeine in the classpath, the DefaultLoadBalancerCache, which comes automatically with spring-cloud-starter-loadbalancer, will be used. +See the LoadBalancerCacheConfiguration section for information on how to configure it.

    +
    +
    + + + + + +
    + + +To use Caffeine instead of the default cache, add the com.github.ben-manes.caffeine:caffeine dependency to classpath. +
    +
    +
    +
    +

    3.2.3. LoadBalancer Cache Configuration

    +
    +

    You can set your own ttl value (the time after write after which entries should be expired), expressed as Duration, by passing a String compliant with the Spring Boot String to Duration converter syntax. +as the value of the spring.cloud.loadbalancer.cache.ttl property. +You can also set your own LoadBalancer cache initial capacity by setting the value of the spring.cloud.loadbalancer.cache.capacity property.

    +
    +
    +

    The default setup includes ttl set to 30 seconds and the default initialCapacity is 256.

    You can also altogether disable loadBalancer caching by setting the value of spring.cloud.loadbalancer.cache.enabled @@ -1381,6 +1415,7 @@ than the cached versions, so we recommend always using the cached version in pro

    +

    3.3. Spring Cloud LoadBalancer starter

    @@ -1396,7 +1431,8 @@ Cloud dependencies in your build file.

    Spring Cloud LoadBalancer starter includes -Spring Boot Caching. +Spring Boot Caching +and Evictor. diff --git a/reference/html/spring-cloud-commons.html b/reference/html/spring-cloud-commons.html index 3036a0db..7f9b9bb7 100644 --- a/reference/html/spring-cloud-commons.html +++ b/reference/html/spring-cloud-commons.html @@ -157,7 +157,13 @@ $(addBlockSwitches);
  • 3. Spring Cloud LoadBalancer @@ -1346,22 +1352,50 @@ in the following sections:

    3.2. Spring Cloud LoadBalancer Caching

    -

    Apart from the basic ServiceInstanceListSupplier implementation that retrieves instances -via DiscoveryClient each time it has to choose an instance, we provide a Caffeine-backed -implementation. -To make use of it, you need to have com.github.ben-manes.caffeine:caffeine in the classpath. -The default setup includes expireAfterWrite set to 30 seconds and records set to soft references.

    +

    Apart from the basic ServiceInstanceListSupplier implementation that retrieves instances via DiscoveryClient each time it has to choose an instance, we provide two caching implementations.

    +
    +
    +

    3.2.1. Caffeine-backed LoadBalancer Cache Implementation

    +
    +

    If you have com.github.ben-manes.caffeine:caffeine in the classpath, Caffeine-based implementation will be used. +See the LoadBalancerCacheConfiguration section for information on how to configure it.

    -

    You can set your own TTL value (the time after write after which entries should be expired), expressed as Duration, by passing a String compliant with the Spring Boot String to Duration converter syntax. -as the value of spring.cloud.loadbalancer.cache.ttl property.

    -
    -
    -

    You can also override the default Caffeine Cache setup for the LoadBalancer by passing your own Caffeine Specification +

    If you are using Caffeine, you can also override the default Caffeine Cache setup for the LoadBalancer by passing your own Caffeine Specification in the spring.cloud.loadbalancer.cache.caffeine.spec property.

    -

    WARN: Passing your own Caffeine specification will override any other LoadBalancerCache settings, including TTL.

    +

    WARN: Passing your own Caffeine specification will override any other LoadBalancerCache settings, including General LoadBalancer Cache Configuration fields, such as ttl and capacity.

    +
    +
    +
    +

    3.2.2. Default LoadBalancer Cache Implementation

    +
    +

    If you do not have Caffeine in the classpath, the DefaultLoadBalancerCache, which comes automatically with spring-cloud-starter-loadbalancer, will be used. +See the LoadBalancerCacheConfiguration section for information on how to configure it.

    +
    +
    + + + + + +
    + + +To use Caffeine instead of the default cache, add the com.github.ben-manes.caffeine:caffeine dependency to classpath. +
    +
    +
    +
    +

    3.2.3. LoadBalancer Cache Configuration

    +
    +

    You can set your own ttl value (the time after write after which entries should be expired), expressed as Duration, by passing a String compliant with the Spring Boot String to Duration converter syntax. +as the value of the spring.cloud.loadbalancer.cache.ttl property. +You can also set your own LoadBalancer cache initial capacity by setting the value of the spring.cloud.loadbalancer.cache.capacity property.

    +
    +
    +

    The default setup includes ttl set to 30 seconds and the default initialCapacity is 256.

    You can also altogether disable loadBalancer caching by setting the value of spring.cloud.loadbalancer.cache.enabled @@ -1381,6 +1415,7 @@ than the cached versions, so we recommend always using the cached version in pro

    +

    3.3. Spring Cloud LoadBalancer starter

    @@ -1396,7 +1431,8 @@ Cloud dependencies in your build file.

    Spring Cloud LoadBalancer starter includes -Spring Boot Caching. +Spring Boot Caching +and Evictor.