|
@@ -32,7 +32,7 @@ import java.util.concurrent.TimeUnit;
|
|
public class BaiYiJinFuCreditService implements DockingApi {
|
|
public class BaiYiJinFuCreditService implements DockingApi {
|
|
|
|
|
|
@Resource
|
|
@Resource
|
|
- private RetryRestTemplate httpTemPlateClient;
|
|
|
|
|
|
+ private RetryRestTemplate httpRestTemplate;
|
|
|
|
|
|
@Resource
|
|
@Resource
|
|
private ProductBusinessApiInfoService apiInfoService;
|
|
private ProductBusinessApiInfoService apiInfoService;
|
|
@@ -103,7 +103,7 @@ public class BaiYiJinFuCreditService implements DockingApi {
|
|
userInfo1.setUsername(config.getString("Username"));
|
|
userInfo1.setUsername(config.getString("Username"));
|
|
userInfo1.setPassword(config.getString("Password"));
|
|
userInfo1.setPassword(config.getString("Password"));
|
|
try{
|
|
try{
|
|
- responseUrl =httpTemPlateClient.restTemplate().postForObject(tokenUrl,userInfo1, String.class);
|
|
|
|
|
|
+ responseUrl =httpRestTemplate.restTemplate().postForObject(tokenUrl,userInfo1, String.class);
|
|
}catch (Exception e){
|
|
}catch (Exception e){
|
|
log.error("佰亿金服准入异常,异常信息:{}", e.getMessage(), e);
|
|
log.error("佰亿金服准入异常,异常信息:{}", e.getMessage(), e);
|
|
}
|
|
}
|
|
@@ -123,7 +123,7 @@ public class BaiYiJinFuCreditService implements DockingApi {
|
|
head.put("Content-Type", "application/json");
|
|
head.put("Content-Type", "application/json");
|
|
head.put("Authorization", "Bearer "+token);
|
|
head.put("Authorization", "Bearer "+token);
|
|
log.info("token{},值:{}",token,"Bearer "+token);
|
|
log.info("token{},值:{}",token,"Bearer "+token);
|
|
- HttpResponse httpResponse = httpTemPlateClient.restTemplate().postForObject(url, null, null, head, null, s);
|
|
|
|
|
|
+ HttpResponse httpResponse = httpRestTemplate.restTemplate().postForObject(url, null, null, head, null, s);
|
|
String responseStr = EntityUtils.toString(httpResponse.getEntity());
|
|
String responseStr = EntityUtils.toString(httpResponse.getEntity());
|
|
response = JSONObject.parseObject(responseStr);
|
|
response = JSONObject.parseObject(responseStr);
|
|
}catch (Exception e){
|
|
}catch (Exception e){
|