Spring Boot:编写一个 Hello World 应用(Kotlin & Gradle)(16)

Spring Boot:编写一个 Hello World 应用(Kotlin & Gradle)

或者,通过 curl 来验证:

$ curl -v http://localhost:8080/hello

* Trying ::1...

* TCP_NODELAY set

* Connected to localhost (::1) port 8080 (#0)

> GET /hello HTTP/1.1

> Host: localhost:8080

> User-Agent: curl/7.54.0> Accept: */*

>

< HTTP/1.1 200

< Content-Type: text/plain;charset=UTF-8

< Content-Length: 13

< Date: Mon, 14 Jan 2019 13:03:50 GMT

推荐阅读