|
@@ -68,7 +68,8 @@ public class AigcServiceImpl implements AigcService {
|
|
|
public LongArticleSystemContentVO listWaitingMatchMiniprogramContents(GetContentsParam param) {
|
|
|
String apiUrl = "http://aigc-api.cybertogether.net/aigc/publish/LongArticleSystem/listWaitingMatchMiniprogramContents";
|
|
|
try {
|
|
|
- String res = HTTP_POOL_CLIENT_UTIL_DEFAULT.post(apiUrl, JSON.toJSONString(param));
|
|
|
+ HttpPoolClientUtil httpPoolClientUtil = HttpClientUtil.create(5000, 8000, 5, 10, 3, 3000);
|
|
|
+ String res = httpPoolClientUtil.post(apiUrl, JSON.toJSONString(param));
|
|
|
JSONObject jsonObject = JSON.parseObject(res);
|
|
|
Integer code = jsonObject.getInteger("code");
|
|
|
if (code == 0) {
|
|
@@ -84,7 +85,8 @@ public class AigcServiceImpl implements AigcService {
|
|
|
public LongArticleSystemContentVO listWaitingSortContents(GetContentsParam param) {
|
|
|
String apiUrl = "http://aigc-api.cybertogether.net/aigc/publish/LongArticleSystem/listWaitingSortContents";
|
|
|
try {
|
|
|
- String res = HTTP_POOL_CLIENT_UTIL_DEFAULT.post(apiUrl, JSON.toJSONString(param));
|
|
|
+ HttpPoolClientUtil httpPoolClientUtil = HttpClientUtil.create(5000, 200000, 5, 10, 3, 3000);
|
|
|
+ String res = httpPoolClientUtil.post(apiUrl, JSON.toJSONString(param));
|
|
|
JSONObject jsonObject = JSON.parseObject(res);
|
|
|
Integer code = jsonObject.getInteger("code");
|
|
|
if (code == 0) {
|
|
@@ -101,7 +103,8 @@ public class AigcServiceImpl implements AigcService {
|
|
|
public String createPushTask(CreatePushTaskParam param) {
|
|
|
String apiUrl = "http://aigc-api.cybertogether.net/aigc/publish/LongArticleSystem/createPushTask";
|
|
|
try {
|
|
|
- String res = HTTP_POOL_CLIENT_UTIL_DEFAULT.post(apiUrl, JSON.toJSONString(param));
|
|
|
+ HttpPoolClientUtil httpPoolClientUtil = HttpClientUtil.create(5000, 8000, 5, 10, 3, 3000);
|
|
|
+ String res = httpPoolClientUtil.post(apiUrl, JSON.toJSONString(param));
|
|
|
JSONObject jsonObject = JSON.parseObject(res);
|
|
|
Integer code = jsonObject.getInteger("code");
|
|
|
if (code == 0) {
|
|
@@ -118,7 +121,8 @@ public class AigcServiceImpl implements AigcService {
|
|
|
public boolean updateMatchMiniprogramStatus(MatchMiniprogramStatusParam param) {
|
|
|
String apiUrl = "http://aigc-api.cybertogether.net/aigc/publish/LongArticleSystem/updateMatchMiniprogramStatus";
|
|
|
try {
|
|
|
- String res = HTTP_POOL_CLIENT_UTIL_DEFAULT.post(apiUrl, JSON.toJSONString(param));
|
|
|
+ HttpPoolClientUtil httpPoolClientUtil = HttpClientUtil.create(5000, 8000, 5, 10, 3, 3000);
|
|
|
+ String res = httpPoolClientUtil.post(apiUrl, JSON.toJSONString(param));
|
|
|
JSONObject jsonObject = JSON.parseObject(res);
|
|
|
Integer code = jsonObject.getInteger("code");
|
|
|
if (code == 0) {
|
|
@@ -134,7 +138,8 @@ public class AigcServiceImpl implements AigcService {
|
|
|
public boolean filterSortContents(FilterSortParam param) {
|
|
|
String apiUrl = "http://aigc-api.cybertogether.net/aigc/publish/LongArticleSystem/filterSortContents";
|
|
|
try {
|
|
|
- String res = HTTP_POOL_CLIENT_UTIL_DEFAULT.post(apiUrl, JSON.toJSONString(param));
|
|
|
+ HttpPoolClientUtil httpPoolClientUtil = HttpClientUtil.create(5000, 8000, 5, 10, 3, 3000);
|
|
|
+ String res = httpPoolClientUtil.post(apiUrl, JSON.toJSONString(param));
|
|
|
JSONObject jsonObject = JSON.parseObject(res);
|
|
|
Integer code = jsonObject.getInteger("code");
|
|
|
if (code == 0) {
|
|
@@ -169,10 +174,11 @@ public class AigcServiceImpl implements AigcService {
|
|
|
}
|
|
|
String apiUrl = "http://aigc-api.cybertogether.net/aigc//publish/LongArticleSystem/uploadMiniprogramCover";
|
|
|
try {
|
|
|
+ HttpPoolClientUtil httpPoolClientUtil = HttpClientUtil.create(5000, 8000, 5, 10, 3, 3000);
|
|
|
JSONObject param = new JSONObject();
|
|
|
param.put("coverUrl", coverUrl);
|
|
|
param.put("publishContentId", publishContentId);
|
|
|
- String res = HTTP_POOL_CLIENT_UTIL_DEFAULT.post(apiUrl, JSONObject.toJSONString(param));
|
|
|
+ String res = httpPoolClientUtil.post(apiUrl, JSONObject.toJSONString(param));
|
|
|
JSONObject jsonObject = JSON.parseObject(res);
|
|
|
Integer code = jsonObject.getInteger("code");
|
|
|
if (code == 0) {
|