Code Review
/
ric-plt
/
e2mgr.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
[RIC-432] - Support Update eNB REST API - swagger changed: /nodeb/ids to /nodeb/state...
[ric-plt/e2mgr.git]
/
E2Manager
/
httpserver
/
http_server.go
diff --git
a/E2Manager/httpserver/http_server.go
b/E2Manager/httpserver/http_server.go
index
a022ecb
..
3ee48ef
100644
(file)
--- a/
E2Manager/httpserver/http_server.go
+++ b/
E2Manager/httpserver/http_server.go
@@
-29,7
+29,7
@@
import (
func Run(log *logger.Logger, port int, rootController controllers.IRootController, nodebController controllers.INodebController, e2tController controllers.IE2TController) error {
func Run(log *logger.Logger, port int, rootController controllers.IRootController, nodebController controllers.INodebController, e2tController controllers.IE2TController) error {
- router := mux.NewRouter()
;
+ router := mux.NewRouter()
initializeRoutes(router, rootController, nodebController, e2tController)
addr := fmt.Sprintf(":%d", port)
initializeRoutes(router, rootController, nodebController, e2tController)
addr := fmt.Sprintf(":%d", port)
@@
-45,10
+45,14
@@
func initializeRoutes(router *mux.Router, rootController controllers.IRootContro
r.HandleFunc("/health", rootController.HandleHealthCheckRequest).Methods(http.MethodGet)
rr := r.PathPrefix("/nodeb").Subrouter()
r.HandleFunc("/health", rootController.HandleHealthCheckRequest).Methods(http.MethodGet)
rr := r.PathPrefix("/nodeb").Subrouter()
- rr.HandleFunc("/
id
s", nodebController.GetNodebIdList).Methods(http.MethodGet)
+ rr.HandleFunc("/
state
s", nodebController.GetNodebIdList).Methods(http.MethodGet)
rr.HandleFunc("/{ranName}", nodebController.GetNodeb).Methods(http.MethodGet)
rr.HandleFunc("/{ranName}", nodebController.GetNodeb).Methods(http.MethodGet)
+ rr.HandleFunc("/enb", nodebController.AddEnb).Methods(http.MethodPost)
+ rr.HandleFunc("/enb/{ranName}", nodebController.DeleteEnb).Methods(http.MethodDelete)
rr.HandleFunc("/{ranName}/update", nodebController.UpdateGnb).Methods(http.MethodPut)
rr.HandleFunc("/{ranName}/update", nodebController.UpdateGnb).Methods(http.MethodPut)
+ rr.HandleFunc("/enb/{ranName}", nodebController.UpdateEnb).Methods(http.MethodPut)
rr.HandleFunc("/shutdown", nodebController.Shutdown).Methods(http.MethodPut)
rr.HandleFunc("/shutdown", nodebController.Shutdown).Methods(http.MethodPut)
+ rr.HandleFunc("/parameters", nodebController.SetGeneralConfiguration).Methods(http.MethodPut)
rrr := r.PathPrefix("/e2t").Subrouter()
rrr.HandleFunc("/list", e2tController.GetE2TInstances).Methods(http.MethodGet)
}
rrr := r.PathPrefix("/e2t").Subrouter()
rrr.HandleFunc("/list", e2tController.GetE2TInstances).Methods(http.MethodGet)
}