gateway/core/service.go

18 lines
315 B
Go
Raw Normal View History

2021-09-07 13:40:44 +08:00
package core
type serviceItem struct {
2021-09-07 13:40:44 +08:00
Path string
Service string
2021-09-07 17:12:29 +08:00
Enable bool
Lb Lb
2021-09-07 13:40:44 +08:00
}
func NewServiceMapItem(k, v string, e bool, lb Lb) serviceItem {
//var sma []serviceItem
2021-09-07 13:40:44 +08:00
// 从Nacos读取规则
// gateway:
// - path: /user
// service: mb-user-service
return serviceItem{k, v, e, lb}
2021-09-07 13:40:44 +08:00
}