Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Connection failed with request[{Range=[bytes=-474921016-399245915]}],下载5G文件,下载了1G多,然后暂停再继续失败,应该是分片错了 #791

Closed
hongbiangoal opened this issue Oct 11, 2017 · 7 comments
Labels
Milestone

Comments

@hongbiangoal
Copy link

Before Issue

  1. Please search on the Issues
  2. Please search on the wiki
  3. Please set FileDownloadLog.NEED_LOG=true and review the Logcat output from main process and :filedownloader process ( pay attention to Warn and Error level logcat)

Issue

  1. What problem do you get?
  2. Which version of FileDownloader are you using when you produce such problem?
  3. How to reproduce such problem?
  4. Do you set FileDownloadLog.NEED_LOG=true?
  5. Could you please reproduce this problem and provide all main process and :filedownloader process logcat
  6. Can you fix it by yourself and request PR, if not, what's problem do you get when you try to fix it

P.S. If you don't know how to get :filedownloader process, it's recommended to using pidcat to just filter all your application logcat, or define process.non-separate=true on filedownloader.properties


请在Issue前认真的跟进上面提到的建议,这样将可以极大的加快你遇到问题的处理。

@hongbiangoal hongbiangoal changed the title Connection failed with request[{Range=[bytes=-474921016-399245915]}],下载5 Connection failed with request[{Range=[bytes=-474921016-399245915]}],下载5G文件,下载了1G多,然后暂停再继续失败,应该是分片错了 Oct 11, 2017
@hongbiangoal
Copy link
Author

Connection failed with request[{Range=[bytes=-474921016-399245915]}] response[{null=[HTTP/1.1 416 Requested Range Not Satisfiable], Connection=[close], Content-Length=[213], Content-Range=[bytes */5867766516], Content-Type=[text/html], Date=[Wed, 11 Oct 2017 09:20:44 GMT], Server=[nginx/1.9.12], X-Android-Received-Millis=[1507713645213], X-Android-Response-Source=[NETWORK 416], X-Android-Sent-Millis=[1507713645191]}] http-state[416] on task[-1632494122-3], which is changed after verify connection, so please try again

@Jacksgong
Copy link
Collaborator

使用的是哪个版本?

@hongbiangoal
Copy link
Author

1.6.6

@Jacksgong
Copy link
Collaborator

@hongbiangoal 确定清楚版本,这个问题在 #669 中修复过,我刚刚重新检查了代码,在1.6.2之后就不可能再遇到该问题。

@Jacksgong
Copy link
Collaborator

有任何反馈该Issue将被重新打开。

@hongbiangoal
Copy link
Author

DefaultDatabaseImpl类的findConnectionModel方法中

model.setStartOffset(c.**getInt**(c.getColumnIndex(ConnectionModel.START_OFFSET)));
model.setCurrentOffset(c.**getInt**(c.getColumnIndex(ConnectionModel.CURRENT_OFFSET)));
model.setEndOffset(c.**getInt**(c.getColumnIndex(ConnectionModel.END_OFFSET)));

我改成getLong就ok了

@Jacksgong Jacksgong reopened this Oct 12, 2017
@Jacksgong Jacksgong added bug and removed invalid labels Oct 12, 2017
@Jacksgong Jacksgong added this to the 1.6.7 milestone Oct 12, 2017
@Jacksgong
Copy link
Collaborator

@hongbiangoal 抱歉,确实存在该问题,我这边会提交一个新版本修复这个问题。


也十分欢迎直接提交PR的~

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants