Skip to content

Website content zh cn overview reference pixiu other user samples springcloud springcloud springcloud

alanxtl edited this page Sep 20, 2026 · 1 revision

SpringCloud

关联资料(可能以 Java / Pixiu 为主)。原文按来源版本保留;使用前请读 版本与升级。 来源:原文 · 提交 84b35ebdab20 · 返回目录

快速开始

启动 Nacos [Docker 环境]:

cd samples/springcloud/docker
run docker-compose.yml/services

启动 SpringCloud [Java 环境]:

cd samples/springcloud/server

# the port is 8074
run auth-service

# the port is 8071
run user-service

启动 Pixiu:

go run cmd/pixiu/*.go gateway start -c samples/springcloud/pixiu/conf.yaml

通过 Pixiu 调用 SpringCloud 服务:

# the serviceId is `user-provider`
curl http://localhost:8888/user-service/echo/Pixiu

# the serviceId is `auth-provider`
curl http://localhost:8888/auth-service/echo/Pixiu

控制台输出结果:

Hello Nacos Discovery Pixiu

Clone this wiki locally