step to reproduce @Chanel-Li 's problem:
1. clone the latest version code dubbo-2.7.0
2. run `org.apache.dubbo.container.Main` throw above exception.

This is not a bug. `org.apache.dubbo.container.Main` will default loads `spring 
container`, while the source code of moudle `dubbo-container-api` doesn't add 
dependency of `dubbo-container-spring`, so 
`ExtensionLoader.getExtensionLoader(Container.class).getExtension("spring")` 
will throw exception.

suggestion:

1. You shouldn't run `org.apache.dubbo.container.Main` directly from source 
code.More details you can browse the doc 
[service-container.html](https://dubbo.apache.org/zh-cn/docs/user/demos/service-container.html)
2. If you want to unit test `spring-container`, ask 
`org.apache.dubbo.container.spring.SpringContainerTest` for help.

The simplest way to deal with your problem.Add below dependency to your project
```
        <dependency>
            <groupId>org.apache.dubbo</groupId>
            <artifactId>dubbo-container-spring</artifactId>
            <version>${project.parent.version}</version>
        </dependency>
```
and the try again.

[ Full content available at: 
https://github.com/apache/incubator-dubbo/issues/2478 ]
This message was relayed via gitbox.apache.org for [email protected]

Reply via email to