No application config found or it‘s not a valid config! Please add <dubbo:application name=“...“ />

解决 Dubbo 应用启动时 “No application config found” 错误 Dubbo 是阿里巴巴开源的一个高性能、轻量级的分布式服务框架,广泛应用于构建微服务架构。它主要提供了 RPC 通信机制,并支持多种注册中心、协议和负载均衡策略。Dubbo 通常和 Spring 进行整合,很多配置都可以通过 Spring 的配置文件进行管理。在分布式应用开发中,Dubbo 负责服务的暴露和消费,利用注册中心进行服务的注册与发现,从而实现微服务之间的高效通信。Dubbo 在分布式服务框架中的表现非常出色,但在开发过程中,像这样的问题时有发生。通过添加正确的。 阅读详情
AI摘要

项目在启动时遇到一系列错误,包括找不到应用配置、bean定义冲突以及与Zookeeper连接失败。尝试了不同的Dubbo和JDK版本组合,问题仍然存在。进一步分析发现,可能的原因包括配置不正确、版本不兼容或代码错误。添加特定配置并调整Dubbo版本后,发现元数据服务的空指针异常,以及应用名称包含非法字符的错误。最终,通过修正应用名称的配置解决了启动问题。

首先我的项目结构是这样的:
在这里插入图片描述
作为一个简单的Demo项目,启动时报错:

No application config found or it’s not a valid config! Please add <dubbo:application name=“…” />

可是配置添加了

application.properties

