有没有输入一个url能够得到匹配到哪条路由的接口? #8451
Unanswered
liuguangyu133
asked this question in
Q&A
Replies: 2 comments
-
Maybe you can write some custom logic via the serverless plugin, and output the route content. |
Beta Was this translation helpful? Give feedback.
0 replies
-
参考apisix.http.route.lua、apisix.http.router.radixtree_uri.lua这两个文件可以自己写个插件能够实现,其内部是使用的radixtree库来匹配路由的,我在我的自定义插件中也使用到了radixtree组件来匹配uri。 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
一个集群内有大量路由规则的时候,如何输入一个url然后返回这个url匹配到的路由id?这样某些情况下能够快速定位问题。
目前我知道日志能够打印,但是如果想把这个功能接入到我们自己的界面上,通过日志的结果并不是很方便。所以有没有能直接得到这个结果的方式?
Beta Was this translation helpful? Give feedback.
All reactions