Java自学者论坛

 找回密码
 立即注册

手机号码,快捷登录

恭喜Java自学者论坛(https://www.javazxz.com)已经为数万Java学习者服务超过8年了!积累会员资料超过10000G+
成为本站VIP会员,下载本站10000G+会员资源,会员资料板块,购买链接:点击进入购买VIP会员

JAVA高级面试进阶训练营视频教程

Java架构师系统进阶VIP课程

分布式高可用全栈开发微服务教程Go语言视频零基础入门到精通Java架构师3期(课件+源码)
Java开发全终端实战租房项目视频教程SpringBoot2.X入门到高级使用教程大数据培训第六期全套视频教程深度学习(CNN RNN GAN)算法原理Java亿级流量电商系统视频教程
互联网架构师视频教程年薪50万Spark2.0从入门到精通年薪50万!人工智能学习路线教程年薪50万大数据入门到精通学习路线年薪50万机器学习入门到精通教程
仿小米商城类app和小程序视频教程深度学习数据分析基础到实战最新黑马javaEE2.1就业课程从 0到JVM实战高手教程MySQL入门到精通教程
查看: 446|回复: 0

dubbo-admin-2.5.3 运行报错: Bean property 'URIType' is not writable or has an invalid 解决方法

[复制链接]
  • TA的每日心情
    奋斗
    2024-11-24 15:47
  • 签到天数: 804 天

    [LV.10]以坛为家III

    2053

    主题

    2111

    帖子

    72万

    积分

    管理员

    Rank: 9Rank: 9Rank: 9

    积分
    726782
    发表于 2021-7-18 17:04:24 | 显示全部楼层 |阅读模式

    因为 jdk 是1.8的版本,和 dubbo-admin 存在兼容性问题。所以报错:

    Bean property 'URIType' is not writable or has an invalid

    参见:https://github.com/alibaba/dubbo/issues/50

    解决方法,修改 tomcat 默认的 jdk到 1.7 :

    1) 修改bin文件夹下面的catalina.bat文件,把如下内容
    rem ----- Execute The Requested Command ----------------------------------
    echo Using CATALINA_BASE: %CATALINA_BASE% 
    echo Using CATALINA_HOME: %CATALINA_HOME% 
    echo Using CATALINA_TMPDIR: %CATALINA_TMPDIR% 
    echo Using JAVA_HOME: %JAVA_HOME% 

    修改为:
    echo Using CATALINA_BASE: %CATALINA_BASE% 
    echo Using CATALINA_HOME: %CATALINA_HOME% 
    echo Using CATALINA_TMPDIR: %CATALINA_TMPDIR% 
    echo Using JAVA_HOME: D:\Java\jdk1.7.0_79

    2) 修改bin文件夹下面的setclasspath.bat文件,把如下内容: 
    rem Set standard command for invoking Java. 

    rem Note that NT requires a window name argument when using start. 
    rem Also note the quoting as JAVA_HOME may contain spaces. 
    set _RUNJAVA="%JAVA_HOME%\bin\java" 
    set _RUNJAVAW="%JAVA_HOME%\bin\javaw" 
    set _RUNJDB="%JAVA_HOME%\bin\jdb" 
    set _RUNJAVAC="%JAVA_HOME%\bin\javac" 

    修改为: 
    rem Set standard command for invoking Java. 

    rem Note that NT requires a window name argument when using start. 
    rem Also note the quoting as JAVA_HOME may contain spaces. 
    set _RUNJAVA="D:\Java\jdk1.7.0_79\bin\java.exe"

    set _RUNJDB="D:\Java\jdk1.7.0_79\bin\jdb.exe"

    然后在使用 startup.bat 启动成功:

     INFO context.InheritableListableBeanFactory - Pre-instantiating singletons in com.alibaba.citrus.springext.support.context.InheritableListableBeanFacto
    ry@7c19d2: defining beans [org.springframework.context.annotation.internalCommonAnnotationProcessor,org.springframework.context.annotation.internalAutow
    iredAnnotationProcessor,org.springframework.context.annotation.internalRequiredAnnotationProcessor,com.alibaba.citrus.service.configuration.support.Prop
    ertyPlaceholderConfigurer#0,pullService,templateService,mappingRuleService,dataResolverService,productionModeSensiblePostProcessor,webxConfiguration,pul
    lService#0,pipeline,module.screen.Accesses,module.screen.Addresses,module.screen.Applications,module.screen.Consumers,module.screen.Loadbalances,module.
    screen.NoServicePrivilege,module.screen.Overrides,module.screen.Owners,module.screen.Providers,module.screen.Routes,module.screen.Services,module.screen
    .Weights,moduleLoaderService]; parent: com.alibaba.citrus.springext.support.context.InheritableListableBeanFactory@18f7b25
     INFO pull.PullService - Initialized pull service [key=PullService.pullService.5] with 1 pre-pulled tools, 2 pre-queued tools and 0 runtime tools
     INFO velocity.VelocityEngine - SpringResourceLoaderAdapter : initialization starting.
     INFO velocity.VelocityEngine - SpringResourceLoaderAdapter : set path '/templates/governance/'
     INFO velocity.VelocityEngine - SpringResourceLoaderAdapter : initialization complete.
     INFO rule.ExtensionMappingRule - Initialized extension.input:ExtensionMappingRule with cache disabled
     INFO rule.ExtensionMappingRule - Initialized extension.output:ExtensionMappingRule with cache disabled
     INFO rule.DirectModuleMappingRule - Initialized action:DirectModuleMappingRule with cache disabled
     INFO rule.DirectModuleMappingRule - Initialized screen.notemplate:DirectModuleMappingRule with cache disabled
     INFO rule.FallbackModuleMappingRule - Initialized screen:FallbackModuleMappingRule with cache enabled
     INFO rule.DirectTemplateMappingRule - Initialized screen.template:DirectTemplateMappingRule with cache disabled
     INFO rule.FallbackTemplateMappingRule - Initialized layout.template:FallbackTemplateMappingRule with cache enabled
     INFO rule.DirectModuleMappingRule - Initialized control.notemplate:DirectModuleMappingRule with cache disabled
     INFO rule.FallbackModuleMappingRule - Initialized control:FallbackModuleMappingRule with cache enabled
     INFO rule.DirectTemplateMappingRule - Initialized control.template:DirectTemplateMappingRule with cache disabled
     INFO pull.PullService - Initialized pull service [key=PullService.pullService#0.6] with 16 pre-pulled tools, 9 pre-queued tools and 0 runtime tools
     INFO context.WebxComponentsLoader - WebxComponents: initialization completed
     INFO context.ContextLoader - Root WebApplicationContext: initialization completed in 27302 ms
     INFO servlet.SetLoggingContextFilter - Initializing filter: mdc
     INFO servlet.SetLoggingContextFilter - SetLoggingContextFilter - mdc: initialization completed
     INFO servlet.WebxFrameworkFilter - Initializing filter: webx
     INFO servlet.WebxFrameworkFilter - WebxFrameworkFilter - webx: initialization completed
    二月 21, 2016 8:43:23 下午 org.apache.catalina.startup.HostConfig deployDirectory
    信息: Deployment of web application directory C:\dubbo-admin-tomcat-7.0.68\webapps\ROOT has finished in 32,704 ms
    二月 21, 2016 8:43:23 下午 org.apache.coyote.AbstractProtocol start
    信息: Starting ProtocolHandler ["http-bio-9090"]
    二月 21, 2016 8:43:23 下午 org.apache.coyote.AbstractProtocol start
    信息: Starting ProtocolHandler ["ajp-bio-8029"]
    二月 21, 2016 8:43:23 下午 org.apache.catalina.startup.Catalina start
    信息: Server startup in 32782 ms
    

    当然还有其他解决方法。参见 https://github.com/alibaba/dubbo/issues/50

    访问控制台:

    ----------------------------------------

    dubbo 报错:Failed to read schema document 'http://code.alibabatech.com/schema/dubbo/dubbo.xsd'问题解决方法

    注意上面的 Location 的路径中不能含义 '.' 字符和 '-' 字符开头的目录,不然报错:

    具体原理可以参考:

    http://blog.csdn.net/gaoshanliushui2009/article/details/50469595

     

    dubbo-admin的搭建还是十分简单的。基本只要修改一下 dubbo.properties 就行了:

    dubbo.registry.address=zookeeper://192.168.1.4:2181
    dubbo.admin.root.password=xxxx
    dubbo.admin.guest.password=xxxxx
    

      

     

    哎...今天够累的,签到来了1...
    回复

    使用道具 举报

    您需要登录后才可以回帖 登录 | 立即注册

    本版积分规则

    QQ|手机版|小黑屋|Java自学者论坛 ( 声明:本站文章及资料整理自互联网,用于Java自学者交流学习使用,对资料版权不负任何法律责任,若有侵权请及时联系客服屏蔽删除 )

    GMT+8, 2024-12-22 23:58 , Processed in 0.057933 second(s), 29 queries .

    Powered by Discuz! X3.4

    Copyright © 2001-2021, Tencent Cloud.

    快速回复 返回顶部 返回列表