Issue 1:
I have searched the issues of this repository and believe that this is not a duplicate.

I have checked the FAQ of this repository and believe that this is not a duplicate.

Environment

Dubbo version: xxx

Operating System version: xxx

Java version: xxx

Http Request Solutions

We are going to export dubbo service for front-end request(eg: h5 outside). We are doubt about the advantage and disadvantage of below two solutions, anyone have good ideas for that?

Generally, there are two ways to support that.

Solution1: Add proxy(through GenericService) for the http request (http -> proxy -> dubbo)

Solution2: Support dubbo & http protocol in service side (eg: dubbox/jsonrpc).

For Solution1:

Advantage:

It's easy for the user, no need to maintain both http & dubbo protocols.

No need to maintain two types of configurations (one for dubbo, another for http). Following two conditions may confuse the user. Firstly, xxx config support for dubbo and http, but they are in different key. Secondly, yyy config is supported in dubbo, not for http. User maybe confused on so much of the configs.

Disadvantage:

The latency is high for the proxy mode.

For dubbo protocol: 1k request/100k response/3000QPS, average response is 1-2ms, and able to support 7000-8000QPS in 8Core server.

For the proxy mode: 1K request/100K response/600QPS, the average response is 14ms, only with 600QPS.

The proxy CPU is very high.

For dubbo protocol: With 7000-8000QPS, the service CPU is about 80-90%, with 600QPS, the service CPU below 5-10% maybe.

For proxy mode: With 600QPS, service CPU is low, but the proxy's CPU is almost full (80-90%). That means, it need 4-5times of the server to host the request.

For Solution2:

Advantage:

The latency is very low, as it's directly connect to the service.

Disadvantage:

User have to maintain both dubbo & http protocol, as described in solution 1 .

We are confused to find a better solution. Am i in a wrong way, or anyone have good suggestions or solutions for http request?

Thanks for any suggestions.

Issue 2:
I have searched the issues of this repository and believe that this is not a duplicate.

I have checked the FAQ of this repository and believe that this is not a duplicate.

Environment

Dubbo version: 2.6.2

Operating System version: win10

Java version: 1.8

Step to reproduce this issue

1、the code in ThriftProtocol

String serviceKey = serviceKey(channel.getLocalAddress().getPort(), serviceName, null, null);

DubboExporter exporter = (DubboExporter) exporterMap.get(serviceKey);

2、why set the serviceVersion and serviceGroup null ? I do not understand

com.alibaba.dubbo.remoting.RemotingException: Not found exported service: com.zbss.common.api.config.service.ConfigService$Iface:20080 in [service-config/com.zbss.common.api.config.service.ConfigService$Iface:20080], may be version or group mismatch , channel: consumer: /192.168.3.63:61251 --> provider: /192.168.3.63:20080, message:RpcInvocation [methodName=getVendorConfig, parameterTypes=[class java.lang.String], arguments=[123], attachments={interface=com.zbss.common.api.config.service.ConfigService$Iface}]
at com.alibaba.dubbo.rpc.protocol.thrift.ThriftProtocol$1.reply(ThriftProtocol.java:67)
at com.alibaba.dubbo.remoting.exchange.support.header.HeaderExchangeHandler.handleRequest(HeaderExchangeHandler.java:96)
at com.alibaba.dubbo.remoting.exchange.support.header.HeaderExchangeHandler.received(HeaderExchangeHandler.java:172)
at com.alibaba.dubbo.remoting.transport.DecodeHandler.received(DecodeHandler.java:51)
at com.alibaba.dubbo.remoting.transport.dispatcher.ChannelEventRunnable.run(ChannelEventRunnable.java:80)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)