update to version 2.10.0-SNAPSHOT

added new input parameter to getSize method, for compatibility with s3
client plugin
This commit is contained in:
roberto cirillo 2020-11-09 16:13:18 +01:00
parent abad3acc75
commit c3fde07fc8
5 changed files with 7 additions and 4 deletions

View File

@ -1,5 +1,8 @@
# Changelog for storage-manager-core # Changelog for storage-manager-core
## [v2.10.0-SNAPSHOT]
* added input parameter to getSize method in order to be compatible with the needed of s3 client
## [v2.9.0] 2019-10-19 ## [v2.9.0] 2019-10-19
* SSL enabled * SSL enabled

View File

@ -8,7 +8,7 @@
</parent> </parent>
<groupId>org.gcube.contentmanagement</groupId> <groupId>org.gcube.contentmanagement</groupId>
<artifactId>storage-manager-core</artifactId> <artifactId>storage-manager-core</artifactId>
<version>2.9.0</version> <version>2.10.0-SNAPSHOT</version>
<!-- <properties> --> <!-- <properties> -->
<!-- <distroDirectory>${project.basedir}/distro</distroDirectory> --> <!-- <distroDirectory>${project.basedir}/distro</distroDirectory> -->
<!-- </properties> --> <!-- </properties> -->

View File

@ -37,7 +37,7 @@ public class GetMetaFile extends Operation{
String id=null; String id=null;
String mime=null; String mime=null;
try { try {
dim = tm.getSize(bucket); dim = tm.getSize(bucket, myFile);
id=tm.getId(bucket, false); id=tm.getId(bucket, false);
mime=tm.getFileProperty(bucket, "mimetype"); mime=tm.getFileProperty(bucket, "mimetype");
myFile.setOwner(tm.getFileProperty(bucket, "owner")); myFile.setOwner(tm.getFileProperty(bucket, "owner"));

View File

@ -32,7 +32,7 @@ public class GetSize extends Operation{
TransportManager tm=tmf.getTransport(backendType, myFile.getGcubeMemoryType(), dbNames, myFile.getWriteConcern(), myFile.getReadPreference()); TransportManager tm=tmf.getTransport(backendType, myFile.getGcubeMemoryType(), dbNames, myFile.getWriteConcern(), myFile.getReadPreference());
long dim=0; long dim=0;
try { try {
dim = tm.getSize(bucket); dim = tm.getSize(bucket, myFile);
} catch (Exception e) { } catch (Exception e) {
tm.close(); tm.close();
throw new RemoteBackendException(" Error in GetSize operation ", e.getCause()); } throw new RemoteBackendException(" Error in GetSize operation ", e.getCause()); }

View File

@ -290,7 +290,7 @@ public class MongoOperationManager extends TransportManager{
} }
@Override @Override
public long getSize(String remotePath){ public long getSize(String remotePath, MyFile file){
long length=-1; long length=-1;
if(logger.isDebugEnabled()) if(logger.isDebugEnabled())
logger.debug("MongoDB - get Size for pathServer: "+remotePath); logger.debug("MongoDB - get Size for pathServer: "+remotePath);