scala - Referencing logged in user in akka-http -


we using akka-http (scala version) create api. authenticate (and authorize) users in our routes. once authenticated, call services complete our crud operations. services plain scala classes , traits.

what wanting access authenticated user inside of scala service (class/trait) call route without explicitly passing user info. service may call other services , i'd refrain passing authenticated user implicit or explicit parameter down call chain.

in non-actor world employ threadlocal or dynamicvariable attach user information thread pull out , reference later. understand concepts don't play or apply akka-based systems. there mechanism accomplish i'm going for?


Comments

Popular posts from this blog

javascript - Confirm a form & display message if form is valid with JQuery -

Retrieving ETA (estimated time of arrival) with Google Distance Matrix API and public transit as transport mode -

ionic framework - Meteor - Error: Failed to execute 'insertBefore' on 'Node' -