|
|
|
@ -14,6 +14,8 @@ import java.io.IOException;
|
|
|
|
|
import java.security.InvalidKeyException;
|
|
|
|
|
import java.security.NoSuchAlgorithmException;
|
|
|
|
|
|
|
|
|
|
import com.jfinal.plugin.activerecord.Record;
|
|
|
|
|
|
|
|
|
|
@ApiDoc
|
|
|
|
|
public class ResourceController extends Controller {
|
|
|
|
|
|
|
|
|
@ -33,7 +35,10 @@ public class ResourceController extends Controller {
|
|
|
|
|
//生成一个guid+扩展名的key
|
|
|
|
|
String objectName = java.util.UUID.randomUUID() + "." + extension;
|
|
|
|
|
String signature = MinioUtils.getSignature(objectName);
|
|
|
|
|
renderJson(RetKit.renderSuccess(signature));
|
|
|
|
|
Record record = new Record();
|
|
|
|
|
record.set("object_name", objectName);
|
|
|
|
|
record.set("signature", signature);
|
|
|
|
|
renderJson(RetKit.renderSuccess(record));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|