-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Break out proxying code from all providers #9
Comments
I can work on this |
This is a very big task. Do you think there is a part up you could without committing to it all? |
Derek add label: size/xxl |
As a start point I can move After having this, the work can be separated on those steps/issues: Step 2: Make refactoring to merge Step 3 (advanced): Make refactoring to merge swarm and kubernetes proxy |
Derek assign: me |
**What** - Add standardized proxy handler based on the implementations for swarm and kubernetes **Why** - Reduce duplicated code amoung the various providers - Ensure the proxy behavior is consistent - Addresses openfaas#9 Signed-off-by: Lucas Roesler <roesler.lucas@gmail.com>
**What** - Add standardized proxy handler based on the implementations for swarm and kubernetes **Why** - Reduce duplicated code amoung the various providers - Ensure the proxy behavior is consistent - Addresses openfaas#9 Signed-off-by: Lucas Roesler <roesler.lucas@gmail.com>
I noticed an implementation detail in But this doesn't exist in either k8s implementation I noticed in the Can I remove it from this implementation? |
**What** - Add standardized proxy handler based on the implementations for swarm and kubernetes **Why** - Reduce duplicated code amoung the various providers - Ensure the proxy behavior is consistent - Addresses #9 Signed-off-by: Lucas Roesler <roesler.lucas@gmail.com>
Hi @LucasRoesler I don't believe anyone is using |
The |
Can this issue be closed? @LucasRoesler |
Unfortunately, no. This was applied two faas-swarm in openfaas/faas-swarm#39 But faas-netes is not using the faas-provider proxy yet |
How are we doing with this now? @LucasRoesler |
faas-netes now uses the provider, as of this commit openfaas/faas-netes@c1ba865 4 months ago the operator is using the provider as of this commit https://github.com/openfaas/openfaas-operator/commit/156e27eac06d1db38c977ddcb41de07f45453a17 2 months ago I thinik this means we can close this |
The proxying code is repeated in faas-swarm, faas-netes, openfaas-operator and possibly faas-fargate/faas-nomad.
At least the code for the first three should be moved here.
The proxying code is rarely used apart from when
direct_functions
is set to false. For some reason Capital One need this feature, so we should move the code into one place for maintenance. Each provider will then be able to utilize the package.A similar move was made for the basic auth middleware that I wrote.
In addition the path parsing/trimming code that passes a HTTP Path to functions needs to be ported over so that functions are not invoked with a PATH like
/function/<name>/param1/param2
but with/param1/param2
directly. This code resides in the gateway currently and so it may make sense to also refactor it into a package here.Summary/tasks
To test turn off
direct_functions
on your API gatewaydirect_functions
approachOnce the above is done and we have a release of faas-provider:
The text was updated successfully, but these errors were encountered: