Skip to content

IGNITE-29056 Introduce snapshot lists command to control.sh - #13666

Merged
zstan merged 154 commits into
apache:masterfrom
Vladsz83:IGNITE-29056-Introduce-snapshot-lists-command-to-control.sh
Oct 27, 2026
Merged

zstan merged 154 commits into
apache:masterfrom
Vladsz83:IGNITE-29056-Introduce-snapshot-lists-command-to-control.sh

Conversation

@Vladsz83

@Vladsz83 Vladsz83 commented Oct 8, 2026

Copy link
Copy Markdown
Contributor

Thank you for submitting the pull request to the Apache Ignite.

In order to streamline the review of the contribution
we ask you to ensure the following steps have been taken:

The Contribution Checklist

  • There is a single JIRA ticket related to the pull request.
  • The web-link to the pull request is attached to the JIRA ticket.
  • The JIRA ticket has the Patch Available state.
  • The pull request body describes changes that have been made.
    The description explains WHAT and WHY was made instead of HOW.
  • The pull request title is treated as the final commit message.
    The following pattern must be used: IGNITE-XXXX Change summary where XXXX - number of JIRA issue.
  • A reviewer has been mentioned through the JIRA comments
    (see the Maintainers list)
  • The pull request has been checked by the Teamcity Bot and
    the green visa attached to the JIRA ticket (see tab PR Check at TC.Bot - Instance 1 or TC.Bot - Instance 2)

Notes

If you need any help, please email dev@ignite.apache.org or ask anу advice on http://asf.slack.com #ignite channel.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Unresolved critical feature-ID compatibility and moderate snapshot metadata validation findings remain.

1 open issue
What changed in this PR

Adds control.sh|bat --snapshot list to enumerate snapshots, metadata, sizes, incremental parts, and external storage usage.

Changes:

  • Adds snapshot-list commands, tasks, DTOs, and output formatting.
  • Adds feature gating, documentation, help updates, and extensive tests.
  • Updates snapshot metadata handling and test utilities.
File Description
modules/​ducktests/​src/​main/​java/​org/​apache/​ignite/​internal/​ducktest/​tests/​ContinuousDataLoadApplication.java Corrects a typo.
modules/​core/​src/​test/​resources/​org.apache.ignite.util/​GridCommandHandlerClusterByClassWithSSLTest_help.output Updates CLI help.
modules/​core/​src/​test/​resources/​org.apache.ignite.util/​GridCommandHandlerClusterByClassTest_help.output Updates CLI help.
modules/​core/​src/​test/​java/​org/​apache/​ignite/​testsuites/​IgniteSnapshotTestSuite9.java Adds snapshot-list test suite.
modules/​core/​src/​test/​java/​org/​apache/​ignite/​internal/​processors/​rollingupgrade/​feature/​TestIgniteReleaseFeatures_2_19_4.java Adds release feature definitions.
modules/​core/​src/​test/​java/​org/​apache/​ignite/​internal/​processors/​rollingupgrade/​AbstractRollingUpgradeTest.java Updates release feature coverage.
modules/​core/​src/​test/​java/​org/​apache/​ignite/​internal/​processors/​cache/​persistence/​snapshot/​incremental/​IncrementalSnapshotNodeFailureTest.java Updates snapshot manager access.
modules/​core/​src/​test/​java/​org/​apache/​ignite/​internal/​processors/​cache/​persistence/​snapshot/​incremental/​AbstractIncrementalSnapshotTest.java Updates snapshot manager access.
modules/​core/​src/​test/​java/​org/​apache/​ignite/​internal/​processors/​cache/​persistence/​snapshot/​IgniteClusterSnapshotListTest.java Adds snapshot-list tests.
modules/​core/​src/​test/​java/​org/​apache/​ignite/​internal/​processors/​cache/​persistence/​snapshot/​IgniteClusterSnapshotListRollingUpgradeTest.java Adds rolling-upgrade tests.
modules/​core/​src/​test/​java/​org/​apache/​ignite/​internal/​processors/​cache/​persistence/​snapshot/​AbstractSnapshotSelfTest.java Generalizes snapshot helpers.
modules/​core/​src/​main/​java/​org/​apache/​ignite/​internal/​processors/​rollingupgrade/​feature/​CoreFeatureRegistry.java Registers the snapshot-list feature.
modules/​core/​src/​main/​java/​org/​apache/​ignite/​internal/​processors/​metastorage/​persistence/​DistributedMetaStorageImpl.java Corrects a typo.
modules/​core/​src/​main/​java/​org/​apache/​ignite/​internal/​processors/​cache/​persistence/​snapshot/​SnapshotMetadataVerificationTask.java Adds TODO documentation.
modules/​core/​src/​main/​java/​org/​apache/​ignite/​internal/​processors/​cache/​persistence/​snapshot/​SnapshotListTaskResult.java Adds aggregate result DTO.
modules/​core/​src/​main/​java/​org/​apache/​ignite/​internal/​processors/​cache/​persistence/​snapshot/​SnapshotListJobResult.java Adds per-node result DTO.
modules/​core/​src/​main/​java/​org/​apache/​ignite/​internal/​processors/​cache/​persistence/​snapshot/​SnapshotCheckProcess.java Corrects a typo.
modules/​core/​src/​main/​java/​org/​apache/​ignite/​internal/​processors/​cache/​persistence/​snapshot/​IgniteSnapshotManager.java Supports tolerant metadata reads.
modules/​core/​src/​main/​java/​org/​apache/​ignite/​internal/​processors/​cache/​persistence/​filename/​SnapshotFileTree.java Documents path limitations.
modules/​core/​src/​main/​java/​org/​apache/​ignite/​internal/​processors/​cache/​distributed/​dht/​preloader/​GridDhtPartitionsSingleMessage.java Corrects a typo.
modules/​core/​src/​main/​java/​org/​apache/​ignite/​internal/​management/​snapshot/​SnapshotListTask.java Implements snapshot discovery and sizing.
modules/​core/​src/​main/​java/​org/​apache/​ignite/​internal/​management/​snapshot/​SnapshotListCommandArg.java Adds the --src argument.
modules/​core/​src/​main/​java/​org/​apache/​ignite/​internal/​management/​snapshot/​SnapshotListCommand.java Formats command output.
modules/​core/​src/​main/​java/​org/​apache/​ignite/​internal/​management/​snapshot/​SnapshotCommand.java Registers the list subcommand.
modules/​control-utility/​src/​test/​java/​org/​apache/​ignite/​util/​GridCommandHandlerListSnapshotTest.java Adds CLI tests.
modules/​control-utility/​src/​test/​java/​org/​apache/​ignite/​util/​GridCommandHandlerAbstractTest.java Refactors test cache setup.
modules/​control-utility/​src/​test/​java/​org/​apache/​ignite/​testsuites/​IgniteControlUtilityTestSuite6.java Adds CLI test suite.
docs/​_docs/​snapshots/​snapshots.adoc Documents snapshot listing.

