You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2021/08/05 10:32:29 UTC
[GitHub] [apisix] aaron-codes opened a new issue #4761: request help: API 编排需求实现
aaron-codes opened a new issue #4761:
URL: https://github.com/apache/apisix/issues/4761
### Issue description
能否支持下图中的 API 编排能力

--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] abbluiz edited a comment on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
abbluiz edited a comment on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-912013357
That's a feature I would like to see too. Other API gateways call it Sequential Proxy, Chained Backend Requests, or API Composition. It's not the same as batch requests, because sometimes I need the response from an "upstream backend" to be included in the request of the next "upstream backend", and I think batch requests only support making concurrent requests that are independent from each other.
The motivation for this feature is simply for the frontend convenience, that's why it may also be called "Backend for Frontend" (I guess that's why, not 100% sure). Specially useful for mobile clients and web apps that need to access micro-apis that separates related entities between them. Instead of making chained requests on every frontend client, why not configure them in the gateway?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] abbluiz edited a comment on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
abbluiz edited a comment on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-912013357
I think that is a feature I would like to see too. Other API gateways call it Sequential Proxy or chained backend requests. It's not the same as batch requests, because sometimes I need the response from an "upstream backend" to be included in the request of the next "upstream backend", and I think batch requests only support making concurrent requests, that are independent from each other.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] abbluiz edited a comment on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
abbluiz edited a comment on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-912013357
I think that is a feature I would like to see too. Other API gateways call it Sequential Proxy or chained backend requests, or API composition. It's not the same as batch requests, because sometimes I need the response from an "upstream backend" to be included in the request of the next "upstream backend", and I think batch requests only support making concurrent requests that are independent from each other.
The motivation for this feature is simply for the frontend convenience, that's why Backend for Frontend (I guess that's why, not 100% sure). Specially useful for mobile clients, and web apps that need to access micro-apis that separates entities between them. Instead of making chained requests on every client, why not configure them in the gateway?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] 18300618319 commented on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
18300618319 commented on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-921384737
fizz-gateway这个API编排挺好用的
------------------ 原始邮件 ------------------
发件人: ***@***.***>;
发送时间: 2021年9月17日(星期五) 上午9:44
收件人: ***@***.***>;
抄送: ***@***.***>; ***@***.***>;
主题: Re: [apache/apisix] request help: Support Backend for Frontend (#4761)
@18300618319建议我们可以研究来自其他网关的 API 编排#5076
—
你收到这个是因为你被提到了。
直接回复此邮件,在 GitHub 上查看或取消订阅.
GitHub Mobile 上的分流通知监督办或机器人.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] abbluiz edited a comment on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
abbluiz edited a comment on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-912013357
That's a feature I would like to see too. Other API gateways call it Sequential Proxy or chained backend requests, or API composition. It's not the same as batch requests, because sometimes I need the response from an "upstream backend" to be included in the request of the next "upstream backend", and I think batch requests only support making concurrent requests that are independent from each other.
The motivation for this feature is simply for the frontend convenience, that's why it may also be called Backend for Frontend (I guess that's why, not 100% sure). Specially useful for mobile clients and web apps that need to access micro-apis that separates entities between them. Instead of making chained requests on every frontend client, why not configure them in the gateway?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] abbluiz commented on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
abbluiz commented on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-1011294589
@spacewander Interesting. I will be trying that out in the future.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] spacewander commented on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
spacewander commented on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-1010575525
Yes, you can make additional request inside the external plugin.
There is a real-world example (not in Python): https://github.com/swisscom/apisix-opa-plugin/blob/master/auth.go
Or you can do it in the Lua, like https://github.com/apache/apisix/blob/master/apisix/plugins/forward-auth.lua
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] abbluiz commented on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
abbluiz commented on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-1010200436
@spacewander
How would I write a custom plugin for this? Would you recommend using the `ext-plugin-post-req` with Python, for example? Could I make additional request inside this external plugin?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] abbluiz edited a comment on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
abbluiz edited a comment on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-912013357
I think that is a feature I would like to see too. Other API gateways call it Sequential Proxy or chained backend requests. It's not the same as batch requests, because sometimes I need the response from an "upstream backend" to be included in the request of the next "upstream backend", and I think batch requests only support making concurrent requests that are independent from each other.
The motivation for this feature is simply for the frontend convenience, that's why Backend for Frontend (I guess that's why, not 100% sure). Specially useful for mobile clients, and web apps that need to access micro-apis that separates entities between them. Instead of making chained requests on every client, why not configure them in the gateway?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] membphis commented on issue #4761: request help: API 编排需求实现
Posted by GitBox <gi...@apache.org>.
membphis commented on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-894851381
please change the title to English @aaron-codes
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] tokers commented on issue #4761: request help: API 编排需求实现
Posted by GitBox <gi...@apache.org>.
tokers commented on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-893371652
It's not a good way to support it in Apache APISIX but you can implement it in a custom plugin.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] abbluiz commented on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
abbluiz commented on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-912013357
I think that is a feature I would like to see too. Other API gateways call it Sequential Proxy or chained backend requests. It's not the same as batch requests, because sometimes I need the response from a backend to be included in the request of the next backend.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] spacewander commented on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
spacewander commented on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-915157179
@abbluiz
Maybe the batch-request plugin can serve this purpose?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] abbluiz edited a comment on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
abbluiz edited a comment on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-916858140
@spacewander @tzssangglass
As I mentioned before, the batch-requests would not fully serve this purpose, because yes it would need to handle a few responses, if some request on the pipeline depends on the response of other requests.
Maybe it will become clear for you if you check the implementation of chained requests other API gateways have done, such as "Sequential Proxy" on KrakenD:
https://www.krakend.io/docs/endpoints/sequential-proxy/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] abbluiz edited a comment on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
abbluiz edited a comment on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-912013357
I think that is a feature I would like to see too. Other API gateways call it Sequential Proxy or chained backend requests, or API composition. It's not the same as batch requests, because sometimes I need the response from an "upstream backend" to be included in the request of the next "upstream backend", and I think batch requests only support making concurrent requests that are independent from each other.
The motivation for this feature is simply for the frontend convenience, that's why it may also be called Backend for Frontend (I guess that's why, not 100% sure). Specially useful for mobile clients, and web apps that need to access micro-apis that separates entities between them. Instead of making chained requests on every client, why not configure them in the gateway?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] tzssangglass commented on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
tzssangglass commented on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-915680797
the batch-request plugin can sent more multiple requests, but the "Backend for Frontend" here also need to handle responses of multiple requests.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] abbluiz edited a comment on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
abbluiz edited a comment on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-912013357
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] spacewander commented on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
spacewander commented on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-921383531
@18300618319 suggested that we can study the API orchestration from the other gateways in https://github.com/apache/apisix/issues/5076
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] spacewander commented on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
spacewander commented on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-916902749
I see. To support it, currently we have to write a custom plugin.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] abbluiz commented on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
abbluiz commented on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-916858140
@spacewander @tzssangglass
As I mentioned before, the batch-requests would not fully serve this purpose, because yes it would need to handle a few responses, if some request on the pipeline depends on the response of other requests.
Maybe it will become clear for you if you check the implementation of chained requests other API gateways have done, such as KrakenD:
https://www.krakend.io/docs/endpoints/sequential-proxy/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] abbluiz edited a comment on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
abbluiz edited a comment on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-916858140
@spacewander @tzssangglass
As I mentioned before, the batch-requests would not fully serve this purpose, because yes it would need to handle a few responses, if some request on the pipeline depends on the response of other requests.
Maybe it will become clear for you if you check the implementation of chained requests other API gateways have done, such as "Sequential Proxy" on KrakenD:
https://www.krakend.io/docs/endpoints/sequential-proxy/
But perhaps I am wrong about batch-requests. Please feel free to correct me about its functionality if you still believe it would achieve the same goal I am trying to describe.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] abbluiz edited a comment on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
abbluiz edited a comment on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-912013357
That's a feature I would like to see too. Other API gateways call this differently. I've seem them call it Sequential Proxy, Chained Backend Requests, and API Composition, but all of these seems to do the same basic thing. It's not the same as batch requests, because sometimes I need the response from an "upstream backend" to be included in the request of the next "upstream backend" on the pipeline, and I think batch requests only support making concurrent requests that are independent from each other.
The motivation for this feature is simply for the frontend convenience, that's why it may also be called "Backend for Frontend" (I guess that's why, not 100% sure). Specially useful for mobile clients and web apps that need to access micro-apis that separates related entities between them. Instead of making chained requests on every frontend client, why not configure them in the gateway?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] juzhiyuan commented on issue #4761: request help: API 编排需求实现
Posted by GitBox <gi...@apache.org>.
juzhiyuan commented on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-893986265
see https://apisix.apache.org/docs/apisix/plugins/batch-requests/
Now we support setting the same `Query` for different requests, does it make sense to you?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] tzssangglass edited a comment on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
tzssangglass edited a comment on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-915680797
the batch-request plugin can sent more multiple requests, but the "Backend for Frontend" here also need to handle responses of multiple requests?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] abbluiz edited a comment on issue #4761: request help: Support Backend for Frontend
Posted by GitBox <gi...@apache.org>.
abbluiz edited a comment on issue #4761:
URL: https://github.com/apache/apisix/issues/4761#issuecomment-912013357
I think that is a feature I would like to see too. Other API gateways call it Sequential Proxy or chained backend requests. It's not the same as batch requests, because sometimes I need the response from an "upstream backend" to be included in the request of the next "upstream backend", and I think batch requests only support making concurrent requests that are independent from each other.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org