```java
# 服务器端口号设为8082
server.port=8082
# 应用程序名称设为actuator
spring.application.name=actuator
# Dubbo注册中心地址
dubbo.registry.address=zookeeper://192.168.122.128:2181
# Dubbo协议名称
dubbo.protocol.name=dubbo
# Dubbo协议端口号
dubbo.protocol.port=-1
# Dubbo注册中心连接超时时间
dubbo.registry.timeout=60000
# Dubbo服务消费者重试次数
dubbo.consumer.retries=3
# Dubbo应用程序QoS(Quality of Service)开启
dubbo.application.qos.enable=true
# Dubbo QoS(Quality of Service)协议端口号
dubbo.qos.port=22222

通过搜索引擎尝试:原来项目的dubbo版本是3.0.0,修改为以下

1.jdk1.8+dubbo版本是2.7.5版本是没有问题

2.jdk11+dubbo版本是2.7.1版本是没有问题的

然后报错:

Description:

The bean 'dubboBootstrapApplicationListener' could not be registered. A bean with that name has already been defined and overriding is disabled.

Action:

Consider renaming one of the beans or enabling overriding by setting spring.main.allow-bean-definition-overriding=true

添加配置:spring.main.allow-bean-definition-overriding=true,启动类上添加注解@EnableDubbo
然后报错:

java.lang.IllegalStateException: zookeeper not connected
	at org.apache.dubbo.remoting.zookeeper.curator.CuratorZookeeperClient.<init>(CuratorZookeeperClient.java:83) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.remoting.zookeeper.curator.CuratorZookeeperTransporter.createZookeeperClient(CuratorZookeeperTransporter.java:26) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.remoting.zookeeper.support.AbstractZookeeperTransporter.connect(AbstractZookeeperTransporter.java:68) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.remoting.zookeeper.ZookeeperTransporter$Adaptive.connect(ZookeeperTransporter$Adaptive.java) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.configcenter.support.zookeeper.ZookeeperDynamicConfiguration.<init>(ZookeeperDynamicConfiguration.java:70) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.configcenter.support.zookeeper.ZookeeperDynamicConfigurationFactory.createDynamicConfiguration(ZookeeperDynamicConfigurationFactory.java:37) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.common.config.configcenter.AbstractDynamicConfigurationFactory.lambda$getDynamicConfiguration$0(AbstractDynamicConfigurationFactory.java:39) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.common.config.configcenter.AbstractDynamicConfigurationFactory$$Lambda$565/918738473.apply(Unknown Source) ~[na:na]
	at java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1660) ~[na:1.8.0_51]
	at org.apache.dubbo.common.config.configcenter.AbstractDynamicConfigurationFactory.getDynamicConfiguration(AbstractDynamicConfigurationFactory.java:39) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.common.config.configcenter.DynamicConfiguration.getDynamicConfiguration(DynamicConfiguration.java:223) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.prepareEnvironment(DubboBootstrap.java:815) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.startConfigCenter(DubboBootstrap.java:560) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.useRegistryAsConfigCenterIfNecessary(DubboBootstrap.java:624) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.initialize(DubboBootstrap.java:508) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.start(DubboBootstrap.java:698) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.spring.context.DubboBootstrapApplicationListener.onContextRefreshedEvent(DubboBootstrapApplicationListener.java:52) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.spring.context.DubboBootstrapApplicationListener.onApplicationContextEvent(DubboBootstrapApplicationListener.java:45) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.spring.context.OneTimeExecutionApplicationContextEventListener.onApplicationEvent(OneTimeExecutionApplicationContextEventListener.java:40) ~[dubbo-2.7.5.jar:2.7.5]
	at org.springframework.context.event.SimpleApplicationEventMulticaster.doInvokeListener(SimpleApplicationEventMulticaster.java:172) ~[spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.context.event.SimpleApplicationEventMulticaster.invokeListener(SimpleApplicationEventMulticaster.java:165) ~[spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:139) ~[spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:404) ~[spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:361) ~[spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:898) ~[spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:554) ~[spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:143) ~[spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:755) [spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:747) [spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:402) [spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:312) [spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1247) [spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1236) [spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at com.example.dubboactuator.DubboActuatorApplication.main(DubboActuatorApplication.java:16) [classes/:na]
Caused by: java.lang.IllegalStateException: zookeeper not connected
	at org.apache.dubbo.remoting.zookeeper.curator.CuratorZookeeperClient.<init>(CuratorZookeeperClient.java:80) ~[dubbo-2.7.5.jar:2.7.5]
	... 33 common frames omitted

2023-07-28 22:19:03.204  WARN 15832 --- [           main] ConfigServletWebServerApplicationContext : Exception thrown from ApplicationListener handling ContextClosedEvent

java.lang.NullPointerException: null
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.unexportMetadataService(DubboBootstrap.java:857) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.destroy(DubboBootstrap.java:996) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.stop(DubboBootstrap.java:776) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.spring.context.DubboBootstrapApplicationListener.onContextClosedEvent(DubboBootstrapApplicationListener.java:56) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.spring.context.DubboBootstrapApplicationListener.onApplicationContextEvent(DubboBootstrapApplicationListener.java:47) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.spring.context.OneTimeExecutionApplicationContextEventListener.onApplicationEvent(OneTimeExecutionApplicationContextEventListener.java:40) ~[dubbo-2.7.5.jar:2.7.5]
	at org.springframework.context.event.SimpleApplicationEventMulticaster.doInvokeListener(SimpleApplicationEventMulticaster.java:172) ~[spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.context.event.SimpleApplicationEventMulticaster.invokeListener(SimpleApplicationEventMulticaster.java:165) ~[spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:139) ~[spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:404) [spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:361) [spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.doClose(AbstractApplicationContext.java:1013) [spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.doClose(ServletWebServerApplicationContext.java:170) [spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.close(AbstractApplicationContext.java:979) [spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.boot.SpringApplication.handleRunFailure(SpringApplication.java:811) [spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:322) [spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1247) [spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1236) [spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at com.example.dubboactuator.DubboActuatorApplication.main(DubboActuatorApplication.java:16) [classes/:na]

2023-07-28 22:19:03.205  INFO 15832 --- [           main] o.s.s.concurrent.ThreadPoolTaskExecutor  : Shutting down ExecutorService 'applicationTaskExecutor'
2023-07-28 22:19:03.205  INFO 15832 --- [           main] f.a.ReferenceAnnotationBeanPostProcessor : class org.apache.dubbo.config.spring.beans.factory.annotation.ReferenceAnnotationBeanPostProcessor was destroying!
Disconnected from the target VM, address: '127.0.0.1:53183', transport: 'socket'

Process finished with exit code 1

通过另一个项目测试zookeeper可以正常访问,说明不是zookeeper的问题,那么还是回归到代码本身,推测要么是配置不对,要么是版本有冲突或者不支持。而根据后续日志分析:

java.lang.NullPointerException: null
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.unexportMetadataService(DubboBootstrap.java:857) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.destroy(DubboBootstrap.java:996) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.stop(DubboBootstrap.java:776) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.spring.context.DubboBootstrapApplicationListener.onContextClosedEvent(DubboBootstrapApplicationListener.java:56) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.spring.context.DubboBootstrapApplicationListener.onApplicationContextEvent(DubboBootstrapApplicationListener.java:47) ~[dubbo-2.7.5.jar:2.7.5]
	at org.apache.dubbo.config.spring.context.OneTimeExecutionApplicationContextEventListener.onApplicationEvent(OneTimeExecutionApplicationContextEventListener.java:40) ~[dubbo-2.7.5.jar:2.7.5]

有一个对null对象的引用,而不应该有null对象,特别是在“DubboBootstrap”类中,当取消扩展元数据服务时。可以看到unexportMetadataService()方法中存在空指针异常,可能是由于元数据服务未正确导出或其他原因导致的。这可能是由应用程序中的编码错误或Dubbo框架的配置问题引起的。

尝试使用Dubbo 2.7.6,因为从Dubbo 2.7.6开始,有关元数据服务的处理已经得到了改进。

然后又报错:

java.lang.IllegalStateException: Invalid name="org.apache.dubbo.config.ApplicationConfig#0" contains illegal character, only digit, letter, '-', '_' or '.' is legal.
	at org.apache.dubbo.config.utils.ConfigValidationUtils.checkProperty(ConfigValidationUtils.java:588) ~[dubbo-2.7.6.jar:2.7.6]
	at org.apache.dubbo.config.utils.ConfigValidationUtils.checkName(ConfigValidationUtils.java:546) ~[dubbo-2.7.6.jar:2.7.6]
	at org.apache.dubbo.config.utils.ConfigValidationUtils.validateApplicationConfig(ConfigValidationUtils.java:386) ~[dubbo-2.7.6.jar:2.7.6]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.checkGlobalConfigs(DubboBootstrap.java:526) ~[dubbo-2.7.6.jar:2.7.6]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.initialize(DubboBootstrap.java:513) ~[dubbo-2.7.6.jar:2.7.6]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.start(DubboBootstrap.java:740) ~[dubbo-2.7.6.jar:2.7.6]
	at org.apache.dubbo.config.spring.context.DubboBootstrapApplicationListener.onContextRefreshedEvent(DubboBootstrapApplicationListener.java:59) ~[dubbo-2.7.6.jar:2.7.6]
	at org.apache.dubbo.config.spring.context.DubboBootstrapApplicationListener.onApplicationContextEvent(DubboBootstrapApplicationListener.java:52) ~[dubbo-2.7.6.jar:2.7.6]
	at org.apache.dubbo.config.spring.context.OneTimeExecutionApplicationContextEventListener.onApplicationEvent(OneTimeExecutionApplicationContextEventListener.java:40) ~[dubbo-2.7.6.jar:2.7.6]
	at org.springframework.context.event.SimpleApplicationEventMulticaster.doInvokeListener(SimpleApplicationEventMulticaster.java:172) ~[spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.context.event.SimpleApplicationEventMulticaster.invokeListener(SimpleApplicationEventMulticaster.java:165) ~[spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:139) ~[spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:404) ~[spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:361) ~[spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:898) ~[spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:554) ~[spring-context-5.2.15.RELEASE.jar:5.2.15.RELEASE]
	at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:143) ~[spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:755) [spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:747) [spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:402) [spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:312) [spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1247) [spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1236) [spring-boot-2.3.12.RELEASE.jar:2.3.12.RELEASE]
	at com.example.dubboactuator.DubboActuatorApplication.main(DubboActuatorApplication.java:16) [classes/:na]

2023-07-28 22:48:25.086  INFO 18636 --- [           main] o.s.s.concurrent.ThreadPoolTaskExecutor  : Shutting down ExecutorService 'applicationTaskExecutor'
2023-07-28 22:48:25.086  INFO 18636 --- [           main] f.a.ReferenceAnnotationBeanPostProcessor : class org.apache.dubbo.config.spring.beans.factory.annotation.ReferenceAnnotationBeanPostProcessor was destroying!
Disconnected from the target VM, address: '127.0.0.1:54870', transport: 'socket'

Process finished with exit code 1

添加配置:
dubbo.application.name=actuator
启动就不报错了

Spring Boot整合AWS S3文件上传实战:从配置到权限管理全流程解析 本文详细解析了Spring Boot整合AWS S3文件上传的全流程,包括基础配置、核心上传功能实现、高级权限控制及安全最佳实践。通过实战案例展示如何高效处理文件上传、大文件分片及权限管理,帮助开发者构建健壮的文件管理系统。特别强调AWS S3的高可用性和安全性,适用于企业级应用开发。 阅读详情

相关推荐

手把手教你用STM32F303和LAN9252搭建EtherCAT从站(附IO/AD/DA完整代码)

本文详细介绍了如何使用STM32F303和LAN9252搭建EtherCAT从站,涵盖硬件选型、开发环境配置、协议栈移植及IO/AD/DA功能实现。通过实战指南和完整代码,帮助开发者快速掌握工业自动化中的实时通信技术,提升系统性能与可靠性。

weixin_26802933的博客 235

解决No application config found or it‘s not a valid config Please add <dubboapplication name=“

用springboot启动dubbo时,如果出现这个报错: 1.检查依赖版本,然后检查配置文件关于dubbo的前缀,低版本是spring.dubbo为前缀,高版本是dubbo为前缀。 2.大多数是因为dubbo依赖和jdk版本冲突,如果是jdk1.8,那么就用2.7.5版本的dubbo。如果用jdk11而导入2.7.5版本的dubbo,就会报这个错误,把jdk切换到1.8即可完美解决。 如果必须用jdk11,解决方法: 引入依赖:2.7.1版本 <dependency>

begefefsef的博客 7005

《点亮创新灯塔!AI应用架构师与中小学初等教育AI智能体,共筑智能化教育辅助创新灯塔》

中小学AI智能体,是基于AI技术,能感知教育场景、理解教育规律、辅助教师教学和学生学习的智能系统。做老师“做不了”的事:比如5分钟批改45本作业,精准统计每个学生的易错点;做老师“做不好”的事:比如根据学生的学习风格(视觉/听觉/动觉)推荐个性化内容;绝不做老师“该做的事”:比如情感交流、价值观引导、创意教学设计——这些“人的温度”,AI永远无法替代。我是林宇,资深AI应用架构师,专注教育AI领域8年,参与过10多个中小学AI智能体项目,曾为北京、上海、深圳等城市的100多所学校提供AI教育解决方案。

Java大师兄的博客 432

引入spring-cloud-starter-dubbo后启动项目失败:No application config found or it‘s not a valid config!

引入spring-cloud-starter-dubbo后启动项目失败:java.lang.IllegalStateException: No application config。检查源码是说dubbo.application.name这个配置没有,但是我配置了也是提示这个异常,再检查发现是jar版本问题。spring-cloud-alibaba-dependencies由2.1.0.RELEASE修改为2.1.1.RELEASE即可解决

新林的博客 2万+

影像组学分析流程中,图像分割前要做的事(图像预处理)

在InputVolume中无法找到自己想要重采样的序列,这时可以检查一下序列的Volume type是不是MRMLMulti。这时,Volume type将由MRMLMulti改为Scaler,随后即可在3D slicer中完成Resample Scaler Volume。2.1、重采样:通过3Dslicer中的Resample Scaler Volume实现。具体设置参数:spacing(1,1,1),Interpolation选择Bspline。2、图像预处理:重采样和标准化。

weixin_45011313的博客 3723

【实战指南】利用CAN适配器高效调试CAN总线通信

本文提供了一份利用CAN适配器高效调试CAN总线通信的实战指南。文章从硬件连接、终端电阻配置、软件参数设置等基础环节入手,详细解析了CAN适配器作为关键调试工具的工作原理与使用方法,并针对常见的通信故障提供了系统化的问题排查思路,帮助工程师快速打通通信链路,提升调试效率。

weixin_28285943的博客 412

解决No application config found or it‘s not a valid config Please add <dubbo:application name=“...“ >

用springboot启动dubbo时,如果出现这个报错: 1.检查依赖版本,然后检查配置文件关于dubbo的前缀,低版本是spring.dubbo为前缀,高版本是dubbo为前缀。 2.大多数是因为dubbo依赖和jdk版本冲突,如果是jdk1.8,那么就用2.7.5版本的dubbo。如果用jdk11而导入2.7.5版本的dubbo,就会报这个错误,把jdk切换到1.8即可完美解决。 如果必须用jdk11,解决方法: 引入依赖: <dependency>

weixin_52717390的博客 4539

AI训练加速30%!用numactl玩转多显卡绑核的隐藏技巧

本文深入探讨了如何利用Linux系统的numactl工具,通过精确的NUMA绑核策略优化多GPU AI训练性能。文章详细解析了NUMA架构对性能的影响,提供了从拓扑探查、命令实战到多卡脚本化部署的完整指南,并分享了性能验证与常见陷阱,帮助开发者实现高达30%的训练加速。

web99的专栏 448

记一次No application config found or it‘s not a valid config! Please add <dubbo:application name=“...“

springboot 启动服务的时候报错,显示dubbo.application.name没有获取到,搜网上一直以为是版本不匹配问题 其实是!!!!! 我的配置文件没有编译成功,target目录下没有找到,然后我重新编译了一下项目就正常启动了...... ...

m0_38094649的博客 5742

交叉验证选型指南:k折、留一法、时序与分层CV实战决策

交叉验证是评估机器学习模型泛化能力的基础技术,其核心在于通过系统性数据重划分,缓解有限样本对真实分布估计的偏差。原理上,它通过控制训练-验证数据的独立性与代表性,诊断过拟合风险并提升性能指标的稳定性。技术价值体现在避免单次切分导致的结果偶然性、数据利用低效及验证集污染等问题。典型应用场景涵盖分类任务中的类别不平衡处理、时间序列预测的因果约束、用户行为建模中的数据泄露防控等。本文聚焦k折交叉验证、留一法、时间序列交叉验证与分层抽样等主流方法的适用边界与工程落地要点,结合过拟合诊断和泛化能力评估两大热词,提供可

dienangpiao2051的博客 475

机器翻译:一文掌握离线翻译库 Argos Translate 的详细使用

Argos Translate是一个开源的离线翻译库,支持多语言互译。它通过独立的翻译包(.argosmodel文件)实现翻译功能,每个包对应特定语言对的翻译任务。安装简单,只需pip安装argostranslate库,并通过命令行或Python API管理翻译包。支持批量处理和长期运行优化性能。对于不支持的语种,可采用桥接翻译或自行训练模型。该库提供CLI工具和Python API,适合集成到各种应用中,还可用于批量文件翻译。主要局限包括缺乏上下文理解、专业领域翻译不精准等。

数据知道的博客 3521

报错:No application config found or it‘s not a valid config!

解决报错:No application config found or it's not a valid config! Please add to your spring config.在 application.yml 中,在 provider(提供方)中添加配置:在 consumer(消费方)中添加配置:

m0_58002936的博客 1733

如何实现Docker镜像导入导出 ?

摘要: Docker镜像迁移与备份可通过两种方式实现:1)镜像操作(save/load)完整保存分层结构和元数据,适用于完整备份;2)容器操作(export/import)仅保存文件系统快照,适合创建轻量模板。关键区别在于前者保留历史记录和分层,后者生成单层镜像。save/load命令示例:docker save -o nginx.tar nginx:latest,export/import示例:docker export -o container.tar abc123 && docker

weixin_39291964的博客 875

No application config found or it`s not a valid config! Please add <dubbo:application name=“...“ />

