Package com.gooddata.sdk.service.gdc
Class DataStoreService
java.lang.Object
com.gooddata.sdk.service.gdc.DataStoreService
Uploads, downloads, deletes, ... at datastore
-
Constructor Summary
ConstructorsConstructorDescriptionDataStoreService(SingleEndpointGoodDataRestProvider restProvider, Supplier<String> stagingUriSupplier) Creates new DataStoreService -
Method Summary
Modifier and TypeMethodDescriptionvoidDelete given path from datastore.Download given path and return data as streamReturns uri for given path (which is used by this service for upload, download or delete)voidupload(String path, InputStream stream) Uploads given stream to given datastore path
-
Constructor Details
-
DataStoreService
public DataStoreService(SingleEndpointGoodDataRestProvider restProvider, Supplier<String> stagingUriSupplier) Creates new DataStoreService- Parameters:
restProvider- restProvider to make datastore connectionstagingUriSupplier- used to obtain datastore URI
-
-
Method Details
-
getUri
Returns uri for given path (which is used by this service for upload, download or delete)- Parameters:
path- path the uri is constructed for- Returns:
- uri for given path
-
upload
Uploads given stream to given datastore path- Parameters:
path- path where to upload tostream- stream to upload- Throws:
DataStoreException- in case upload failed
-
download
Download given path and return data as stream- Parameters:
path- path from where to download- Returns:
- download stream
- Throws:
DataStoreException- in case download failed
-
delete
Delete given path from datastore.- Parameters:
path- path to delete- Throws:
DataStoreException- in case delete failed
-