12 lines
253 B
Text
12 lines
253 B
Text
package main
|
|
|
|
import fmt
|
|
import http net.http
|
|
|
|
fun handle(request: *http.Request) = withContext(request.context()) {
|
|
fmt.println(coroutineContext())
|
|
}
|
|
|
|
fun main() {
|
|
println("HTTP handlers can establish their request context with withContext")
|
|
}
|