Refactor testcase
diff --git a/api/src/main/java/com/alibaba/dubbo/test/service/AsyncService.java b/api/src/main/java/com/alibaba/dubbo/test/service/AsyncService.java
index 37e3653..9d247a4 100644
--- a/api/src/main/java/com/alibaba/dubbo/test/service/AsyncService.java
+++ b/api/src/main/java/com/alibaba/dubbo/test/service/AsyncService.java
@@ -4,4 +4,6 @@
  * Created by ken.lj on 2017/9/24.
  */
 public interface AsyncService {
+
+    String asyncMethod();
 }
diff --git a/api/src/main/java/com/alibaba/dubbo/test/service/chain/CatService.java b/api/src/main/java/com/alibaba/dubbo/test/service/chain/CatService.java
deleted file mode 100644
index 7c4fcf2..0000000
--- a/api/src/main/java/com/alibaba/dubbo/test/service/chain/CatService.java
+++ /dev/null
@@ -1,10 +0,0 @@
-package com.alibaba.dubbo.test.service.chain;
-
-/**
- * Created by ken.lj on 2017/9/8.
- */
-public interface CatService {
-    void eat(String master);
-
-    String getName();
-}
diff --git a/api/src/main/java/com/alibaba/dubbo/test/service/chain/DogService.java b/api/src/main/java/com/alibaba/dubbo/test/service/chain/DogService.java
deleted file mode 100644
index 74de994..0000000
--- a/api/src/main/java/com/alibaba/dubbo/test/service/chain/DogService.java
+++ /dev/null
@@ -1,10 +0,0 @@
-package com.alibaba.dubbo.test.service.chain;
-
-/**
- * Created by ken.lj on 2017/9/8.
- */
-public interface DogService {
-    void eat(String master);
-
-    String getName();
-}
diff --git a/api/src/main/java/com/alibaba/dubbo/test/service/chain/LionService.java b/api/src/main/java/com/alibaba/dubbo/test/service/chain/LionService.java
deleted file mode 100644
index 60eb859..0000000
--- a/api/src/main/java/com/alibaba/dubbo/test/service/chain/LionService.java
+++ /dev/null
@@ -1,10 +0,0 @@
-package com.alibaba.dubbo.test.service.chain;
-
-/**
- * Created by ken.lj on 2017/9/8.
- */
-public interface LionService {
-    void eat(String master);
-
-    String getName();
-}
diff --git a/api/src/main/java/com/alibaba/dubbo/test/service/chain/MouseService.java b/api/src/main/java/com/alibaba/dubbo/test/service/chain/MouseService.java
deleted file mode 100644
index 9898cc0..0000000
--- a/api/src/main/java/com/alibaba/dubbo/test/service/chain/MouseService.java
+++ /dev/null
@@ -1,10 +0,0 @@
-package com.alibaba.dubbo.test.service.chain;
-
-/**
- * Created by ken.lj on 2017/9/8.
- */
-public interface MouseService {
-    void eat(String master);
-
-    String getName();
-}
diff --git a/consumer-test/pom.xml b/consumer-test/pom.xml
index 453fd37..bab2417 100644
--- a/consumer-test/pom.xml
+++ b/consumer-test/pom.xml
@@ -23,6 +23,10 @@
         </dependency>
         <dependency>
             <groupId>org.springframework.boot</groupId>
+            <artifactId>spring-boot-starter-aop</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.springframework.boot</groupId>
             <artifactId>spring-boot-starter-test</artifactId>
             <scope>test</scope>
         </dependency>
@@ -46,6 +50,31 @@
             <groupId>com.alibaba</groupId>
             <artifactId>fastjson</artifactId>
         </dependency>
+        <dependency>
+            <groupId>org.apache.cxf</groupId>
+            <artifactId>cxf-rt-frontend-simple</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.cxf</groupId>
+            <artifactId>cxf-rt-transports-http</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.thrift</groupId>
+            <artifactId>libthrift</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>com.caucho</groupId>
+            <artifactId>hessian</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>javax.servlet</groupId>
+            <artifactId>servlet-api</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.mortbay.jetty</groupId>
+            <artifactId>jetty</artifactId>
+        </dependency>
+
 
         <dependency>
             <groupId>org.apache.tomcat</groupId>
@@ -57,8 +86,6 @@
         </dependency>
     </dependencies>
 
-
-
     <build>
         <plugins>
             <plugin>
diff --git a/consumer-test/src/main/java/com/alibaba/dubbo/test/ConsumerTestApp.java b/consumer-test/src/main/java/com/alibaba/dubbo/test/ConsumerTestApp.java
index 47893d9..b1ab269 100644
--- a/consumer-test/src/main/java/com/alibaba/dubbo/test/ConsumerTestApp.java
+++ b/consumer-test/src/main/java/com/alibaba/dubbo/test/ConsumerTestApp.java
@@ -1,5 +1,7 @@
 package com.alibaba.dubbo.test;
 
+import com.alibaba.dubbo.config.spring.context.annotation.DubboComponentScan;
+
 import org.springframework.boot.SpringApplication;
 import org.springframework.boot.autoconfigure.SpringBootApplication;
 
@@ -8,10 +10,12 @@
  * @date 2017/09/10
  */
 @SpringBootApplication
+@DubboComponentScan(basePackages = "com.alibaba.dubbo.test.service")
 public class ConsumerTestApp {
 
 	public static void main(String[] args) throws InterruptedException {
 		SpringApplication.run(ConsumerTestApp.class, args);
 		Thread.sleep(100000000);
 	}
+
 }
