diff --git a/server/assistant/assistant.go b/server/assistant/assistant.go index 8ae0cf8e..5ffd00da 100644 --- a/server/assistant/assistant.go +++ b/server/assistant/assistant.go @@ -23,7 +23,6 @@ func main() { var c config.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) { })) defer server.Stop() diff --git a/server/assistant/etc/assistant.yaml b/server/assistant/etc/assistant.yaml index 3804fea1..f65d63af 100644 --- a/server/assistant/etc/assistant.yaml +++ b/server/assistant/etc/assistant.yaml @@ -1,6 +1,7 @@ Name: assistant Host: 0.0.0.0 Port: 9950 +Timeout: 15000 #服务超时时间 SourceMysql: fusentest:XErSYmLELKMnf3Dh@tcp(110.41.19.98:3306)/fusentest Auth: AccessSecret: fusen2023 diff --git a/server/backend/backend.go b/server/backend/backend.go index 83ae4af9..f3f1672f 100644 --- a/server/backend/backend.go +++ b/server/backend/backend.go @@ -22,7 +22,6 @@ func main() { var c config.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) { diff --git a/server/backend/etc/backend.yaml b/server/backend/etc/backend.yaml index 18f08394..f0cdc6c8 100644 --- a/server/backend/etc/backend.yaml +++ b/server/backend/etc/backend.yaml @@ -1,6 +1,7 @@ Name: backend Host: 0.0.0.0 Port: 9901 +Timeout: 15000 #服务超时时间 SourceMysql: fusentest:XErSYmLELKMnf3Dh@tcp(110.41.19.98:3306)/fusentest Auth: AccessSecret: fusen_backend_2023 diff --git a/server/base/base.go b/server/base/base.go index df2962f3..c5880c16 100644 --- a/server/base/base.go +++ b/server/base/base.go @@ -23,7 +23,7 @@ func main() { var c config.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) + server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) { })) defer server.Stop() diff --git a/server/canteen/canteen.go b/server/canteen/canteen.go index 993573fb..774de30e 100644 --- a/server/canteen/canteen.go +++ b/server/canteen/canteen.go @@ -23,8 +23,6 @@ func main() { var c config.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) - c.Timeout = int64(time.Second * 15) server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) { diff --git a/server/canteen/etc/canteen.yaml b/server/canteen/etc/canteen.yaml index 4b363db8..16b26a52 100644 --- a/server/canteen/etc/canteen.yaml +++ b/server/canteen/etc/canteen.yaml @@ -1,6 +1,7 @@ Name: canteen Host: 0.0.0.0 Port: 9902 +Timeout: 15000 #服务超时时间 SourceMysql: fusentest:XErSYmLELKMnf3Dh@tcp(110.41.19.98:3306)/fusentest Auth: AccessSecret: fusen2023 diff --git a/server/data-transfer/data-transfer.go b/server/data-transfer/data-transfer.go index af86ccc2..95147a0d 100644 --- a/server/data-transfer/data-transfer.go +++ b/server/data-transfer/data-transfer.go @@ -21,7 +21,6 @@ func main() { var c config2.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) { diff --git a/server/data-transfer/etc/data-transfer.yaml b/server/data-transfer/etc/data-transfer.yaml index 4a3e767d..758542f8 100644 --- a/server/data-transfer/etc/data-transfer.yaml +++ b/server/data-transfer/etc/data-transfer.yaml @@ -1,6 +1,7 @@ Name: data-transfer Host: 0.0.0.0 Port: 9903 +Timeout: 15000 #服务超时时间 SourceMysql: fusentest:XErSYmLELKMnf3Dh@tcp(110.41.19.98:3306)/fusentest Auth: AccessSecret: fusen2023 diff --git a/server/home-user-auth/etc/home-user-auth.yaml b/server/home-user-auth/etc/home-user-auth.yaml index 31722119..e9a7b8c8 100644 --- a/server/home-user-auth/etc/home-user-auth.yaml +++ b/server/home-user-auth/etc/home-user-auth.yaml @@ -1,6 +1,7 @@ Name: home-user-auth Host: 0.0.0.0 Port: 9904 +Timeout: 15000 #服务超时时间 MainAddress: "http://localhost:9900" SourceMysql: fusentest:XErSYmLELKMnf3Dh@tcp(110.41.19.98:3306)/fusentest diff --git a/server/home-user-auth/home-user-auth.go b/server/home-user-auth/home-user-auth.go index 28598d4f..3ff860d2 100644 --- a/server/home-user-auth/home-user-auth.go +++ b/server/home-user-auth/home-user-auth.go @@ -23,7 +23,6 @@ func main() { var c config.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) { diff --git a/server/inventory/etc/inventory.yaml b/server/inventory/etc/inventory.yaml index 3633f1b0..afd8bfa7 100644 --- a/server/inventory/etc/inventory.yaml +++ b/server/inventory/etc/inventory.yaml @@ -1,7 +1,7 @@ Name: inventory Host: 0.0.0.0 Port: 9905 - +Timeout: 15000 #服务超时时间 SourceMysql: fusentest:XErSYmLELKMnf3Dh@tcp(110.41.19.98:3306)/fusentest Auth: AccessSecret: fusen2023 diff --git a/server/inventory/inventory.go b/server/inventory/inventory.go index f623a627..00645519 100644 --- a/server/inventory/inventory.go +++ b/server/inventory/inventory.go @@ -22,7 +22,6 @@ func main() { var c config.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) { diff --git a/server/map-library/etc/map-library.yaml b/server/map-library/etc/map-library.yaml index 0dc22627..2ab101a4 100644 --- a/server/map-library/etc/map-library.yaml +++ b/server/map-library/etc/map-library.yaml @@ -1,6 +1,7 @@ Name: map-library Host: 0.0.0.0 Port: 9906 +Timeout: 15000 #服务超时时间 SourceMysql: fusentest:XErSYmLELKMnf3Dh@tcp(110.41.19.98:3306)/fusentest Auth: AccessSecret: fusen2023 diff --git a/server/map-library/map-library.go b/server/map-library/map-library.go index 54ee66f6..254f2781 100644 --- a/server/map-library/map-library.go +++ b/server/map-library/map-library.go @@ -22,7 +22,6 @@ func main() { var c config.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) { diff --git a/server/orders/etc/orders.yaml b/server/orders/etc/orders.yaml index 77573dcf..b8bc7a88 100644 --- a/server/orders/etc/orders.yaml +++ b/server/orders/etc/orders.yaml @@ -1,6 +1,7 @@ Name: orders Host: 0.0.0.0 Port: 9907 +Timeout: 15000 #服务超时时间 SourceMysql: fusentest:XErSYmLELKMnf3Dh@tcp(110.41.19.98:3306)/fusentest Auth: AccessSecret: fusen2023 diff --git a/server/orders/orders.go b/server/orders/orders.go index a4707bea..3eda600a 100644 --- a/server/orders/orders.go +++ b/server/orders/orders.go @@ -22,7 +22,6 @@ func main() { var c config.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) { diff --git a/server/pay/etc/pay.yaml b/server/pay/etc/pay.yaml index 831292a9..1d2b1f75 100644 --- a/server/pay/etc/pay.yaml +++ b/server/pay/etc/pay.yaml @@ -1,6 +1,7 @@ Name: pay Host: 0.0.0.0 Port: 9915 +Timeout: 15000 #服务超时时间 SourceMysql: fusentest:XErSYmLELKMnf3Dh@tcp(110.41.19.98:3306)/fusentest Auth: AccessSecret: fusen2023 diff --git a/server/pay/pay.go b/server/pay/pay.go index 08c53e12..610b9d63 100644 --- a/server/pay/pay.go +++ b/server/pay/pay.go @@ -23,7 +23,6 @@ func main() { var c config.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) { })) defer server.Stop() diff --git a/server/product-model/product-model.go b/server/product-model/product-model.go index e0cabc28..adb3846e 100644 --- a/server/product-model/product-model.go +++ b/server/product-model/product-model.go @@ -22,7 +22,6 @@ func main() { var c config.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) { diff --git a/server/product-template-tag/etc/product-template-tag.yaml b/server/product-template-tag/etc/product-template-tag.yaml index 75f4d2d3..af29ff0a 100644 --- a/server/product-template-tag/etc/product-template-tag.yaml +++ b/server/product-template-tag/etc/product-template-tag.yaml @@ -1,6 +1,7 @@ Name: product-template-tag Host: 0.0.0.0 Port: 9917 +Timeout: 15000 #服务超时时间 SourceMysql: fusentest:XErSYmLELKMnf3Dh@tcp(110.41.19.98:3306)/fusentest Auth: AccessSecret: fusen2023 diff --git a/server/product-template-tag/product-template-tag.go b/server/product-template-tag/product-template-tag.go index 18898784..ea3066d4 100644 --- a/server/product-template-tag/product-template-tag.go +++ b/server/product-template-tag/product-template-tag.go @@ -23,7 +23,6 @@ func main() { var c config.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) { })) defer server.Stop() diff --git a/server/product-template/etc/product-template.yaml b/server/product-template/etc/product-template.yaml index 287b4a33..e8700c9c 100644 --- a/server/product-template/etc/product-template.yaml +++ b/server/product-template/etc/product-template.yaml @@ -1,6 +1,7 @@ Name: product-template Host: 0.0.0.0 Port: 9910 +Timeout: 15000 #服务超时时间 SourceMysql: fusentest:XErSYmLELKMnf3Dh@tcp(110.41.19.98:3306)/fusentest Auth: AccessSecret: fusen2023 diff --git a/server/product-template/product-template.go b/server/product-template/product-template.go index 522be699..d189133d 100644 --- a/server/product-template/product-template.go +++ b/server/product-template/product-template.go @@ -22,7 +22,6 @@ func main() { var c config.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) { diff --git a/server/product/etc/product.yaml b/server/product/etc/product.yaml index 658e5411..39181b84 100644 --- a/server/product/etc/product.yaml +++ b/server/product/etc/product.yaml @@ -1,6 +1,7 @@ Name: product Host: 0.0.0.0 Port: 9908 +Timeout: 15000 #服务超时时间 SourceMysql: fusentest:XErSYmLELKMnf3Dh@tcp(110.41.19.98:3306)/fusentest Auth: AccessSecret: fusen2023 diff --git a/server/render/etc/render.yaml b/server/render/etc/render.yaml index a75711b8..ccacf731 100644 --- a/server/render/etc/render.yaml +++ b/server/render/etc/render.yaml @@ -1,6 +1,7 @@ Name: render Host: 0.0.0.0 Port: 9919 +Timeout: 15000 #服务超时时间 SourceMysql: fusentest:XErSYmLELKMnf3Dh@tcp(110.41.19.98:3306)/fusentest Auth: AccessSecret: fusen2023 diff --git a/server/render/render.go b/server/render/render.go index f3cdafef..4088d424 100644 --- a/server/render/render.go +++ b/server/render/render.go @@ -26,7 +26,6 @@ func main() { var c config.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) { })) defer server.Stop() diff --git a/server/resource/resource.go b/server/resource/resource.go index 6a09918b..2841e642 100644 --- a/server/resource/resource.go +++ b/server/resource/resource.go @@ -23,7 +23,6 @@ func main() { var c config.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) { })) defer server.Stop() diff --git a/server/shopping-cart-confirmation/etc/shopping-cart-confirmation.yaml b/server/shopping-cart-confirmation/etc/shopping-cart-confirmation.yaml index fa40bb45..58a74824 100644 --- a/server/shopping-cart-confirmation/etc/shopping-cart-confirmation.yaml +++ b/server/shopping-cart-confirmation/etc/shopping-cart-confirmation.yaml @@ -1,6 +1,7 @@ Name: shopping-cart-confirmation Host: 0.0.0.0 Port: 9911 +Timeout: 15000 #服务超时时间 SourceMysql: fusentest:XErSYmLELKMnf3Dh@tcp(110.41.19.98:3306)/fusentest Auth: AccessSecret: fusen2023 diff --git a/server/shopping-cart-confirmation/shopping-cart-confirmation.go b/server/shopping-cart-confirmation/shopping-cart-confirmation.go index 55f29602..b3d9386e 100644 --- a/server/shopping-cart-confirmation/shopping-cart-confirmation.go +++ b/server/shopping-cart-confirmation/shopping-cart-confirmation.go @@ -22,7 +22,6 @@ func main() { var c config.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) { diff --git a/server/upload/etc/upload.yaml b/server/upload/etc/upload.yaml index 3e1c96f3..9d4ff5a2 100644 --- a/server/upload/etc/upload.yaml +++ b/server/upload/etc/upload.yaml @@ -1,6 +1,7 @@ Name: upload Host: 0.0.0.0 Port: 9912 +Timeout: 15000 #服务超时时间 SourceMysql: "fusentest:XErSYmLELKMnf3Dh@tcp(110.41.19.98:3306)/fusentest" Env: "test" Auth: diff --git a/server/upload/upload.go b/server/upload/upload.go index 603fe25a..2f5ef7f3 100644 --- a/server/upload/upload.go +++ b/server/upload/upload.go @@ -22,7 +22,6 @@ func main() { var c config.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) { diff --git a/server/webset/etc/webset.yaml b/server/webset/etc/webset.yaml index 4d7bb858..828b657b 100644 --- a/server/webset/etc/webset.yaml +++ b/server/webset/etc/webset.yaml @@ -1,6 +1,7 @@ Name: webset Host: 0.0.0.0 Port: 9913 +Timeout: 15000 #服务超时时间 SourceMysql: "fusentest:XErSYmLELKMnf3Dh@tcp(110.41.19.98:3306)/fusentest" Auth: AccessSecret: fusen2023 diff --git a/server/webset/webset.go b/server/webset/webset.go index 0b8d0ea7..069a0e07 100644 --- a/server/webset/webset.go +++ b/server/webset/webset.go @@ -22,7 +22,6 @@ func main() { var c config.Config conf.MustLoad(*configFile, &c) - c.Timeout = int64(time.Second * 15) server := rest.MustNewServer(c.RestConf, rest.WithCustomCors(auth.FsCors, func(w http.ResponseWriter) {