From ee5ee6e080cf8e90a60c44e729bddf1e0f3cc31f Mon Sep 17 00:00:00 2001 From: laoyuyu <511455842@qq.com> Date: Thu, 28 Nov 2019 09:58:53 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0m3u8=E5=AF=86=E9=92=A5url?= =?UTF-8?q?=E8=BD=AC=E6=8D=A2=E5=99=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- DEV_LOG.md | 3 ++- .../com/arialyy/aria/m3u8/M3U8InfoThread.java | 4 ++++ .../arialyy/aria/core/TaskOptionParams.java | 2 ++ README.md | 24 ++++++++++++------- app/src/main/assets/aria_config.xml | 2 +- .../download/m3u8/M3U8VodDLoadActivity.java | 10 ++++++++ build.gradle | 2 +- 7 files changed, 35 insertions(+), 12 deletions(-) diff --git a/DEV_LOG.md b/DEV_LOG.md index 550522d4..2fa357ca 100644 --- a/DEV_LOG.md +++ b/DEV_LOG.md @@ -1,9 +1,10 @@ ## 开发日志 - + v_3.7.8 + + v_3.7.8 (2019/11/28) - fix bug https://github.com/AriaLyy/Aria/issues/526 - fix bug https://github.com/AriaLyy/Aria/issues/533 - fix bug https://github.com/AriaLyy/Aria/issues/535 - 修复ftp无法完成下载的问题 + - 修复一个非分块模式下,调用`updateUrl(newUrl)`后无法恢复下载的问题 - 增加立即恢复任务的接口,正常来说,当执行队列满时,调用恢复任务接口,只能将任务放到缓存队列中。如果希望调用恢复接口,马上进入执行队列,需要调用`resume(true)`这个重载方法。 - 增加M3U8加密密钥的下载地址转换器 https://github.com/AriaLyy/Aria/issues/522 + v_3.7.7 (2019/11/20) diff --git a/M3U8Component/src/main/java/com/arialyy/aria/m3u8/M3U8InfoThread.java b/M3U8Component/src/main/java/com/arialyy/aria/m3u8/M3U8InfoThread.java index d92589b8..4c92af17 100644 --- a/M3U8Component/src/main/java/com/arialyy/aria/m3u8/M3U8InfoThread.java +++ b/M3U8Component/src/main/java/com/arialyy/aria/m3u8/M3U8InfoThread.java @@ -360,6 +360,10 @@ final public class M3U8InfoThread implements Runnable { if (keyUrlConverter != null) { keyUrl = keyUrlConverter.convert(keyUrl); } + if (TextUtils.isEmpty(keyUrl)){ + ALog.e(TAG, "m3u8密钥key url 为空"); + return; + } URL url = ConnectionHelp.handleUrl(keyUrl, mHttpOption); conn = ConnectionHelp.handleConnection(url, mHttpOption); diff --git a/PublicComponent/src/main/java/com/arialyy/aria/core/TaskOptionParams.java b/PublicComponent/src/main/java/com/arialyy/aria/core/TaskOptionParams.java index 4d3a0f59..0e188919 100644 --- a/PublicComponent/src/main/java/com/arialyy/aria/core/TaskOptionParams.java +++ b/PublicComponent/src/main/java/com/arialyy/aria/core/TaskOptionParams.java @@ -22,6 +22,7 @@ import com.arialyy.aria.core.processor.FtpInterceptHandler; import com.arialyy.aria.core.processor.IBandWidthUrlConverter; import com.arialyy.aria.core.processor.IFtpUploadInterceptor; import com.arialyy.aria.core.processor.IHttpFileLenAdapter; +import com.arialyy.aria.core.processor.IKeyUrlConverter; import com.arialyy.aria.core.processor.ILiveTsUrlConverter; import com.arialyy.aria.core.processor.ITsMergeHandler; import com.arialyy.aria.core.processor.IVodTsUrlConverter; @@ -61,6 +62,7 @@ public class TaskOptionParams { PROCESSORES.add(ILiveTsUrlConverter.class); PROCESSORES.add(ITsMergeHandler.class); PROCESSORES.add(IVodTsUrlConverter.class); + PROCESSORES.add(IKeyUrlConverter.class); } /** diff --git a/README.md b/README.md index 36343c40..1885981c 100644 --- a/README.md +++ b/README.md @@ -44,16 +44,16 @@ Aria有以下特点: ## 引入库 [![license](http://img.shields.io/badge/license-Apache2.0-brightgreen.svg?style=flat)](https://github.com/AriaLyy/Aria/blob/master/LICENSE) -[![Core](https://img.shields.io/badge/Core-3.7.8-pre-1-blue)](https://github.com/AriaLyy/Aria) -[![Compiler](https://img.shields.io/badge/Compiler-3.7.8-pre-1-blue)](https://github.com/AriaLyy/Aria) -[![FtpComponent](https://img.shields.io/badge/FtpComponent-3.7.8-pre-1-orange)](https://github.com/AriaLyy/Aria) -[![M3U8Component](https://img.shields.io/badge/M3U8Component-3.7.8-pre-1-orange)](https://github.com/AriaLyy/Aria) +[![Core](https://img.shields.io/badge/Core-3.7.8-blue)](https://github.com/AriaLyy/Aria) +[![Compiler](https://img.shields.io/badge/Compiler-3.7.8-blue)](https://github.com/AriaLyy/Aria) +[![FtpComponent](https://img.shields.io/badge/FtpComponent-3.7.8-orange)](https://github.com/AriaLyy/Aria) +[![M3U8Component](https://img.shields.io/badge/M3U8Component-3.7.8-orange)](https://github.com/AriaLyy/Aria) ```java -implementation 'com.arialyy.aria:core:3.7.8-pre-3' -annotationProcessor 'com.arialyy.aria:compiler:3.7.8-pre-3' -implementation 'com.arialyy.aria:ftpComponent:3.7.8-pre-3' # 如果需要使用ftp,请增加该组件 -implementation 'com.arialyy.aria:m3u8Component:3.7.8-pre-3' # 如果需要使用m3u8下载功能,请增加该组件 +implementation 'com.arialyy.aria:core:3.7.8' +annotationProcessor 'com.arialyy.aria:compiler:3.7.8' +implementation 'com.arialyy.aria:ftpComponent:3.7.8' # 如果需要使用ftp,请增加该组件 +implementation 'com.arialyy.aria:m3u8Component:3.7.8' # 如果需要使用m3u8下载功能,请增加该组件 ``` 如果出现android support依赖错误,请将 `compile 'com.arialyy.aria:core:'`替换为 ``` @@ -137,8 +137,14 @@ protected void onCreate(Bundle savedInstanceState) { ### 版本日志 - + v_3.7.8-pre-1 (2019/11/20) + + v_3.7.8 (2019/11/28) - fix bug https://github.com/AriaLyy/Aria/issues/526 + - fix bug https://github.com/AriaLyy/Aria/issues/533 + - fix bug https://github.com/AriaLyy/Aria/issues/535 + - 修复ftp无法完成下载的问题 + - 修复一个非分块模式下,调用`updateUrl(newUrl)`后无法恢复下载的问题 + - 增加立即恢复任务的接口,正常来说,当执行队列满时,调用恢复任务接口,只能将任务放到缓存队列中。如果希望调用恢复接口,马上进入执行队列,需要调用`resume(true)`这个重载方法。 + - 增加M3U8加密密钥的下载地址转换器 https://github.com/AriaLyy/Aria/issues/522 [更多版本记录](https://github.com/AriaLyy/Aria/blob/master/DEV_LOG.md) diff --git a/app/src/main/assets/aria_config.xml b/app/src/main/assets/aria_config.xml index e4ea2d42..cb8d1c24 100644 --- a/app/src/main/assets/aria_config.xml +++ b/app/src/main/assets/aria_config.xml @@ -32,7 +32,7 @@ 3、只对新的多线程下载任务有效 4、只对多线程的任务有效 --> - +