JsonWebToken and thread safety with kotlin co-routines #38699
-
HI, I'm using Quarkus, with Kotlin and suspending functions. Say I have something like: @Path("/temp")
class TempResource(private val jwt: JsonWebToken) {
private val log = KotlinLogging.logger {}
@GET
suspend fun temp(): String {
log.info { jwt.subject }
return "temp"
}
} Do I have to do anything on top to make sure that jwt.subject will always be resolved to the subject of the currently processed request? I saw some thing called Thanks in advance 🙇 |
Beta Was this translation helpful? Give feedback.
Answered by
geoand
Feb 9, 2024
Replies: 2 comments 2 replies
-
/cc @geoand (kotlin) |
Beta Was this translation helpful? Give feedback.
0 replies
-
It should just work without having to do anything |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
dodalovicgran
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It should just work without having to do anything