Class SnapshotFacadeImpl

java.lang.Object
org.gridgain.internal.snapshots.SnapshotFacadeImpl
All Implemented Interfaces:
SnapshotFacade

public class SnapshotFacadeImpl extends Object implements SnapshotFacade
Class implementing SnapshotFacade.
  • Constructor Details

    • SnapshotFacadeImpl

      public SnapshotFacadeImpl(org.apache.ignite.internal.network.ClusterService clusterService, org.apache.ignite.internal.metastorage.impl.MetaStorageManagerImpl metaStorageManager, org.gridgain.internal.encryption.EncryptionManager encryptionManager)
      Creates a new Facade instance.
      Parameters:
      clusterService - Network manager.
      metaStorageManager - Meta Storage manager.
  • Method Details

    • createSnapshot

      public CompletableFuture<UUID> createSnapshot(org.apache.ignite.internal.rest.api.snapshot.SnapshotType snapshotType, Set<String> tableNames, Set<String> structureNames, @Nullable @Nullable String destination, @Nullable @Nullable Instant timestamp, @Nullable @Nullable String encryptionProvider)
      Description copied from interface: SnapshotFacade
      Starts a Snapshot over the provided tables at a given moment in time.
      Specified by:
      createSnapshot in interface SnapshotFacade
      Parameters:
      snapshotType - Type of the snapshot.
      tableNames - Set of fully-qualified table names that will be parts of the snapshot. If empty, all tables actual at the moment of starting the operation will be used instead.
      destination - Name of the snapshot URI in configuration or null for default.
      timestamp - Timestamp at which the Snapshot should be taken. If null then current time is used.
      encryptionProvider - The name of encryption provider.
      Returns:
      Future that completes after a Full Snapshot has been started and contains the Snapshot ID.
    • restoreSnapshot

      public CompletableFuture<UUID> restoreSnapshot(UUID targetSnapshotId, Set<String> tableNames, @Nullable @Nullable String source, @Nullable @Nullable String decryptionProvider)
      Description copied from interface: SnapshotFacade
      Initiates restoration of a given Snapshot.
      Specified by:
      restoreSnapshot in interface SnapshotFacade
      Parameters:
      targetSnapshotId - ID of the Snapshot to be restored.
      tableNames - Set of fully-qualified table names to restore from the snapshot. If empty, restores all tables from the snapshot.
      source - Name of the snapshot URI in configuration or null for default.
      decryptionProvider - Name of the decryption provider.
      Returns:
      Future that completes after a Snapshot restoration has been started and contains the ID of the operation.
    • deleteSnapshot

      public CompletableFuture<UUID> deleteSnapshot(UUID targetSnapshotId)
      Description copied from interface: SnapshotFacade
      Initiates deletion of a given Snapshot.
      Specified by:
      deleteSnapshot in interface SnapshotFacade
      Parameters:
      targetSnapshotId - ID of the Snapshot to be deleted.
      Returns:
      Future that completes after a Snapshot deletion has been started and contains the ID of the operation.
    • getSnapshotOperationsList

      public CompletableFuture<List<org.apache.ignite.internal.rest.api.snapshot.SnapshotOperation>> getSnapshotOperationsList()
      Description copied from interface: SnapshotFacade
      Returns a list of all snapshot creation and restoration operations, sorted from newest to oldest.
      Specified by:
      getSnapshotOperationsList in interface SnapshotFacade
      Returns:
      Future that completes after all snapshot operations are retrieved.
    • getOperationById

      public CompletableFuture<List<org.apache.ignite.internal.rest.api.snapshot.SnapshotOperation>> getOperationById(UUID operationId, boolean allNodes)
      Description copied from interface: SnapshotFacade
      Returns operation by ID.
      Specified by:
      getOperationById in interface SnapshotFacade
      Parameters:
      operationId - ID of the operation.
      allNodes - if operation status for every node should be retrieved.
      Returns:
      Completable future that will be completed when all operations are retrieved.