Skip to content

Latest commit

 

History

History
37 lines (25 loc) · 582 Bytes

Readme.md

File metadata and controls

37 lines (25 loc) · 582 Bytes

Golang API

REST API example.

Deploy

$ up

Usage

$ curl -d Tobi https://example.com/
welcome to the family "Tobi"!

$ curl -d Loki https://example.com/
welcome to the family "Loki"!

$ curl -d Jane https://example.com/
welcome to the family "Jane"!

$ curl https://example.com/
- Tobi
- Jane
- Loki

Notes

There's no need to wrap pets in a mutex since Lambda processes only a single request per container concurrently.

Don't actually rely on local state like this, use a database. In-memory state is only useful for caching in a Lambda container.