Loading go-apps/meep-app-enablement/server/app-support/app-support.go +2 −1 Original line number Diff line number Diff line Loading @@ -370,6 +370,7 @@ func applicationsSubscriptionsPOST(w http.ResponseWriter, r *http.Request) { http.Error(w, err.Error(), http.StatusInternalServerError) return } w.Header().Set("Location", subscription.Links.Self.Href) w.WriteHeader(http.StatusCreated) fmt.Fprintf(w, string(jsonResponse)) } Loading Loading @@ -488,7 +489,7 @@ func applicationsSubscriptionsGET(w http.ResponseWriter, r *http.Request) { var subscription SubscriptionLinkListLinksSubscriptions subscription.Href = appTermSubscription.Links.Self.Href //in v2.1.1 it should be SubscriptionType, but spec is expecting "rel" as per v1.1.1 subscription.Rel = APP_TERMINATION_NOTIFICATION_SUBSCRIPTION_TYPE subscription.SubscriptionType = APP_TERMINATION_NOTIFICATION_SUBSCRIPTION_TYPE subscriptionLinkList.Links.Subscriptions = append(subscriptionLinkList.Links.Subscriptions, subscription) } } Loading go-apps/meep-app-enablement/server/service-mgmt/service-mgmt.go +6 −1 Original line number Diff line number Diff line Loading @@ -347,6 +347,9 @@ func appServicesPOST(w http.ResponseWriter, r *http.Request) { return } // Get resource uri resourceUri := hostUrl.String() + basePath + "applications/" + appInstanceId + "/services/" + sInfo.SerInstanceId // Send response jsonResponse, err := json.Marshal(sInfo) if err != nil { Loading @@ -354,6 +357,7 @@ func appServicesPOST(w http.ResponseWriter, r *http.Request) { http.Error(w, err.Error(), http.StatusInternalServerError) return } w.Header().Set("Location", resourceUri) w.WriteHeader(http.StatusCreated) fmt.Fprintf(w, string(jsonResponse)) } Loading Loading @@ -638,6 +642,7 @@ func applicationsSubscriptionsPOST(w http.ResponseWriter, r *http.Request) { http.Error(w, err.Error(), http.StatusInternalServerError) return } w.Header().Set("Location", subscription.Links.Self.Href) w.WriteHeader(http.StatusCreated) fmt.Fprintf(w, string(jsonResponse)) } Loading Loading @@ -1096,7 +1101,7 @@ func populateSubscriptionsList(key string, jsonInfo string, data interface{}) er var subscription SubscriptionLinkListLinksSubscriptions subscription.Href = serAvailSubscription.Links.Self.Href //in v2.1.1 it should be SubscriptionType, but spec is expecting "rel" as per v1.1.1 subscription.Rel = SER_AVAILABILITY_NOTIFICATION_SUBSCRIPTION_TYPE subscription.SubscriptionType = SER_AVAILABILITY_NOTIFICATION_SUBSCRIPTION_TYPE // Add subscription to list subscriptionLinkList.Links.Subscriptions = append(subscriptionLinkList.Links.Subscriptions, subscription) Loading Loading
go-apps/meep-app-enablement/server/app-support/app-support.go +2 −1 Original line number Diff line number Diff line Loading @@ -370,6 +370,7 @@ func applicationsSubscriptionsPOST(w http.ResponseWriter, r *http.Request) { http.Error(w, err.Error(), http.StatusInternalServerError) return } w.Header().Set("Location", subscription.Links.Self.Href) w.WriteHeader(http.StatusCreated) fmt.Fprintf(w, string(jsonResponse)) } Loading Loading @@ -488,7 +489,7 @@ func applicationsSubscriptionsGET(w http.ResponseWriter, r *http.Request) { var subscription SubscriptionLinkListLinksSubscriptions subscription.Href = appTermSubscription.Links.Self.Href //in v2.1.1 it should be SubscriptionType, but spec is expecting "rel" as per v1.1.1 subscription.Rel = APP_TERMINATION_NOTIFICATION_SUBSCRIPTION_TYPE subscription.SubscriptionType = APP_TERMINATION_NOTIFICATION_SUBSCRIPTION_TYPE subscriptionLinkList.Links.Subscriptions = append(subscriptionLinkList.Links.Subscriptions, subscription) } } Loading
go-apps/meep-app-enablement/server/service-mgmt/service-mgmt.go +6 −1 Original line number Diff line number Diff line Loading @@ -347,6 +347,9 @@ func appServicesPOST(w http.ResponseWriter, r *http.Request) { return } // Get resource uri resourceUri := hostUrl.String() + basePath + "applications/" + appInstanceId + "/services/" + sInfo.SerInstanceId // Send response jsonResponse, err := json.Marshal(sInfo) if err != nil { Loading @@ -354,6 +357,7 @@ func appServicesPOST(w http.ResponseWriter, r *http.Request) { http.Error(w, err.Error(), http.StatusInternalServerError) return } w.Header().Set("Location", resourceUri) w.WriteHeader(http.StatusCreated) fmt.Fprintf(w, string(jsonResponse)) } Loading Loading @@ -638,6 +642,7 @@ func applicationsSubscriptionsPOST(w http.ResponseWriter, r *http.Request) { http.Error(w, err.Error(), http.StatusInternalServerError) return } w.Header().Set("Location", subscription.Links.Self.Href) w.WriteHeader(http.StatusCreated) fmt.Fprintf(w, string(jsonResponse)) } Loading Loading @@ -1096,7 +1101,7 @@ func populateSubscriptionsList(key string, jsonInfo string, data interface{}) er var subscription SubscriptionLinkListLinksSubscriptions subscription.Href = serAvailSubscription.Links.Self.Href //in v2.1.1 it should be SubscriptionType, but spec is expecting "rel" as per v1.1.1 subscription.Rel = SER_AVAILABILITY_NOTIFICATION_SUBSCRIPTION_TYPE subscription.SubscriptionType = SER_AVAILABILITY_NOTIFICATION_SUBSCRIPTION_TYPE // Add subscription to list subscriptionLinkList.Links.Subscriptions = append(subscriptionLinkList.Links.Subscriptions, subscription) Loading