소스 검색

更新demo

yjp 1 년 전
부모
커밋
6ce717b81d
1개의 변경된 파일5개의 추가작업 그리고 3개의 파일을 삭제
  1. 5 3
      project/gateway/main.go

+ 5 - 3
project/gateway/main.go

@@ -29,9 +29,11 @@ func main() {
 	defer gateway.DestroyGateway(gw)
 
 	gw.BindPassThrough(prefixRootBinder, &gateway.PassThrough{
-		HttpMethod:   http.MethodGet,
-		RelativePath: "/version",
-		ToUrl:        "http://localhost:31000/example/api/version",
+		HttpMethod: http.MethodGet,
+		SimplePassThrough: &gateway.SimplePassThrough{
+			RelativePath: "/version",
+			ToUrl:        "http://localhost:31000/example/api/version",
+		},
 	})
 
 	go func() {