// toSEID = iClient.getId(storageId); //to Storage Encrypted ID
// LOG.info("Decoded ID"+" = "+ toSEID);
// }catch(Exception e){
// LOG.error("Storage Client Exception when getting file from storage: ", e);
// throw ExceptionManager.notFoundException(httpRequest, "Storage Client Exception when getting file from storage with id: "+storageId, StorageIDResolver.class, help);
// }
storageId=identifyIdAndMemory(storageId);
storageId=identifyIdAndMemory(storageId);
IClientiClient=getStorageClientInstance(memory);
IClientiClient=getStorageClientInstance(memory);
StringtoSEID=null;
StringtoSEID=null;
@ -152,10 +139,6 @@ public class StorageIDResolver {
LOG.error("Storage Client Exception when getting file from storage: ",e);
LOG.error("Storage Client Exception when getting file from storage: ",e);
throwExceptionManager.notFoundException(httpRequest,"Storage Client Exception when getting file from storage with id: "+storageId,StorageIDResolver.class,help);
throwExceptionManager.notFoundException(httpRequest,"Storage Client Exception when getting file from storage with id: "+storageId,StorageIDResolver.class,help);
}
}
/** END PATCH 2.6.1-SNAPSHOT **/
if(toSEID==null||toSEID.isEmpty()){
if(toSEID==null||toSEID.isEmpty()){
LOG.error("Decrypted id for storageId: "+storageId+" is null or empty!");
LOG.error("Decrypted id for storageId: "+storageId+" is null or empty!");
throwExceptionManager.notFoundException(httpRequest,"Error on decrypting the "+STORAGE_ID+" '"+storageId+"'. Is it a valid id?",StorageIDResolver.class,help);
throwExceptionManager.notFoundException(httpRequest,"Error on decrypting the "+STORAGE_ID+" '"+storageId+"'. Is it a valid id?",StorageIDResolver.class,help);
@ -274,23 +257,7 @@ public class StorageIDResolver {
if(storageId==null||storageId.isEmpty()){
if(storageId==null||storageId.isEmpty()){
LOG.warn("storageId not found");
LOG.warn("storageId not found");
throwExceptionManager.badRequestException(httpRequest,"Storage Client Exception when getting file from storage with id: "+storageId,this.getClass(),help);
throwExceptionManager.badRequestException(httpRequest,"Storage Client Exception when getting file from storage with id: "+storageId,this.getClass(),help);
// toSEID = iClient.getId(storageId); //to Storage Encrypted ID
// LOG.info("Decoded ID"+" = "+ toSEID);
// }catch(Exception e){
// LOG.error("Storage Client Exception when getting file from storage: ", e);
// throw ExceptionManager.notFoundException(httpRequest, "Storage Client Exception when getting file from storage with id: "+storageId, StorageIDResolver.class, help);
// }
storageId=identifyIdAndMemory(storageId);
storageId=identifyIdAndMemory(storageId);
IClientiClient=getStorageClientInstance(memory);
IClientiClient=getStorageClientInstance(memory);
StringtoSEID=null;
StringtoSEID=null;
@ -302,14 +269,10 @@ public class StorageIDResolver {
LOG.error("Storage Client Exception when getting file from storage: ",e);
LOG.error("Storage Client Exception when getting file from storage: ",e);
throwExceptionManager.notFoundException(httpRequest,"Storage Client Exception when getting file from storage with id: "+storageId,StorageIDResolver.class,help);
throwExceptionManager.notFoundException(httpRequest,"Storage Client Exception when getting file from storage with id: "+storageId,StorageIDResolver.class,help);
}
}
/** END PATCH 2.6.1-SNAPSHOT **/
if(toSEID==null||toSEID.isEmpty()){
if(toSEID==null||toSEID.isEmpty()){
LOG.error("Decrypted id for storageId: "+storageId+" is null or empty!");
LOG.error("Decrypted id for storageId: "+storageId+" is null or empty!");
throwExceptionManager.notFoundException(httpRequest,"Error on decrypting the "+STORAGE_ID+" '"+storageId+"'. Is it a valid id?",StorageIDResolver.class,help);
throwExceptionManager.notFoundException(httpRequest,"Error on decrypting the "+STORAGE_ID+" '"+storageId+"'. Is it a valid id?",StorageIDResolver.class,help);