This project can mount a server and expose a GET /message
endpoint from which a message is returned from the Fuck Off as a Service service.
The only restriction is that a user consuming this endpoint can use it UP TO 5 times within a 10 second period.
The userID is identified from the user-id
header.
- Spring Boot ๐
- Guava Cache โก๏ธ
- Lombok โก๏ธ
- The API with a given userId is consumed once and returns the service message
- The API is consumed 5 times within a period of 10 seconds and it returns the 5 messages from the service
- The API is consumed 6 times within a period of 10 seconds and the sixth call returns an error.
- The API is consumed 6 times within a period of 10 seconds, a seventh call is made 10 seconds after the first call and it returns a message from the service