Mysterious Error log from IdentityClient when using DefaultAzureCredential

Ian Lee 5 Reputation points
2024-02-28T07:14:20.6233333+00:00
2024-02-27 23:08:54.995 ERROR 54214 --- [           main] c.a.i.implementation.IdentityClient      : Could not invoke the MSAL Broker. Ensure that the azure-identity-broker library is on the classpath.
java.lang.IllegalStateException: Could not invoke the MSAL Broker. Ensure that the azure-identity-broker library is on the classpath.
        at com.azure.identity.implementation.IdentityClientBase.getPublicClient(IdentityClientBase.java:353)
        at com.azure.identity.implementation.IdentityClient.lambda$getPublicClientApplication$8(IdentityClient.java:199)

This is happening even though I included

implementation("com.azure:azure-identity")
implementation("com.azure:azure-identity-broker")

in my build.gradle.

Eventually the broker is able to identify the credentials from CLI. But we just want to get rid of the error log. Thanks in Advance!

2024-02-27 23:08:55.495 DEBUG 54214 --- [           main] c.a.i.implementation.IdentityClient      : Azure CLI Authentication => A token response was received from Azure CLI, deserializing the response into an Access Token.
2024-02-27 23:08:55.521  INFO 54214 --- [           main] com.azure.identity.AzureCliCredential    : Azure Identity => getToken() result for scopes [https://vault.azure.net/.default]: SUCCESS
ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
4,182 questions
ASP.NET
ASP.NET
A set of technologies in the .NET Framework for building web applications and XML web services.
3,265 questions
Microsoft Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
19,549 questions
{count} vote