add mcp bridge (#107)

This commit is contained in:
Zhanghaibin
2022-12-09 15:18:49 +08:00
committed by GitHub
parent 4776d62515
commit b08b00f9d5
26 changed files with 4290 additions and 0 deletions

30
registry/memory/model.go Normal file
View File

@@ -0,0 +1,30 @@
package memory
import (
"time"
"istio.io/api/networking/v1alpha3"
)
type ServiceEntryWrapper struct {
ServiceName string
ServiceEntry *v1alpha3.ServiceEntry
Suffix string
RegistryType string
createTime time.Time
}
func (sew *ServiceEntryWrapper) DeepCopy() *ServiceEntryWrapper {
return &ServiceEntryWrapper{
ServiceEntry: sew.ServiceEntry.DeepCopy(),
createTime: sew.GetCreateTime(),
}
}
func (sew *ServiceEntryWrapper) SetCreateTime(createTime time.Time) {
sew.createTime = createTime
}
func (sew *ServiceEntryWrapper) GetCreateTime() time.Time {
return sew.createTime
}