class WorkspaceFileSystem implements WorkspaceContentAddressableStorage {

    @Override
    public void deleteFolder(String containerName, String folderName)
        throws ContentAddressableStorageNotFoundException, ContentAddressableStorageServerException {
        ParametersChecker.checkParameter(ErrorMessage.CONTAINER_FOLDER_NAMES_ARE_A_MANDATORY_PARAMETER.getMessage(),
            containerName, folderName);
        if (!isExistingFolder(containerName, folderName)) {
            LOGGER.error(ErrorMessage.FOLDER_NOT_FOUND.getMessage() + folderName);
            throw new ContentAddressableStorageNotFoundException(
                ErrorMessage.FOLDER_NOT_FOUND.getMessage() + folderName);
        }
        Path folderPath = null;
        try {
            folderPath = getFolderPath(containerName, folderName);
            Files.delete(folderPath);
        } catch (DirectoryNotEmptyException ex) {
            LOGGER.warn("Directory {} not empty, then we delete files and folder",
                folderPath != null ? folderPath.toString() : "");
            try (Stream<Path> streams = Files.walk(folderPath, FileVisitOption.FOLLOW_LINKS)) {
                streams.sorted(Comparator.reverseOrder())
                    .map(Path::toFile).forEach(File::delete);

            } catch (IOException exc) {
                throw new ContentAddressableStorageServerException(exc);
            }
        } catch (IOException ex) {
            throw new ContentAddressableStorageServerException(ex);
        }
    }

    public  WorkspaceFileSystem(StorageConfiguration configuration);

}