This is an automated email from the ASF dual-hosted git repository.
liuhan pushed a commit to branch tmp_disable_reading
in repository https://gitbox.apache.org/repos/asf/skywalking-rover.git
The following commit(s) were added to refs/heads/tmp_disable_reading by this
push:
new 2fe5909 rebuild the connection when have update
2fe5909 is described below
commit 2fe59097b6e523bbb1fce070b8850b42ab8faba5
Author: mrproliu <[email protected]>
AuthorDate: Sat Dec 21 22:03:35 2024 +0800
rebuild the connection when have update
---
pkg/accesslog/common/connection.go | 3 +++
1 file changed, 3 insertions(+)
diff --git a/pkg/accesslog/common/connection.go
b/pkg/accesslog/common/connection.go
index 1e8fc36..2a98326 100644
--- a/pkg/accesslog/common/connection.go
+++ b/pkg/accesslog/common/connection.go
@@ -347,6 +347,9 @@ func (c *ConnectionManager) connectionPostHandle(connection
*ConnectionInfo, eve
}
}
+// According to https://github.com/golang/protobuf/issues/1609
+// if the message is modified during marshalling, it may cause the error when
send the message to the backend
+// so, we need to clone the message and change it before sending it to the
channel
func (c *ConnectionManager)
rebuildRPCConnectionWithTLSModeAndProtocol(connection *ConnectionInfo,
tls v3.AccessLogConnectionTLSMode, protocol v3.AccessLogProtocolType) {
logConnection :=
proto.Clone(connection.RPCConnection).(*v3.AccessLogConnection)