| | |
| | | import io.minio.PutObjectArgs; |
| | | import io.minio.credentials.StaticProvider; |
| | | import io.minio.errors.MinioException; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.http.HttpStatus; |
| | |
| | | * 适配 MinIO SDK 8.3.7 + 服务器 RELEASE.2024-08-03 |
| | | * 承接大疆 PUT 上传请求,中转上传到 MinIO HTTPS 接口 |
| | | */ |
| | | @Api(tags = "机场上传minio") |
| | | @Slf4j |
| | | @RestController |
| | | @RequestMapping("/minioTransfer") // 根路径,匹配 Nginx 转发的 /dock/、/kmz/ 路径 |
| | |
| | | * @param contentType 文件 MIME 类型(默认二进制流,适配多种文件格式) |
| | | * @return S3 规范 XML 响应(返回给大疆,衔接后续流程) |
| | | */ |
| | | @ApiOperation("minio上传") |
| | | @PutMapping("/{bucketName}/{objectName}") |
| | | public ResponseEntity<S3PutObjectResponse> proxyUpload( |
| | | @PathVariable String bucketName, |