From 5207bd099a84832a5d7c3333bf540fa8481ce78a Mon Sep 17 00:00:00 2001 From: Kiran Kamineni Date: Thu, 23 May 2019 13:50:50 -0700 Subject: Update broker responses to match spec and SO The broker responses need to match the spec and what SO expects as responses. CREATE_COMPLETE instead of CREATED in both POST and GET DELETE now returns a response body GET by name is now supported Name is an alias for vf_module_id which is expected to be provided as an attribute in sdnc_directives in the original POST request Issue-ID: MULTICLOUD-645 Change-Id: Ifeca755a07298d0a858cbe9e80f9ce654d6d21b8 Signed-off-by: Kiran Kamineni --- src/k8splugin/api/api.go | 1 + 1 file changed, 1 insertion(+) (limited to 'src/k8splugin/api/api.go') diff --git a/src/k8splugin/api/api.go b/src/k8splugin/api/api.go index 58e50a16..808d6f5b 100644 --- a/src/k8splugin/api/api.go +++ b/src/k8splugin/api/api.go @@ -47,6 +47,7 @@ func NewRouter(defClient rb.DefinitionManager, brokerHandler := brokerInstanceHandler{client: instClient} router.HandleFunc("/{cloud-owner}/{cloud-region}/infra_workload", brokerHandler.createHandler).Methods("POST") router.HandleFunc("/{cloud-owner}/{cloud-region}/infra_workload/{instID}", brokerHandler.getHandler).Methods("GET") + router.HandleFunc("/{cloud-owner}/{cloud-region}/infra_workload", brokerHandler.findHandler).Queries("name", "{name}").Methods("GET") router.HandleFunc("/{cloud-owner}/{cloud-region}/infra_workload/{instID}", brokerHandler.deleteHandler).Methods("DELETE") //Setup the connectivity api handler here -- cgit 1.2.3-korg