dubbo.xml文件解析错误
pom文件报错:
– cvc-complex-type.2.4.c: The matching wildcard is strict, but no declaration can be found for element ‘dubbo:application’.
– schema_reference.4: Failed to read schema document ‘http://code.alibabatech.com/schema/dubbo/dubbo.xsd’,
because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not
解决办法:
找到dubbo的jar包,解压后在META-INF文件夹下找到dubbo.xsd
在eclipse中点击windows-->preferrence-->xml-->xmlcatalog
选择add-->catalog entry -->file system
找到dubbo.xsd文件。
key:http://code.alibabatech.com/schema/dubbo/dubbo.xsd
点击OK,点击OK。
在pom文件右击选择validate。
ok了
注意:这里的key值要与xml中的dubbo.xsd名称一致