3.8.7
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
## 开发日志
|
## 开发日志
|
||||||
+ v_3.8.7
|
+ v_3.8.7 (2020/5/25)
|
||||||
- 修复组合任务单个子任务失败后,重新恢复组合任务,组合任务状态变为完成的问题
|
- 修复组合任务单个子任务失败后,重新恢复组合任务,组合任务状态变为完成的问题
|
||||||
- 修复40x错误,会继续重试并且无法重试成功的问题 https://github.com/AriaLyy/Aria/issues/619
|
- 修复40x错误,会继续重试并且无法重试成功的问题 https://github.com/AriaLyy/Aria/issues/619
|
||||||
- 修复wait模式下,resume(true)无效问题
|
- 修复wait模式下,resume(true)无效问题
|
||||||
|
|||||||
@@ -291,6 +291,10 @@ final class HttpDFileInfoTask implements IInfoTask, Runnable {
|
|||||||
ALog.d(TAG, String.format("文件重命名为:%s", newName));
|
ALog.d(TAG, String.format("文件重命名为:%s", newName));
|
||||||
File oldFile = new File(mEntity.getFilePath());
|
File oldFile = new File(mEntity.getFilePath());
|
||||||
String newPath = oldFile.getParent() + "/" + newName;
|
String newPath = oldFile.getParent() + "/" + newName;
|
||||||
|
if (!CheckUtil.checkDPathConflicts(false, newPath, mTaskWrapper.getRequestType())) {
|
||||||
|
ALog.e(TAG, "文件重命名失败");
|
||||||
|
return;
|
||||||
|
}
|
||||||
if (oldFile.exists()) {
|
if (oldFile.exists()) {
|
||||||
boolean b = oldFile.renameTo(new File(newPath));
|
boolean b = oldFile.renameTo(new File(newPath));
|
||||||
ALog.d(TAG, String.format("文件重命名%s", b ? "成功" : "失败"));
|
ALog.d(TAG, String.format("文件重命名%s", b ? "成功" : "失败"));
|
||||||
|
|||||||
@@ -150,7 +150,7 @@ class DelegateUpdate extends AbsDelegate {
|
|||||||
*/
|
*/
|
||||||
private ContentValues createValues(DbEntity dbEntity) {
|
private ContentValues createValues(DbEntity dbEntity) {
|
||||||
List<Field> fields = CommonUtil.getAllFields(dbEntity.getClass());
|
List<Field> fields = CommonUtil.getAllFields(dbEntity.getClass());
|
||||||
if (fields != null && fields.size() > 0) {
|
if (fields.size() > 0) {
|
||||||
ContentValues values = new ContentValues();
|
ContentValues values = new ContentValues();
|
||||||
try {
|
try {
|
||||||
for (Field field : fields) {
|
for (Field field : fields) {
|
||||||
|
|||||||
@@ -148,6 +148,14 @@ final class SqlHelper extends SQLiteOpenHelper {
|
|||||||
return db;
|
return db;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override public SQLiteDatabase getWritableDatabase() {
|
||||||
|
if (!mainTmpDirSet) {
|
||||||
|
createDbCacheDir();
|
||||||
|
return super.getWritableDatabase();
|
||||||
|
}
|
||||||
|
return super.getWritableDatabase();
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 用于修复 Too many open files 的问题
|
* 用于修复 Too many open files 的问题
|
||||||
* https://github.com/AriaLyy/Aria/issues/664
|
* https://github.com/AriaLyy/Aria/issues/664
|
||||||
@@ -155,15 +163,19 @@ final class SqlHelper extends SQLiteOpenHelper {
|
|||||||
@Override
|
@Override
|
||||||
public SQLiteDatabase getReadableDatabase() {
|
public SQLiteDatabase getReadableDatabase() {
|
||||||
if (!mainTmpDirSet) {
|
if (!mainTmpDirSet) {
|
||||||
|
createDbCacheDir();
|
||||||
|
return super.getReadableDatabase();
|
||||||
|
}
|
||||||
|
return super.getReadableDatabase();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void createDbCacheDir() {
|
||||||
String cacheDir = mContext.getCacheDir().getPath() + "/AriaDbCacheDir";
|
String cacheDir = mContext.getCacheDir().getPath() + "/AriaDbCacheDir";
|
||||||
boolean rs = new File(cacheDir).mkdir();
|
boolean rs = new File(cacheDir).mkdir();
|
||||||
ALog.d(TAG, rs + "");
|
ALog.d(TAG, rs + "");
|
||||||
super.getReadableDatabase()
|
super.getReadableDatabase()
|
||||||
.execSQL("PRAGMA temp_store_directory = '" + cacheDir + "'");
|
.execSQL("PRAGMA temp_store_directory = '" + cacheDir + "'");
|
||||||
mainTmpDirSet = true;
|
mainTmpDirSet = true;
|
||||||
return super.getReadableDatabase();
|
|
||||||
}
|
|
||||||
return super.getReadableDatabase();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
38
README.md
38
README.md
@@ -45,19 +45,19 @@ Aria有以下特点:
|
|||||||
|
|
||||||
## 引入库
|
## 引入库
|
||||||
[](https://github.com/AriaLyy/Aria/blob/master/LICENSE)
|
[](https://github.com/AriaLyy/Aria/blob/master/LICENSE)
|
||||||
[](https://github.com/AriaLyy/Aria)
|
[](https://github.com/AriaLyy/Aria)
|
||||||
[](https://github.com/AriaLyy/Aria)
|
[](https://github.com/AriaLyy/Aria)
|
||||||
[](https://github.com/AriaLyy/Aria)
|
[](https://github.com/AriaLyy/Aria)
|
||||||
[](https://github.com/AriaLyy/Aria)
|
[](https://github.com/AriaLyy/Aria)
|
||||||
[](https://github.com/AriaLyy/Aria)
|
[](https://github.com/AriaLyy/Aria)
|
||||||
|
|
||||||
|
|
||||||
```java
|
```java
|
||||||
implementation 'com.arialyy.aria:core:3.8.6'
|
implementation 'com.arialyy.aria:core:3.8.7'
|
||||||
annotationProcessor 'com.arialyy.aria:compiler:3.8.6'
|
annotationProcessor 'com.arialyy.aria:compiler:3.8.7'
|
||||||
implementation 'com.arialyy.aria:ftpComponent:3.8.6' # 如果需要使用ftp,请增加该组件
|
implementation 'com.arialyy.aria:ftpComponent:3.8.7' # 如果需要使用ftp,请增加该组件
|
||||||
implementation 'com.arialyy.aria:sftpComponent:3.8.6' # 如果需要使用ftp,请增加该组件
|
implementation 'com.arialyy.aria:sftpComponent:3.8.7' # 如果需要使用ftp,请增加该组件
|
||||||
implementation 'com.arialyy.aria:m3u8Component:3.8.6' # 如果需要使用m3u8下载功能,请增加该组件
|
implementation 'com.arialyy.aria:m3u8Component:3.8.7' # 如果需要使用m3u8下载功能,请增加该组件
|
||||||
```
|
```
|
||||||
|
|
||||||
如果你使用的是kotlin,请使用kotlin官方提供的方法配置apt,[kotlin kapt官方配置传送门](https://www.kotlincn.net/docs/reference/kapt.html)
|
如果你使用的是kotlin,请使用kotlin官方提供的方法配置apt,[kotlin kapt官方配置传送门](https://www.kotlincn.net/docs/reference/kapt.html)
|
||||||
@@ -138,13 +138,17 @@ protected void onCreate(Bundle savedInstanceState) {
|
|||||||
|
|
||||||
|
|
||||||
### 版本日志
|
### 版本日志
|
||||||
+ v_3.8.6 (2020/2/18)
|
+ v_3.8.7 (2020/5/25)
|
||||||
- fix bug https://github.com/AriaLyy/Aria/issues/608
|
- 修复组合任务单个子任务失败后,重新恢复组合任务,组合任务状态变为完成的问题
|
||||||
- fix bug https://github.com/AriaLyy/Aria/issues/579#issuecomment-586665035
|
- 修复40x错误,会继续重试并且无法重试成功的问题 https://github.com/AriaLyy/Aria/issues/619
|
||||||
- fix bug https://github.com/AriaLyy/Aria/issues/610
|
- 修复wait模式下,resume(true)无效问题
|
||||||
- fix bug https://github.com/AriaLyy/Aria/issues/614
|
- 修复now模式下的一些问题 https://github.com/AriaLyy/Aria/issues/620
|
||||||
- 增加文件名适配器(感谢小伙伴[DaveBoy](https://github.com/DaveBoy)的PR)
|
- 修复组任务,其中一个子任务在获取文件长度失败后,重新恢复组合任务,组合任务状态变为完成的问题 https://github.com/AriaLyy/Aria/issues/628
|
||||||
- 优化异常提示
|
- 修复组任务中,其中一个子任务是30x地址,导致调度器无法出现该子任务状态的问题
|
||||||
|
- 增加组任务groupHash冲突检查 https://github.com/AriaLyy/Aria/issues/635
|
||||||
|
- 修复task.cancel(false)还是把本地文件删除的问题 https://github.com/AriaLyy/Aria/issues/646
|
||||||
|
- fix bug https://github.com/AriaLyy/Aria/issues/670
|
||||||
|
- fix bug https://github.com/AriaLyy/Aria/issues/664
|
||||||
|
|
||||||
[更多版本记录](https://github.com/AriaLyy/Aria/blob/master/DEV_LOG.md)
|
[更多版本记录](https://github.com/AriaLyy/Aria/blob/master/DEV_LOG.md)
|
||||||
|
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ task clean(type: Delete) {
|
|||||||
|
|
||||||
ext {
|
ext {
|
||||||
versionCode = 387
|
versionCode = 387
|
||||||
versionName = '3.8.7-beta-12'
|
versionName = '3.8.7'
|
||||||
userOrg = 'arialyy'
|
userOrg = 'arialyy'
|
||||||
groupId = 'com.arialyy.aria'
|
groupId = 'com.arialyy.aria'
|
||||||
publishVersion = versionName
|
publishVersion = versionName
|
||||||
|
|||||||
Reference in New Issue
Block a user