diff --git a/buildSrc/src/main/kotlin/io/spine/internal/dependency/ProtoData.kt b/buildSrc/src/main/kotlin/io/spine/internal/dependency/ProtoData.kt
index ce95ecf6..25367c0c 100644
--- a/buildSrc/src/main/kotlin/io/spine/internal/dependency/ProtoData.kt
+++ b/buildSrc/src/main/kotlin/io/spine/internal/dependency/ProtoData.kt
@@ -29,17 +29,107 @@ package io.spine.internal.dependency
/**
* Dependencies on ProtoData modules.
*
+ * In order to use locally published ProtoData version instead of the version from a public plugin
+ * registry, set the `PROTODATA_VERSION` and/or the `PROTODATA_DF_VERSION` environment variables
+ * and stop the Gradle daemons so that Gradle observes the env change:
+ * ```
+ * export PROTODATA_VERSION=0.43.0-local
+ * export PROTODATA_DF_VERSION=0.41.0
+ *
+ * ./gradle --stop
+ * ./gradle build # Conduct the intended checks.
+ * ```
+ *
+ * Then, in order to reset the console to run the usual versions again, remove the values of
+ * the environment variables and stop the daemon:
+ * ```
+ * export PROTODATA_VERSION=""
+ * export PROTODATA_DF_VERSION=""
+ *
+ * ./gradle --stop
+ * ```
+ *
* See [`SpineEventEngine/ProtoData`](https://github.com/SpineEventEngine/ProtoData/).
*/
-@Suppress("unused", "ConstPropertyName")
+@Suppress(
+ "unused" /* Some subprojects do not use ProtoData directly. */,
+ "ConstPropertyName" /* We use custom convention for artifact properties. */,
+ "MemberVisibilityCanBePrivate" /* The properties are used directly by other subprojects. */,
+ "KDocUnresolvedReference" /* Referencing private properties in constructor KDoc. */
+)
object ProtoData {
- const val version = "0.11.4"
- const val dogfoodingVersion = "0.11.0"
const val group = "io.spine.protodata"
- const val compiler = "$group:protodata-compiler:$version"
+ const val pluginId = "io.spine.protodata"
- const val codegenJava = "io.spine.protodata:protodata-codegen-java:$version"
+ /**
+ * The version of ProtoData dependencies.
+ */
+ val version: String
+ private const val fallbackVersion = "0.12.0"
- const val pluginId = "io.spine.protodata"
- const val pluginLib = "${Spine.group}:protodata:$version"
+ /**
+ * The distinct version of ProtoData used by other build tools.
+ *
+ * When ProtoData is used both for building the project and as a part of the Project's
+ * transitional dependencies, this is the version used to build the project itself.
+ */
+ val dogfoodingVersion: String
+ private const val fallbackDfVersion = "0.9.11"
+
+ /**
+ * The artifact for the ProtoData Gradle plugin.
+ */
+ val pluginLib: String
+
+ val api
+ get() = "$group:protodata-api:$version"
+ val compiler
+ get() = "$group:protodata-compiler:$version"
+ val codegenJava
+ get() = "$group:protodata-codegen-java:$version"
+
+ /**
+ * An env variable storing a custom [version].
+ */
+ private const val VERSION_ENV = "PROTODATA_VERSION"
+
+ /**
+ * An env variable storing a custom [dogfoodingVersion].
+ */
+ private const val DF_VERSION_ENV = "PROTODATA_DF_VERSION"
+
+ /**
+ * Sets up the versions and artifacts for the build to use.
+ *
+ * If either [VERSION_ENV] or [DF_VERSION_ENV] is set, those versions are used instead of
+ * the hardcoded ones. Also, in this mode, the [pluginLib] coordinates are changed so that
+ * it points at a locally published artifact. Otherwise, it points at an artifact that would be
+ * published to a public plugin registry.
+ */
+ init {
+ val experimentVersion = System.getenv(VERSION_ENV)
+ val experimentDfVersion = System.getenv(DF_VERSION_ENV)
+ if (experimentVersion?.isNotBlank() == true || experimentDfVersion?.isNotBlank() == true) {
+ version = experimentVersion ?: fallbackVersion
+ dogfoodingVersion = experimentDfVersion ?: fallbackDfVersion
+
+ pluginLib = "${group}:gradle-plugin:$version"
+ println("""
+
+ ❗ Running an experiment with ProtoData. ❗
+ -----------------------------------------
+ Regular version = v$version
+ Dogfooding version = v$dogfoodingVersion
+
+ ProtoData Gradle plugin can now be loaded from Maven Local.
+
+ To reset the versions, erase the `$$VERSION_ENV` and `$$DF_VERSION_ENV` environment variables.
+
+ """.trimIndent())
+ } else {
+ version = fallbackVersion
+ dogfoodingVersion = fallbackDfVersion
+ pluginLib = "${Spine.group}:protodata:$version"
+ }
+ }
}
diff --git a/buildSrc/src/main/kotlin/io/spine/internal/dependency/Roaster.kt b/buildSrc/src/main/kotlin/io/spine/internal/dependency/Roaster.kt
index c18d9b92..af524da3 100644
--- a/buildSrc/src/main/kotlin/io/spine/internal/dependency/Roaster.kt
+++ b/buildSrc/src/main/kotlin/io/spine/internal/dependency/Roaster.kt
@@ -30,6 +30,13 @@ package io.spine.internal.dependency
@Suppress("unused", "ConstPropertyName")
object Roaster {
+ /**
+ * This is the last version build with Java 11.
+ *
+ * Starting from version
+ * [2.29.0.Final](https://github.com/forge/roaster/releases/tag/2.29.0.Final),
+ * Roaster requires Java 17.
+ */
private const val version = "2.28.0.Final"
const val api = "org.jboss.forge.roaster:roaster-api:${version}"
diff --git a/buildSrc/src/main/kotlin/io/spine/internal/dependency/Spine.kt b/buildSrc/src/main/kotlin/io/spine/internal/dependency/Spine.kt
index b5332cdd..e935bf41 100644
--- a/buildSrc/src/main/kotlin/io/spine/internal/dependency/Spine.kt
+++ b/buildSrc/src/main/kotlin/io/spine/internal/dependency/Spine.kt
@@ -59,7 +59,7 @@ object Spine {
*
* @see spine-logging
*/
- const val logging = "2.0.0-SNAPSHOT.210"
+ const val logging = "2.0.0-SNAPSHOT.226"
/**
* The version of [Spine.testlib].
@@ -75,7 +75,7 @@ object Spine {
* @see [Spine.CoreJava.server]
* @see core-java
*/
- const val core = "2.0.0-SNAPSHOT.157"
+ const val core = "2.0.0-SNAPSHOT.159"
/**
* The version of [Spine.modelCompiler].
@@ -89,7 +89,7 @@ object Spine {
*
* @see spine-mc-java
*/
- const val mcJava = "2.0.0-SNAPSHOT.169"
+ const val mcJava = "2.0.0-SNAPSHOT.170"
/**
* The version of [Spine.baseTypes].
@@ -103,7 +103,7 @@ object Spine {
*
* @see spine-time
*/
- const val time = "2.0.0-SNAPSHOT.133"
+ const val time = "2.0.0-SNAPSHOT.134"
/**
* The version of [Spine.change].
@@ -124,7 +124,7 @@ object Spine {
*
* @see spine-tool-base
*/
- const val toolBase = "2.0.0-SNAPSHOT.183"
+ const val toolBase = "2.0.0-SNAPSHOT.186"
/**
* The version of [Spine.javadocTools].
@@ -165,8 +165,20 @@ object Spine {
const val version = ArtifactVersion.logging
const val lib = "$group:spine-logging:$version"
const val backend = "$group:spine-logging-backend:$version"
+ const val log4j2Backend = "$group:spine-logging-log4j2-backend:$version"
const val context = "$group:spine-logging-context:$version"
+ const val grpcContext = "$group:spine-logging-grpc-context:$version"
+
+ @Deprecated(
+ message = "Please use `Logging.lib` instead.",
+ replaceWith = ReplaceWith("lib")
+ )
const val floggerApi = "$group:spine-flogger-api:$version"
+
+ @Deprecated(
+ message = "Please use `grpcContext` instead.",
+ replaceWith = ReplaceWith("grpcContext")
+ )
const val floggerGrpcContext = "$group:spine-flogger-grpc-context:$version"
const val smokeTest = "$group:spine-logging-smoke-test:$version"
}
diff --git a/buildSrc/src/main/kotlin/io/spine/internal/dependency/Validation.kt b/buildSrc/src/main/kotlin/io/spine/internal/dependency/Validation.kt
index 3da83fe7..a4a45be3 100644
--- a/buildSrc/src/main/kotlin/io/spine/internal/dependency/Validation.kt
+++ b/buildSrc/src/main/kotlin/io/spine/internal/dependency/Validation.kt
@@ -33,7 +33,7 @@ package io.spine.internal.dependency
*/
@Suppress("unused", "ConstPropertyName")
object Validation {
- const val version = "2.0.0-SNAPSHOT.103"
+ const val version = "2.0.0-SNAPSHOT.104"
const val group = "io.spine.validation"
const val runtime = "$group:spine-validation-java-runtime:$version"
const val java = "$group:spine-validation-java:$version"
diff --git a/config b/config
index d4f23221..f43d55f8 160000
--- a/config
+++ b/config
@@ -1 +1 @@
-Subproject commit d4f232214236e9bca746ab2984ce6e46c5d79600
+Subproject commit f43d55f8f031e5a3ccede3c7bc0c17b59599774d
diff --git a/gradle/wrapper/gradle-wrapper.jar b/gradle/wrapper/gradle-wrapper.jar
index 943f0cbf..afba1092 100644
Binary files a/gradle/wrapper/gradle-wrapper.jar and b/gradle/wrapper/gradle-wrapper.jar differ
diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties
index 4e86b927..b1624c47 100644
--- a/gradle/wrapper/gradle-wrapper.properties
+++ b/gradle/wrapper/gradle-wrapper.properties
@@ -1,6 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
-distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.2-bin.zip
+distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.3-bin.zip
networkTimeout=10000
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists