Просмотр исходного кода

//update log

release_toaliyun_real
xhxu 4 лет назад
Родитель
Сommit
baab18a432
2 измененных файлов: 8 добавлений и 4 удалений
  1. +4
    -2
      mallinkService/src/main/java/com/iformall/douyin/web/api/TtWebGetRequestExecutor.java
  2. +4
    -2
      mallinkService/src/main/java/com/iformall/douyin/web/api/TtWebPostRequestExecutor.java

+ 4
- 2
mallinkService/src/main/java/com/iformall/douyin/web/api/TtWebGetRequestExecutor.java Просмотреть файл

@@ -45,8 +45,7 @@ public class TtWebGetRequestExecutor implements RequestExecutor<String, String>

@Override
public String execute(String uri, String queryParam, WxType wxType) throws WxErrorException, IOException {
logger.info("uri{}"+uri);
logger.info("request{}"+queryParam);

String access_token = handleUrl(uri);
if(StringUtils.isBlank(access_token)){
WxError wxError = WxError.fromJson("{\n" +
@@ -66,6 +65,9 @@ public class TtWebGetRequestExecutor implements RequestExecutor<String, String>
HttpGet httpGet = new HttpGet(uri);
httpGet.addHeader("Content-Type","application/json");
httpGet.addHeader("access-token",access_token);
logger.info("get请求地址uri{}"+uri);
logger.info("header-----access_token{}"+access_token);

if (requestHttp.getRequestHttpProxy() != null) {
RequestConfig config = RequestConfig.custom().setProxy(requestHttp.getRequestHttpProxy()).build();
httpGet.setConfig(config);


+ 4
- 2
mallinkService/src/main/java/com/iformall/douyin/web/api/TtWebPostRequestExecutor.java Просмотреть файл

@@ -46,8 +46,7 @@ public class TtWebPostRequestExecutor implements RequestExecutor<String, String>

@Override
public String execute(String uri, String postEntity, WxType wxType) throws WxErrorException, IOException {
logger.info("uri{}"+uri);
logger.info("request{}"+postEntity);

String access_token = handleUrl(uri);
if(StringUtils.isBlank(access_token)){
WxError wxError = WxError.fromJson("{\n" +
@@ -60,6 +59,9 @@ public class TtWebPostRequestExecutor implements RequestExecutor<String, String>
HttpPost httpPost = new HttpPost(uri);
httpPost.addHeader("Content-Type","application/json");
httpPost.addHeader("access-token",access_token);
logger.info("post请求地址uri{}"+uri);
logger.info("header-----access_token{}"+access_token);
logger.info("请求参数{}"+postEntity);

if (requestHttp.getRequestHttpProxy() != null) {
RequestConfig config = RequestConfig.custom().setProxy(requestHttp.getRequestHttpProxy()).build();


Загрузка…
Отмена
Сохранить