需要在微服务项目中集成nacos配置中心,然后RPC远程调用使用的是dubbo 3.2.0,所以在集成配置中心的时候也把dubbo的配置参数也放到了配置中心里。

weixin_43168278的博客 765

假人有限元模型

假人模型,车辆碰撞假人有限元模型,适合做乘员安全的研究者利用

ET2012新版免狗免安装绿色软件

ET2012新版免狗免安祖昂绿色软件。,新界面,新视觉,

dubbo:问题记录

一、No application config found or it’s not a valid config! Please add <dubbo:application name="…" /> to your spring config. 明明配置了dubbo:application name,但是启动provider的时候,还是提示这个错误。 错误原因:jdk版本问题。使用xml和使用注解,是一样的。 解决方案: 把jdk版本设置正确,而且需要统一版本 我使用的版本: 软件

JoyceYoung的博客 869

汉书HE8,好用的汇编代码编写工具

汉书HE8,好用的汇编代码编写工具早期编写汇编代码所用功能强大

dubbo项目启动报错

Exception in thread "main" java.lang.IllegalStateException: No application config found or it's not a valid config! Please add <dubbo:application name="..." /> to your spring config. 这个是由于dubbo和spring版本不兼容导致,将dubbo高于2.7.5的版本降到2.7.3即可 ...

