Skip to content
Bug Barometer
All issues
In Review

MuleSoft / Anypoint Connectors

Anypoint MQ Connector publish intermittently fails with "Can not login into Authentication Server" during token refresh

Summary

When an application sends several Anypoint MQ requests at the same time (for example, concurrent publish or subscriber operations), a publish can intermittently fail with:


Failed to publish message to destination '<destination>': An error occurred while executing the operation: AUTHORIZE AGAINST AUTH SERVER. Cause: Can not login into Authentication Server https://<control-plane>/accounts/oauth2/token


The error happens even though the Anypoint Platform token endpoint responds successfully (HTTP 200) to every token request. The cause is a race condition in the connector's access-token handling. When the access token expires, concurrent requests that share the same connection refresh the token at the same time, and a request in flight can fail during that refresh.


The issue is intermittent and timing-dependent. It is more likely when more threads publish to Anypoint MQ at the same time, for example with higher throughput or more vCores.


If the application's error handling stops a flow or a message source when the publish fails, that flow can stop consuming messages until it is restarted.


Affected versions: Anypoint MQ Connector 4.0.x up to and including 4.0.24.

Workaround

1. Wrap each Anypoint MQ Publish operation in an Until Successful scope, for example 3 retries 1000 ms apart. The retry uses the refreshed access token and succeeds.

Steps to reproduce

Intermittent issue.

Error details

Failed to publish message to destination '': An error occurred while executing the operation: AUTHORIZE AGAINST AUTH SERVER. Cause: Can not login into Authentication Server https:///accounts/oauth2/token

History

  1. Description updated

    Nov 30, 2026

  2. First tracked here as In Review with 3 reports

    Nov 30, 2026