🎨 #3834 【基础架构】小程序和开放平台两个模块补充了 Apache HttpClient 5.x 实现,同时并将多个模块的默认服务实现迁移至 Apache HttpClient 5.x 客户端
This commit is contained in:
@@ -4,6 +4,7 @@ import com.binarywang.solon.wxjava.mp.enums.HttpClientType;
|
||||
import com.binarywang.solon.wxjava.mp.properties.WxMpProperties;
|
||||
import me.chanjar.weixin.mp.api.WxMpService;
|
||||
import me.chanjar.weixin.mp.api.impl.WxMpServiceHttpClientImpl;
|
||||
import me.chanjar.weixin.mp.api.impl.WxMpServiceHttpComponentsImpl;
|
||||
import me.chanjar.weixin.mp.api.impl.WxMpServiceImpl;
|
||||
import me.chanjar.weixin.mp.api.impl.WxMpServiceJoddHttpImpl;
|
||||
import me.chanjar.weixin.mp.api.impl.WxMpServiceOkHttpImpl;
|
||||
@@ -35,6 +36,9 @@ public class WxMpServiceAutoConfiguration {
|
||||
case HttpClient:
|
||||
wxMpService = newWxMpServiceHttpClientImpl();
|
||||
break;
|
||||
case HttpComponents:
|
||||
wxMpService = newWxMpServiceHttpComponentsImpl();
|
||||
break;
|
||||
default:
|
||||
wxMpService = newWxMpServiceImpl();
|
||||
break;
|
||||
@@ -60,4 +64,8 @@ public class WxMpServiceAutoConfiguration {
|
||||
return new WxMpServiceJoddHttpImpl();
|
||||
}
|
||||
|
||||
private WxMpService newWxMpServiceHttpComponentsImpl() {
|
||||
return new WxMpServiceHttpComponentsImpl();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user