dubbo icon indicating copy to clipboard operation
dubbo copied to clipboard

泛化调用返回结果解析不正

Open mahaixue opened this issue 8 years ago • 5 comments

参照图1调用接口,返回格式正确,参照返回结果格式说明 通过泛化调用返回结果:[{class=org.json.JSONObject}, {class=org.json.JSONObject}, {class=org.json.JSONObject}]

由于dubbo测试现在做了个平台通过泛化调用来获取,这个BUG导致结果无法展示,求优先处理

dubbo

default

返回结果格式: [ { "map": { "lineUrl": "//bbs.wtoip.com/article/1517899684455020036.html", "articleTitle": "20180206\u003d\u003d\u003d\u003d投票贴", "articleCreateTime": 1517899685861, "tagObj": "3D打印" } }, { "map": { "lineUrl": "//bbs.wtoip.com/article/1516959574329020005.html", "articleTitle": "20180126\u003d\u003d\u003d\u003d\u003d1111", "articleCreateTime": 1516959574329, "tagObj": "影视动漫" } }, { "map": { "lineUrl": "//bbs.wtoip.com/article/1514865621766.html", "articleTitle": "测试投票人数", "articleCreateTime": 1514865622317, "tagObj": "汇桔人" } } ]

mahaixue avatar May 15 '18 06:05 mahaixue

Please use gson.toJson() for the result of generic invocation.

diecui1202 avatar May 15 '18 07:05 diecui1202

using gson.toJson() is the same

mahaixue avatar May 25 '18 09:05 mahaixue

it is not about how to print ,becease not all the same,just some specified object .pretty sure is the logic error of the dubbo.

mahaixue avatar May 25 '18 09:05 mahaixue

Can you provide a demo for us to check?

diecui1202 avatar May 25 '18 09:05 diecui1202

Feel free to reopen if necessary.

diecui1202 avatar Aug 16 '18 05:08 diecui1202