Apache ShenYu 项目教程

Apache ShenYu 项目教程

shenyuApache ShenYu is a Java native API Gateway for service proxy, protocol conversion and API governance.项目地址:https://gitcode.com/gh_mirrors/sh/shenyu

1. 项目的目录结构及介绍

Apache ShenYu 是一个高性能、响应式的 API 网关,适用于微服务架构。项目的目录结构如下:

shenyu
├── shenyu-admin
├── shenyu-bootstrap
├── shenyu-client
├── shenyu-common
├── shenyu-discovery
├── shenyu-disruptor
├── shenyu-dist
├── shenyu-e2e
├── shenyu-examples
├── shenyu-integrated-test
├── shenyu-kubernetes-controller
├── shenyu-loadbalancer
├── shenyu-plugin
├── shenyu-protocol
├── shenyu-register-center
├── shenyu-registry
├── shenyu-sdk
├── shenyu-spi
├── shenyu-spring-boot-starter
├── shenyu-sync-data-center
└── shenyu-web

主要目录介绍:

  • shenyu-admin: 管理后台模块,负责配置和管理网关。
  • shenyu-bootstrap: 启动模块,负责启动网关服务。
  • shenyu-client: 客户端模块,提供与网关交互的客户端库。
  • shenyu-common: 通用模块,包含项目中使用的通用工具和类。
  • shenyu-plugin: 插件模块,包含各种网关插件。

2. 项目的启动文件介绍

shenyu-admin 启动文件

shenyu-admin 的启动文件位于 shenyu-admin/src/main/java/org/apache/shenyu/admin/ShenyuAdminBootstrap.java。该文件负责启动管理后台服务。

shenyu-bootstrap 启动文件

shenyu-bootstrap 的启动文件位于 shenyu-bootstrap/src/main/java/org/apache/shenyu/bootstrap/ShenyuBootstrapApplication.java。该文件负责启动网关服务。

3. 项目的配置文件介绍

shenyu-admin 配置文件

shenyu-admin 的配置文件位于 shenyu-admin/src/main/resources/application.yml。该文件包含管理后台的配置信息,如数据库连接、端口等。

shenyu-bootstrap 配置文件

shenyu-bootstrap 的配置文件位于 shenyu-bootstrap/src/main/resources/application.yml。该文件包含网关服务的配置信息,如端口、插件配置等。

示例配置

server:
  port: 9195

spring:
  application:
    name: shenyu-bootstrap

shenyu:
  local:
    enabled: true
    sha512Key: 123456

以上是 Apache ShenYu 项目的基本教程,涵盖了项目的目录结构、启动文件和配置文件的介绍。希望对您有所帮助。

shenyuApache ShenYu is a Java native API Gateway for service proxy, protocol conversion and API governance.项目地址:https://gitcode.com/gh_mirrors/sh/shenyu

  • 4
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

打赏作者

裴晓佩

你的鼓励将是我创作的最大动力

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

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

打赏作者

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

抵扣说明:

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

余额充值