xxl-job 将连接超时时间设为20秒
This commit is contained in:
parent
9f0b9d7d34
commit
94ef0bdc7b
@ -29,7 +29,7 @@ public class AdminBizClient implements AdminBiz {
|
||||
|
||||
private String addressUrl ;
|
||||
private String accessToken;
|
||||
private int timeout = 3;
|
||||
private int timeout = 20;
|
||||
|
||||
|
||||
@Override
|
||||
|
@ -86,7 +86,7 @@ public class XxlJobRemotingUtil {
|
||||
connection.setDoInput(true);
|
||||
connection.setUseCaches(false);
|
||||
connection.setReadTimeout(timeout * 1000);
|
||||
connection.setConnectTimeout(3 * 1000);
|
||||
connection.setConnectTimeout(20 * 1000);
|
||||
connection.setRequestProperty("connection", "Keep-Alive");
|
||||
connection.setRequestProperty("Content-Type", "application/json;charset=UTF-8");
|
||||
connection.setRequestProperty("Accept-Charset", "application/json;charset=UTF-8");
|
||||
|
Loading…
Reference in New Issue
Block a user