This is an automated email from the ASF dual-hosted git repository.
mxsm pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/eventmesh.git
The following commit(s) were added to refs/heads/master by this push:
new af1c041f4 [ISSUE #3411] Do some code
optimization[ReplyMessageProcessor] (#4871)
af1c041f4 is described below
commit af1c041f44d191bc8cb1d12e013848870049d7b1
Author: Zaki <[email protected]>
AuthorDate: Mon May 6 22:45:43 2024 +0800
[ISSUE #3411] Do some code optimization[ReplyMessageProcessor] (#4871)
---
.../runtime/core/protocol/http/processor/ReplyMessageProcessor.java | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git
a/eventmesh-runtime/src/main/java/org/apache/eventmesh/runtime/core/protocol/http/processor/ReplyMessageProcessor.java
b/eventmesh-runtime/src/main/java/org/apache/eventmesh/runtime/core/protocol/http/processor/ReplyMessageProcessor.java
index ce178f0f1..55051573c 100644
---
a/eventmesh-runtime/src/main/java/org/apache/eventmesh/runtime/core/protocol/http/processor/ReplyMessageProcessor.java
+++
b/eventmesh-runtime/src/main/java/org/apache/eventmesh/runtime/core/protocol/http/processor/ReplyMessageProcessor.java
@@ -73,12 +73,12 @@ public class ReplyMessageProcessor extends
AbstractHttpRequestProcessor {
@Override
public void processRequest(ChannelHandlerContext ctx,
AsyncContext<HttpCommand> asyncContext) throws Exception {
- HttpCommand responseEventMeshCommand;
String localAddress = IPUtils.getLocalAddress();
HttpCommand request = asyncContext.getRequest();
+ final String channelRemoteAddr =
RemotingHelper.parseChannelRemoteAddr(ctx.channel());
cmdLogger.info("cmd={}|{}|client2eventMesh|from={}|to={}",
RequestCode.get(Integer.valueOf(request.getRequestCode())),
EventMeshConstants.PROTOCOL_HTTP,
- RemotingHelper.parseChannelRemoteAddr(ctx.channel()),
localAddress);
+ channelRemoteAddr, localAddress);
ReplyMessageRequestHeader replyMessageRequestHeader =
(ReplyMessageRequestHeader) request.getHeader();
@@ -167,7 +167,6 @@ public class ReplyMessageProcessor extends
AbstractHttpRequestProcessor {
try {
// body
- //
omsMsg.setBody(replyMessageRequestBody.getContent().getBytes(EventMeshConstants.DEFAULT_CHARSET));
event = CloudEventBuilder.from(event)
.withSubject(replyTopic)
.withExtension(EventMeshConstants.MSG_TYPE,
EventMeshConstants.PERSISTENT)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]