pom.xml 1.5 KB

123456789101112131415161718192021222324252627282930313233343536
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <project xmlns="http://maven.apache.org/POM/4.0.0"
  3. xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  4. xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
  5. <parent>
  6. <artifactId>spring-cloud-alibaba</artifactId>
  7. <groupId>com.tanyun</groupId>
  8. <version>1.0-SNAPSHOT</version>
  9. </parent>
  10. <modelVersion>4.0.0</modelVersion>
  11. <artifactId>api-gateway</artifactId>
  12. <dependencies>
  13. <!--不能引用web-starter, 因为其中包含有web容器,而gateway不需要web容器,底层采用webflux-->
  14. <dependency>
  15. <groupId>org.springframework.cloud</groupId>
  16. <artifactId>spring-cloud-starter-gateway</artifactId>
  17. </dependency>
  18. <!-- nacos客户端 -->
  19. <dependency>
  20. <groupId>com.alibaba.cloud</groupId>
  21. <artifactId>spring-cloud-starter-alibaba-nacos-discovery</artifactId>
  22. </dependency>
  23. <!--
  24. 限流
  25. 提供两种资源未读的限流
  26. 1. route维度: 在spring配置文件中配置的路由条目,资源名为对应的routeid
  27. 2. 自定义API维度:用户可以利用Sentinel提供的api来自定义一些api分组
  28. -->
  29. <dependency>
  30. <groupId>com.alibaba.csp</groupId>
  31. <artifactId>sentinel-spring-cloud-gateway-adapter</artifactId>
  32. </dependency>
  33. </dependencies>
  34. </project>