public class ServiceProviderImplementation extends java.lang.Object implements ServiceProvider
ServiceProvider interface| Modifier and Type | Field and Description |
|---|---|
static boolean |
cleaned |
static java.lang.Long |
numberOfFiles |
static java.nio.file.Path |
PATH_FOR_DIRECTORY_SIZE_MAP |
static java.nio.file.Path |
PATH_FOR_TOTAL_FILE_NUMBER |
static java.nio.file.Path |
PATH_FOR_TOTAL_VOLUME |
| Constructor and Description |
|---|
ServiceProviderImplementation() |
| Modifier and Type | Method and Description |
|---|---|
void |
calculateDirectorySizes()
Function to calculate the size of
PrimaryDataDirectorys via
CalculateDirectorySizeThread |
void |
cleanUpForBrokenEntities(PrimaryDataDirectory root)
Clean up function to remove objects, if a upload failed
|
void |
cleanUpForRejectedEntities()
Clean up function to remove objects, if a request for a persistent identifier
was rejected
|
void |
deleteDirectoriesRecursively(org.hibernate.Session session,
PrimaryDataDirectory currentDirectory) |
void |
deleteFilesRecursively(org.hibernate.Session session,
PrimaryDataDirectory currentDirectory) |
java.lang.Long |
getAvailableStorageSpace()
Getter for the available space in the mount path of eDAL.
|
int |
getNumberOfUsers()
Function to get the current number of users, who have ever login to the
current instance
|
java.lang.Long |
getUsedStorageSpace()
Getter for the used space in the mount path of eDAL.
|
boolean |
isCleaned()
Get flag for rebuild Lucene Index after a cleanup.
|
void |
setCleaned(boolean flag)
Set flag for rebuild Lucene Index after a cleanup.
|
public static boolean cleaned
public static final java.nio.file.Path PATH_FOR_DIRECTORY_SIZE_MAP
public static final java.nio.file.Path PATH_FOR_TOTAL_FILE_NUMBER
public static final java.nio.file.Path PATH_FOR_TOTAL_VOLUME
public static java.lang.Long numberOfFiles
public java.lang.Long getUsedStorageSpace()
throws EdalException
getUsedStorageSpace in interface ServiceProviderEdalException - if no path is specified.public java.lang.Long getAvailableStorageSpace()
throws EdalException
getAvailableStorageSpace in interface ServiceProviderEdalException - if no path is specified.public void cleanUpForRejectedEntities()
ServiceProvidercleanUpForRejectedEntities in interface ServiceProviderpublic void deleteDirectoriesRecursively(org.hibernate.Session session,
PrimaryDataDirectory currentDirectory)
throws PrimaryDataDirectoryException
PrimaryDataDirectoryExceptionpublic void deleteFilesRecursively(org.hibernate.Session session,
PrimaryDataDirectory currentDirectory)
throws PrimaryDataDirectoryException
PrimaryDataDirectoryExceptionpublic void calculateDirectorySizes()
ServiceProviderPrimaryDataDirectorys via
CalculateDirectorySizeThreadcalculateDirectorySizes in interface ServiceProviderpublic int getNumberOfUsers()
ServiceProvidergetNumberOfUsers in interface ServiceProviderpublic void cleanUpForBrokenEntities(PrimaryDataDirectory root)
ServiceProvidercleanUpForBrokenEntities in interface ServiceProviderroot - the initial directory to start clean processpublic boolean isCleaned()
ServiceProviderisCleaned in interface ServiceProviderpublic void setCleaned(boolean flag)
ServiceProvidersetCleaned in interface ServiceProviderflag - the flag to set