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/03/17 01:51:07 UTC
[GitHub] [dubbo-go-hessian2] miracle-xiang commented on issue #311: dubboVersion为"2.8.4a" 可以使用该库解析吗?
miracle-xiang commented on issue #311:
URL: https://github.com/apache/dubbo-go-hessian2/issues/311#issuecomment-1069824334
- UT
`func TestParseDubboHessian(t *testing.T) {
raw, _ := loadPcap("dubbo_req.pcap")
codecR := hessian2.NewHessianCodec(bufio.NewReader(bytes.NewReader(raw[108:])))
header := &hessian2.DubboHeader{}
err := codecR.ReadHeader(header)
if err != nil {
t.Errorf("read header err [%v]\n", err)
}
c := make([]interface{}, 7)
err = codecR.ReadBody(c)
if err != nil {
t.Errorf("read body err [%v]\n", err)
}
}`
- panic信息
`--- FAIL: TestParseDubboHessian (0.00s)
panic: interface conversion: interface {} is int32, not string [recovered]
panic: interface conversion: interface {} is int32, not string
goroutine 25 [running]:
testing.tRunner.func1.2({0xaa3fe0, 0xc0003da150})
/usr/lib/golang/src/testing/testing.go:1209 +0x24e
testing.tRunner.func1()
/usr/lib/golang/src/testing/testing.go:1212 +0x218
panic({0xaa3fe0, 0xc0003da150})
/usr/lib/golang/src/runtime/panic.go:1038 +0x215
github.com/apache/dubbo-go-hessian2.unpackRequestBody(0xc0003c4e60, {0xa54000, 0xc0003cad80})
/home/xiangwang/go/src/gitlab.yunshan.net/platform/trident/vendor/github.com/apache/dubbo-go-hessian2/request.go:322 +0xbeb
github.com/apache/dubbo-go-hessian2.(*HessianCodec).ReadBody(0xc000090e98, {0xa54000, 0xc0003cad80})
/home/xiangwang/go/src/gitlab.yunshan.net/platform/trident/vendor/github.com/apache/dubbo-go-hessian2/hessian.go:200 +0x185
gitlab.yunshan.net/platform/trident/flowgenerator/rpc/dubbo.TestParseDubboHessian(0xc0003ac4e0)
/home/xiangwang/go/src/gitlab.yunshan.net/platform/trident/flowgenerator/rpc/dubbo/flow_dubbo_log_test.go:39 +0x2a5
testing.tRunner(0xc0003ac4e0, 0xbba1d8)
/usr/lib/golang/src/testing/testing.go:1259 +0x102
created by testing.(*T).Run
/usr/lib/golang/src/testing/testing.go:1306 +0x35a`
--
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