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: 2.6.x

Operating System version: *nix

Java version: 1.7

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?

We can see code like this

@Override
public void create(String path, boolean ephemeral) {
if (!ephemeral) {
if (checkExists(path)) {
return;
}
}
int i = path.lastIndexOf('/');
if (i > 0) {
create(path.substring(0, i), false);
}
if (ephemeral) {
createEphemeral(path);
} else {
createPersistent(path);
}
}

You can see recursive here.

If we have a lot of dubbo reference or service.

This method would execute too many times and cost a large time.

In fact , if dubbo group is same then the path may no need to check every time

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.7.0

Operating System version: MAC

Java version: 1.8

Steps to reproduce this issue

update dubbo to 2.7.0

update edas-dubbo-extension to 1.0.4

start app

Expected Result

services successfully registery to edas config center

Actual Result

java.lang.IllegalStateException: Failed to load extension class(interface: interface org.apache.dubbo.registry.RegistryFactory, class line: com.alibaba.edas.dubbo.EdasRegistryFactory) in jar, cause: com.alibaba.dubbo.registry.support.AbstractRegistryFactory

java.lang.IllegalStateException: Failed to load extension class(interface: interface org.apache.dubbo.registry.RegistryFactory, class line: com.alibaba.edas.dubbo.EdasRegistryFactory) in jar:file:/Users/nobody/.m2/repository/com/alibaba/edas/edas-dubbo-extension/1.0.4/edas-dubbo-extension-1.0.4.jar!/META-INF/dubbo/com.alibaba.dubbo.registry.RegistryFactory, cause: com.alibaba.dubbo.registry.support.AbstractRegistryFactory
at org.apache.dubbo.common.extension.ExtensionLoader.loadResource(ExtensionLoader.java:675) ~[dubbo-2.7.0.jar:2.7.0]
at org.apache.dubbo.common.extension.ExtensionLoader.loadDirectory(ExtensionLoader.java:643) ~[dubbo-2.7.0.jar:2.7.0]
at org.apache.dubbo.common.extension.ExtensionLoader.loadExtensionClasses(ExtensionLoader.java:624) ~[dubbo-2.7.0.jar:2.7.0]
at org.apache.dubbo.common.extension.ExtensionLoader.getExtensionClasses(ExtensionLoader.java:595) ~[dubbo-2.7.0.jar:2.7.0]
at org.apache.dubbo.common.extension.ExtensionLoader.getSupportedExtensions(ExtensionLoader.java:373) ~[dubbo-2.7.0.jar:2.7.0]
at org.apache.dubbo.common.extension.factory.SpiExtensionFactory.getExtension(SpiExtensionFactory.java:32) ~[dubbo-2.7.0.jar:2.7.0]
at org.apache.dubbo.common.extension.factory.AdaptiveExtensionFactory.getExtension(AdaptiveExtensionFactory.java:47) ~[dubbo-2.7.0.jar:2.7.0]
at org.apache.dubbo.common.extension.ExtensionLoader.injectExtension(ExtensionLoader.java:562) ~[dubbo-2.7.0.jar:2.7.0]
at org.apache.dubbo.common.extension.ExtensionLoader.createExtension(ExtensionLoader.java:529) ~[dubbo-2.7.0.jar:2.7.0]
at org.apache.dubbo.common.extension.ExtensionLoader.getExtension(ExtensionLoader.java:344) ~[dubbo-2.7.0.jar:2.7.0]
at org.apache.dubbo.rpc.Protocol$Adaptive.export(Protocol$Adaptive.java) ~[dubbo-2.7.0.jar:2.7.0]
at org.apache.dubbo.config.ServiceConfig.doExportUrlsFor1Protocol(ServiceConfig.java:553) ~[dubbo-2.7.0.jar:2.7.0]
at org.apache.dubbo.config.ServiceConfig.doExportUrls(ServiceConfig.java:402) ~[dubbo-2.7.0.jar:2.7.0]
at org.apache.dubbo.config.ServiceConfig.doExport(ServiceConfig.java:363) ~[dubbo-2.7.0.jar:2.7.0]
at org.apache.dubbo.config.ServiceConfig.export(ServiceConfig.java:345) ~[dubbo-2.7.0.jar:2.7.0]
at org.apache.dubbo.config.spring.ServiceBean.export(ServiceBean.java:318) ~[dubbo-2.7.0.jar:2.7.0]
at org.apache.dubbo.config.spring.ServiceBean.onApplicationEvent(ServiceBean.java:112) ~[dubbo-2.7.0.jar:2.7.0]
at org.apache.dubbo.config.spring.ServiceBean.onApplicationEvent(ServiceBean.java:58) ~[dubbo-2.7.0.jar:2.7.0]
at org.springframework.context.event.SimpleApplicationEventMulticaster.doInvokeListener(SimpleApplicationEventMulticaster.java:172) ~[spring-context-5.1.5.RELEASE.jar:5.1.5.RELEASE]
at org.springframework.context.event.SimpleApplicationEventMulticaster.invokeListener(SimpleApplicationEventMulticaster.java:165) ~[spring-context-5.1.5.RELEASE.jar:5.1.5.RELEASE]
at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:139) ~[spring-context-5.1.5.RELEASE.jar:5.1.5.RELEASE]
at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:402) ~[spring-context-5.1.5.RELEASE.jar:5.1.5.RELEASE]
at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:359) ~[spring-context-5.1.5.RELEASE.jar:5.1.5.RELEASE]
at org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:896) ~[spring-context-5.1.5.RELEASE.jar:5.1.5.RELEASE]
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:552) ~[spring-context-5.1.5.RELEASE.jar:5.1.5.RELEASE]
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:775) ~[spring-boot-2.1.3.RELEASE.jar:2.1.3.RELEASE]
at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:397) ~[spring-boot-2.1.3.RELEASE.jar:2.1.3.RELEASE]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:316) ~[spring-boot-2.1.3.RELEASE.jar:2.1.3.RELEASE]
at org.springframework.boot.builder.SpringApplicationBuilder.run(SpringApplicationBuilder.java:139) [spring-boot-2.1.3.RELEASE.jar:2.1.3.RELEASE]
at com.copote.nstamp.AuthRpcServiceApplication.main(AuthRpcServiceApplication.java:25) [classes/:na]
Caused by: java.lang.NoClassDefFoundError: com.alibaba.dubbo.registry.support.AbstractRegistryFactory
at java.lang.Class.forName0(Native Method) ~[na:1.8.0_192]
at java.lang.Class.forName(Class.java:348) ~[na:1.8.0_192]
at org.apache.dubbo.common.extension.ExtensionLoader.loadResource(ExtensionLoader.java:672) ~[dubbo-2.7.0.jar:2.7.0]
... 29 common frames omitted