微服务配置nacos

参考地址:

Maven引入nacos的版本问题以及如何在阿里Maven仓库中找到想要的jar和Maven中的groupId、artifactId、version_cannot resolve com.alibaba.cloud:spring-cloud-star-CSDN博客

pom文件中报错:

Could not find artifact com.alibaba.cloud:spring-cloud-starter-alibaba-nacos-discovery:pom:unknown in spring-milestones (https://repo.spring.io/milestone) Could not find artifact com.alibaba.cloud:spring-cloud-starter-alibaba-nacos-discovery:pom:unknown i

解决方案:

Maven中Could not find artifact XXXX和引入alibaba.cloud依赖_could not find artifact com.alibaba.cloud:spring-c-CSDN博客

在Maven引入alibaba.cloud依赖时,可在父类pom进行指定应该如下:

复制代码
<dependencyManagement>
		<dependencies>
			<!-- spring cloud Hoxton.SR1 -->
			<dependency>
				<groupId>org.springframework.cloud</groupId>
				<artifactId>spring-cloud-dependencies</artifactId>
				<version>Hoxton.SR1</version>
				<type>pom</type>
				<scope>import</scope>
			</dependency>

			<!-- spring cloud alibaba 2.1.0.RELEASE-->
			<dependency>
				<groupId>com.alibaba.cloud</groupId>
				<artifactId>spring-cloud-alibaba-dependencies</artifactId>
				<version>2.1.0.RELEASE</version>
				<type>pom</type>
				<scope>import</scope>
			</dependency>
		</dependencies>
	</dependencyManagement>
相关推荐
李景琰1 天前
多级缓存架构与一致性核心挑战:基于Caffeine本地缓存、Redis分布式缓存与MySQL数据库的多级缓存数据一致性方案
数据库·缓存·架构
v***44671 天前
【MySQL — 数据库基础】深入理解数据库服务与数据库关系、MySQL连接创建、客户端工具及架构解析
数据库·mysql·架构
左灯右行的爱情1 天前
MySQL高并发-主从架构
数据库·mysql·架构
GIOTTO情1 天前
技术深度拆解:Infoseek 字节探索危机公关系统的核心架构与实现逻辑
架构
❥ღ Komo·1 天前
K8s集群搭建全流程详解
云原生·容器·kubernetes
稚辉君.MCA_P8_Java1 天前
Gemini永久会员 三个线程(A、B、C)交替执行
java·后端·架构
8***a8151 天前
springboot项目架构
spring boot·后端·架构
7***53341 天前
PHP在微服务中的Phalcon
开发语言·微服务·php
JienDa1 天前
JienDa聊PHP:算命平台实战中主流PHP框架的协同架构方略
开发语言·架构·php
p***95001 天前
DeepSeek R1 简易指南:架构、本地部署和硬件要求
人工智能·架构