This is an automated email from the ASF dual-hosted git repository.

jooger pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/ignite-3.git


The following commit(s) were added to refs/heads/main by this push:
     new 128fcc89c5f IGNITE-26204 Add step to create configuration snapshot to 
release procedure (#6425)
128fcc89c5f is described below

commit 128fcc89c5fc0cfd8566bba5092fd98d116c4401
Author: ygerzhedovich <[email protected]>
AuthorDate: Fri Aug 22 14:01:21 2025 +0300

    IGNITE-26204 Add step to create configuration snapshot to release procedure 
(#6425)
    
    Co-authored-by: Iurii Gerzhedovich <[email protected]>
---
 RELEASE.md                                              | 11 ++++++++++-
 modules/runner/build.gradle                             | 17 +++++++++++++++++
 .../compatibility/GenerateConfigurationSnapshot.java    |  9 ++++++++-
 3 files changed, 35 insertions(+), 2 deletions(-)

diff --git a/RELEASE.md b/RELEASE.md
index af2eca46015..d4a200028ef 100644
--- a/RELEASE.md
+++ b/RELEASE.md
@@ -112,4 +112,13 @@ Perform the following actions ONLY after the vote is 
successful and closed.
    * Get API key from 
https://svn.apache.org/repos/private/pmc/ignite/credentials/nuget.org (PMC only)
    * `for i in *.nupkg; do dotnet nuget push $i -k API_KEY_HERE -s 
"https://nuget.org/";; done`
 9. Publish Python packages (TODO 
[IGNITE-24327](https://issues.apache.org/jira/browse/IGNITE-24327))
-10. Update https://ignite.apache.org/download.cgi page - see 
https://cwiki.apache.org/confluence/display/IGNITE/Website+Development
\ No newline at end of file
+10. Update https://ignite.apache.org/download.cgi page - see 
https://cwiki.apache.org/confluence/display/IGNITE/Website+Development
+
+## Post Release steps
+
+1. Add compatibility snapshot for released version:
+
+   * On release git branch need to generate a new snapshot with compatibility 
information `./gradlew :ignite-runner:generateCompatibilitySnapshot`
+   * Switch git to main branch
+   * Run compatibility test `./gradlew :ignite-runner:test --tests 
"org.apache.ignite.internal.configuration.compatibility.ConfigurationCompatibilityTest"`
+   * Add generated compatibility snapshot to git. Commit the file under 
separate JIRA ticket with commit message `{jira_ticket} Add configuration 
snapshot for Ignite {version}`. Push the change to main branch.
diff --git a/modules/runner/build.gradle b/modules/runner/build.gradle
index d5101dc3b45..e27829a3bed 100644
--- a/modules/runner/build.gradle
+++ b/modules/runner/build.gradle
@@ -233,6 +233,23 @@ dependencies {
     testFixturesImplementation libs.typesafe.config
 }
 
+tasks.register('generateCompatibilitySnapshot', JavaExec) {
+    def testResourcePath = 
sourceSets.test.resources.srcDirs.iterator().next().absolutePath
+    def snapshotFilePath = java.nio.file.Path.of(testResourcePath, 
"compatibility/configuration", "ignite-${projectVersion}.bin").toString()
+
+    description = 'Generates compatibility snapshot for the project.'
+    classpath = sourceSets.test.runtimeClasspath
+    mainClass = 
'org.apache.ignite.internal.configuration.compatibility.GenerateConfigurationSnapshot'
+    args = [snapshotFilePath]
+    jvmArgs += defaultJvmArgs
+
+    doFirst {
+        if (version.toString().endsWith('-SNAPSHOT')) {
+            throw new GradleException("The task can be executed only on 
release version: ${version}")
+        }
+    }
+}
+
 tasks.register('runnerPlatformTest', JavaExec) {
     dependsOn tasks.integrationTestClasses
     mainClass = 'org.apache.ignite.internal.runner.app.PlatformTestNodeRunner'
diff --git 
a/modules/runner/src/test/java/org/apache/ignite/internal/configuration/compatibility/GenerateConfigurationSnapshot.java
 
b/modules/runner/src/test/java/org/apache/ignite/internal/configuration/compatibility/GenerateConfigurationSnapshot.java
index b31fcecc17c..d34da2af97b 100644
--- 
a/modules/runner/src/test/java/org/apache/ignite/internal/configuration/compatibility/GenerateConfigurationSnapshot.java
+++ 
b/modules/runner/src/test/java/org/apache/ignite/internal/configuration/compatibility/GenerateConfigurationSnapshot.java
@@ -22,6 +22,7 @@ import static 
org.apache.ignite.internal.configuration.compatibility.Configurati
 
 import java.io.IOException;
 import java.nio.file.Path;
+import java.util.Arrays;
 import java.util.List;
 import 
org.apache.ignite.internal.configuration.compatibility.framework.ConfigNode;
 import 
org.apache.ignite.internal.configuration.compatibility.framework.ConfigShuttle;
@@ -41,13 +42,19 @@ public class GenerateConfigurationSnapshot {
      * Generates a snapshot of the current configuration metadata and saves it 
to a file.
      */
     public static void main(String[] args) throws IOException {
+        LOG.info("Passed arguments are ", Arrays.toString(args));
         List<ConfigNode> configNodes = loadCurrentConfiguration();
 
         ConfigShuttle shuttle = node -> LOG.info(node.toString());
         LOG.info("DUMP TREE:");
         configNodes.forEach(c -> c.accept(shuttle));
 
-        ConfigurationSnapshotManager.saveSnapshotToFile(configNodes, 
DEFAULT_SNAPSHOT_FILE);
+        Path outputPath = DEFAULT_SNAPSHOT_FILE;
+        if (args.length > 0) {
+            outputPath = Path.of(args[0]);
+        }
+
+        ConfigurationSnapshotManager.saveSnapshotToFile(configNodes, 
outputPath);
 
         LOG.info("Snapshot saved to: " + 
DEFAULT_SNAPSHOT_FILE.toAbsolutePath());
     }

Reply via email to