From 18671c3ed6bfb9f1ca9d5418c915b29758642517 Mon Sep 17 00:00:00 2001 From: yuxueliang0813 <407010292@qq.com> Date: Tue, 25 Mar 2025 13:13:32 +0800 Subject: [PATCH] =?UTF-8?q?OA=E9=99=84=E4=BB=B6=E6=8E=A5=E5=8F=A3=E8=B6=85?= =?UTF-8?q?=E6=97=B6=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- main/java/shkd/repc/task/DobeContractAttachmentTask.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/main/java/shkd/repc/task/DobeContractAttachmentTask.java b/main/java/shkd/repc/task/DobeContractAttachmentTask.java index 0c49a77..b78457b 100644 --- a/main/java/shkd/repc/task/DobeContractAttachmentTask.java +++ b/main/java/shkd/repc/task/DobeContractAttachmentTask.java @@ -34,6 +34,8 @@ public class DobeContractAttachmentTask extends AbstractTask implements Plugin { private static final String oa_menthod = "/seeyon/rest/ats/dlNas/";//OA接口方法 public static final String oaUrl = System.getProperty("oaurl");//(测试环境外网地址)http://140.206.96.138:9091 + private static final int connectionTimeout = 5000;//5秒 + private static final int readTimeout = 60000;//60秒 public static final String updatesql = "UPDATE t_recon_contractbill SET fk_qeug_nofj=0 WHERE fid=?;"; @Override @@ -79,8 +81,8 @@ public class DobeContractAttachmentTask extends AbstractTask implements Plugin { requrl = oaUrl+oa_menthod+contractno+"?summaryId="+fj_oaid+"&subReference="+fj_zwid; logger.info(contractno+" OA附件接口请求地址\n{}", requrl); try { - // 发送get请求oa附件接口并获取响应 - resultjson = HttpClientUtils.get(requrl, customerHeader,null); + // 发送get请求oa附件接口并获取响应,目前有合同readTimeout 将此字段值修改大一点 + resultjson = HttpClientUtils.get(requrl, customerHeader,null,connectionTimeout,readTimeout); logger.info(contractno+" OA附件接口返回结果\n{}", resultjson); resultjsonObject = JSONObject.parseObject(resultjson); // 检查JSON对象是否为空