20 lines
395 B
Go
20 lines
395 B
Go
package main
|
|
|
|
import "log"
|
|
import "net/http"
|
|
import "hnakra/service"
|
|
|
|
func main () {
|
|
http.HandleFunc("/kamikaze/", hellorld)
|
|
|
|
err := service.NewHTTP (
|
|
"Kamikaze",
|
|
"A service that abrupltly closes upon any request, for testing.",
|
|
"@", "/kamikaze/").Run()
|
|
if err != nil { log.Println("XXX", err) }
|
|
}
|
|
|
|
func hellorld (res http.ResponseWriter, req *http.Request) {
|
|
log.Fatal("Goodbye!")
|
|
}
|