Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Fedex
/
iClear-api
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
tao.mo
2023-04-19 14:37:41 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
1a80d762f852f0565e3274dc7c885dc7e95ff982
1a80d762
1 parent
814cb2cc
监控系统是否可以正常访问
mt 2023年4月19日14:37:34
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
14 additions
and
12 deletions
src/main/java/com/erry/iclear/dateInterface/service/EmailSenderService.java
src/main/java/com/erry/iclear/dateInterface/task/IClearApiTask.java
src/main/resources/application-dev.properties
src/main/resources/application-prod.properties
src/main/resources/application-test.properties
src/main/java/com/erry/iclear/dateInterface/service/EmailSenderService.java
View file @
1a80d76
package
com
.
erry
.
iclear
.
dateInterface
.
service
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.mail.javamail.JavaMailSenderImpl
;
import
org.springframework.mail.javamail.MimeMessageHelper
;
...
...
@@ -10,6 +11,7 @@ import java.util.*;
/**
* Created on 2017-9-22.
*/
@Slf4j
@Service
(
"emailSenderService"
)
public
class
EmailSenderService
{
...
...
src/main/java/com/erry/iclear/dateInterface/task/IClearApiTask.java
View file @
1a80d76
...
...
@@ -68,12 +68,12 @@ public class IClearApiTask {
try
{
log
.
info
(
"monitorIclearNodesTask start>>>>>>>>>>>>"
);
boolean
requestResult42
=
apiService
.
connectIclearNode
(
this
.
iclearAddressUrl42
);
if
(
requestResult42
){
emailSenderService
.
sendMail
(
null
,
"系统访问异常提示"
,
"
42机器无法正常访问
"
);
if
(
!
requestResult42
){
emailSenderService
.
sendMail
(
null
,
"系统访问异常提示"
,
"
系统提示:42节点访问异常,请及时查看
"
);
}
boolean
requestResult43
=
apiService
.
connectIclearNode
(
this
.
iclearAddressUrl43
);
if
(
requestResult43
){
emailSenderService
.
sendMail
(
null
,
"系统访问异常提示"
,
"
43机器无法正常访问
"
);
if
(
!
requestResult43
){
emailSenderService
.
sendMail
(
null
,
"系统访问异常提示"
,
"
系统提示:43节点访问异常,请及时查看
"
);
}
log
.
info
(
"monitorIclearNodesTask end>>>>>>>>>>>>"
);
}
catch
(
Exception
e
){
...
...
src/main/resources/application-dev.properties
View file @
1a80d76
...
...
@@ -15,8 +15,8 @@ task.pushMawbTask=0 0/1 * * * ?
task.pushErrorReturnDate
=
0 0/3 * * * ?
#推送失败的申报数据
task.pushErrorDeclareDate
=
0 0/3 * * * ?
#
推送失败的回执数据
task.monitorIclearNodes
=
0 0/
1
* * * ?
#
监听iclear节点是否正常定时任务间隔
task.monitorIclearNodes
=
0 0/
5
* * * ?
api.base-
address
=
http://localhost:8080/Exp
#获取token账号
...
...
@@ -38,8 +38,8 @@ api.address.customs-url=https://apiuat.iclrccd-fedex.com/export/outbound/customs
#推送完整报文地址
api.address.complete-msg-
url
=
https://apiuat.iclrccd-fedex.com/export/outbound/mawb
#iclear应用节点是否能够正常访问
iclear.address.url42
=
http
s://www.fedex.com/
iclear.address.url43
=
http
s://www.baidu.com/
iclear.address.url42
=
http
://localhost:8080/Exp
iclear.address.url43
=
http
://localhost:8080/Exp
#代理地址(刷新token、传输海关回执地址、推送完整报文地址)
api.address.proxy-
url
=
cn2-proxy.apac.fedex.com
api.address.proxy-
port
=
3128
\ No newline at end of file
...
...
src/main/resources/application-prod.properties
View file @
1a80d76
...
...
@@ -8,7 +8,7 @@ task.pushMawbTask=0 0/1 * * * ?
task.pushErrorReturnDate
=
0 0/30 * * * ?
#推送失败的申报数据
task.pushErrorDeclareDate
=
0 0/30 * * * ?
#
推送失败的回执数据
#
监听iclear节点是否正常定时任务间隔
task.monitorIclearNodes
=
0 0/5 * * * ?
api.base-
address
=
https://declaration.fedex.com.cn/Exp
...
...
src/main/resources/application-test.properties
View file @
1a80d76
...
...
@@ -8,7 +8,7 @@ task.pushMawbTask=0 0/1 * * * ?
task.pushErrorReturnDate
=
0 0/3 * * * ?
#推送失败的申报数据
task.pushErrorDeclareDate
=
0 0/3 * * * ?
#
推送失败的回执数据
#
监听iclear节点是否正常定时任务间隔
task.monitorIclearNodes
=
0 0/5 * * * ?
api.base-
address
=
https://declarationuat.fedex.com.cn/Exp
...
...
@@ -31,8 +31,8 @@ api.address.customs-url=https://apiuat.iclrccd-fedex.com/export/outbound/customs
#推送完整报文地址
api.address.complete-msg-
url
=
https://apiuat.iclrccd-fedex.com/export/outbound/mawb
#iclear应用节点是否能够正常访问
iclear.address.url42
=
http
s://pjec0003.cndczmd.apac.fedex.com:9002/Exp/
iclear.address.url43
=
http
s://pjec0004.cndczmd.apac.fedex.com:9002/Exp/
iclear.address.url42
=
http
://ujec0003.cndczmd.apac.fedex.com:9001/Exp/#login
iclear.address.url43
=
http
://ujec0004.cndczmd.apac.fedex.com:9001/Exp/#login
#代理地址(刷新token、传输海关回执地址、推送完整报文地址)
api.address.proxy-
url
=
cn2-proxy.apac.fedex.com
api.address.proxy-
port
=
3128
\ No newline at end of file
...
...
Please
register
or
login
to post a comment