Skip to content

Commit

Permalink
处理内存溢出
Browse files Browse the repository at this point in the history
  • Loading branch information
wushuo894 committed Nov 13, 2024
1 parent 6b91213 commit d2c4ce2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/main/java/ani/rss/util/AlistUtil.java
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ public static void upload(TorrentsInfo torrentsInfo) {
.header(Header.AUTHORIZATION, alistToken)
.header("As-Task", "true")
.header("File-Path", URLUtil.encode(finalFilePath))
.header(Header.CONTENT_LENGTH, String.valueOf(file.length()))
.body(new InputStreamResource(inputStream))
.then(res -> {
Assert.isTrue(res.isOk(), "上传失败 {} 状态码:{}", string, res.getStatus());
Expand Down

0 comments on commit d2c4ce2

Please sign in to comment.