Toggle to fall back to http.ListenAndServe
Aperta
- Lingua principale
- Go
- Stelle
- 651
- Fork
- 75
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
Using `sam local start-api` is great but
- it's slow handling requests
- it would be nice to have the option of running code stand alone outside Lambda
I'd like to have a toggle to fall back to `net/http` only:
```
ApexGatewayDisabled := os.Getenv("APEX_GATEWAY_DISABLED")
if ApexGatewayDisabled == "true" {
log.Fatal(http.ListenAndServe(":3000", nil))
} else {
log.Fatal(gateway.ListenAndServe(":3000", nil))
}
```
Everywhere AWS specific functionality is used above condition must also be checked.
Does this approach make sense or is there a better way?
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Valutazione
Questa issue non è ancora stata valutata.