Chronicle.Identity.IdentityProvider (cratis_chronicle v1.0.2)

Copy Markdown View Source

Process-scoped identity provider.

Stores the current identity in the process dictionary so identity flows naturally through the calling process.

Summary

Functions

Clears the current identity for the calling process.

Gets the current identity for the calling process.

Sets the current identity for the calling process.

Functions

clear_current_identity()

@spec clear_current_identity() :: :ok

Clears the current identity for the calling process.

get_current()

@spec get_current() :: Chronicle.Identity.t()

Gets the current identity for the calling process.

set_current_identity(identity)

@spec set_current_identity(Chronicle.Identity.t()) :: Chronicle.Identity.t()

Sets the current identity for the calling process.