Class OmSnapshotLocalDataManager
java.lang.Object
org.apache.hadoop.ozone.om.snapshot.OmSnapshotLocalDataManager
- All Implemented Interfaces:
AutoCloseable
Manages local data and metadata associated with Ozone Manager (OM) snapshots,
including the creation, storage, and representation of data as YAML files.
-
Constructor Summary
ConstructorsConstructorDescriptionOmSnapshotLocalDataManager(org.apache.hadoop.ozone.om.OMMetadataManager omMetadataManager) -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()voidcreateNewOmSnapshotLocalDataFile(org.apache.hadoop.hdds.utils.db.RDBStore snapshotStore, org.apache.hadoop.ozone.om.helpers.SnapshotInfo snapshotInfo) Creates and writes snapshot local properties to a YAML file with not defragged SST file list.getOmSnapshotLocalData(File snapshotDataPath) getOmSnapshotLocalData(UUID snapshotId) getOmSnapshotLocalData(org.apache.hadoop.ozone.om.helpers.SnapshotInfo snapshotInfo) static StringgetSnapshotLocalPropertyYamlPath(Path snapshotPath) Returns the path to the YAML file that stores local properties for the given snapshot.getSnapshotLocalPropertyYamlPath(UUID snapshotId) getSnapshotLocalPropertyYamlPath(org.apache.hadoop.ozone.om.helpers.SnapshotInfo snapshotInfo) Returns the path to the YAML file that stores local properties for the given snapshot.
-
Constructor Details
-
OmSnapshotLocalDataManager
public OmSnapshotLocalDataManager(org.apache.hadoop.ozone.om.OMMetadataManager omMetadataManager) throws IOException - Throws:
IOException
-
-
Method Details
-
getSnapshotLocalPropertyYamlPath
Returns the path to the YAML file that stores local properties for the given snapshot.- Parameters:
snapshotPath- path to the snapshot checkpoint dir- Returns:
- the path to the snapshot's local property YAML file
-
getSnapshotLocalPropertyYamlPath
public String getSnapshotLocalPropertyYamlPath(org.apache.hadoop.ozone.om.helpers.SnapshotInfo snapshotInfo) Returns the path to the YAML file that stores local properties for the given snapshot.- Parameters:
snapshotInfo- snapshot metadata- Returns:
- the path to the snapshot's local property YAML file
-
getSnapshotLocalPropertyYamlPath
-
createNewOmSnapshotLocalDataFile
public void createNewOmSnapshotLocalDataFile(org.apache.hadoop.hdds.utils.db.RDBStore snapshotStore, org.apache.hadoop.ozone.om.helpers.SnapshotInfo snapshotInfo) throws IOException Creates and writes snapshot local properties to a YAML file with not defragged SST file list.- Parameters:
snapshotStore- snapshot metadata manager.snapshotInfo- snapshot info instance corresponding to snapshot.- Throws:
IOException
-
getOmSnapshotLocalData
public OmSnapshotLocalData getOmSnapshotLocalData(org.apache.hadoop.ozone.om.helpers.SnapshotInfo snapshotInfo) throws IOException - Throws:
IOException
-
getOmSnapshotLocalData
- Throws:
IOException
-
getOmSnapshotLocalData
- Throws:
IOException
-
close
public void close()- Specified by:
closein interfaceAutoCloseable
-