-
Notifications
You must be signed in to change notification settings - Fork 54
demo service
henry.huang edited this page Mar 16, 2021
·
1 revision
示例服务说明:
- run 示例服务:
app/basic/demo
cd ./app/basic/demo
# 启动 API 服务:
make run.demo
########################################################################################
#
# 或者使用: 基于 air, watch 该服务目录, 修改后, 自动 hot reload, 无需重新编译
#
########################################################################################
# 启动 http api sever:
make run.auto.api
# 启动 internal rpc sever:
make run.auto.svc
# 启动 job sever:
make run.auto.job
# 启动 admin api sever:
make run.auto.admin
########################################################################################
# http echo test:
make curl.api
#
# will print:
#
-> % make curl.api
curl -i http://localhost:8888/from/you
HTTP/1.1 200 OK
Content-Type: application/json
Date: Thu, 18 Feb 2021 10:48:23 GMT
Content-Length: 25
{"message":"hello world"}%