Class TapeLibraryServiceImpl
java.lang.Object
fr.gouv.vitam.storage.offers.tape.impl.readwrite.TapeLibraryServiceImpl
- All Implemented Interfaces:
TapeLibraryService
-
Field Summary
Fields inherited from interface fr.gouv.vitam.storage.offers.tape.spec.TapeLibraryService
TAPE_LABEL, TAPE_MSG
-
Constructor Summary
ConstructorDescriptionTapeLibraryServiceImpl
(TapeDriveService tapeDriveService, TapeRobotPool tapeRobotPool, int fullCartridgeDetectionThresholdInMB) -
Method Summary
Modifier and TypeMethodDescriptionvoid
void
ensureTapeIsEmpty
(TapeCatalog tape, boolean forceOverrideNonEmptyCartridges) getDriveStatus
(ReadWriteErrorCode readWriteErrorCode) void
goToPosition
(TapeCatalog tape, Integer position, ReadWriteErrorCode readWriteErrorCode) void
loadTape
(TapeCatalog tape) void
read
(TapeCatalog tape, Integer position, String outputPath) void
rewindTape
(TapeCatalog tape) void
unloadTape
(TapeCatalog tape) void
write
(String filePath, long writtenBytes, TapeCatalog tape)
-
Field Details
-
MSG_PREFIX
-
-
Constructor Details
-
TapeLibraryServiceImpl
public TapeLibraryServiceImpl(TapeDriveService tapeDriveService, TapeRobotPool tapeRobotPool, int fullCartridgeDetectionThresholdInMB)
-
-
Method Details
-
goToPosition
public void goToPosition(TapeCatalog tape, Integer position, ReadWriteErrorCode readWriteErrorCode) throws ReadWriteException - Specified by:
goToPosition
in interfaceTapeLibraryService
- Throws:
ReadWriteException
-
rewindTape
- Specified by:
rewindTape
in interfaceTapeLibraryService
- Throws:
ReadWriteException
-
write
- Specified by:
write
in interfaceTapeLibraryService
- Throws:
ReadWriteException
-
read
- Specified by:
read
in interfaceTapeLibraryService
- Throws:
ReadWriteException
-
loadTape
- Specified by:
loadTape
in interfaceTapeLibraryService
- Throws:
ReadWriteException
-
unloadTape
- Specified by:
unloadTape
in interfaceTapeLibraryService
- Throws:
ReadWriteException
-
getDriveStatus
public TapeDriveSpec getDriveStatus(ReadWriteErrorCode readWriteErrorCode) throws ReadWriteException - Specified by:
getDriveStatus
in interfaceTapeLibraryService
- Throws:
ReadWriteException
-
getDriveIndex
- Specified by:
getDriveIndex
in interfaceTapeLibraryService
-
getLibraryIdentifier
- Specified by:
getLibraryIdentifier
in interfaceTapeLibraryService
-
getTmpOutputDirectory
- Specified by:
getTmpOutputDirectory
in interfaceTapeLibraryService
-
ensureTapeIsEmpty
public void ensureTapeIsEmpty(TapeCatalog tape, boolean forceOverrideNonEmptyCartridges) throws ReadWriteException - Specified by:
ensureTapeIsEmpty
in interfaceTapeLibraryService
- Throws:
ReadWriteException
-
checkNonEmptyTapeLabel
- Specified by:
checkNonEmptyTapeLabel
in interfaceTapeLibraryService
- Throws:
ReadWriteException
-