Comments (14)
同问
from okdownload.
同问
from okdownload.
同问
from okdownload.
@huanghaoda8 你那边报错是必现吗,我最近一直在找必现的case,如果这个问题比较急,可以交流一下
from okdownload.
@huanghaoda8 你那边报错是必现吗,我最近一直在找必现的case,如果这个问题比较急,可以交流一下
多块下载时必现,现在改成单链接下载,就不再出现了。根据log,包头返回的块范围值、总长度值没有问题,实际下载到流结束时,就必现的获取到的数据流长度与块长度不一致,不能确定是不是服务器问题;以下是可验证的下载链接:
https://obsbot-static-resource.oss-accelerate.aliyuncs.com/product_system_back/firmware_test/update1-0-1.zip
from okdownload.
@huanghaoda8 谢谢,我明天抽时间校验一下,你测试的是android 多少版本,什么型号手机,不同型号都必现吗
from okdownload.
@huanghaoda8 https://github.com/tianshaokai/okdownload 你可以在这个代码里,修改单次下载 改为你上边的链接试一下,我测试了两遍目前没有发现问题,如果有问题可以随时通过邮箱联系我([email protected])
from okdownload.
@tianshaokai 修改是不是增加了同步锁。 在android10中以前我增加了这段代码
synchronized (noSyncLengthMap) {
// make sure the length of noSyncLengthMap is equal to outputStreamMap
outputStreamMap.remove(blockIndex);
noSyncLengthMap.remove(blockIndex);
但还是偶尔会出现这个错误,概率比较低。我再把这个同步锁加上看看会不会复现此问题
from okdownload.
@zhongxingqiang 就算增加了你说的这个同步锁,依然偶现问题
from okdownload.
@tianshaokai 在done方法增加同步锁后 让一个任务反复下载,测试了半小时没有出现。 在inspectComplete中如果出现此问题我修改为不抛异常 这样可以继续完成任务 不知道有其他大的影响不
from okdownload.
@zhongxingqiang 你这样改就是吞了异常,出了问题无法获取到原因,如果到了线上就变成了线上事故
from okdownload.
@tianshaokai 那我就在taskEnd回调中 如果出现这个异常就再次下载 可以么
你是怎么测试复现的 我又跑了半个小时还没复现
from okdownload.
@zhongxingqiang 你可以按照自己理解的改,发布到线上,每天那么大的日活量帮你测试一下,看看有什么问题,多线程问题本地是不好复现的
from okdownload.
@tianshaokai 好的 感谢
from okdownload.
Related Issues (20)
- is OkDownload support config custom Executor?
- 断点下载的判断为什么没有使用If-Range呢 HOT 1
- 下载超过2G多大文件时,杀进程后,再次下载无法断点续传。 HOT 2
- 报错啦,求大佬支援 HOT 2
- The current offset on block-info isn't update correct, 104466100 != 106391228 on 3
- 当文件存在时,如何覆盖当前文件下载 HOT 2
- How do I download and run this ? HOT 1
- TaskEnd while EachBlockProgress not always called
- 如何在杀了应用后,可以断点续传下载
- java.lang.IllegalStateException: The current store is com.liulishuo.okdownload.core.breakpoint.BreakpointStoreOnSQLite@11ffbcb not RemitStoreOnSQLite!
- Build Failed AGP8
- Resume failed because of RESPONSE_PRECONDITION_FAILED
- Android13 taskEnd: 1 ERROR java.io.IOException: Create parent folder failed!
- How to Download with Referer on Header HOT 1
- m.My/ HOT 1
- targetSDK升级到30后无法正常使用 HOT 10
- 不需要断点续传的单文件下载场景,可使用以下替代方案试一试
- https://m.facebook.com,au
- 当前url请求失败或者下载异常,如何通过备用url或者ip直连的方式重试, HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from okdownload.