X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=dmaap-mediator-producer%2Fstub%2Fdmaap%2Fmrstub.go;h=451bc9a1cebb8c8a1e8e5736966f9c43a7e78237;hb=df5eeb6e3fe42f87ac399f624edef20c87d1e475;hp=82ae08d5bdd226a085b984eea4a7124884a7b40e;hpb=6f48adb69090799c74c29204dd2cd1737cc9d6ac;p=nonrtric.git diff --git a/dmaap-mediator-producer/stub/dmaap/mrstub.go b/dmaap-mediator-producer/stub/dmaap/mrstub.go index 82ae08d5..451bc9a1 100644 --- a/dmaap-mediator-producer/stub/dmaap/mrstub.go +++ b/dmaap-mediator-producer/stub/dmaap/mrstub.go @@ -57,7 +57,7 @@ func main() { http.HandleFunc("/events/unauthenticated.SEC_FAULT_OUTPUT/dmaapmediatorproducer/STD_Fault_Messages", handleData) fmt.Print("Starting mr on port: ", *port) - http.ListenAndServeTLS(fmt.Sprintf(":%v", *port), "../../security/producer.crt", "../../security/producer.key", nil) + fmt.Println(http.ListenAndServeTLS(fmt.Sprintf(":%v", *port), "../../security/producer.crt", "../../security/producer.key", nil)) } @@ -71,12 +71,13 @@ func handleData(w http.ResponseWriter, req *http.Request) { var responseBody []byte if critical { responseBody = getFaultMessage("CRITICAL") + fmt.Println("Sending CRITICAL") critical = false } else { responseBody = getFaultMessage("NORMAL") + fmt.Println("Sending NORMAL") critical = true } - // w.Write(responseBody) fmt.Fprint(w, string(responseBody)) }