dubbo-admin 在jdk8 tomcat8下启动错误解决

在jdk1.8下启动dubbo,没想到出错了,在网上查了一下说是dubbo中某些方法不规范导致在jdk1.8下报错,按照网上的办法依然不行,那只能下载源码,修改错误,重新编译错误如下:

ERROR context.ContextLoader - Context initialization failed  
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'uriBrokerService': Cannot create inner bean '(inner bean)' of type [com.alibaba.citrus.service.uribroker.impl.URIBrokerServiceImpl$URIBrokerInfo] while setting bean property 'brokers' with key [0]; nested excepti  
on is org.springframework.beans.factory.BeanCreationException: Error creating bean with name '(inner bean)#25': Cannot create inner bean 'server' of type [com.alibaba.citrus.service.uribroker.uri.GenericURIBroker] while setting constructor argument; nested exception is org.springframework.beans.fact  
ory.BeanCreationException: Error creating bean with name 'server': Error setting property values; nested exception is org.springframework.beans.NotWritablePropertyException: Invalid property 'URIType' of bean class [com.alibaba.citrus.service.uribroker.uri.GenericURIBroker]: Bean property 'URIType'  
is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?  
        at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveInnerBean(BeanDefinitionValueResolver.java:230)  
        at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:122)  
        at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveManagedList(BeanDefinitionValueResolver.java:287)


dubbo-admin 在jdk8 tomcat8下启动错误解决_第1张图片


项目比较多,但是我们只看dubbo-admin。


这里我已经编译好了可以直接下载使用,点击下载。dubbo-admin-2.5.7.war

下载地址:http://download.csdn.net/download/u010781073/10121031


打开pom.xml文件修改下列地方

1、修改citrus-webx-all版本。



2、添加velocity




3、排除spring的包。




然后保存,编译,打包重新发布,启动,这时候可以正常启动了。

dubbo-admin 在jdk8 tomcat8下启动错误解决_第2张图片



然后再浏览器输入http://127.0.0.1:8082/dubbo-admin-2.5.7/

dubbo-admin 在jdk8 tomcat8下启动错误解决_第3张图片



你可能感兴趣的:(spring)