Skip to content

Commit

Permalink
Fix the type with return payload, providing correct bucket name.
Browse files Browse the repository at this point in the history
  • Loading branch information
ssaniev committed Mar 25, 2016
1 parent 95c3017 commit 68a1b8e
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/main/java/generator/components/RasterGenerator.java
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ private DataResource getDataSource(String id, RasterCropRequest request){
//create data type to return
S3FileStore s3Store = new S3FileStore();
s3Store.domainName = request.getSource().getDomain();
s3Store.bucketName = request.getSource().getBucketName();
s3Store.bucketName = S3_OUTPUT_BUCKET;
s3Store.fileName = id;

RasterDataType dataType = new RasterDataType();
Expand Down Expand Up @@ -196,9 +196,7 @@ private String writeFileToS3(File file, FileLocation fileLocation) throws FileNo
// Making the object Public
PutObjectRequest putObj = new PutObjectRequest(S3_OUTPUT_BUCKET, fileKey, file);
putObj.setCannedAcl(CannedAccessControlList.PublicRead);

//InputStream inputStream = new FileInputStream(file);
//s3Client.putObject(S3_OUTPUT_BUCKET, fileKey, inputStream, metadata);

s3Client.putObject(putObj);

return fileKey;
Expand Down

0 comments on commit 68a1b8e

Please sign in to comment.