Closed miracle-xiang closed 2 years ago
@miracle-xiang pls provide more details, like golang struct definition, java object definition, your unit test, etc..
@miracle-xiang there is an example that decoding data from java, u can create a new unit test:
您好, 麻烦您帮忙看下, 我的UT和PCAP。 dubbo-go-hessian2 tag v1.11.0
我想参照codecR.ReadBody
来解析body
https://github.com/apache/dubbo-go-hessian2/blob/master/hessian_test.go#L177
不使用java解码可以么?
@miracle-xiang the dubbo version 2.8.4a seems not the official version, the protocol is incompatible. https://github.com/wongoo/dubbo-go-test/blob/cc71636a7b6678833271243b60ecbdada4521d3f/hessian_issue311/parse_dubbo_test.go#L43
The dubbo version v2.8.4a belongs to dubbox which was maintained by DangDang before 2018. And then it was merged into dubbo 2.6. Now it has been out of date.
@wongoo can we close this issue?
@miracle-xiang I will close this issue,u can open a new issue if having other questions.
What would you like to be added:
Why is this needed:
目前发现个情况,codecR.ReadBody-argsTypes 类型推断为int32, 但是在解析该字段时,强行按照string进行了类型推断。
导致
panic[panic:interface conversion: interface {} is int32, not string [recovered] panic: interface conversion: interface {} is int32, not string]
值类型判断
值的解析