diff --git a/consumer-test/src/main/java/com/alibaba/dubbo/test/DubboServiceTestRunner.java b/consumer-test/src/main/java/com/alibaba/dubbo/test/DubboServiceTestRunner.java
new file mode 100644
index 0000000..e730130
--- /dev/null
+++ b/consumer-test/src/main/java/com/alibaba/dubbo/test/DubboServiceTestRunner.java
@@ -0,0 +1,82 @@
+package com.alibaba.dubbo.test;
+
+import com.alibaba.dubbo.common.logger.Logger;
+import com.alibaba.dubbo.common.logger.LoggerFactory;
+import com.alibaba.dubbo.config.annotation.Reference;
+import com.alibaba.dubbo.rpc.service.GenericService;
+import com.alibaba.dubbo.test.service.AnnotateService;
+import com.alibaba.dubbo.test.service.AsyncService;
+import com.alibaba.dubbo.test.service.DemoService;
+
+import org.springframework.beans.BeansException;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.context.ApplicationContext;
+import org.springframework.context.ApplicationContextAware;
+import org.springframework.stereotype.Service;
+
+import javax.annotation.PostConstruct;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Map;
+import java.util.Set;
+
+/**
+ * 自动执行一遍所有服务调用
+ *
+ * @author ken.lj
+ * @date 2017/11/3
+ */
+@Service
+public class DubboServiceTestRunner implements ApplicationContextAware {
+    Logger logger = LoggerFactory.getLogger(DubboServiceTestRunner.class);
+    private ApplicationContext context;
+
+    @Autowired
+    private DemoService demoService;
+
+    @Autowired
+    private AsyncService asyncService;
+
+    @Reference
+    private AnnotateService annotateService;
+
+    @PostConstruct
+    public void start() {
+        logger.info("******  start testcase!  ******");
+        try {
+            runSimple();
+            runAync();
+            runAnnotate();
+            runGeneric();
+        } catch (Throwable t) {
+            logger.error("有测试用例报错,请检查!", t);
+        }
+    }
+
+    public void runSimple() {
+        demoService.testString("string param");
+    }
+
+    public void runAync() {
+        asyncService.asyncMethod();
+    }
+
+    public void runAnnotate() {
+        annotateService.sayHello();
+    }
+
+    public void runGeneric() {
+        GenericService genericService = (GenericService) context.getBean("genericTestService");
+        Map<String, Set<String>> map = new HashMap<String, Set<String>>();
+        Set<String> set = new HashSet<String>();
+        set.add("v1");
+        set.add("v2");
+        map.put("key", set);
+        Object result = genericService.$invoke("testGenericWithJsonSerialization", new String[]{"java.util.Map"}, new Object[]{map});
+    }
+
+    @Override
+    public void setApplicationContext(ApplicationContext applicationContext) throws BeansException {
+        this.context = applicationContext;
+    }
+}
diff --git a/consumer-test/src/main/java/com/alibaba/dubbo/test/conf/DubboConfiguration.java b/consumer-test/src/main/java/com/alibaba/dubbo/test/conf/DubboConfiguration.java
index cce5046..1caacce 100644
--- a/consumer-test/src/main/java/com/alibaba/dubbo/test/conf/DubboConfiguration.java
+++ b/consumer-test/src/main/java/com/alibaba/dubbo/test/conf/DubboConfiguration.java
@@ -1,5 +1,10 @@
 package com.alibaba.dubbo.test.conf;
 
+import com.alibaba.dubbo.config.ApplicationConfig;
+import com.alibaba.dubbo.config.ConsumerConfig;
+import com.alibaba.dubbo.config.RegistryConfig;
+
+import org.springframework.context.annotation.Bean;
 import org.springframework.context.annotation.Configuration;
 import org.springframework.context.annotation.ImportResource;
 
@@ -8,7 +13,28 @@
  * @date 2017/09/10
  */
 @Configuration
-@ImportResource(locations = {"classpath:dubbo-common.xml", "classpath:dubbo-${config.file}.xml"})
+@ImportResource(locations = {"classpath:*.xml"})
 public class DubboConfiguration {
 
+    @Bean
+    public ApplicationConfig applicationConfig() {
+        ApplicationConfig applicationConfig = new ApplicationConfig();
+        applicationConfig.setName("consumer-test");
+        return applicationConfig;
+    }
+
+    @Bean
+    public ConsumerConfig consumerConfig() {
+        ConsumerConfig consumerConfig = new ConsumerConfig();
+        consumerConfig.setTimeout(3000);
+        return consumerConfig;
+    }
+
+    @Bean
+    public RegistryConfig registryConfig() {
+        RegistryConfig registryConfig = new RegistryConfig();
+        registryConfig.setAddress("zookeeper://127.0.0.1:2181");
+        registryConfig.setClient("curator");
+        return registryConfig;
+    }
 }
diff --git a/consumer-test/src/main/java/com/alibaba/dubbo/test/web/AnnotationParentReferenceController.java b/consumer-test/src/main/java/com/alibaba/dubbo/test/web/AnnotationParentReferenceController.java
new file mode 100644
index 0000000..6b66f39
--- /dev/null
+++ b/consumer-test/src/main/java/com/alibaba/dubbo/test/web/AnnotationParentReferenceController.java
@@ -0,0 +1,24 @@
+package com.alibaba.dubbo.test.web;
+
+import com.alibaba.dubbo.config.annotation.Reference;
+import com.alibaba.dubbo.test.service.AnnotateService;
+
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+/**
+ * @author ken.lj
+ * @date 2017/09/10
+ */
+@RestController("annotation")
+public class AnnotationParentReferenceController extends BaseController<AnnotateService> {
+
+    @Reference
+    public AnnotateService annotateServiceSub;
+
+    @RequestMapping("/subclass")
+    String subHello() {
+        return annotateServiceSub.sayHello();
+    }
+
+}
diff --git a/consumer-test/src/main/java/com/alibaba/dubbo/test/web/AsyncController.java b/consumer-test/src/main/java/com/alibaba/dubbo/test/web/AsyncController.java
new file mode 100644
index 0000000..9b1d6af
--- /dev/null
+++ b/consumer-test/src/main/java/com/alibaba/dubbo/test/web/AsyncController.java
@@ -0,0 +1,31 @@
+package com.alibaba.dubbo.test.web;
+
+import com.alibaba.dubbo.rpc.RpcContext;
+import com.alibaba.dubbo.test.service.AsyncService;
+
+import org.junit.Assert;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+import java.util.concurrent.Future;
+
+/**
+ * @author ken.lj
+ * @date 2017/11/3
+ */
+@RestController
+@RequestMapping("/async")
+public class AsyncController {
+    @Autowired(required = false)
+    private AsyncService asyncService;
+
+    @RequestMapping("/hello")
+    public String testSimple() throws Exception {
+        String result = asyncService.asyncMethod();
+        Assert.assertNull(result);
+        Future<String> future = RpcContext.getContext().getFuture();
+
+        return future.get();
+    }
+}
diff --git a/consumer-test/src/main/java/com/alibaba/dubbo/test/web/BaseController.java b/consumer-test/src/main/java/com/alibaba/dubbo/test/web/BaseController.java
index 8b940ec..bdf65ee 100644
--- a/consumer-test/src/main/java/com/alibaba/dubbo/test/web/BaseController.java
+++ b/consumer-test/src/main/java/com/alibaba/dubbo/test/web/BaseController.java
@@ -1,18 +1,21 @@
 package com.alibaba.dubbo.test.web;
 
