插件请求为何会走一道网关 #5466
-
Beta Was this translation helpful? Give feedback.
Replies: 11 comments 1 reply
-
Thank you for raising an issue. We will investigate into the matter and get back to you as soon as possible. |
Beta Was this translation helpful? Give feedback.
-
The issue you're experiencing with the plugin using the If the To continue talking to Dosu, mention @dosu. Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Other |
Beta Was this translation helpful? Give feedback.
-
Gateway是实际后端发请求的接口。没有啥问题 |
Beta Was this translation helpful? Give feedback.
-
Gateway is the interface through which the actual backend sends requests. No problem |
Beta Was this translation helpful? Give feedback.
-
除了api-key和engine-id还有什么需要额外配置的吗 为什么会发送gateway |
Beta Was this translation helpful? Give feedback.
-
In addition to api-key and engine-id, is there anything else that needs to be configured? Why is gateway sent? |
Beta Was this translation helpful? Give feedback.
-
即使我在官方网站使用,在配置api-key和engine-id后仍然会gateway |
Beta Was this translation helpful? Give feedback.
-
Even if I use it on the official website, the gateway will still appear after configuring the api-key and engine-id. |
Beta Was this translation helpful? Give feedback.
-
gateway 是插件请求的统一网关,请求路径为: lobechat 前端 -> lobechat 后端插件网关 -> 三方插件服务端 通过后端对后端请求可以解决前端发请求的跨域问题,同时后端插件网关也承担了插件服务发现、插件请求入参校验等职能。 |
Beta Was this translation helpful? Give feedback.
-
十分感谢你的回答 我了解了gateway的必要性,但是对于google-cse-lobechat这个插件,为什么在前端直接向第三方插件服务端发起请求 |
Beta Was this translation helpful? Give feedback.
-
我查看了相关源码 发现google-cse-lobechat在manifest里面指定了gateway,这可能是导致错误的原因 |
Beta Was this translation helpful? Give feedback.
gateway 是插件请求的统一网关,请求路径为:
lobechat 前端 -> lobechat 后端插件网关 -> 三方插件服务端
通过后端对后端请求可以解决前端发请求的跨域问题,同时后端插件网关也承担了插件服务发现、插件请求入参校验等职能。