Commit 5428721a authored by Yann Garcia's avatar Yann Garcia
Browse files

Bug fixed in federation self registration; Add flexcontainer support for meep-sss

parent ef2d5a38
Loading
Loading
Loading
Loading
+3 −1
Changes for go-apps/meep-federation/sbi/federation-sbi.go: 3 added lines, 1 removed line.
Original line number Diff line number Diff line
@@ -100,7 +100,7 @@ type Addresses struct {
	Port int32
}

var localSystemInfo SystemInfo
var localSystemInfo = SystemInfo{}

var sbi *FedSbi

@@ -329,8 +329,10 @@ func RegisterSystemInfo(requestData SystemInfo) (responseData SystemInfo, err er
	}

	responseData = requestData
	if localSystemInfo.SystemId == "" { // Self registration
		localSystemInfo = requestData
		log.Debug("RegisterSystemInfo: localSystemInfo=", localSystemInfo)
	} // otherwise, this is another MEC platform which is regsitering

	systemInfopMap[responseData.SystemId] = responseData
	log.Debug("RegisterSystemInfo: systemInfopMap=", systemInfopMap)
+1 −4
Changes for go-apps/meep-federation/server/federation.go: 1 added line, 4 removed lines.
Original line number Diff line number Diff line
@@ -951,14 +951,11 @@ func systeminfoPOST(w http.ResponseWriter, r *http.Request) {
		errHandlerProblemDetails(w, err.Error(), http.StatusInternalServerError)
		return
	}
	// Same data type
	localSystemInfo = responseData

	// Populate systemInfopMap
	systemInfopMap[responseData.SystemId] = responseData
	log.Debug("systeminfoPOST: new systemInfopMap: ", systemInfopMap)

	log.Info("Registration succeed: ", localSystemInfo)

	// Prepare & send response
	var l = SystemInfo{
		SystemId:       responseData.SystemId,