+import com.alibaba.dubbo.config.annotation.Reference;
 import com.alibaba.dubbo.test.service.AnnotateService;
 
 import org.springframework.web.bind.annotation.RequestMapping;
 
 /**
+ * 测试Reference支持父类属性注入
  * @author ken.lj
  * @date 2017/09/10
  */
 public class BaseController<T extends AnnotateService> {
 
+    @Reference
     public T annotateService;
 
-    @RequestMapping("/hello")
+    @RequestMapping("/parentclass")
     String hello() {
         return annotateService.sayHello();
     }
diff --git a/consumer-test/src/main/java/com/alibaba/dubbo/test/web/GenericReferenceController.java b/consumer-test/src/main/java/com/alibaba/dubbo/test/web/GenericReferenceController.java
new file mode 100644
index 0000000..992e8c3
--- /dev/null
+++ b/consumer-test/src/main/java/com/alibaba/dubbo/test/web/GenericReferenceController.java
@@ -0,0 +1,42 @@
+package com.alibaba.dubbo.test.web;
+
+import com.alibaba.dubbo.rpc.service.GenericService;
+
+import org.springframework.beans.BeansException;
+import org.springframework.context.ApplicationContext;
+import org.springframework.context.ApplicationContextAware;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Map;
+import java.util.Set;
+
+/**
+ * @author ken.lj
+ * @date 2017/11/3
+ */
+@RestController
+@RequestMapping("/simple")
+public class GenericReferenceController implements ApplicationContextAware {
+
+    private ApplicationContext context;
+
+    @RequestMapping("/reference/generic")
+    public String testReferenceGeneric() {
+        GenericService genericService = (GenericService) context.getBean("genericTestService");
+        Map<String, Set<String>> map = new HashMap<String, Set<String>>();
+        Set<String> set = new HashSet<String>();
+        set.add("v1");
+        set.add("v2");
+        map.put("key", set);
+        Object result = genericService.$invoke("testGenericWithJsonSerialization", new String[]{"java.util.Map"}, new Object[]{map});
+        return "generic";
+    }
+
+    @Override
+    public void setApplicationContext(ApplicationContext applicationContext) throws BeansException {
+        this.context = applicationContext;
+    }
+}
diff --git a/consumer-test/src/main/java/com/alibaba/dubbo/test/web/HelloController.java b/consumer-test/src/main/java/com/alibaba/dubbo/test/web/HelloController.java
deleted file mode 100644
index 35cea8b..0000000
--- a/consumer-test/src/main/java/com/alibaba/dubbo/test/web/HelloController.java
+++ /dev/null
@@ -1,15 +0,0 @@
-package com.alibaba.dubbo.test.web;
-
-import com.alibaba.dubbo.test.service.AnnotateService;
-
-import org.springframework.web.bind.annotation.RestController;
-
-/**
- * @author ken.lj
- * @date 2017/09/10
- */
-@RestController
-public class HelloController extends BaseController<AnnotateService> {
-
-
-}
diff --git a/consumer-test/src/main/java/com/alibaba/dubbo/test/web/SimpleController.java b/consumer-test/src/main/java/com/alibaba/dubbo/test/web/SimpleController.java
new file mode 100644
index 0000000..57faf1b
--- /dev/null
+++ b/consumer-test/src/main/java/com/alibaba/dubbo/test/web/SimpleController.java
@@ -0,0 +1,27 @@
+package com.alibaba.dubbo.test.web;
+
+import com.alibaba.dubbo.test.service.DemoService;
+
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+/**
+ * @author ken.lj
+ * @date 2017/09/10
+ */
+@RestController
+@RequestMapping("/simple")
+public class SimpleController {
+
+    @Autowired(required = false)
+    private DemoService demoService;
+
+    @RequestMapping("/hello")
+    public String testSimple() {
+        String result = demoService.testString("hello");
+        System.out.println(result);
+        return "DemoService string";
+    }
+
+}
diff --git a/consumer-test/src/main/java/com/alibaba/dubbo/test/web/TestcaseController.java b/consumer-test/src/main/java/com/alibaba/dubbo/test/web/TestcaseController.java
deleted file mode 100644
index 0ffbf15..0000000
--- a/consumer-test/src/main/java/com/alibaba/dubbo/test/web/TestcaseController.java
+++ /dev/null
@@ -1,145 +0,0 @@
-package com.alibaba.dubbo.test.web;
-
-import com.alibaba.dubbo.rpc.RpcContext;
-import com.alibaba.dubbo.rpc.service.GenericService;
-import com.alibaba.dubbo.test.dto.Bean;
-import com.alibaba.dubbo.test.service.AnnotateService;
-import com.alibaba.dubbo.test.service.AsyncService;
-import com.alibaba.dubbo.test.service.CacheService;
-import com.alibaba.dubbo.test.service.DemoService;
-import com.alibaba.dubbo.test.service.WSService;
-
-import org.junit.Assert;
-import org.springframework.beans.BeansException;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.context.ApplicationContext;
-import org.springframework.context.ApplicationContextAware;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RestController;
-
-import javax.annotation.Resource;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-/**
- * @author ken.lj
- * @date 2017/09/10
- */
-@RestController
-@RequestMapping("/testcase")
-public class TestcaseController implements ApplicationContextAware{
-    private ApplicationContext context;
-
-    @Resource(name="demoService")
-    private DemoService demoService;
-    // RMI RPC协议测试
-    @Resource(name="rmiDemoService")
-    private DemoService rmiDemoService;
-    @Autowired
-    private AsyncService asyncService;
-    @Autowired
-    private CacheService cacheService;
-    @Autowired
-    private WSService wsService;
-    @Autowired
-    private AnnotateService annotateService;
-
-    @RequestMapping("/all")
-    public String testAll() {
-        String arg = "hello";
-        String retStr = demoService.testString(arg);
-        Assert.assertEquals(retStr, arg);
-
-        Bean bean1 = new Bean(1, "pojo1");
-        Bean retBean = demoService.testPojo(bean1);
-//        Assert.assertEquals(retBean, bean1);
-        Assert.assertNotNull(retBean);
-
-        List<Bean> list = new ArrayList<Bean>();
-        Bean bean2 = new Bean(2, "pojo2");
-        list.add(bean1);
-        list.add(bean2);
-        List<Bean> retList = demoService.testList(list);
-//        Assert.assertEquals(retList, list);
-        Assert.assertTrue(retList.size() == 2);
-
-        Map<String, Object> map = new HashMap<String, Object>();
-        map.put("key1", bean1);
-        map.put("key2", bean2);
-        Map<String, Object> retMap = demoService.testMap(map);
-//        Assert.assertEquals(retMap, map);
-        Assert.assertTrue(map.size() == 2);
-
-        // asyncService.test();
-        return "all";
-    }
-
-    @RequestMapping("/async")
-    public String testAsync() {
-        return "async";
-    }
-
-    @RequestMapping("/cache")
-    public String testCache() {
-        return "cache";
-    }
-
-    @RequestMapping("/simple")
-    public String testSimple() {
-        String result = demoService.testString("hello");
-        System.out.println(result);
-        return "DemoService string";
-    }
-
-    @RequestMapping("/annotate")
-    public String testAnnotate() {
-        return "annotate";
-    }
-
-    @RequestMapping("/reference/generic")
-    public String testReferenceGeneric() {
-        GenericService genericService = (GenericService)context.getBean("genericTestService");
-        Map<String, Set<String>> map = new HashMap<String, Set<String>>();
-        Set<String> set = new HashSet<String>();
-        set.add("v1");
-        set.add("v2");
-        map.put("key", set);
-        Object result = genericService.$invoke("testGenericWithJsonSerialization", new String[] { "java.util.Map" }, new Object[] { map });
-        return "generic";
-    }
-
-    @RequestMapping("/rmi")
-    public String testRMI() {
-        RpcContext context = RpcContext.getContext();
-        context.setAttachment("rmikey", "rmivalue");
-        return rmiDemoService.testString("rmi");
-    }
-
-    @Override
-    public void setApplicationContext(ApplicationContext applicationContext) throws BeansException {
-        this.context = applicationContext;
-    }
-
-
-   /* @RequestMapping("/java8time")
-    public String testJava8Time() {
-        LocalDateTime localDateTime = LocalDateTime.now();
-        LocalDateTime retInstant = demoService.testJava8Time(localDateTime);
-        System.out.println(localDateTime);
-        System.out.println(retInstant);
-        return "aaa";
-    }
-
-    @RequestMapping("/java8zoneddatetime")
-    public String testJava8Zoneddatetime() {
-        ZonedDateTime zonedDateTime = ZonedDateTime.now();
-        ZonedDateTime retZonedDateTime = demoService.testJava8Time(zonedDateTime);
-        System.out.println(zonedDateTime);
-        System.out.println(retZonedDateTime);
-        return "bbb";
-    }*/
-}
diff --git a/consumer-test/src/main/resources/application.properties b/consumer-test/src/main/resources/application.properties
index e69de29..2338e47 100644
--- a/consumer-test/src/main/resources/application.properties
+++ b/consumer-test/src/main/resources/application.properties
@@ -0,0 +1 @@
+server.port=8088
\ No newline at end of file
diff --git a/consumer-test/src/main/resources/dubbo-annotation.xml b/consumer-test/src/main/resources/dubbo-annotation.xml
index 9029388..c07e53f 100644
--- a/consumer-test/src/main/resources/dubbo-annotation.xml
+++ b/consumer-test/src/main/resources/dubbo-annotation.xml
@@ -15,18 +15,7 @@
  - limitations under the License.
 -->
 <beans xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-       xmlns:dubbo="http://code.alibabatech.com/schema/dubbo"
        xmlns="http://www.springframework.org/schema/beans"
-       xmlns:context="http://www.springframework.org/schema/context"
-       xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
-	http://code.alibabatech.com/schema/dubbo http://code.alibabatech.com/schema/dubbo/dubbo.xsd
-    http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd">
-
-
-    <bean id="mouseService" class="com.alibaba.dubbo.MouseServiceImpl" />
-
-    <dubbo:annotation />
-
-    <context:component-scan base-package="com.alibaba.dubbo.test.service"> </context:component-scan>
+       xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd">
 
 </beans>
\ No newline at end of file
diff --git a/consumer-test/src/main/resources/dubbo-mouse.xml b/consumer-test/src/main/resources/dubbo-async.xml
similarity index 83%
rename from consumer-test/src/main/resources/dubbo-mouse.xml
rename to consumer-test/src/main/resources/dubbo-async.xml
index 23204d8..07aee2e 100644
--- a/consumer-test/src/main/resources/dubbo-mouse.xml
+++ b/consumer-test/src/main/resources/dubbo-async.xml
@@ -20,9 +20,6 @@
        xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
 	http://code.alibabatech.com/schema/dubbo http://code.alibabatech.com/schema/dubbo/dubbo.xsd">
 
-    <bean id="mouseService" class="com.alibaba.dubbo.MouseServiceImpl" />
-
-    <!-- 和本地bean一样实现服务 -->
-    <dubbo:service interface="com.alibaba.dubbo.test.service.MouseService" ref="mouseService"/>
+    <dubbo:reference id="asyncService" async="true" interface="com.alibaba.dubbo.test.service.AsyncService"/>
 
 </beans>
\ No newline at end of file
diff --git a/consumer-test/src/main/resources/dubbo-cat.xml b/consumer-test/src/main/resources/dubbo-cat.xml
deleted file mode 100644
index 3a92d66..0000000
--- a/consumer-test/src/main/resources/dubbo-cat.xml
+++ /dev/null
@@ -1,29 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- - Copyright 1999-2011 Alibaba Group.
- -  
- - Licensed under the Apache License, Version 2.0 (the "License");
- - you may not use this file except in compliance with the License.
- - You may obtain a copy of the License at
- -  
- -      http://www.apache.org/licenses/LICENSE-2.0
- -  
- - Unless required by applicable law or agreed to in writing, software
- - distributed under the License is distributed on an "AS IS" BASIS,
- - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- - See the License for the specific language governing permissions and
- - limitations under the License.
--->
-<beans xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-       xmlns:dubbo="http://code.alibabatech.com/schema/dubbo"
-       xmlns="http://www.springframework.org/schema/beans"
-       xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
-	http://code.alibabatech.com/schema/dubbo http://code.alibabatech.com/schema/dubbo/dubbo.xsd">
-
-
-    <!-- 和本地bean一样实现服务 -->
-    <dubbo:service interface="com.alibaba.dubbo.test.service.CatService" ref="catService"/>
-
-    <dubbo:reference id="mouseService" interface="com.alibaba.dubbo.test.service.MouseService" />
-
-</beans>
\ No newline at end of file
diff --git a/consumer-test/src/main/resources/dubbo-common.xml b/consumer-test/src/main/resources/dubbo-common.xml
deleted file mode 100644
index 78ad5e7..0000000
--- a/consumer-test/src/main/resources/dubbo-common.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- - Copyright 1999-2011 Alibaba Group.
- -  
- - Licensed under the Apache License, Version 2.0 (the "License");
- - you may not use this file except in compliance with the License.
- - You may obtain a copy of the License at
- -  
- -      http://www.apache.org/licenses/LICENSE-2.0
- -  
- - Unless required by applicable law or agreed to in writing, software
- - distributed under the License is distributed on an "AS IS" BASIS,
- - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- - See the License for the specific language governing permissions and
- - limitations under the License.
--->
-<beans xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-       xmlns:dubbo="http://code.alibabatech.com/schema/dubbo"
-       xmlns="http://www.springframework.org/schema/beans"
-       xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
-	http://code.alibabatech.com/schema/dubbo http://code.alibabatech.com/schema/dubbo/dubbo.xsd">
-
-    <!-- 提供方应用信息,用于计算依赖关系 -->
-    <dubbo:application name="dubbo-feature-test" />
-
-    <!-- 使用multicast广播注册中心暴露服务地址 -->
-    <dubbo:registry client="curator" address="zookeeper://127.0.0.1:2181"/>
-
-    <!-- 用dubbo协议在20880端口暴露服务 -->
-    <dubbo:protocol name="dubbo" port="-1" transporter="mina"/>
-
-</beans>
\ No newline at end of file
diff --git a/consumer-test/src/main/resources/dubbo-consumer.xml b/consumer-test/src/main/resources/dubbo-consumer.xml
index 2448c2b..978cdd1 100644
--- a/consumer-test/src/main/resources/dubbo-consumer.xml
+++ b/consumer-test/src/main/resources/dubbo-consumer.xml
@@ -19,22 +19,7 @@
        xmlns="http://www.springframework.org/schema/beans"
        xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
 	http://code.alibabatech.com/schema/dubbo http://code.alibabatech.com/schema/dubbo/dubbo.xsd">
-    
-    <dubbo:consumer />
 
     <dubbo:reference id="demoService" interface="com.alibaba.dubbo.test.service.DemoService" />
 
-    <dubbo:reference id="asyncService" interface="com.alibaba.dubbo.test.service.AsyncService" />
-
-    <dubbo:reference id="cacheService" interface="com.alibaba.dubbo.test.service.CacheService" />
-
-    <dubbo:reference id="wsService" interface="com.alibaba.dubbo.test.service.WSService" />
-
-    <dubbo:reference id="annotateService" interface="com.alibaba.dubbo.test.service.AnnotateService" />
-
-    <dubbo:reference id="genericTestService" generic="true"  interface="com.alibaba.dubbo.test.service.GenericTestService" />
-
-    <!-- RMI RPC测试 -->
-    <dubbo:reference id="rmiDemoService" interface="com.alibaba.dubbo.test.service.DemoService" protocol="rmi"/>
-
 </beans>
\ No newline at end of file
diff --git a/consumer-test/src/main/resources/dubbo-dog.xml b/consumer-test/src/main/resources/dubbo-dog.xml
deleted file mode 100644
index d9794ed..0000000
--- a/consumer-test/src/main/resources/dubbo-dog.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- - Copyright 1999-2011 Alibaba Group.
- -  
- - Licensed under the Apache License, Version 2.0 (the "License");
- - you may not use this file except in compliance with the License.
- - You may obtain a copy of the License at
- -  
- -      http://www.apache.org/licenses/LICENSE-2.0
- -  
- - Unless required by applicable law or agreed to in writing, software
- - distributed under the License is distributed on an "AS IS" BASIS,
- - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- - See the License for the specific language governing permissions and
- - limitations under the License.
--->
-<beans xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-       xmlns:dubbo="http://code.alibabatech.com/schema/dubbo"
-       xmlns="http://www.springframework.org/schema/beans"
-       xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
-	http://code.alibabatech.com/schema/dubbo http://code.alibabatech.com/schema/dubbo/dubbo.xsd">
-
-    <!-- 和本地bean一样实现服务 -->
-    <dubbo:service interface="com.alibaba.dubbo.test.service.DogService" ref="dogService"/>
-
-    <dubbo:reference id="catService" interface="com.alibaba.dubbo.test.service.CatService" />
-
-    <dubbo:reference id="mouseService" interface="com.alibaba.dubbo.test.service.MouseService" />
-
-</beans>
\ No newline at end of file
diff --git a/consumer-test/src/main/resources/dubbo-lion.xml b/consumer-test/src/main/resources/dubbo-lion.xml
deleted file mode 100644
index e7c6b13..0000000
--- a/consumer-test/src/main/resources/dubbo-lion.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- - Copyright 1999-2011 Alibaba Group.
- -  
- - Licensed under the Apache License, Version 2.0 (the "License");
- - you may not use this file except in compliance with the License.
- - You may obtain a copy of the License at
- -  
- -      http://www.apache.org/licenses/LICENSE-2.0
- -  
- - Unless required by applicable law or agreed to in writing, software
- - distributed under the License is distributed on an "AS IS" BASIS,
- - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- - See the License for the specific language governing permissions and
- - limitations under the License.
--->
-<beans xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-       xmlns:dubbo="http://code.alibabatech.com/schema/dubbo"
-       xmlns="http://www.springframework.org/schema/beans"
-       xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
-	http://code.alibabatech.com/schema/dubbo http://code.alibabatech.com/schema/dubbo/dubbo.xsd">
-
-    <!-- 和本地bean一样实现服务 -->
-    <dubbo:service interface="com.alibaba.dubbo.test.service.LionService" ref="lionService"/>
-
-    <dubbo:reference id="mouseService" interface="com.alibaba.dubbo.test.service.MouseService" />
-
-    <dubbo:reference id="dogService" interface="com.alibaba.dubbo.test.service.DogService" />
-
-    <dubbo:reference id="catService" interface="com.alibaba.dubbo.test.service.CatService" />
-
-</beans>
\ No newline at end of file
diff --git a/pom.xml b/pom.xml
index 6ffc96e..d3d63c5 100644
--- a/pom.xml
+++ b/pom.xml
@@ -50,7 +50,7 @@
 		<dependency>
 			<groupId>com.alibaba</groupId>
 			<artifactId>dubbo</artifactId>
-			<version>2.5.6</version>
+			<version>2.5.7</version>
 		</dependency>
 		<dependency>
 			<groupId>io.netty</groupId>
@@ -73,6 +73,37 @@
 			<version>1.2.31</version>
 		</dependency>
 		<dependency>
+			<groupId>org.apache.cxf</groupId>
+			<artifactId>cxf-rt-frontend-simple</artifactId>
+			<version>3.0.14</version>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.cxf</groupId>
+			<artifactId>cxf-rt-transports-http</artifactId>
+			<version>3.0.14</version>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.thrift</groupId>
+			<artifactId>libthrift</artifactId>
+			<version>0.8.0</version>
+		</dependency>
+		<dependency>
+			<groupId>com.caucho</groupId>
+			<artifactId>hessian</artifactId>
+			<version>4.0.38</version>
+		</dependency>
+		<dependency>
+			<groupId>javax.servlet</groupId>
+			<artifactId>servlet-api</artifactId>
+			<version>2.5</version>
+		</dependency>
+		<dependency>
+			<groupId>org.mortbay.jetty</groupId>
+			<artifactId>jetty</artifactId>
+			<version>6.1.26</version>
+		</dependency>
+
+		<dependency>
 			<groupId>org.apache.tomcat</groupId>
 			<artifactId>tomcat-juli</artifactId>
 			<version>${tomcat.version}</version>
diff --git a/provider-test/pom.xml b/provider-test/pom.xml
index 900bf28..70d9015 100644
--- a/provider-test/pom.xml
+++ b/provider-test/pom.xml
@@ -23,6 +23,10 @@
         </dependency>
         <dependency>
             <groupId>org.springframework.boot</groupId>
+            <artifactId>spring-boot-starter-aop</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.springframework.boot</groupId>
             <artifactId>spring-boot-starter-jdbc</artifactId>
         </dependency>
 
@@ -48,9 +52,30 @@
             <artifactId>curator-framework</artifactId>
         </dependency>
         <dependency>
-            <groupId>com.alibaba</groupId>
-            <artifactId>fastjson</artifactId>
+            <groupId>org.apache.cxf</groupId>
+            <artifactId>cxf-rt-frontend-simple</artifactId>
         </dependency>
+        <dependency>
+            <groupId>org.apache.cxf</groupId>
+            <artifactId>cxf-rt-transports-http</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.thrift</groupId>
+            <artifactId>libthrift</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>com.caucho</groupId>
+            <artifactId>hessian</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>javax.servlet</groupId>
+            <artifactId>servlet-api</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.mortbay.jetty</groupId>
+            <artifactId>jetty</artifactId>
+        </dependency>
+
 
         <dependency>
             <groupId>junit</groupId>
diff --git a/provider-test/src/main/java/com/alibaba/dubbo/test/ProviderTestApp.java b/provider-test/src/main/java/com/alibaba/dubbo/test/ProviderTestApp.java
index ec36149..f9f52a7 100644
--- a/provider-test/src/main/java/com/alibaba/dubbo/test/ProviderTestApp.java
+++ b/provider-test/src/main/java/com/alibaba/dubbo/test/ProviderTestApp.java
@@ -1,14 +1,17 @@
 package com.alibaba.dubbo.test;
 
-import org.springframework.boot.SpringApplication;
+import com.alibaba.dubbo.config.spring.context.annotation.DubboComponentScan;
+
 import org.springframework.boot.autoconfigure.SpringBootApplication;
+import org.springframework.boot.builder.SpringApplicationBuilder;
 
 
 @SpringBootApplication
+@DubboComponentScan(basePackages = "com.alibaba.dubbo.test.service.impl")
 public class ProviderTestApp {
 
 	public static void main(String[] args) throws InterruptedException {
-		SpringApplication.run(ProviderTestApp.class, args);
+		new SpringApplicationBuilder(ProviderTestApp.class).web(false).run(args);
 		Thread.sleep(100000000);
 	}
 }
diff --git a/provider-test/src/main/java/com/alibaba/dubbo/test/conf/DubboConfiguration.java b/provider-test/src/main/java/com/alibaba/dubbo/test/conf/DubboConfiguration.java
index cce5046..8923085 100644
--- a/provider-test/src/main/java/com/alibaba/dubbo/test/conf/DubboConfiguration.java
+++ b/provider-test/src/main/java/com/alibaba/dubbo/test/conf/DubboConfiguration.java
@@ -8,7 +8,7 @@
  * @date 2017/09/10
  */
 @Configuration
-@ImportResource(locations = {"classpath:dubbo-common.xml", "classpath:dubbo-${config.file}.xml"})
+@ImportResource(locations = {"classpath:*.xml"})
 public class DubboConfiguration {
 
 }
diff --git a/provider-test/src/main/java/com/alibaba/dubbo/test/service/chain/impl/CatServiceImpl.java b/provider-test/src/main/java/com/alibaba/dubbo/test/service/chain/impl/CatServiceImpl.java
deleted file mode 100644
index d46e1a9..0000000
--- a/provider-test/src/main/java/com/alibaba/dubbo/test/service/chain/impl/CatServiceImpl.java
+++ /dev/null
@@ -1,30 +0,0 @@
-package com.alibaba.dubbo.test.service.chain.impl;
-
-
-import com.alibaba.dubbo.test.service.chain.CatService;
-import com.alibaba.dubbo.test.service.chain.MouseService;
-
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-
-/**
- * @author ken.lj
- * @date 2017/09/10
- */
-@Service("catService")
-public class CatServiceImpl implements CatService {
-
-    @Autowired
-    private MouseService mouseService;
-
-    @Override
-    public void eat(String master) {
-        System.out.println(master + " eat me.");
-        mouseService.eat("Cat");
-    }
-
-    @Override
-    public String getName() {
-        return "Tom Cat";
-    }
-}
diff --git a/provider-test/src/main/java/com/alibaba/dubbo/test/service/chain/impl/DogServiceImpl.java b/provider-test/src/main/java/com/alibaba/dubbo/test/service/chain/impl/DogServiceImpl.java
deleted file mode 100644
index 39c03d6..0000000
--- a/provider-test/src/main/java/com/alibaba/dubbo/test/service/chain/impl/DogServiceImpl.java
+++ /dev/null
@@ -1,33 +0,0 @@
-package com.alibaba.dubbo.test.service.chain.impl;
-
-import com.alibaba.dubbo.test.service.chain.CatService;
-import com.alibaba.dubbo.test.service.chain.DogService;
-import com.alibaba.dubbo.test.service.chain.MouseService;
-
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-
-/**
- * @author ken.lj
- * @date 2017/09/10
- */
-@Service("dogService")
-public class DogServiceImpl implements DogService {
-    @Autowired
-    private CatService catService;
-
-    @Autowired
-    private MouseService mouseService;
-
-    @Override
-    public void eat(String master) {
-        System.out.println(master + " eat me.");
-        catService.eat("cat");
-        mouseService.eat("mouse");
-    }
-
-    @Override
-    public String getName() {
-        return "Hachiko Dog";
-    }
-}
diff --git a/provider-test/src/main/java/com/alibaba/dubbo/test/service/chain/impl/LionServiceImpl.java b/provider-test/src/main/java/com/alibaba/dubbo/test/service/chain/impl/LionServiceImpl.java
deleted file mode 100644
index f3cebeb..0000000
--- a/provider-test/src/main/java/com/alibaba/dubbo/test/service/chain/impl/LionServiceImpl.java
+++ /dev/null
@@ -1,38 +0,0 @@
-package com.alibaba.dubbo.test.service.chain.impl;
-
-import com.alibaba.dubbo.test.service.chain.CatService;
-import com.alibaba.dubbo.test.service.chain.DogService;
-import com.alibaba.dubbo.test.service.chain.LionService;
-import com.alibaba.dubbo.test.service.chain.MouseService;
-
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-
-/**
- * @author ken.lj
- * @date 2017/09/10
- */
-@Service("lionService")
-public class LionServiceImpl implements LionService {
-    @Autowired
-    private CatService catService;
-
-    @Autowired
-    private MouseService mouseService;
-
-    @Autowired
-    private DogService dogService;
-
-    @Override
-    public void eat(String master) {
-        System.out.println(master + " eat me.");
-        dogService.eat("dog");
-        catService.eat("cat");
-        mouseService.eat("mouse");
-    }
-
-    @Override
-    public String getName() {
-        return "Simba Lion";
-    }
-}
diff --git a/provider-test/src/main/java/com/alibaba/dubbo/test/service/chain/impl/MouseServiceImpl.java b/provider-test/src/main/java/com/alibaba/dubbo/test/service/chain/impl/MouseServiceImpl.java
deleted file mode 100644
index f754aed..0000000
--- a/provider-test/src/main/java/com/alibaba/dubbo/test/service/chain/impl/MouseServiceImpl.java
+++ /dev/null
@@ -1,22 +0,0 @@
-package com.alibaba.dubbo.test.service.chain.impl;
-
-import com.alibaba.dubbo.test.service.chain.MouseService;
-
-import org.springframework.stereotype.Service;
-
-/**
- * @author ken.lj
- * @date 2017/09/10
- */
-@Service("mouseService")
-public class MouseServiceImpl implements MouseService {
-    @Override
-    public void eat(String master) {
-        System.out.println(master + " eat me.");
-    }
-
-    @Override
-    public String getName() {
-        return "Mickey mouse";
-    }
-}
diff --git a/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/AnnotateServiceImpl.java b/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/AnnotateServiceImpl.java
index d6565c6..0f5035b 100644
--- a/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/AnnotateServiceImpl.java
+++ b/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/AnnotateServiceImpl.java
@@ -1,6 +1,5 @@
 package com.alibaba.dubbo.test.service.impl;
 
-import com.alibaba.dubbo.config.annotation.Service;
 import com.alibaba.dubbo.test.service.AnnotateService;
 
 import org.springframework.transaction.annotation.Transactional;
@@ -10,8 +9,9 @@
  * @author ken.lj
  * @date 2017/09/10
  */
-@Service
+@com.alibaba.dubbo.config.annotation.Service(timeout = 5000, application = "provider-test")
 public class AnnotateServiceImpl implements AnnotateService {
+
     @Override
     @Transactional
     public String sayHello() {
diff --git a/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/AsycServiceImpl.java b/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/AsycServiceImpl.java
index 385aa25..94b42f4 100644
--- a/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/AsycServiceImpl.java
+++ b/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/AsycServiceImpl.java
@@ -2,9 +2,18 @@
 
 import com.alibaba.dubbo.test.service.AsyncService;
 
+import org.springframework.stereotype.Service;
+
 /**
  * @author ken.lj
  * @date 2017/09/10
  */
+@Service("asyncService")
 public class AsycServiceImpl implements AsyncService{
+
+    @Override
+    public String asyncMethod() {
+        return null;
+    }
+
 }
diff --git a/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/CacheServiceImpl.java b/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/CacheServiceImpl.java
deleted file mode 100644
index 8388dd2..0000000
--- a/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/CacheServiceImpl.java
+++ /dev/null
@@ -1,10 +0,0 @@
-package com.alibaba.dubbo.test.service.impl;
-
-import com.alibaba.dubbo.test.service.CacheService;
-
-/**
- * @author ken.lj
- * @date 2017/09/10
- */
-public class CacheServiceImpl implements CacheService {
-}
diff --git a/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/DemoServiceImpl.java b/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/DemoServiceImpl.java
index bf7d8e3..82ba4c5 100644
--- a/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/DemoServiceImpl.java
+++ b/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/DemoServiceImpl.java
@@ -4,16 +4,20 @@
 import com.alibaba.dubbo.test.dto.SubMap;
 import com.alibaba.dubbo.test.service.DemoService;
 
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
 import java.util.List;
 import java.util.Map;
-import java.util.Set;
 
 /**
  * @author ken.lj
  * @date 2017/09/10
  */
+@Service("demoService")
 public class DemoServiceImpl implements DemoService {
     @Override
+    @Transactional
     public String testString(String str) {
         return str;
     }
diff --git a/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/GenericTestServiceImpl.java b/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/GenericTestServiceImpl.java
index f35ec32..79a7da4 100644
--- a/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/GenericTestServiceImpl.java
+++ b/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/GenericTestServiceImpl.java
@@ -2,6 +2,8 @@
 
 import com.alibaba.dubbo.test.service.GenericTestService;
 
+import org.springframework.stereotype.Service;
+
 import java.util.Map;
 import java.util.Set;
 
@@ -9,6 +11,7 @@
  * @author ken.lj
  * @date 2017/09/10
  */
+@Service("genericService")
 public class GenericTestServiceImpl implements GenericTestService {
     @Override
     public void testGenericWithJsonSerialization(Map<String, Set<String>> params) {
diff --git a/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/WSServiceImpl.java b/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/WSServiceImpl.java
deleted file mode 100644
index 3771039..0000000
--- a/provider-test/src/main/java/com/alibaba/dubbo/test/service/impl/WSServiceImpl.java
+++ /dev/null
@@ -1,10 +0,0 @@
-package com.alibaba.dubbo.test.service.impl;
-
-import com.alibaba.dubbo.test.service.WSService;
-
-/**
- * @author ken.lj
- * @date 2017/09/10
- */
-public class WSServiceImpl implements WSService {
-}
diff --git a/provider-test/src/main/resources/dubbo-annotation.xml b/provider-test/src/main/resources/dubbo-annotation.xml
index ee1261c..a175ae7 100644
--- a/provider-test/src/main/resources/dubbo-annotation.xml
+++ b/provider-test/src/main/resources/dubbo-annotation.xml
@@ -15,17 +15,13 @@
  - limitations under the License.
 -->
 <beans xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-       xmlns:dubbo="http://code.alibabatech.com/schema/dubbo"
        xmlns="http://www.springframework.org/schema/beans"
-       xmlns:context="http://www.springframework.org/schema/context"
-       xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
-	http://code.alibabatech.com/schema/dubbo http://code.alibabatech.com/schema/dubbo/dubbo.xsd
-    http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd">
+       xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd">
 
-    <dubbo:annotation package="com.alibaba.dubbo.test.service"/>
+    <!--<dubbo:annotation package="com.alibaba.dubbo.test.service"/>-->
 
-    <context:component-scan base-package="com.alibaba.dubbo.test.service"> </context:component-scan>
+    <!--<context:component-scan base-package="com.alibaba.dubbo.test.service"> </context:component-scan>-->
 
-
-
+    <!--<dubbo:service interface="com.alibaba.dubbo.test.service.AnnotateService" ref="annotateService"/>-->
+    <!--<bean id="demoService" class="com.alibaba.dubbo.test.service.impl.DemoServiceImpl" />-->
 </beans>
\ No newline at end of file
diff --git a/provider-test/src/main/resources/dubbo-mouse.xml b/provider-test/src/main/resources/dubbo-async.xml
similarity index 83%
rename from provider-test/src/main/resources/dubbo-mouse.xml
rename to provider-test/src/main/resources/dubbo-async.xml
index 23204d8..e47eb72 100644
--- a/provider-test/src/main/resources/dubbo-mouse.xml
+++ b/provider-test/src/main/resources/dubbo-async.xml
@@ -20,9 +20,6 @@
        xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
 	http://code.alibabatech.com/schema/dubbo http://code.alibabatech.com/schema/dubbo/dubbo.xsd">
 
-    <bean id="mouseService" class="com.alibaba.dubbo.MouseServiceImpl" />
-
-    <!-- 和本地bean一样实现服务 -->
-    <dubbo:service interface="com.alibaba.dubbo.test.service.MouseService" ref="mouseService"/>
+    <dubbo:service interface="com.alibaba.dubbo.test.service.AsyncService" ref="asyncService"/>
 
 </beans>
\ No newline at end of file
diff --git a/provider-test/src/main/resources/dubbo-cat.xml b/provider-test/src/main/resources/dubbo-cat.xml
deleted file mode 100644
index 3a92d66..0000000
--- a/provider-test/src/main/resources/dubbo-cat.xml
+++ /dev/null
@@ -1,29 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- - Copyright 1999-2011 Alibaba Group.
- -  
- - Licensed under the Apache License, Version 2.0 (the "License");
- - you may not use this file except in compliance with the License.
- - You may obtain a copy of the License at
- -  
- -      http://www.apache.org/licenses/LICENSE-2.0
- -  
- - Unless required by applicable law or agreed to in writing, software
- - distributed under the License is distributed on an "AS IS" BASIS,
- - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- - See the License for the specific language governing permissions and
- - limitations under the License.
--->
-<beans xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-       xmlns:dubbo="http://code.alibabatech.com/schema/dubbo"
-       xmlns="http://www.springframework.org/schema/beans"
-       xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
-	http://code.alibabatech.com/schema/dubbo http://code.alibabatech.com/schema/dubbo/dubbo.xsd">
-
-
-    <!-- 和本地bean一样实现服务 -->
-    <dubbo:service interface="com.alibaba.dubbo.test.service.CatService" ref="catService"/>
-
-    <dubbo:reference id="mouseService" interface="com.alibaba.dubbo.test.service.MouseService" />
-
-</beans>
\ No newline at end of file
diff --git a/provider-test/src/main/resources/dubbo-common.xml b/provider-test/src/main/resources/dubbo-common.xml
index ef4cd6a..7ad547c 100644
--- a/provider-test/src/main/resources/dubbo-common.xml
+++ b/provider-test/src/main/resources/dubbo-common.xml
@@ -20,13 +20,18 @@
        xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
 	http://code.alibabatech.com/schema/dubbo http://code.alibabatech.com/schema/dubbo/dubbo.xsd">
 
-    <!--<dubbo:application name="provider-test" />-->
+    <dubbo:application name="provider-test"/>
     <!--<dubbo:monitor address="zabbix://127.0.0.1:20880" />-->
 
     <!-- 使用multicast广播注册中心暴露服务地址 -->
     <dubbo:registry client="curator" address="zookeeper://127.0.0.1:2181"/>
 
+    <!-- 注册中心分组测试 -->
+    <dubbo:registry client="curator" group="testgroup" address="zookeeper://127.0.0.1:2181"/>
+
     <!-- 用dubbo协议在20880端口暴露服务 -->
-    <dubbo:protocol name="dubbo" port="-1" transporter="netty4" />
+    <dubbo:protocol accesslog="true" name="dubbo" port="-1" transporter="netty4"/>
+
+    <dubbo:provider delay="-1"/>
 
 </beans>
\ No newline at end of file
diff --git a/provider-test/src/main/resources/dubbo-dog.xml b/provider-test/src/main/resources/dubbo-dog.xml
deleted file mode 100644
index d9794ed..0000000
--- a/provider-test/src/main/resources/dubbo-dog.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- - Copyright 1999-2011 Alibaba Group.
- -  
- - Licensed under the Apache License, Version 2.0 (the "License");
- - you may not use this file except in compliance with the License.
- - You may obtain a copy of the License at
- -  
- -      http://www.apache.org/licenses/LICENSE-2.0
- -  
- - Unless required by applicable law or agreed to in writing, software
- - distributed under the License is distributed on an "AS IS" BASIS,
- - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- - See the License for the specific language governing permissions and
- - limitations under the License.
--->
-<beans xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-       xmlns:dubbo="http://code.alibabatech.com/schema/dubbo"
-       xmlns="http://www.springframework.org/schema/beans"
-       xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
-	http://code.alibabatech.com/schema/dubbo http://code.alibabatech.com/schema/dubbo/dubbo.xsd">
-
-    <!-- 和本地bean一样实现服务 -->
-    <dubbo:service interface="com.alibaba.dubbo.test.service.DogService" ref="dogService"/>
-
-    <dubbo:reference id="catService" interface="com.alibaba.dubbo.test.service.CatService" />
-
-    <dubbo:reference id="mouseService" interface="com.alibaba.dubbo.test.service.MouseService" />
-
-</beans>
\ No newline at end of file
diff --git a/provider-test/src/main/resources/dubbo-lion.xml b/provider-test/src/main/resources/dubbo-lion.xml
deleted file mode 100644
index e7c6b13..0000000
--- a/provider-test/src/main/resources/dubbo-lion.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- - Copyright 1999-2011 Alibaba Group.
- -  
- - Licensed under the Apache License, Version 2.0 (the "License");
- - you may not use this file except in compliance with the License.
- - You may obtain a copy of the License at
- -  
- -      http://www.apache.org/licenses/LICENSE-2.0
- -  
- - Unless required by applicable law or agreed to in writing, software
- - distributed under the License is distributed on an "AS IS" BASIS,
- - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- - See the License for the specific language governing permissions and
- - limitations under the License.
--->
-<beans xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-       xmlns:dubbo="http://code.alibabatech.com/schema/dubbo"
-       xmlns="http://www.springframework.org/schema/beans"
-       xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
-	http://code.alibabatech.com/schema/dubbo http://code.alibabatech.com/schema/dubbo/dubbo.xsd">
-
-    <!-- 和本地bean一样实现服务 -->
-    <dubbo:service interface="com.alibaba.dubbo.test.service.LionService" ref="lionService"/>
-
-    <dubbo:reference id="mouseService" interface="com.alibaba.dubbo.test.service.MouseService" />
-
-    <dubbo:reference id="dogService" interface="com.alibaba.dubbo.test.service.DogService" />
-
-    <dubbo:reference id="catService" interface="com.alibaba.dubbo.test.service.CatService" />
-
-</beans>
\ No newline at end of file
diff --git a/provider-test/src/main/resources/dubbo-provider.xml b/provider-test/src/main/resources/dubbo-provider.xml
index a21c5a4..eba5816 100644
--- a/provider-test/src/main/resources/dubbo-provider.xml
+++ b/provider-test/src/main/resources/dubbo-provider.xml
@@ -20,29 +20,6 @@
        xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
 	http://code.alibabatech.com/schema/dubbo http://code.alibabatech.com/schema/dubbo/dubbo.xsd">
 
-    <dubbo:provider delay="-1" protocol="" serialization="fastjson"/>
-
     <dubbo:service interface="com.alibaba.dubbo.test.service.DemoService" ref="demoService"/>
 
-    <dubbo:service async="true" interface="com.alibaba.dubbo.test.service.AsyncService" ref="asyncService"/>
-
-    <dubbo:service interface="com.alibaba.dubbo.test.service.CacheService" ref="cacheService"/>
-
-    <dubbo:service interface="com.alibaba.dubbo.test.service.WSService" ref="wsService"/>
-
-    <dubbo:service interface="com.alibaba.dubbo.test.service.AnnotateService" ref="annotateService"/>
-
-    <dubbo:service interface="com.alibaba.dubbo.test.service.GenericTestService" ref="genericTestService"/>
-
-    <!-- RMI RPC协议测试 -->
-    <dubbo:service interface="com.alibaba.dubbo.test.service.DemoService" ref="demoService" protocol="rmi"/>
-
-    <bean id="demoService" class="com.alibaba.dubbo.test.service.impl.DemoServiceImpl" />
-    <bean id="asyncService" class="com.alibaba.dubbo.test.service.impl.AsycServiceImpl" />
-    <bean id="cacheService" class="com.alibaba.dubbo.test.service.impl.CacheServiceImpl" />
-    <bean id="wsService" class="com.alibaba.dubbo.test.service.impl.WSServiceImpl" />
-    <bean id="annotateService" class="com.alibaba.dubbo.test.service.impl.AnnotateServiceImpl" />
-    <bean id="genericTestService" class="com.alibaba.dubbo.test.service.impl.GenericTestServiceImpl" />
-
-
 </beans>
\ No newline at end of file
diff --git a/provider-test/src/main/resources/dubbo.properties b/provider-test/src/main/resources/dubbo.properties
index bfb676a..4cd1d73 100644
--- a/provider-test/src/main/resources/dubbo.properties
+++ b/provider-test/src/main/resources/dubbo.properties
@@ -1,2 +1,2 @@
-dubbo.application.dump.directory=/home/ken.lj
+dubbo.application.dump.directory=/home/tmp
 dubbo.application.name=provider-test
\ No newline at end of file