EmptyCity-111 commented on code in PR #3613:
URL: https://github.com/apache/dubbo-go/pull/3613#discussion_r3742832544


##########
server/action.go:
##########
@@ -201,11 +207,9 @@ func (svcOpts *ServiceOptions) Export() error {
                        common.WithToken(svcConf.Token),
                        common.WithParamsValue(constant.MetadataTypeKey, 
svcOpts.metadataType),
 
-                       // fix https://github.com/apache/dubbo-go/issues/2176
-                       // TODO: remove MaxServerSendMsgSize value and 
MaxServerRecvMsgSize value when version 4.0.0
-                       // use TripleConfig to transport arguments
-                       common.WithParamsValue(constant.MaxServerSendMsgSize, 
protocolConf.MaxServerSendMsgSize),
-                       common.WithParamsValue(constant.MaxServerRecvMsgSize, 
protocolConf.MaxServerRecvMsgSize),
+                       // Preserve the legacy URL parameters for downstream 
protocol compatibility.
+                       common.WithParamsValue(constant.MaxServerSendMsgSize, 
maxServerSendMsgSize),

Review Comment:
   这个测试建议很有价值,原来的测试确实只覆盖了配置对象状态,没有把生产传播链锁住。
   
   我在 3b4437ef 补了公开入口到真实服务端的回归测试:
   - `dubbo.NewInstance -> protocol.WithTriple -> ServiceOptions.Export -> 
legacy URL params -> real Triple handler`;
   - recv 限制设为 1 KiB 后,512 B 请求成功,4 KiB 请求稳定失败;
   - URL 同时覆盖默认值(send 为空、recv 为 4mib)、显式 nested 值、legacy fallback,以及 nested 
非空值优先级。
   
   验证结果:相关包全量测试通过,`go test ./... -count=1` 全仓通过,golangci-lint 为 0 issues。



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to