Skip to content

Commit

Permalink
optimized returned reply in subscribe method
Browse files Browse the repository at this point in the history
  • Loading branch information
kyooosukedn committed Jan 19, 2024
1 parent 42c0d06 commit 98bf805
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions eventmesh-sdks/eventmesh-sdk-rust/src/grpc/grpc_consumer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -161,12 +161,11 @@ impl EventMeshGrpcConsumer {
ProtocolKey::SUB_MESSAGE_TYPE.to_string(),
PbCloudEventAttributeValue {
attr: Some(PbAttr::CeString(
SubscriptionReply::SUB_TYPE.to_string(),
ProtocolKey::SUB_REPLY_MESSAGE.to_string(),
)),
},
);
received.data =
Some(PbData::TextData(serde_json::to_string(&reply).unwrap()));
received.data = None;
let _ = keeper.sender.send(received).await;
}
} else {
Expand Down

0 comments on commit 98bf805

Please sign in to comment.