mirror of
https://github.com/LamGC/ContentGrabbingJi.git
synced 2025-07-01 12:57:26 +00:00
[Change] ImageCacheHandler 将缓存键名从downloadLink更改为fileName;
[Change] PixivUgoiraBuilderTest 暂时设置单元测试忽略以关闭耗时的测试, 加快构建速度;
This commit is contained in:
@ -2,6 +2,7 @@ package net.lamgc.cgj.bot.cache;
|
||||
|
||||
import net.lamgc.cgj.Main;
|
||||
import net.lamgc.cgj.pixiv.PixivURL;
|
||||
import net.lamgc.cgj.util.URLs;
|
||||
import net.lamgc.utils.event.EventHandler;
|
||||
import org.apache.commons.io.IOUtils;
|
||||
import org.apache.http.HttpResponse;
|
||||
@ -69,7 +70,7 @@ public class ImageCacheHandler implements EventHandler {
|
||||
log.error("下载图片时发生异常", e);
|
||||
return;
|
||||
}
|
||||
event.getImageCache().put(event.getDownloadLink(), storeFile);
|
||||
event.getImageCache().put(URLs.getResourceName(event.getDownloadLink()), storeFile);
|
||||
} finally {
|
||||
log.info("图片 {} Event结束({})", event.getStoreFile().getName(), Integer.toHexString(event.hashCode()));
|
||||
cacheQueue.remove(event);
|
||||
|
Reference in New Issue
Block a user