Skip to content

Commit 599e741

Browse files
authored
Merge pull request #391 from sxci/v7.2.18
v7.2.18
2 parents 737d106 + cb4414e commit 599e741

File tree

8 files changed

+16
-25
lines changed

8 files changed

+16
-25
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
# Changelog
22

3+
## 7.2.18 (2018-12-17)
4+
## 修正
5+
* 分片上传重试添加 crc32 校验
6+
* pili stream 管理,参数 json 格式
7+
38
## 7.2.15 (2018-09-10)
49
## 移除内部鉴权打印
510

src/main/java/com/qiniu/common/Constants.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ public final class Constants {
99
/**
1010
* 版本号
1111
*/
12-
public static final String VERSION = "7.2.17";
12+
public static final String VERSION = "7.2.18";
1313
/**
1414
* 块大小,不能改变
1515
*/

src/main/java/com/qiniu/common/QiniuException.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@ public final class QiniuException extends IOException {
1616
public QiniuException(Response response) {
1717
super(response != null ? response.getInfo() : null);
1818
this.response = response;
19+
if (response != null) {
20+
response.close();
21+
}
1922
}
2023

2124
public QiniuException(Exception e) {

src/main/java/com/qiniu/storage/BucketManager.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
import com.qiniu.http.Response;
99
import com.qiniu.storage.model.*;
1010
import com.qiniu.util.*;
11+
1112
import java.util.*;
1213

1314
/**
@@ -326,7 +327,7 @@ public Response changeType(String bucket, String key, StorageType type)
326327
*
327328
* @param bucket 空间名称
328329
* @param key 文件名称
329-
* @param status 0表示启用;1表示禁用。
330+
* @param status 0表示启用;1表示禁用。
330331
* @throws QiniuException
331332
*/
332333
public Response changeStatus(String bucket, String key, int status)

src/main/java/com/qiniu/streaming/StreamingManager.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,8 @@ public String saveAs(String streamKey, String fileName, long start, long end) th
164164
* @param end 录制结束的时间戳,单位秒
165165
* @param other 文档中指定的其它参数
166166
*/
167-
public String saveAs(String streamKey, String fileName, long start, long end, StringMap other) throws QiniuException {
167+
public String saveAs(String streamKey, String fileName, long start, long end, StringMap other)
168+
throws QiniuException {
168169
String path = encodeKey(streamKey) + "/saveas";
169170
StringMap param = other != null ? other : new StringMap();
170171
param.putNotEmpty("fname", fileName).put("start", start).put("end", end);

src/test/java/test/com/qiniu/rtc/RtcTest.java

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -10,18 +10,7 @@
1010

1111

1212
public class RtcTest {
13-
private String ak = "DXFtikq1YuD"; //AccessKey you get from qiniu
14-
private String sk = "F397hz"; //SecretKey you get from qiniu
15-
private Auth auth = null;
16-
17-
{
18-
try {
19-
auth = Auth.create(ak, sk);
20-
} catch (Exception e) {
21-
auth = TestConfig.testAuth;
22-
}
23-
}
24-
13+
private Auth auth = TestConfig.testAuth;
2514
private RtcAppManager manager = new RtcAppManager(auth);
2615
private RtcRoomManager rmanager = new RtcRoomManager(auth);
2716

src/test/java/test/com/qiniu/storage/BucketTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ public class BucketTest {
2929
};
3030

3131
@Before
32-
protected void setUp() throws Exception {
32+
public void setUp() throws Exception {
3333
//default config
3434
Configuration cfg = new Configuration();
3535
cfg.useHttpsDomains = false;

src/test/java/test/com/qiniu/streaming/StreamingTest.java

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -18,15 +18,7 @@
1818
* Created by bailong on 16/9/22
1919
*/
2020
public class StreamingTest {
21-
private Auth auth = null;
22-
23-
{
24-
try {
25-
auth = Auth.create(System.getenv("ak"), System.getenv("sk"));
26-
} catch (Exception e) {
27-
auth = TestConfig.testAuth;
28-
}
29-
}
21+
private Auth auth = TestConfig.testAuth;
3022

3123
private String hub = "pilisdktest";
3224
private String streamKeyPrefix = "pilijava" + System.currentTimeMillis();

0 commit comments

Comments
 (0)