Signed-off-by: khemendra kumar <khemendra.kumar@huawei.com>
Change-Id: I906207378d206fa3d4da184034cc1ec79f44a11c
meputil "mepserver/mp1/util"
)
meputil "mepserver/mp1/util"
)
+// This type represents the general information of a MEC service info for registry/discovery
type ServiceInfo struct {
SerInstanceId string `json:"serInstanceId,omitempty"`
SerName string `json:"serName"`
type ServiceInfo struct {
SerInstanceId string `json:"serInstanceId,omitempty"`
SerName string `json:"serName"`
s.SerCategory.Version = properties["serCategory/version"]
}
s.SerCategory.Version = properties["serCategory/version"]
}
+//Parse service endpoint info
func (s *ServiceInfo) fromEndpoints(uris []string, epType string) {
if epType == "uris" {
s.TransportInfo.Endpoint.Uris = uris
func (s *ServiceInfo) fromEndpoints(uris []string, epType string) {
if epType == "uris" {
s.TransportInfo.Endpoint.Uris = uris
+//Parse service transport info
func (s *ServiceInfo) transportInfoFromProperties(properties map[string]string) {
if properties == nil {
return
func (s *ServiceInfo) transportInfoFromProperties(properties map[string]string) {
if properties == nil {
return