Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
P
pica-cloud-account
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
1
合并请求
1
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
Close sidebar
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
com.pica.cloud.account
pica-cloud-account
提交
fb8fba24
提交
fb8fba24
编写于
3月 24, 2020
作者:
Chongwen.jiang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
/H5/authCode 添加打印日志
获取图形码接口..
上级
935d4f7a
流水线
#23403
已失败 于阶段
in 0 second
变更
2
流水线
1
显示空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
8 行增加
和
0 行删除
+8
-0
AccountBaseController.java
...ount/account/server/controller/AccountBaseController.java
+3
-0
AutoCodeController.java
...account/account/server/controller/AutoCodeController.java
+5
-0
未找到文件。
server/src/main/java/com/pica/cloud/account/account/server/controller/AccountBaseController.java
浏览文件 @
fb8fba24
...
@@ -131,7 +131,10 @@ public abstract class AccountBaseController extends BaseController {
...
@@ -131,7 +131,10 @@ public abstract class AccountBaseController extends BaseController {
String
postData
=
JSON
.
toJSONString
(
picapSendMsgModel
);
String
postData
=
JSON
.
toJSONString
(
picapSendMsgModel
);
logger
.
info
(
"sendMobileTo-mobile:{}, senderId-{}"
,
mobile
,
senderId
);
logger
.
info
(
"sendMobileTo-mobile:{}, senderId-{}"
,
mobile
,
senderId
);
long
start
=
System
.
currentTimeMillis
();
String
jsonObj
=
HttpClientUtil
.
httpExecute
(
messageUrl
,
postData
);
String
jsonObj
=
HttpClientUtil
.
httpExecute
(
messageUrl
,
postData
);
long
end1
=
System
.
currentTimeMillis
();
logger
.
info
(
"sendMobileMessage-send message used {} million seconds"
,
end1
-
start
);
logger
.
info
(
"sendMobileTo-{}"
,
jsonObj
);
logger
.
info
(
"sendMobileTo-{}"
,
jsonObj
);
if
(
StringUtils
.
isEmpty
(
jsonObj
))
{
if
(
StringUtils
.
isEmpty
(
jsonObj
))
{
...
...
server/src/main/java/com/pica/cloud/account/account/server/controller/AutoCodeController.java
浏览文件 @
fb8fba24
...
@@ -259,6 +259,7 @@ public class AutoCodeController extends AccountBaseController {
...
@@ -259,6 +259,7 @@ public class AutoCodeController extends AccountBaseController {
* @param authCodeKeySecure
* @param authCodeKeySecure
*/
*/
private
void
processSendAuthCode
(
String
mobilePhone
,
Integer
flag
,
String
authCodeKeySecure
)
{
private
void
processSendAuthCode
(
String
mobilePhone
,
Integer
flag
,
String
authCodeKeySecure
)
{
long
start
=
System
.
currentTimeMillis
();
String
authCode
=
CommonUtil
.
createValidateCode
();
String
authCode
=
CommonUtil
.
createValidateCode
();
String
message
=
"您的验证码是"
+
authCode
+
",在10分钟内有效。如非本人操作,请忽略本短信!"
;
String
message
=
"您的验证码是"
+
authCode
+
",在10分钟内有效。如非本人操作,请忽略本短信!"
;
Integer
accountIdByMobilePhone
=
accountService
.
getAccountIdByMobilePhone
(
mobilePhone
);
Integer
accountIdByMobilePhone
=
accountService
.
getAccountIdByMobilePhone
(
mobilePhone
);
...
@@ -271,7 +272,11 @@ public class AutoCodeController extends AccountBaseController {
...
@@ -271,7 +272,11 @@ public class AutoCodeController extends AccountBaseController {
cacheClient
.
set
(
authCodeKeySecure
,
System
.
currentTimeMillis
(),
60
);
cacheClient
.
set
(
authCodeKeySecure
,
System
.
currentTimeMillis
(),
60
);
//处理验证码原子性的问题
//处理验证码原子性的问题
cacheClient
.
set
(
RegisterCodeKeyUtils
.
getRegisterKey
(
mobilePhone
,
authCode
),
100
,
600
);
cacheClient
.
set
(
RegisterCodeKeyUtils
.
getRegisterKey
(
mobilePhone
,
authCode
),
100
,
600
);
long
end1
=
System
.
currentTimeMillis
();
logger
.
info
(
"processSendAuthCode-1 used {} million seconds"
,
end1
-
start
);
super
.
sendMobileMessage
(
mobilePhone
,
message
,
senderId
);
super
.
sendMobileMessage
(
mobilePhone
,
message
,
senderId
);
long
end2
=
System
.
currentTimeMillis
();
logger
.
info
(
"processSendAuthCode-2 used {} million seconds"
,
end2
-
start
);
}
}
//获取验证码redis key
//获取验证码redis key
...
...
写
预览
Markdown
格式
0%
请重试
or
附加一个文件
附加文件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录