diff --git a/spring-test/src/main/java/org/springframework/test/context/cache/ContextCache.java b/spring-test/src/main/java/org/springframework/test/context/cache/ContextCache.java index e79163336e..1f15c76301 100644 --- a/spring-test/src/main/java/org/springframework/test/context/cache/ContextCache.java +++ b/spring-test/src/main/java/org/springframework/test/context/cache/ContextCache.java @@ -22,13 +22,13 @@ import org.springframework.test.context.MergedContextConfiguration; /** * {@code ContextCache} defines the SPI for caching Spring - * {@link ApplicationContext ApplicationContexts} within the Spring - * TestContext Framework. + * {@link ApplicationContext ApplicationContexts} within the + * Spring TestContext Framework. * *

A {@code ContextCache} maintains a cache of {@code ApplicationContexts} - * keyed by {@link MergedContextConfiguration} instances, potentially - * configured with a {@linkplain ContextCacheUtils#retrieveMaxCacheSize - * maximum size} and a custom eviction policy. + * keyed by {@link MergedContextConfiguration} instances, potentially configured + * with a {@linkplain ContextCacheUtils#retrieveMaxCacheSize maximum size} and + * a custom eviction policy. * *

Rationale

*

Context caching can have significant performance benefits if context @@ -50,25 +50,26 @@ public interface ContextCache { * The name of the logging category used for reporting {@code ContextCache} * statistics. */ - public static final String CONTEXT_CACHE_LOGGING_CATEGORY = "org.springframework.test.context.cache"; + String CONTEXT_CACHE_LOGGING_CATEGORY = "org.springframework.test.context.cache"; /** * The default maximum size of the context cache: {@value #DEFAULT_MAX_CONTEXT_CACHE_SIZE}. + * @since 4.3 * @see #MAX_CONTEXT_CACHE_SIZE_PROPERTY_NAME */ - public static final int DEFAULT_MAX_CONTEXT_CACHE_SIZE = 32; + int DEFAULT_MAX_CONTEXT_CACHE_SIZE = 32; /** * System property used to configure the maximum size of the {@link ContextCache} - * as a positive integer. - *

May alternatively be configured via - * {@link org.springframework.core.SpringProperties SpringProperties}. - *

Note that implementations of {@code ContextCache} are not required - * to support a maximum cache size. Consult the documentation of the + * as a positive integer. May alternatively be configured via the + * {@link org.springframework.core.SpringProperties} mechanism. + *

Note that implementations of {@code ContextCache} are not required to + * actually support a maximum cache size. Consult the documentation of the * corresponding implementation for details. + * @since 4.3 * @see #DEFAULT_MAX_CONTEXT_CACHE_SIZE */ - public static final String MAX_CONTEXT_CACHE_SIZE_PROPERTY_NAME = "spring.test.context.cache.maxSize"; + String MAX_CONTEXT_CACHE_SIZE_PROPERTY_NAME = "spring.test.context.cache.maxSize"; /**