Skip to content

Commit 93b53fc

Browse files
committed
Create spring-boot-cache module
1 parent 6f10fdf commit 93b53fc

File tree

62 files changed

+187
-119
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

62 files changed

+187
-119
lines changed

settings.gradle

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ include "spring-boot-project:spring-boot-artemis"
5050
include "spring-boot-project:spring-boot-autoconfigure"
5151
include "spring-boot-project:spring-boot-autoconfigure-all"
5252
include "spring-boot-project:spring-boot-batch"
53+
include "spring-boot-project:spring-boot-cache"
5354
include "spring-boot-project:spring-boot-cassandra"
5455
include "spring-boot-project:spring-boot-couchbase"
5556
include "spring-boot-project:spring-boot-data-cassandra"

spring-boot-project/spring-boot-actuator-autoconfigure/build.gradle

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ dependencies {
2020
optional(project(":spring-boot-project:spring-boot-activemq"))
2121
optional(project(":spring-boot-project:spring-boot-amqp"))
2222
optional(project(":spring-boot-project:spring-boot-artemis"))
23+
optional(project(":spring-boot-project:spring-boot-cache"))
2324
optional(project(":spring-boot-project:spring-boot-couchbase"))
2425
optional(project(":spring-boot-project:spring-boot-data-cassandra"))
2526
optional(project(":spring-boot-project:spring-boot-data-elasticsearch"))

spring-boot-project/spring-boot-actuator-autoconfigure/src/main/java/org/springframework/boot/actuate/autoconfigure/cache/CachesEndpointAutoConfiguration.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@
2424
import org.springframework.boot.actuate.cache.CachesEndpointWebExtension;
2525
import org.springframework.boot.autoconfigure.AutoConfiguration;
2626
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
27-
import org.springframework.boot.autoconfigure.cache.CacheAutoConfiguration;
2827
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
2928
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
3029
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
@@ -38,7 +37,7 @@
3837
* @author Stephane Nicoll
3938
* @since 2.1.0
4039
*/
41-
@AutoConfiguration(after = CacheAutoConfiguration.class)
40+
@AutoConfiguration(afterName = "org.springframework.boot.cache.autoconfigure.CacheAutoConfiguration")
4241
@ConditionalOnClass(CacheManager.class)
4342
@ConditionalOnAvailableEndpoint(CachesEndpoint.class)
4443
public class CachesEndpointAutoConfiguration {

spring-boot-project/spring-boot-actuator-autoconfigure/src/main/java/org/springframework/boot/actuate/autoconfigure/metrics/cache/CacheMetricsAutoConfiguration.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2012-2022 the original author or authors.
2+
* Copyright 2012-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -19,7 +19,6 @@
1919
import org.springframework.boot.actuate.autoconfigure.metrics.MetricsAutoConfiguration;
2020
import org.springframework.boot.autoconfigure.AutoConfiguration;
2121
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
22-
import org.springframework.boot.autoconfigure.cache.CacheAutoConfiguration;
2322
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
2423
import org.springframework.cache.Cache;
2524
import org.springframework.cache.CacheManager;
@@ -32,7 +31,8 @@
3231
* @author Stephane Nicoll
3332
* @since 2.0.0
3433
*/
35-
@AutoConfiguration(after = { MetricsAutoConfiguration.class, CacheAutoConfiguration.class })
34+
@AutoConfiguration(after = MetricsAutoConfiguration.class,
35+
afterName = "org.springframework.boot.cache.autoconfigure.CacheAutoConfiguration")
3636
@ConditionalOnBean(CacheManager.class)
3737
@Import({ CacheMeterBinderProvidersConfiguration.class, CacheMetricsRegistrarConfiguration.class })
3838
public class CacheMetricsAutoConfiguration {

spring-boot-project/spring-boot-actuator-autoconfigure/src/test/java/org/springframework/boot/actuate/autoconfigure/metrics/cache/CacheMetricsAutoConfigurationTests.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525

2626
import org.springframework.boot.actuate.autoconfigure.metrics.test.MetricsRun;
2727
import org.springframework.boot.autoconfigure.AutoConfigurations;
28-
import org.springframework.boot.autoconfigure.cache.CacheAutoConfiguration;
28+
import org.springframework.boot.cache.autoconfigure.CacheAutoConfiguration;
2929
import org.springframework.boot.test.context.runner.ApplicationContextRunner;
3030
import org.springframework.cache.CacheManager;
3131
import org.springframework.cache.annotation.CachingConfigurer;

spring-boot-project/spring-boot-actuator/build.gradle

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ dependencies {
1212
api(project(":spring-boot-project:spring-boot-all"))
1313

1414
dockerTestImplementation(project(":spring-boot-project:spring-boot-autoconfigure-all"))
15+
dockerTestImplementation(project(":spring-boot-project:spring-boot-cache"))
1516
dockerTestImplementation(project(":spring-boot-project:spring-boot-neo4j"))
1617
dockerTestImplementation(project(":spring-boot-project:spring-boot-test"))
1718
dockerTestImplementation(project(":spring-boot-project:spring-boot-tools:spring-boot-test-support-docker"))

spring-boot-project/spring-boot-actuator/src/dockerTest/java/org/springframework/boot/actuate/metrics/cache/RedisCacheMetricsTests.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
import org.testcontainers.junit.jupiter.Testcontainers;
2929

3030
import org.springframework.boot.autoconfigure.AutoConfigurations;
31-
import org.springframework.boot.autoconfigure.cache.CacheAutoConfiguration;
31+
import org.springframework.boot.cache.autoconfigure.CacheAutoConfiguration;
3232
import org.springframework.boot.data.redis.autoconfigure.RedisAutoConfiguration;
3333
import org.springframework.boot.test.context.assertj.AssertableApplicationContext;
3434
import org.springframework.boot.test.context.runner.ApplicationContextRunner;

spring-boot-project/spring-boot-autoconfigure-all/build.gradle

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -33,14 +33,12 @@ dependencies {
3333
dockerTestImplementation("org.junit.jupiter:junit-jupiter")
3434
dockerTestImplementation("org.mockito:mockito-core")
3535
dockerTestImplementation("org.springframework:spring-test")
36-
dockerTestImplementation("org.testcontainers:couchbase")
3736
dockerTestImplementation("org.testcontainers:junit-jupiter")
3837
dockerTestImplementation("org.testcontainers:mongodb")
3938
dockerTestImplementation("org.testcontainers:testcontainers")
4039

4140
optional(project(":spring-boot-project:spring-boot-activemq"))
4241
optional(project(":spring-boot-project:spring-boot-artemis"))
43-
optional(project(":spring-boot-project:spring-boot-data-couchbase"))
4442
optional(project(":spring-boot-project:spring-boot-data-jpa"))
4543
optional(project(":spring-boot-project:spring-boot-data-mongodb"))
4644
optional(project(":spring-boot-project:spring-boot-data-redis"))
@@ -67,7 +65,6 @@ dependencies {
6765
optional("com.fasterxml.jackson.datatype:jackson-datatype-jsr310")
6866
optional("com.fasterxml.jackson.module:jackson-module-jakarta-xmlbind-annotations")
6967
optional("com.fasterxml.jackson.module:jackson-module-parameter-names")
70-
optional("com.hazelcast:hazelcast-spring")
7168
optional("com.nimbusds:oauth2-oidc-sdk")
7269
optional("com.oracle.database.jdbc:ojdbc11")
7370
optional("com.oracle.database.jdbc:ucp11")
@@ -102,19 +99,12 @@ dependencies {
10299
optional("org.apache.tomcat:tomcat-jdbc")
103100
optional("org.apiguardian:apiguardian-api")
104101
optional("org.eclipse.angus:angus-mail")
105-
optional("com.github.ben-manes.caffeine:caffeine")
106102
optional("com.zaxxer:HikariCP")
107103
optional("org.aspectj:aspectjweaver")
108-
optional("org.cache2k:cache2k-spring")
109104
optional("org.eclipse.jetty.ee10:jetty-ee10-webapp")
110105
optional("org.eclipse.jetty:jetty-reactive-httpclient")
111106
optional("org.eclipse.jetty.ee10.websocket:jetty-ee10-websocket-jakarta-server")
112107
optional("org.eclipse.jetty.ee10.websocket:jetty-ee10-websocket-jetty-server")
113-
optional("org.ehcache:ehcache") {
114-
artifact {
115-
classifier = 'jakarta'
116-
}
117-
}
118108
optional("org.glassfish.jersey.containers:jersey-container-servlet-core")
119109
optional("org.glassfish.jersey.containers:jersey-container-servlet")
120110
optional("org.glassfish.jersey.core:jersey-server")
@@ -123,11 +113,6 @@ dependencies {
123113
optional("org.hibernate.orm:hibernate-core")
124114
optional("org.hibernate.orm:hibernate-jcache")
125115
optional("org.hibernate.validator:hibernate-validator")
126-
optional("org.infinispan:infinispan-commons")
127-
optional("org.infinispan:infinispan-component-annotations")
128-
optional("org.infinispan:infinispan-core")
129-
optional("org.infinispan:infinispan-jcache")
130-
optional("org.infinispan:infinispan-spring6-embedded")
131116
optional("org.influxdb:influxdb-java")
132117
optional("org.jooq:jooq") {
133118
exclude group: "javax.xml.bind", module: "jaxb-api"
@@ -152,7 +137,6 @@ dependencies {
152137
optional("org.springframework:spring-websocket")
153138
optional("org.springframework:spring-webflux")
154139
optional("org.springframework:spring-webmvc")
155-
optional("org.springframework.data:spring-data-couchbase")
156140
optional("org.springframework.data:spring-data-envers") {
157141
exclude group: "javax.activation", module: "javax.activation-api"
158142
exclude group: "javax.persistence", module: "javax.persistence-api"

spring-boot-project/spring-boot-autoconfigure-all/src/main/resources/META-INF/additional-spring-configuration-metadata.json

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -504,17 +504,6 @@
504504
}
505505
],
506506
"hints": [
507-
{
508-
"name": "spring.cache.jcache.provider",
509-
"providers": [
510-
{
511-
"name": "class-reference",
512-
"parameters": {
513-
"target": "javax.cache.spi.CachingProvider"
514-
}
515-
}
516-
]
517-
},
518507
{
519508
"name": "spring.graphql.cors.allowed-headers",
520509
"values": [

spring-boot-project/spring-boot-autoconfigure-all/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
org.springframework.boot.autoconfigure.aop.AopAutoConfiguration
2-
org.springframework.boot.autoconfigure.cache.CacheAutoConfiguration
32
org.springframework.boot.autoconfigure.dao.PersistenceExceptionTranslationAutoConfiguration
43
org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration
54
org.springframework.boot.autoconfigure.graphql.data.GraphQlReactiveQueryByExampleAutoConfiguration

0 commit comments

Comments
 (0)