12#if defined(_azure_TESTING_BUILD)
13class DefaultAzureCredential_CachingCredential_Test;
16namespace Azure {
namespace Identity {
namespace _detail {
18 class ChainedTokenCredentialImpl final {
20#if defined(_azure_TESTING_BUILD)
22 friend class ::DefaultAzureCredential_CachingCredential_Test;
26 ChainedTokenCredentialImpl(
27 std::string
const& credentialName,
29 bool reuseSuccessfulSource =
false);
31 Core::Credentials::AccessToken GetToken(
32 std::string
const& credentialName,
33 Core::Credentials::TokenRequestContext
const& tokenRequestContext,
34 Core::Context
const& context)
const;
38 mutable std::mutex m_sourcesMutex;
41 constexpr static std::size_t SuccessfulSourceNotSet = (std::numeric_limits<std::size_t>::max)();
43 mutable std::atomic<std::size_t> m_successfulSourceIndex = {SuccessfulSourceNotSet};
44 bool m_reuseSuccessfulSource;
Chained Token Credential.
std::vector< std::shared_ptr< Core::Credentials::TokenCredential > > Sources
A container type to store the ordered chain of credentials.
Definition chained_token_credential.hpp:34