【文件属性】:
文件名称:echo:简单的回显网络服务器
文件大小:2KB
文件格式:ZIP
更新时间:2021-06-09 01:52:36
Go
回声
简单的回显网络服务器。
$ go get hawx.me/code/echo
$ $GOPATH /bin/echo
2014/01/26 21:43:59 serving on :8080
……还有其他地方……
$ curl localhost:8080
{
" body " : " " ,
" form " : {},
" headers " : {
" Accept " : " */* " ,
" User-Agent " : " curl/7.32.0 "
},
" method " : " GET " ,
" url " : " localhost:8080/ " ,
" version " : " HTTP/1.1 "
}
路线
/status/:code :返回具有给定状态代码的响应。
/delay/:ms :在ms毫
【文件预览】:
echo-master
----echo.go(2KB)
----LICENSE(1KB)
----README.md(500B)