Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
matrix
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
CI / CD
CI / CD
Pipelines
Schedules
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
mall
arch
matrix
Commits
052ba0fd
Commit
052ba0fd
authored
Sep 02, 2019
by
鲁强
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' into 'master'
Dev Closes #15 See merge request mall/arch/matrix!21
parents
7a72bd29
ca74988e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1 additions
and
3 deletions
+1
-3
logback-secoo.xml
logger-starter/src/main/resources/logback-secoo.xml
+0
-2
MatrixProducerHook.java
rocketmq-starter/src/main/java/com/secoo/mall/mq/hook/MatrixProducerHook.java
+1
-1
No files found.
logger-starter/src/main/resources/logback-secoo.xml
View file @
052ba0fd
...
@@ -14,8 +14,6 @@
...
@@ -14,8 +14,6 @@
<!-- 控制台输出 -->
<!-- 控制台输出 -->
<appender
name=
"STDOUT"
class=
"ch.qos.logback.core.ConsoleAppender"
>
<appender
name=
"STDOUT"
class=
"ch.qos.logback.core.ConsoleAppender"
>
<encoder
class=
"ch.qos.logback.classic.encoder.PatternLayoutEncoder"
>
<encoder
class=
"ch.qos.logback.classic.encoder.PatternLayoutEncoder"
>
<!--格式化输出:%d表示日期,%thread表示线程名,%-5level:级别从左显示5个字符宽度%msg:日志消息,%n是换行符 -->
<!-- <pattern>%d{yyyy-MM-dd HH:mm:ss.SSS}|%msgno|%thread|%-5level|%logger{20}-%msg%n</pattern> -->
<pattern>
${PATTERN}
</pattern>
<pattern>
${PATTERN}
</pattern>
</encoder>
</encoder>
<filter
class=
"ch.qos.logback.classic.filter.ThresholdFilter"
>
<filter
class=
"ch.qos.logback.classic.filter.ThresholdFilter"
>
...
...
rocketmq-starter/src/main/java/com/secoo/mall/mq/hook/MatrixProducerHook.java
View file @
052ba0fd
...
@@ -25,7 +25,7 @@ public class MatrixProducerHook implements SendMessageHook {
...
@@ -25,7 +25,7 @@ public class MatrixProducerHook implements SendMessageHook {
@Override
@Override
public
void
sendMessageAfter
(
SendMessageContext
context
)
{
public
void
sendMessageAfter
(
SendMessageContext
context
)
{
try
{
try
{
log
.
info
(
"sendMessageAfter,
Mid:{},Mode:{},Topic:{},Targs:{},ProducerGroup:{},BrokerAddr:{},Namespace:{},Exception:{}"
,
context
.
getMessage
().
getProperties
().
get
(
"id"
),
context
.
getCommunicationMode
().
name
(),
context
.
getMessage
().
getTopic
(),
context
.
getMessage
().
getTags
(),
context
.
getProducerGroup
(),
context
.
getBrokerAddr
(),
context
.
getNamespace
(),
context
.
getException
()==
null
?
null
:
context
.
getException
().
getMessage
());
log
.
info
(
"sendMessageAfter,
TraceContext:{},Mode:{},Topic:{},Targs:{},ProducerGroup:{},BrokerAddr:{},Namespace:{},Exception:{}"
,
context
.
getMqTraceContext
(
),
context
.
getCommunicationMode
().
name
(),
context
.
getMessage
().
getTopic
(),
context
.
getMessage
().
getTags
(),
context
.
getProducerGroup
(),
context
.
getBrokerAddr
(),
context
.
getNamespace
(),
context
.
getException
()==
null
?
null
:
context
.
getException
().
getMessage
());
}
catch
(
Exception
e
)
{
//防灾冗余}
}
catch
(
Exception
e
)
{
//防灾冗余}
}
}
}
}
...
...
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