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

Steps to reproduce this issue

xxx

xxx

xxx

Pls. provide [GitHub address] to reproduce this issue.

Expected Result

What do you expected from the above steps？

Actual Result

What actually happens?

If there is an exception, please attach the exception trace:

Just put your stack trace here!

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: v2.7.3

Java version: 1.8

Maven version: 3.6.1

Steps to reproduce this issue

here is an project that reproduces this issue.

https://github.com/spawpaw/dubbo-duplicate-dep-demo

Actual Result

What actually happens?

this is my error log:

2019-12-16 14:43:06.210 ERROR 3220 --- [ restartedMain] o.a.d.c.Version : [DUBBO] Duplicate class org/apache/dubbo/common/Version.class in 2 jar [file:/C:/var/repository/org/apache/dubbo/dubbo-common/2.7.3/dubbo-common-2.7.3.jar!/org/apache/dubbo/common/Version.class, file:/C:/var/repository/org/apache/dubbo/dubbo/2.7.3/dubbo-2.7.3.jar!/org/apache/dubbo/common/Version.class], dubbo version: 2.7.3, current host: 169.254.227.5
14:43:21.307 ERROR 3220 --- [ restartedMain] o.a.d.c.Version :236 : [DUBBO] Duplicate class org/apache/dubbo/remoting/exchange/Exchangers.class in 2 jar [file:/C:/var/repository/org/apache/dubbo/dubbo-remoting-api/2.7.3/dubbo-remoting-api-2.7.3.jar!/org/apache/dubbo/remoting/exchange/Exchangers.class, file:/C:/var/repository/org/apache/dubbo/dubbo/2.7.3/dubbo-2.7.3.jar!/org/apache/dubbo/remoting/exchange/Exchangers.class], dubbo version: 2.7.3, current host: 169.254.227.5
14:43:21.319 ERROR 3220 --- [ restartedMain] o.a.d.c.Version :236 : [DUBBO] Duplicate class org/apache/dubbo/remoting/Transporters.class in 2 jar [file:/C:/var/repository/org/apache/dubbo/dubbo-remoting-api/2.7.3/dubbo-remoting-api-2.7.3.jar!/org/apache/dubbo/remoting/Transporters.class, file:/C:/var/repository/org/apache/dubbo/dubbo/2.7.3/dubbo-2.7.3.jar!/org/apache/dubbo/remoting/Transporters.class], dubbo version: 2.7.3, current host: 169.254.227.5
14:43:21.320 ERROR 3220 --- [ restartedMain] o.a.d.c.Version :236 : [DUBBO] Duplicate class org/apache/dubbo/remoting/RemotingException.class in 2 jar [file:/C:/var/repository/org/apache/dubbo/dubbo/2.7.3/dubbo-2.7.3.jar!/org/apache/dubbo/remoting/RemotingException.class, file:/C:/var/repository/org/apache/dubbo/dubbo-remoting-api/2.7.3/dubbo-remoting-api-2.7.3.jar!/org/apache/dubbo/remoting/RemotingException.class], dubbo version: 2.7.3, current host: 169.254.227.5

lets inspect the artifact org.apache.dubbo:dubbo-common and org.apache.dubbo:dubbo:

dubbo-common:

dubbo-remoting:

It seems that org.apache.dubbo:dubbo packages all classes in all modules into one artifact, so when other framework wants to depend a single dubbo module, the duplicate class error occurs.

Expected Result

decompose org.apache.dubbo:dubbo

See also

#4427 #2314