当前位置:网站首页>Getting started with gateway
Getting started with gateway
2022-07-28 18:50:00 【Minor Wang Zhi】
Catalog
1.Gateway
SpringCloud The launch is based on WebFlux+Netty Of Reactor Responsive programming gateway components , Performance equivalent to Zuul More than double . Gateway can do many things in distributed microservice architecture : Flow control 、 Log monitoring 、 Unified authentication authority verification, etc .
Gateway There is 3 An important concept :
- Route route : Routing information includes ID、URI、 The factory 、 A group of Filter.
- Predicates Assertion : Check various conditions and parameters of the request , If it meets the conditions, it will be released .
- Filter filter : Filtering chain processing of requests and responses .Gateway Of Filter Support Pre and Post Two modes .
2. Assertion
Gateway There are many built-in assertion types available :
- After: Assertion Verification Based on time , Release only after the specified date .
- Before: and After contrary .
- Between: Release within a certain time .
- Cookie: Verify the specified Cookie, Qualified release .
- Header: Check request header .
- Host: Verify whether the matching current request comes from the set host address .
- Method: matching HTTP Request method , for example Post、Get etc. .
- Path: Match path .
- Query: Parameter matching verification .
3.Filter filter
Gateway Filter support for Pre Preprocessing and Post Post processing has two modes , We can also achieve Filter Interface comes from definition Gateway Filter , adopt Order Interface can realize filter sorting .
Gateway There are dozens of official built-in Filter,Filter Divided into two :GatewayFilter、GlobalFilter. The difference is that the scope of the former is specific Route route , The latter belongs to global filtering . Generally speaking, we are used to GlobalFilter, It's covered with filter Method to implement the requested custom operation , Log for example 、 Certificate authority 、 add to Header Wait for the operation .
边栏推荐
- What is the employment prospect of software testing?
- MYSQL入门与进阶(二)
- Chinese enterprise service industry market in 2022
- NDK series (5): from introduction to practice, JNI explodes the liver and explains everything in detail!
- 行业落地呈现新进展 | 2022开放原子全球开源峰会OpenAtom OpenHarmony分论坛圆满召开
- Golang is packaged and released to various platforms
- 使用自开发的代理服务器解决 SAP UI5 FileUploader 上传文件时遇到的跨域访问错误试读版
- Meta Q2 earnings: revenue fell for the first time, and metaverse will compete with apple
- MYSQL入门与进阶(七)
- UE5 GAS 学习笔记 1.7 任务Ability Tasks
猜你喜欢

kotlin:Nothing

It is said that software testing is the worst in the IT industry. Is that so?

面试官:ThreadLocal使用场景有哪些?内存泄露问题如何避免?

什么样的知识付费系统功能,更有利于平台与讲师发展?

1.1. Sparse array

1.3、链表

kotlin:Nothing

The switching language of unity causes an error: system FormatException:String was not recognized as a valid DateTime.

Bubble sorting and Related videos

jvm四种引用类型
随机推荐
Pyqt5 rapid development and practice 5.3 multithreading
Ue5 gas learning notes 1.5 gameplay effects game effects
JVM four reference types
Tencent Tang Daosheng: open source is a new mode of production and collaboration in the era of industrial Internet
112. 使用自开发的代理服务器解决 SAP UI5 FileUploader 上传文件时遇到的跨域访问错误
MYSQL入门与进阶(九)
Redis缓存雪崩、穿透、击穿,布隆过滤器,分布式锁详解
冒泡排序和相关视频
[GXYCTF2019]StrongestMind
UE5 GAS 学习笔记 1.8 游戏特效(GameplayCue)
Go exe generates icon version information
leetcode 二叉树类
The switching language of unity causes an error: system FormatException:String was not recognized as a valid DateTime.
Is the training institution of software testing reliable
Digital torrent: resource reorganization and strategic conflict in enterprise transformation
Look at Devops construction from SRE
Ue5 gas learning notes 1.8 game special effects (gameplaycue)
NDK series (5): from introduction to practice, JNI explodes the liver and explains everything in detail!
UE5 GAS 学习笔记0.1 案例预览
面试官:ThreadLocal使用场景有哪些?内存泄露问题如何避免?