1
0
mirror of https://github.com/go-kratos/kratos.git synced 2025-01-22 03:38:41 +02:00
Tony Chen 8d8cd8c8a8
Middleware/metadata v2 (#1050)
* add middleware metadata
* add transport header
* add transport carrier

Co-authored-by: longXboy <longxboy@gmail.com>
2021-06-14 00:59:07 +08:00
..
2021-06-13 15:21:29 +08:00
2021-06-12 20:20:18 +08:00
2021-06-12 20:20:18 +08:00
2021-06-12 20:20:18 +08:00
2021-06-12 20:20:18 +08:00

Run the examples

gin

1、Compile and execute the server code:

$ go run gin/main.go

2、From a different terminal, access the api to see the output:

$ curl http://127.0.0.1:8000/home
Hello Gin!

mux

1、Compile and execute the server code:

$ go run mux/main.go

2、From a different terminal, access the api to see the output:

$ curl http://127.0.0.1:8000/home
Hello Gorilla Mux!

static

1、Compile and execute the server code:

$ go run static/main.go

2、Access the following url with your browser:

http://127.0.0.1:8000/assets