Project

General

Profile

« Previous | Next » 

Revision 56855

reverted storage on s3, we save before on a predefined path and then on s3, because storing directly on s3 not works well

View differences:

S3ObjectStoreDao.java
49 49
    @Value("${dnet.objectStore.s3.objectStoreBucket}")
50 50
    private String objectStoreBucket;
51 51

  
52
    @Value("${dnet.objectStore.s3.basePath}")
53
    private String objectStoreBasePath;
52 54

  
55

  
53 56
	private Document getObjectStoreMetadata(final String objectStoreId) {
54 57
        String find_id = objectStoreId;
55 58
        if (objectStoreId.length() == 36) {
......
70 73
        if ((resultQuery == null)) throw new ObjectStoreFileNotFoundException("the objectStore with identifier: "+objectStoreId+" was not found");
71 74
        final MongoCollection<Document> collection = getDb().getCollection(objectStoreId.substring(0,36));
72 75
        collection.createIndexes(metadataIndexes);
73
        return new S3ObjectStore(resultQuery.getString(OBJECTSTORE_ID_FIELD),resultQuery.getString(INTERPRETATION_FIELD),accessKey, secretKey, s3EndPoint, objectStoreBucket, collection);
76
        return new S3ObjectStore(resultQuery.getString(OBJECTSTORE_ID_FIELD),resultQuery.getString(INTERPRETATION_FIELD),accessKey, secretKey, s3EndPoint, objectStoreBucket, collection, objectStoreBasePath);
74 77
    }
75 78

  
76 79
    @Override

Also available in: Unified diff