You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by GitBox <gi...@apache.org> on 2022/04/15 14:49:36 UTC

[GitHub] [dubbo-go] Lvnszn opened a new pull request, #1833: Fix: decode net stream bytes as getty rule

Lvnszn opened a new pull request, #1833:
URL: https://github.com/apache/dubbo-go/pull/1833

   <!--  Thanks for sending a pull request!
   Read https://github.com/apache/dubbo-go/blob/master/CONTRIBUTING.md before commit pull request.
   -->
   
   **What this PR does**: 
   fix decode net stream bytes as getty rule in 1.5
   **Which issue(s) this PR fixes**: 
   Fixes #
   
   **You should pay attention to items below to ensure your pr passes our ci test**
   We do not merge pr with ci tests failed
   
   - [ ] All ut passed (run 'go test ./...' in project root)
   - [ ] After go-fmt ed , run 'go fmt project' using goland.
   - [ ] Golangci-lint passed, run 'sudo golangci-lint run' in project root.
   - [ ] After import formatted, (using [imports-formatter](https://github.com/dubbogo/tools#5-how-to-get-imports-formatter) to run 'imports-formatter .' in project root, to format your import blocks, mentioned in [CONTRIBUTING.md](https://github.com/apache/dubbo-go/blob/master/CONTRIBUTING.md) above) 
   - [ ] Your new-created file needs to have [apache license](https://raw.githubusercontent.com/dubbogo/resources/master/tools/license/license.txt) at the top, like other existed file does.
   - [ ] All integration test passed. You can run integration test locally (with docker env). Clone our [dubbo-go-samples](https://github.com/apache/dubbo-go-samples) project and replace the go.mod to your dubbo-go, and run 'sudo sh start_integration_test.sh' at root of samples project root. (M1 Slice is not Support)


-- 
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: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go] AlexStocks commented on pull request #1833: Fix: decode net stream bytes as getty rule

Posted by GitBox <gi...@apache.org>.
AlexStocks commented on PR #1833:
URL: https://github.com/apache/dubbo-go/pull/1833#issuecomment-1100652585

   > CI 问题在看一下?
   
   binbin,这个可以先merge了。再来一个新的pr解决问题


-- 
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: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go] Lvnszn commented on a diff in pull request #1833: Fix: decode net stream bytes as getty rule

Posted by GitBox <gi...@apache.org>.
Lvnszn commented on code in PR #1833:
URL: https://github.com/apache/dubbo-go/pull/1833#discussion_r851598333


##########
protocol/dubbo/dubbo_codec.go:
##########
@@ -240,10 +249,13 @@ func (c *DubboCodec) decodeResponse(data []byte) (*remoting.Response, int, error
 	if err != nil {
 		originErr := perrors.Cause(err)
 		// if the data is very big, so the receive need much times.
-		if originErr == hessian.ErrHeaderNotEnough || originErr == hessian.ErrBodyNotEnough {
-			return nil, 0, originErr
+		if originErr == hessian.ErrHeaderNotEnough { // this is impossible, as dubbo_codec.go:DubboCodec::Decode() line 167

Review Comment:
   1.5 应该是正确的,167 是 return nil, 0, nil。



-- 
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: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go] AlexStocks commented on a diff in pull request #1833: Fix: decode net stream bytes as getty rule

Posted by GitBox <gi...@apache.org>.
AlexStocks commented on code in PR #1833:
URL: https://github.com/apache/dubbo-go/pull/1833#discussion_r851598317


##########
protocol/dubbo/dubbo_codec.go:
##########
@@ -240,10 +249,13 @@ func (c *DubboCodec) decodeResponse(data []byte) (*remoting.Response, int, error
 	if err != nil {

Review Comment:
   这个批注跟此行代码无关。
   
   请在 line 35 吧 package rename 为 invct
   然后在line 236 处,把 invocation package 调用 rename 为 incvt
   
   dubbogo 中 invocation 既作为包名,又作为 package name,这不好。



-- 
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: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go] AlexStocks commented on a diff in pull request #1833: Fix: decode net stream bytes as getty rule

Posted by GitBox <gi...@apache.org>.
AlexStocks commented on code in PR #1833:
URL: https://github.com/apache/dubbo-go/pull/1833#discussion_r851599454


##########
protocol/dubbo/dubbo_codec.go:
##########
@@ -240,10 +249,13 @@ func (c *DubboCodec) decodeResponse(data []byte) (*remoting.Response, int, error
 	if err != nil {
 		originErr := perrors.Cause(err)
 		// if the data is very big, so the receive need much times.
-		if originErr == hessian.ErrHeaderNotEnough || originErr == hessian.ErrBodyNotEnough {
-			return nil, 0, originErr
+		if originErr == hessian.ErrHeaderNotEnough { // this is impossible, as dubbo_codec.go:DubboCodec::Decode() line 167

Review Comment:
   你去看看3.0中line 167 行对应的是哪行代码。然后在 1.5 分支这个代码也是在这行吗?



-- 
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: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go] sanxun0325 commented on pull request #1833: Fix: decode net stream bytes as getty rule

Posted by GitBox <gi...@apache.org>.
sanxun0325 commented on PR #1833:
URL: https://github.com/apache/dubbo-go/pull/1833#issuecomment-1100650010

   CI 问题在看一下?


-- 
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: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go] AlexStocks merged pull request #1833: Fix: decode net stream bytes as getty rule

Posted by GitBox <gi...@apache.org>.
AlexStocks merged PR #1833:
URL: https://github.com/apache/dubbo-go/pull/1833


-- 
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: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go] AlexStocks commented on a diff in pull request #1833: Fix: decode net stream bytes as getty rule

Posted by GitBox <gi...@apache.org>.
AlexStocks commented on code in PR #1833:
URL: https://github.com/apache/dubbo-go/pull/1833#discussion_r851597771


##########
protocol/dubbo/dubbo_codec.go:
##########
@@ -240,10 +249,13 @@ func (c *DubboCodec) decodeResponse(data []byte) (*remoting.Response, int, error
 	if err != nil {
 		originErr := perrors.Cause(err)
 		// if the data is very big, so the receive need much times.
-		if originErr == hessian.ErrHeaderNotEnough || originErr == hessian.ErrBodyNotEnough {
-			return nil, 0, originErr
+		if originErr == hessian.ErrHeaderNotEnough { // this is impossible, as dubbo_codec.go:DubboCodec::Decode() line 167

Review Comment:
   确定在 1.5 分支中,这个注释也是正确的么?



-- 
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: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go] Lvnszn commented on a diff in pull request #1833: Fix: decode net stream bytes as getty rule

Posted by GitBox <gi...@apache.org>.
Lvnszn commented on code in PR #1833:
URL: https://github.com/apache/dubbo-go/pull/1833#discussion_r851598995


##########
protocol/dubbo/dubbo_codec.go:
##########
@@ -240,10 +249,13 @@ func (c *DubboCodec) decodeResponse(data []byte) (*remoting.Response, int, error
 	if err != nil {

Review Comment:
   address



-- 
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: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org