Class TapeLibraryPoolImpl
java.lang.Object
fr.gouv.vitam.storage.offers.tape.pool.TapeLibraryPoolImpl
- All Implemented Interfaces:
TapeDrivePool,TapeLibraryPool,TapeRobotPool
-
Constructor Summary
ConstructorsConstructorDescriptionTapeLibraryPoolImpl(String libraryIdentifier, BlockingQueue<TapeRobotService> tapeRobotServicePool, ConcurrentHashMap<Integer, TapeDriveService> tapeDriveServicePool) -
Method Summary
Modifier and TypeMethodDescriptioncheckoutDriveService(Integer driveIndex) Retrieves and removes the head of this pool, waiting if necessary until an element becomes available.Retrieves and removes the head of this pool, waiting if necessary until an element becomes available.checkoutRobotService(long timeout, TimeUnit unit) Retrieves and removes the head of this queue, waiting up to the specified wait time if necessary for an element to become available.drives()voidpushDriveService(TapeDriveService tapeDriveService) Return or add TapeDriveService to the poolvoidpushRobotService(TapeRobotService tapeRobotService) Return or add TapeRobotService to the pool
-
Constructor Details
-
TapeLibraryPoolImpl
public TapeLibraryPoolImpl(String libraryIdentifier, BlockingQueue<TapeRobotService> tapeRobotServicePool, ConcurrentHashMap<Integer, TapeDriveService> tapeDriveServicePool)
-
-
Method Details
-
checkoutRobotService
Description copied from interface:TapeRobotPoolRetrieves and removes the head of this pool, waiting if necessary until an element becomes available.- Specified by:
checkoutRobotServicein interfaceTapeRobotPool- Returns:
- TapeRobotService
- Throws:
InterruptedException
-
checkoutRobotService
public TapeRobotService checkoutRobotService(long timeout, TimeUnit unit) throws InterruptedException Description copied from interface:TapeRobotPoolRetrieves and removes the head of this queue, waiting up to the specified wait time if necessary for an element to become available.- Specified by:
checkoutRobotServicein interfaceTapeRobotPool- Returns:
- TapeRobotService
- Throws:
InterruptedException
-
checkoutDriveService
Description copied from interface:TapeDrivePoolRetrieves and removes the head of this pool, waiting if necessary until an element becomes available.- Specified by:
checkoutDriveServicein interfaceTapeDrivePool- Returns:
- TapeDriveService
-
pushRobotService
Description copied from interface:TapeRobotPoolReturn or add TapeRobotService to the pool- Specified by:
pushRobotServicein interfaceTapeRobotPool- Throws:
InterruptedException
-
pushDriveService
Description copied from interface:TapeDrivePoolReturn or add TapeDriveService to the pool- Specified by:
pushDriveServicein interfaceTapeDrivePool
-
drives
- Specified by:
drivesin interfaceTapeDrivePool
-
getLibraryIdentifier
- Specified by:
getLibraryIdentifierin interfaceTapeRobotPool
-