Skip to content

Commit

Permalink
Fix logging during async refresh
Browse files Browse the repository at this point in the history
  • Loading branch information
lauzadis committed Feb 17, 2024
1 parent 2cbf22b commit 8ec0916
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import aws.sdk.kotlin.services.s3.*
import aws.smithy.kotlin.runtime.auth.awscredentials.Credentials
import aws.smithy.kotlin.runtime.collections.LruCache
import aws.smithy.kotlin.runtime.io.Closeable
import aws.smithy.kotlin.runtime.telemetry.TelemetryProviderContext
import aws.smithy.kotlin.runtime.telemetry.logging.logger
import aws.smithy.kotlin.runtime.time.Clock
import aws.smithy.kotlin.runtime.time.until
Expand All @@ -25,7 +26,7 @@ internal class S3ExpressCredentialsCache(
private val client: S3Client,
private val clock: Clock = Clock.System,
) : CoroutineScope, Closeable {
override val coroutineContext: CoroutineContext = Job() + CoroutineName("S3ExpressCredentialsCacheRefresh")
override val coroutineContext: CoroutineContext = Job() + CoroutineName("S3ExpressCredentialsCacheRefresh") + TelemetryProviderContext(client.config.telemetryProvider)

private val lru = LruCache<S3ExpressCredentialsCacheKey, S3ExpressCredentialsCacheValue>(DEFAULT_S3_EXPRESS_CACHE_SIZE)

Expand Down

0 comments on commit 8ec0916

Please sign in to comment.