Create spring-boot-data-r2dbc module
This commit is contained in:
committed by
Phillip Webb
parent
cacaeacbe9
commit
de2827e23f
@@ -60,6 +60,7 @@ include "spring-boot-project:spring-boot-data-jpa"
|
||||
include "spring-boot-project:spring-boot-data-ldap"
|
||||
include "spring-boot-project:spring-boot-data-mongodb"
|
||||
include "spring-boot-project:spring-boot-data-neo4j"
|
||||
include "spring-boot-project:spring-boot-data-r2dbc"
|
||||
include "spring-boot-project:spring-boot-data-redis"
|
||||
include "spring-boot-project:spring-boot-dependencies"
|
||||
include "spring-boot-project:spring-boot-devtools"
|
||||
|
||||
@@ -19,12 +19,6 @@
|
||||
"description": "Whether to enable the PersistenceExceptionTranslationPostProcessor.",
|
||||
"defaultValue": true
|
||||
},
|
||||
{
|
||||
"name": "spring.data.r2dbc.repositories.enabled",
|
||||
"type": "java.lang.Boolean",
|
||||
"description": "Whether to enable R2DBC repositories.",
|
||||
"defaultValue": true
|
||||
},
|
||||
{
|
||||
"name": "spring.graphql.schema.file-extensions",
|
||||
"defaultValue": ".graphqls,.gqls"
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
org.springframework.boot.autoconfigure.aop.AopAutoConfiguration
|
||||
org.springframework.boot.autoconfigure.cache.CacheAutoConfiguration
|
||||
org.springframework.boot.autoconfigure.dao.PersistenceExceptionTranslationAutoConfiguration
|
||||
org.springframework.boot.autoconfigure.data.r2dbc.R2dbcDataAutoConfiguration
|
||||
org.springframework.boot.autoconfigure.data.r2dbc.R2dbcRepositoriesAutoConfiguration
|
||||
org.springframework.boot.autoconfigure.data.rest.RepositoryRestMvcAutoConfiguration
|
||||
org.springframework.boot.autoconfigure.data.web.SpringDataWebAutoConfiguration
|
||||
org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration
|
||||
|
||||
26
spring-boot-project/spring-boot-data-r2dbc/build.gradle
Normal file
26
spring-boot-project/spring-boot-data-r2dbc/build.gradle
Normal file
@@ -0,0 +1,26 @@
|
||||
plugins {
|
||||
id "java-library"
|
||||
id "org.springframework.boot.auto-configuration"
|
||||
id "org.springframework.boot.configuration-properties"
|
||||
id "org.springframework.boot.deployed"
|
||||
id "org.springframework.boot.optional-dependencies"
|
||||
}
|
||||
|
||||
description = "Spring Boot Data R2DBC"
|
||||
|
||||
dependencies {
|
||||
api(project(":spring-boot-project:spring-boot-r2dbc"))
|
||||
api("io.r2dbc:r2dbc-spi")
|
||||
api("io.r2dbc:r2dbc-pool")
|
||||
api("org.springframework.data:spring-data-r2dbc")
|
||||
|
||||
optional(project(":spring-boot-project:spring-boot-autoconfigure"))
|
||||
|
||||
testImplementation(project(":spring-boot-project:spring-boot-test"))
|
||||
testImplementation(project(":spring-boot-project:spring-boot-tools:spring-boot-test-support"))
|
||||
testImplementation(testFixtures(project(":spring-boot-project:spring-boot-autoconfigure")))
|
||||
testImplementation("io.projectreactor:reactor-test")
|
||||
testImplementation("io.r2dbc:r2dbc-h2")
|
||||
|
||||
testRuntimeOnly("ch.qos.logback:logback-classic")
|
||||
}
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package org.springframework.boot.autoconfigure.data.r2dbc;
|
||||
package org.springframework.boot.data.r2dbc.autoconfigure;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
@@ -49,7 +49,7 @@ import org.springframework.r2dbc.core.DatabaseClient;
|
||||
*
|
||||
* @author Mark Paluch
|
||||
* @author Oliver Drotbohm
|
||||
* @since 2.3.0
|
||||
* @since 4.0.0
|
||||
*/
|
||||
@AutoConfiguration(after = R2dbcAutoConfiguration.class)
|
||||
@ConditionalOnClass({ DatabaseClient.class, R2dbcEntityTemplate.class })
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package org.springframework.boot.autoconfigure.data.r2dbc;
|
||||
package org.springframework.boot.data.r2dbc.autoconfigure;
|
||||
|
||||
import io.r2dbc.spi.ConnectionFactory;
|
||||
|
||||
@@ -34,7 +34,7 @@ import org.springframework.r2dbc.core.DatabaseClient;
|
||||
* {@link EnableAutoConfiguration Auto-configuration} for Spring Data R2DBC Repositories.
|
||||
*
|
||||
* @author Mark Paluch
|
||||
* @since 2.3.0
|
||||
* @since 4.0.0
|
||||
* @see EnableR2dbcRepositories
|
||||
*/
|
||||
@AutoConfiguration(after = R2dbcDataAutoConfiguration.class)
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2024 the original author or authors.
|
||||
* Copyright 2012-2025 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package org.springframework.boot.autoconfigure.data.r2dbc;
|
||||
package org.springframework.boot.data.r2dbc.autoconfigure;
|
||||
|
||||
import java.lang.annotation.Annotation;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2020 the original author or authors.
|
||||
* Copyright 2012-2025 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -17,4 +17,4 @@
|
||||
/**
|
||||
* Auto-Configuration for Spring Data R2DBC.
|
||||
*/
|
||||
package org.springframework.boot.autoconfigure.data.r2dbc;
|
||||
package org.springframework.boot.data.r2dbc.autoconfigure;
|
||||
@@ -0,0 +1,11 @@
|
||||
{
|
||||
"groups": [],
|
||||
"properties": [
|
||||
{
|
||||
"name": "spring.data.r2dbc.repositories.enabled",
|
||||
"type": "java.lang.Boolean",
|
||||
"description": "Whether to enable R2DBC repositories.",
|
||||
"defaultValue": true
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
org.springframework.boot.data.r2dbc.autoconfigure.R2dbcDataAutoConfiguration
|
||||
org.springframework.boot.data.r2dbc.autoconfigure.R2dbcRepositoriesAutoConfiguration
|
||||
@@ -14,13 +14,13 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package org.springframework.boot.autoconfigure.data.r2dbc;
|
||||
package org.springframework.boot.data.r2dbc.autoconfigure;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import org.springframework.boot.autoconfigure.AutoConfigurations;
|
||||
import org.springframework.boot.autoconfigure.TestAutoConfigurationPackage;
|
||||
import org.springframework.boot.autoconfigure.data.r2dbc.city.City;
|
||||
import org.springframework.boot.data.r2dbc.domain.city.City;
|
||||
import org.springframework.boot.r2dbc.autoconfigure.R2dbcAutoConfiguration;
|
||||
import org.springframework.boot.test.context.runner.ApplicationContextRunner;
|
||||
import org.springframework.data.domain.ManagedTypes;
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package org.springframework.boot.autoconfigure.data.r2dbc;
|
||||
package org.springframework.boot.data.r2dbc.autoconfigure;
|
||||
|
||||
import java.time.Duration;
|
||||
|
||||
@@ -25,9 +25,9 @@ import reactor.test.StepVerifier;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.boot.autoconfigure.AutoConfigurations;
|
||||
import org.springframework.boot.autoconfigure.TestAutoConfigurationPackage;
|
||||
import org.springframework.boot.autoconfigure.data.empty.EmptyDataPackage;
|
||||
import org.springframework.boot.autoconfigure.data.r2dbc.city.City;
|
||||
import org.springframework.boot.autoconfigure.data.r2dbc.city.CityRepository;
|
||||
import org.springframework.boot.data.r2dbc.domain.city.City;
|
||||
import org.springframework.boot.data.r2dbc.domain.city.CityRepository;
|
||||
import org.springframework.boot.data.r2dbc.domain.empty.EmptyDataPackage;
|
||||
import org.springframework.boot.r2dbc.autoconfigure.R2dbcAutoConfiguration;
|
||||
import org.springframework.boot.test.context.FilteredClassLoader;
|
||||
import org.springframework.boot.test.context.runner.ApplicationContextRunner;
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2020 the original author or authors.
|
||||
* Copyright 2012-2025 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package org.springframework.boot.autoconfigure.data.r2dbc.city;
|
||||
package org.springframework.boot.data.r2dbc.domain.city;
|
||||
|
||||
import org.springframework.data.annotation.Id;
|
||||
import org.springframework.data.relational.core.mapping.Table;
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2020 the original author or authors.
|
||||
* Copyright 2012-2025 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package org.springframework.boot.autoconfigure.data.r2dbc.city;
|
||||
package org.springframework.boot.data.r2dbc.domain.city;
|
||||
|
||||
import org.springframework.data.repository.reactive.ReactiveCrudRepository;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2019 the original author or authors.
|
||||
* Copyright 2012-2025 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -14,13 +14,8 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package org.springframework.boot.autoconfigure.data.empty;
|
||||
package org.springframework.boot.data.r2dbc.domain.empty;
|
||||
|
||||
/**
|
||||
* Empty package used with data tests.
|
||||
*
|
||||
* @author Phillip Webb
|
||||
*/
|
||||
public class EmptyDataPackage {
|
||||
|
||||
}
|
||||
@@ -1995,6 +1995,7 @@ bom {
|
||||
"spring-boot-data-ldap",
|
||||
"spring-boot-data-mongodb",
|
||||
"spring-boot-data-neo4j",
|
||||
"spring-boot-data-r2dbc",
|
||||
"spring-boot-data-redis",
|
||||
"spring-boot-devtools",
|
||||
"spring-boot-docker-compose",
|
||||
|
||||
@@ -76,6 +76,7 @@ dependencies {
|
||||
autoConfiguration(project(path: ":spring-boot-project:spring-boot-data-ldap", configuration: "autoConfigurationMetadata"))
|
||||
autoConfiguration(project(path: ":spring-boot-project:spring-boot-data-mongodb", configuration: "autoConfigurationMetadata"))
|
||||
autoConfiguration(project(path: ":spring-boot-project:spring-boot-data-neo4j", configuration: "autoConfigurationMetadata"))
|
||||
autoConfiguration(project(path: ":spring-boot-project:spring-boot-data-r2dbc", configuration: "autoConfigurationMetadata"))
|
||||
autoConfiguration(project(path: ":spring-boot-project:spring-boot-data-redis", configuration: "autoConfigurationMetadata"))
|
||||
autoConfiguration(project(path: ":spring-boot-project:spring-boot-devtools", configuration: "autoConfigurationMetadata"))
|
||||
autoConfiguration(project(path: ":spring-boot-project:spring-boot-elasticsearch", configuration: "autoConfigurationMetadata"))
|
||||
@@ -135,6 +136,7 @@ dependencies {
|
||||
configurationProperties(project(path: ":spring-boot-project:spring-boot-data-jpa", configuration: "configurationPropertiesMetadata"))
|
||||
configurationProperties(project(path: ":spring-boot-project:spring-boot-data-ldap", configuration: "configurationPropertiesMetadata"))
|
||||
configurationProperties(project(path: ":spring-boot-project:spring-boot-data-neo4j", configuration: "configurationPropertiesMetadata"))
|
||||
configurationProperties(project(path: ":spring-boot-project:spring-boot-data-r2dbc", configuration: "configurationPropertiesMetadata"))
|
||||
configurationProperties(project(path: ":spring-boot-project:spring-boot-data-redis", configuration: "configurationPropertiesMetadata"))
|
||||
configurationProperties(project(path: ":spring-boot-project:spring-boot-devtools", configuration: "configurationPropertiesMetadata"))
|
||||
configurationProperties(project(path: ":spring-boot-project:spring-boot-docker-compose", configuration: "configurationPropertiesMetadata"))
|
||||
|
||||
@@ -6,9 +6,6 @@ description = "Starter for using Spring Data R2DBC"
|
||||
|
||||
dependencies {
|
||||
api(project(":spring-boot-project:spring-boot-starters:spring-boot-starter"))
|
||||
api(project(":spring-boot-project:spring-boot-r2dbc"))
|
||||
api(project(":spring-boot-project:spring-boot-data-r2dbc"))
|
||||
api(project(":spring-boot-project:spring-boot-tx"))
|
||||
api("org.springframework.data:spring-data-r2dbc")
|
||||
api("io.r2dbc:r2dbc-spi")
|
||||
api("io.r2dbc:r2dbc-pool")
|
||||
}
|
||||
|
||||
@@ -44,6 +44,7 @@ dependencies {
|
||||
optional(project(":spring-boot-project:spring-boot-data-ldap"))
|
||||
optional(project(":spring-boot-project:spring-boot-data-mongodb"))
|
||||
optional(project(":spring-boot-project:spring-boot-data-neo4j"))
|
||||
optional(project(":spring-boot-project:spring-boot-data-r2dbc"))
|
||||
optional(project(":spring-boot-project:spring-boot-data-redis"))
|
||||
optional(project(":spring-boot-project:spring-boot-flyway"))
|
||||
optional(project(":spring-boot-project:spring-boot-groovy-templates"))
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# AutoConfigureDataR2dbc auto-configuration imports
|
||||
org.springframework.boot.autoconfigure.data.r2dbc.R2dbcRepositoriesAutoConfiguration
|
||||
org.springframework.boot.autoconfigure.data.r2dbc.R2dbcDataAutoConfiguration
|
||||
org.springframework.boot.data.r2dbc.autoconfigure.R2dbcRepositoriesAutoConfiguration
|
||||
org.springframework.boot.data.r2dbc.autoconfigure.R2dbcDataAutoConfiguration
|
||||
org.springframework.boot.r2dbc.autoconfigure.R2dbcAutoConfiguration
|
||||
org.springframework.boot.r2dbc.autoconfigure.R2dbcInitializationAutoConfiguration
|
||||
org.springframework.boot.r2dbc.autoconfigure.R2dbcTransactionManagerAutoConfiguration
|
||||
|
||||
Reference in New Issue
Block a user