From a0a71ceb18ffba5573a98d693ce296f518959334 Mon Sep 17 00:00:00 2001 From: imankitsingh Date: Fri, 5 Oct 2018 11:31:42 +0530 Subject: [PATCH] Added a field to mark stored file for deletion, using aws s3 v4 signature, Upgraded plugin version --- build.gradle | 2 +- grails-app/domain/com/wizpanda/file/StoredFile.groovy | 2 ++ .../com/wizpanda/file/service/AmazonS3UploaderService.groovy | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/build.gradle b/build.gradle index fcf972f..b9d6459 100644 --- a/build.gradle +++ b/build.gradle @@ -8,7 +8,7 @@ buildscript { } } -version "0.1.1" +version "0.1.2" group "com.wizpanda.plugins" apply plugin: "eclipse" diff --git a/grails-app/domain/com/wizpanda/file/StoredFile.groovy b/grails-app/domain/com/wizpanda/file/StoredFile.groovy index c24ffdb..540dd74 100644 --- a/grails-app/domain/com/wizpanda/file/StoredFile.groovy +++ b/grails-app/domain/com/wizpanda/file/StoredFile.groovy @@ -4,6 +4,8 @@ import grails.util.Holders class StoredFile { + boolean markedForDeletion + String originalName String name String url diff --git a/src/main/groovy/com/wizpanda/file/service/AmazonS3UploaderService.groovy b/src/main/groovy/com/wizpanda/file/service/AmazonS3UploaderService.groovy index e75e419..3d8239f 100644 --- a/src/main/groovy/com/wizpanda/file/service/AmazonS3UploaderService.groovy +++ b/src/main/groovy/com/wizpanda/file/service/AmazonS3UploaderService.groovy @@ -21,7 +21,7 @@ class AmazonS3UploaderService extends UploaderService { * TODO https://github.com/aws/aws-sdk-java/issues/740 * TODO Planned to be released in https://github.com/jclouds/jclouds/pull/678 */ - //System.setProperty("com.amazonaws.services.s3.enableV4", "true") + System.setProperty("com.amazonaws.services.s3.enableV4", "true") } @Override