This is an example of implementation of Real World Application backend-specs
- Application
- Go-Standards Project Layout
- Environment Variable Configuration
- Health-Check and Debug API
- Graceful Shutdown
- Layered architecture
- SOLID Principle
- Database Transaction
- HTTP Server
- Echo framework
- Server Side Caching
- Cache but revalidate (Header
Cache-Control: no-cache
) - Set Expiration Time (Header
Cache-Control: max-age=120
)
- Cache but revalidate (Header
- Request ID in logger (Header
X-Request-Id: xxx
)
- RESTful
- Create Resource (
POST
verb) - Update Resource (
PUT
verb) - Partially Update Resource (
PATCH
verb) - Find Resource (
GET
verb)- Offset Pagination (Query param
?limit=10&page=1
) - Sorting (Query param
?sort=fullname DESC,id DESC
)
- Offset Pagination (Query param
- Create Resource (
- Testing
- Table Driven Test
- Mocking
- Others
- Database migration and seed tool
- Releaser
setup environment and running on local
make run # Start the database, run migrations, and start the application locally
Golang:
- Go Documentation
- Go For Industrial Programming
- Uber Go Style Guide
- Go Code Review Comments
- typical-rest-server
- go-clean-arch
- a-clean-way-to-implement-database-transaction-in-golang
This project is licensed under the MIT License.