Review effort: Lite

Comment thread docs/_docs/snapshots/snapshots.adoc
…s-command-to-control.sh' into IGNITE-29056-Introduce-snapshot-lists-command-to-control.sh
…and-to-control.sh

# Conflicts:
#	modules/core/src/main/java/org/apache/ignite/internal/processors/rollingupgrade/feature/CoreFeatureRegistry.java
…and-to-control.sh

# Conflicts:
#	modules/core/src/main/java/org/apache/ignite/internal/processors/rollingupgrade/feature/CoreFeatureRegistry.java
…and-to-control.sh-dev

# Conflicts:
#	docs/_docs/snapshots/snapshots.adoc
#	modules/control-utility/src/test/java/org/apache/ignite/testsuites/IgniteControlUtilityTestSuite6.java
#	modules/core/src/main/java/org/apache/ignite/internal/management/snapshot/SnapshotCommand.java
#	modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/snapshot/IgniteSnapshotManager.java
#	modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/snapshot/SnapshotMetadataVerificationTask.java
#	modules/core/src/main/java/org/apache/ignite/internal/processors/rollingupgrade/feature/CoreFeatureRegistry.java
#	modules/core/src/test/java/org/apache/ignite/testsuites/IgniteSnapshotTestSuite9.java
#	modules/core/src/test/resources/org.apache.ignite.util/GridCommandHandlerClusterByClassTest_help.output
#	modules/core/src/test/resources/org.apache.ignite.util/GridCommandHandlerClusterByClassWithSSLTest_help.output
…l.sh-dev' into IGNITE-29056-Introduce-snapshot-lists-command-to-control.sh

@zstan zstan left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Plz fix (or reply) last comments

Comment on lines +168 to +169
int i0 = i;
int k0 = k;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

redundant variables

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

ComputeJobResult nodeJobRes = nodesJobsResults.get(i);

if (nodeJobRes.getException() != null) {
throw new IgniteException("Failed to execute snapshot list job on node [uuid=" + nodeJobRes.getNode().id() + ']',

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I`d prefer to fix it, but if other places are uses the same approach - it`s up to you

@github-actions

Copy link
Copy Markdown

Possible compatibility issues. Please, check rolling upgrade cases

This PR modifies protected classes (with Order annotation).
Changes to these classes can break rolling upgrade compatibility.

Affected files:

  • modules/core/src/main/java/org/apache/ignite/internal/management/snapshot/SnapshotCheckCommandArg.java
  • modules/core/src/main/java/org/apache/ignite/internal/management/snapshot/SnapshotDeleteCommandArg.java
  • modules/core/src/main/java/org/apache/ignite/internal/management/snapshot/SnapshotListCommandArg.java
  • modules/core/src/main/java/org/apache/ignite/internal/management/snapshot/SnapshotRestoreCommandArg.java
  • modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/snapshot/SnapshotListJobResult.java
  • modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/snapshot/SnapshotListTaskResult.java

@zstan
zstan merged commit 69e3a7c into apache:master Oct 27, 2026
6 checks passed
@Vladsz83
Vladsz83 deleted the IGNITE-29056-Introduce-snapshot-lists-command-to-control.sh branch October 27, 2026 08:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants