This repo use for dummy aplication when u implementation using single flight golang and call endpoint on this repo.
U need install redis on your local and go lang with min version 1.16.x
- clone this repo on your local
- After clone, u need run this code on your terminal and folder target
go mod init
to initiate of import package. - Run on your terminal
go mod tidy
to add module requirements and sum, this action will create new filego.sum
andgo.mod
- Final step is u just type
go run main.go
and application already running.
GET /get_data
on this endpoint no need parameter request. But showing response parameters.
Parameter | Type | Description |
---|---|---|
error_code |
int |
Showing error code of http |
error_message |
string |
showing error message if any error |
result |
string |
result data |
example response:
{
"error_code": 200,
"error_message": "",
"result": "get key_testing: Hello Data Founded"
}