Decadent丶沉沦の博客 1510

VB摄像头监控

该VB模块可对摄像头捕获的画面进行录像等,可在创建的窗口进行控制

dubbo生产者demo启动报错

dubbo生产者demo启动报错 最近学习dubbo时,遇到一个奇怪问题:当生产者启动时,报 No application config found or it's not a valid config! Please add <dubbo:application name="..." /> to your spring config,记录一下解决问题的过程。 报错原因 先说问题结论:jdk版本过高,导致dubbo容器启动失败,demo的dubbo版本是2.7.5,使用jdk11编译运行就会报上

super_boy2008的博客 864

【Springboot+Dubbo】常见报错解决

springboot集成dubbo常见错误

H'Senseiの工坊 2430

springboot+dubbo主要的要点之 No application config found or it's not a valid config!

idea2019 maven 3.3.9 dubbo2.7.5 springboot集成dubbo一定要引入dubbo-spring-boot-starter 依赖 <dependency> <groupId>org.apache.dubbo</groupId> <artifactId>dubbo-spring-boot-starter</artifactId> <version>2.7.5</versio

dandanwang521的博客 1万+

dubbo之奇怪的问题---No such application config Please add dubbo application name=

和同事闲聊,发现同事之前也遇到了这个问题,遇到问题的同学可以试一下,就是 springboot和dubbo版本不兼容,导致classloader加载遇到了什么未知的问题,但是But 我试了一下从1.5.8升级到了2.2.5 还改了 好多不兼容的东西发现。并不好用,哈哈哈,但是同事说解决了,过后哪天加班有时间我会再继续试一下的~~~~~~好的 我又试了一下下面老哥的回复 写两遍...

iijik55的博客 488
上一篇: 【count(列名)、count(1)和 count(星号)有什么区别】
下一篇: 【结合业务需求给出合理的技术解决方案,改进现有模块功能,提高系统的可扩展性,封装性,稳定性】
Java程序员廖志伟
Java程序员廖志伟 优质创作者: Java技术领域 优质创作者: Java技术领域 领域专家: 后端开发技术领域 领域专家: 后端开发技术领域
博客等级 码龄8年 2万+粉丝 1902原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

Java程序员廖志伟

赏我包辣条呗

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值