mosn / mosn

The Cloud-Native Network Proxy Platform
https://mosn.io
Apache License 2.0
4.43k stars 797 forks source link

The `error` in the pkg/stream/http2/var.go is always nil #2273

Open muyuan0 opened 1 year ago

muyuan0 commented 1 year ago

Your question

For example, even if there is an error return, the final returned error is still always nil: https://github.com/mosn/mosn/blob/21cfb09295bcd44348e8b93ee7b10676e5ed532b/pkg/stream/http2/var.go#L73-L76

And the error handling code in the pkg/stream/http/var.go file is different from pkg/stream/http2/var.go in the cookie getter: https://github.com/mosn/mosn/blob/21cfb09295bcd44348e8b93ee7b10676e5ed532b/pkg/stream/http/var.go#L162-L167 https://github.com/mosn/mosn/blob/21cfb09295bcd44348e8b93ee7b10676e5ed532b/pkg/stream/http2/var.go#L109-L112

One returns an error but the other doesn't.

Environment

3062 commented 1 year ago

Sorry, my oversight, this problem should have been solved in the previous version

taoyuanyuan commented 1 year ago

https://github.com/mosn/mosn/pull/2174