jvmMain.io.ktor.client.plugins.observer.ResponseObserverContextJvm.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of ktor-client-core-jvm Show documentation
Show all versions of ktor-client-core-jvm Show documentation
Ktor is a framework for quickly creating web applications in Kotlin with minimal effort.
/*
* Copyright 2014-2022 JetBrains s.r.o and contributors. Use of this source code is governed by the Apache 2.0 license.
*/
package io.ktor.client.plugins.observer
import kotlinx.coroutines.slf4j.*
import kotlin.coroutines.*
internal actual suspend fun getResponseObserverContext(): CoroutineContext =
coroutineContext[MDCContext] ?: EmptyCoroutineContext