provider.xml配置
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:dubbo="http://code.alibabatech.com/schema/dubbo"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
http://code.alibabatech.com/schema/dubbo
http://code.alibabatech.com/schema/dubbo/dubbo.xsd">
<!-- 提供方應用信息,用于計算依賴關系 -->
<dubbo:application name="hello-world-app" />
<!-- 使用multicast廣播注冊中心暴露服務地址 -->
<dubbo:registry address="multicast://224.5.6.7:1234" />
<!-- 用dubbo協議在20880端口暴露服務 -->
<dubbo:protocol name="dubbo" port="20880"/>
<!-- 聲明需要暴露的服務接口 -->
<dubbo:service interface="com.alibaba.dubbo.demo.DemoService" ref="demoService"/>
<!-- 和本地bean一樣實現服務 -->
<bean id="demoService" class="com.alibaba.dubbo.demo.provider.DemoServiceImpl"/>
</beans>
<dubbo:application>配置選項:
標簽|屬性|對應URL參數|類型|是否必填|缺省值|作用|描述
-|-:
<dubbo:application>|name|application|string|必填||服務治理|當前應用名稱,用于注冊中心計算應用間依賴關系,注意:消費者和提供者應用名不要一樣,此參數不是匹配條件,你當前項目叫什么名字就填什么,和提供者消費者角色無關,比如:kylin應用調用了morgan應用的服務,則kylin項目配成kylin,morgan項目配成morgan,可能kylin也提供其它服務給別人使用,但kylin項目永遠配成kylin,這樣注冊中心將顯示kylin依賴于morgan
<dubbo:application>|version|application.version|string|可選||服務治理|當前應用的版本
<dubbo:application>|owner|owner|string|可選||服務治理|應用負責人,用于服務治理,請填寫負責人公司郵箱前綴
<div class="row">
<div class="span4">
<table>
<tr>
</tr>
</table>
</div>
</div>
<div>
<table border="1">
<tr>
<td>sdfsdfsdf</td>
</tr>
</table>
</div>```