Re:Dito – an advanced Layer 7 reverse proxy server written i...
by vrosas on Wednesday October 09, 2024 @05:25PM
(#41792825)
In my experience those specific sets of constraints come sooner or later. Someone is going to ask for some complex auth or routing rules and it’s easier to just write it in go than it is to learn a whole new DSL or lua to implement it.
Re:Dito – an advanced Layer 7 reverse proxy server written i...
by denysvitali on Wednesday October 09, 2024 @05:42PM
(#41792993)
Complex Auth:
https://doc.traefik.io/traefik/middlewares/http/forwardauth/
Complex routing rules: https://doc.traefik.io/traefik/routing/routers/
If you need something more than this, you're either in a very specific situation (where an API Gateway written from scratch might be a good idea) or that someone is doing something wrong
Re:Dito – an advanced Layer 7 reverse proxy server written i...
by vrosas on Wednesday October 09, 2024 @08:10PM
(#41794204)
Why would I want to write another service to handle auth? That’s somehow less complex than just writing it into my gateway?
Re:Dito – an advanced Layer 7 reverse proxy server written i...
by Aeolun on Wednesday October 09, 2024 @06:47PM
(#41793621)
I sort of agree with you, but only if you aren’t in a position to say ‘the software doesn’t support it’.
Re:Dito – an advanced Layer 7 reverse proxy server written i...
by tluyben2 on Thursday October 10, 2024 @12:28AM
(#41795513)
We had a specific use case that was needed urgently which we couldn't get working with any of the standard systems, so we used Go. Works very well. It is sometimes simply a matter of time; we needed it before the morning (for a launch) and in discord/reddit people were providing solutions with haproxy, nginx, traefik etc that should work according to the docs but just didn't.
As someone who already did this (because no other solution with our needs was available), I strongly disagree.
Most of the time, NGINX, Caddy, Traefik or APISIX are enough. The only time I felt the need to implement an API Gateway from scratch was to support a very specific use case with a specific set of constraints. No matter how robust the Go standard library is, implementing an API Gateway from scratch is rarely a good idea.