Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
midjourney-proxy
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
徐少华
midjourney-proxy
Commits
61abed3f
Commit
61abed3f
authored
Aug 31, 2021
by
田超
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'fixbug/1005354' into 'master'
bug: [1005354] 生产error处理 See merge request rays/pcloud-book!1393
parents
a66c0ac8
a4755935
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
34 additions
and
13 deletions
+34
-13
BookConstant.java
...main/java/com/pcloud/book/book/constant/BookConstant.java
+5
-0
AnswerSubscribeBizImpl.java
...m/pcloud/book/applet/biz/impl/AnswerSubscribeBizImpl.java
+6
-1
AppletThirdResourcesStaticBizImpl.java
...ok/applet/biz/impl/AppletThirdResourcesStaticBizImpl.java
+3
-2
BookAdviserBizImpl.java
...ava/com/pcloud/book/book/biz/impl/BookAdviserBizImpl.java
+1
-1
BookBizImpl.java
.../main/java/com/pcloud/book/book/biz/impl/BookBizImpl.java
+4
-0
BookGroupBizImpl.java
...java/com/pcloud/book/group/biz/impl/BookGroupBizImpl.java
+4
-4
ResourcePageBizImpl.java
...a/com/pcloud/book/group/biz/impl/ResourcePageBizImpl.java
+3
-0
PushBizImpl.java
.../main/java/com/pcloud/book/push/biz/impl/PushBizImpl.java
+3
-5
ThreadPoolUtils.java
...ain/java/com/pcloud/book/util/common/ThreadPoolUtils.java
+5
-0
No files found.
pcloud-facade-book/src/main/java/com/pcloud/book/book/constant/BookConstant.java
View file @
61abed3f
...
...
@@ -449,4 +449,9 @@ public class BookConstant {
public
static
String
IGNOR_BOOK_KEY
=
CacheConstant
.
BOOK
+
"ignorBookKey"
;
/**
* qq公众号
*/
public
static
final
Long
QQ_ACCOUNT_SETTING_ID
=
999L
;
}
pcloud-service-book/src/main/java/com/pcloud/book/applet/biz/impl/AnswerSubscribeBizImpl.java
View file @
61abed3f
...
...
@@ -43,6 +43,8 @@ import java.util.Map;
import
lombok.extern.slf4j.Slf4j
;
import
static
com
.
pcloud
.
book
.
book
.
constant
.
BookConstant
.
QQ_ACCOUNT_SETTING_ID
;
/**
* @ClassName com.pcloud.book.applet.biz.impl.AnswerSubscribeBizImpl
* @Author zhuyajie
...
...
@@ -294,6 +296,10 @@ public class AnswerSubscribeBizImpl implements AnswerSubscribeBiz {
@Override
public
AnswerSubscribeDTO
getSubscribeQrcodeState
(
Long
wechatUserId
,
Long
accountSettingId
)
{
AnswerSubscribeDTO
dto
=
new
AnswerSubscribeDTO
();
if
(
QQ_ACCOUNT_SETTING_ID
.
equals
(
accountSettingId
))
{
return
dto
;
}
String
openId
=
readerConsr
.
getOpenIdByWechatUserIdAndOfficialAccountsId
(
wechatUserId
,
accountSettingId
);
WechatUserOfficialAccounts
accounts
=
readerConsr
.
getOfficialAccounts
(
accountSettingId
,
openId
,
wechatUserId
);
Boolean
isSubscribe
=
false
;
...
...
@@ -301,7 +307,6 @@ public class AnswerSubscribeBizImpl implements AnswerSubscribeBiz {
isSubscribe
=
accounts
.
getIsSubscribe
()
==
1
?
true
:
false
;
}
GroupQrcodeVO
groupQrcodeVO
=
qrcodeSceneConsr
.
getSubscribeQrcode
(
accountSettingId
);
AnswerSubscribeDTO
dto
=
new
AnswerSubscribeDTO
();
dto
.
setQrcodeUrl
(
groupQrcodeVO
.
getQrcodeUrl
());
dto
.
setIsSubscribe
(
isSubscribe
);
return
dto
;
...
...
pcloud-service-book/src/main/java/com/pcloud/book/applet/biz/impl/AppletThirdResourcesStaticBizImpl.java
View file @
61abed3f
...
...
@@ -91,7 +91,8 @@ public class AppletThirdResourcesStaticBizImpl implements AppletThirdResourcesSt
@Override
@ParamLog
(
"获取跟谁学统计数据"
)
public
void
getAppletThirdResourceStatic
(
Integer
isAll
)
{
PageBeanNew
pageBeanNew
=
null
;
//20210831 接口调用不通 ,暂停调用
/*PageBeanNew pageBeanNew = null;
//PageBeanNew pageBeanNew = appletThirdResourcesStaticDao.listPageNew(new PageParam(0, 10), null, "getList");
if (null != pageBeanNew && !ListUtils.isEmpty(pageBeanNew.getRecordList()) && YesOrNoEnums.YES.getValue().equals(isAll)) {
throw new BookBizException(BookBizException.ERROR, "当统计数据表不为空时不能导入全部数据只能导入昨日数据");
...
...
@@ -134,7 +135,7 @@ public class AppletThirdResourcesStaticBizImpl implements AppletThirdResourcesSt
} catch (ParseException e) {
LOGGER.error("获取跟谁学统计数据失败", e);
}
}
}
*/
}
...
...
pcloud-service-book/src/main/java/com/pcloud/book/book/biz/impl/BookAdviserBizImpl.java
View file @
61abed3f
...
...
@@ -1608,7 +1608,7 @@ public class BookAdviserBizImpl implements BookAdviserBiz {
Map
<
String
,
BookAdviserDto
>
bookAdviserDtoMap
=
new
HashMap
<>();
try
{
bookAdviserDtoMap
=
bookAdviserSubmit
.
get
(
ThreadPoolUtils
.
REMOTE_TIME_OUT
,
TimeUnit
.
SECONDS
);
bookAdviserDtoMap
=
bookAdviserSubmit
.
get
(
ThreadPoolUtils
.
REMOTE_TIME_OUT
_LONG
,
TimeUnit
.
SECONDS
);
}
catch
(
InterruptedException
|
ExecutionException
|
TimeoutException
e
)
{
LOGGER
.
error
(
"获取现代纸书是否小睿流程错误: {}=="
,
e
);
}
...
...
pcloud-service-book/src/main/java/com/pcloud/book/book/biz/impl/BookBizImpl.java
View file @
61abed3f
...
...
@@ -118,6 +118,7 @@ import com.pcloud.usercenter.party.adviser.dto.AdviserBaseInfoDto;
import
com.pcloud.usercenter.party.agent.dto.SaleAgentDTO
;
import
org.apache.commons.collections.MapUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.lucene.queryparser.classic.QueryParser
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.BeanUtils
;
...
...
@@ -2740,6 +2741,9 @@ public class BookBizImpl implements BookBiz {
if
(
null
!=
agentId
)
{
adviserIds
=
adviserConsr
.
getByAgentId
(
agentId
);
}
if
(!
StringUtil
.
isEmpty
(
keyword
))
{
keyword
=
QueryParser
.
escape
(
keyword
);
}
Page
<
ESBookAndAdviser
>
esPage
=
esBookAndAdviserBiz
.
getESAdviserBooks4AppletV2
(
grayStatus
,
keyword
,
templetIds
,
graLabelIds
,
subLabelIds
,
currentPage
,
numPerPage
,
scecondTempletIds
,
adviserIds
,
agentId
);
...
...
pcloud-service-book/src/main/java/com/pcloud/book/group/biz/impl/BookGroupBizImpl.java
View file @
61abed3f
...
...
@@ -5103,11 +5103,11 @@ public class BookGroupBizImpl implements BookGroupBiz {
}
Long
raysClassifyId
=
null
;
BookAdviserDto
bookAdviserDto
=
bookAdviserDao
.
getBase
(
bookId
,
channelId
,
adviserId
);
if
(
null
!=
bookAdviserDto
)
{
if
(
null
!=
bookAdviserDto
&&
null
!=
bookAdviserDto
.
getTempletId
()
)
{
raysClassifyId
=
bookRaysClassifyDao
.
getClassifyIdByBookTemplateId
(
bookAdviserDto
.
getTempletId
());
}
if
(
null
==
raysClassifyId
)
{
LOGGER
.
error
(
"书刊分类没有对应的小睿分类"
+
bookGroupId
);
if
(
null
==
raysClassifyId
)
{
LOGGER
.
warn
(
"书刊分类没有对应的小睿分类"
+
bookGroupId
);
}
}
String
page
=
null
;
//小程序跳转页 todo
String
appletId
=
createOneAppletId
();
...
...
pcloud-service-book/src/main/java/com/pcloud/book/group/biz/impl/ResourcePageBizImpl.java
View file @
61abed3f
...
...
@@ -1798,6 +1798,9 @@ public class ResourcePageBizImpl implements ResourcePageBiz {
course
.
setTypeName
(
dto
.
getTypeName
());
course
.
setAgentId
(
dto
.
getAgencyId
());
course
.
setChannelId
(
dto
.
getChannelId
());
course
.
setProLabelId
(
dto
.
getProLableId
());
course
.
setDepLableId
(
dto
.
getDepLableId
());
course
.
setPurLabelId
(
dto
.
getPurLableId
());
...
...
pcloud-service-book/src/main/java/com/pcloud/book/push/biz/impl/PushBizImpl.java
View file @
61abed3f
...
...
@@ -322,7 +322,7 @@ public class PushBizImpl implements PushBiz {
//获取群信息
GroupQrcode
groupQrcode
=
groupQrcodeDao
.
getById
(
pushGroup
.
getBookGroupQrcodeId
());
if
(
groupQrcode
==
null
)
{
LOGGER
.
error
(
"未找到群信息!qrcodeId="
+
pushGroup
.
getBookGroupQrcodeId
());
LOGGER
.
warn
(
"未找到群信息!qrcodeId="
+
pushGroup
.
getBookGroupQrcodeId
());
continue
;
}
//获取机器人微信号
...
...
@@ -334,9 +334,8 @@ public class PushBizImpl implements PushBiz {
LOGGER
.
info
(
"发送一个群里的一个消息结束,休眠1秒pushGroup="
+
pushGroup
.
toString
()
+
"pushItem="
+
pushItem
.
toString
()
+
"altId="
+
altId
);
Thread
.
sleep
(
1000
);
}
catch
(
InterruptedException
e
)
{
LOGGER
.
error
(
"发消息休眠1秒出错"
,
e
);
LOGGER
.
warn
(
"发消息休眠1秒出错"
);
}
}
}
}
...
...
@@ -349,8 +348,7 @@ public class PushBizImpl implements PushBiz {
//获取群信息
GroupQrcode
groupQrcode
=
groupQrcodeDao
.
getById
(
pushGroup
.
getBookGroupQrcodeId
());
if
(
groupQrcode
==
null
)
{
LOGGER
.
error
(
"未找到群信息!"
);
return
;
throw
new
BookBizException
(
BookBizException
.
PARAM_IS_NULL
,
"未找到群信息"
);
}
String
groupId
=
groupQrcode
.
getWeixinGroupId
();
ClassifyDTO
classifyDTO
=
bookGroupClassifyDao
.
getById
(
groupQrcode
.
getClassifyId
());
...
...
pcloud-service-book/src/main/java/com/pcloud/book/util/common/ThreadPoolUtils.java
View file @
61abed3f
...
...
@@ -14,6 +14,11 @@ public class ThreadPoolUtils {
*/
public
static
final
int
REMOTE_TIME_OUT
=
5
;
/**
* 远程调用超时时间(单位:秒)
*/
public
static
final
int
REMOTE_TIME_OUT_LONG
=
30
;
/**
* 异步导出线程池
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment