Create a maven 2 proxy repo to remote URL https://packages.atlassian.com/mvn/maven-external/. Make sure the setting Auto blocking enabled is NOT turned on ( checked ). Save.
Send an inbound request for an artifact that does not exist at the remote site, but causes the remote site to return 401 response. A 401 response from a remote is intended to auto-block a repository ( if the Auto block feature is enabled ).
Client requests this http://localhost:8081/repository/atlassian-maven/com/example/example/0.1.029/maven-metadata.xml
NXRM sends to remote and gets 401, then sets the repo status to unavailable:
When the Auto blocking feature for a proxy repository is disabled, then the repository should never appear to become blocked automatically or have the repo status set to anything other than READY or AVAILABLE.
Find some other way to surface sporadic 401 responses from the remote, when most requests work.
Note: There is a manual set Blocked setting - that setting is independent and takes precedence if turned on.
The UNAVAILABLE status doesn't indicate the repository is blocked, there is a distinct AUTO_BLOCKED_UNAVAILABLE for that. The intent of the UNAVAILABLE status was meant to surface a potential connection error.
This UNAVAILABLE repo status was introduced by
NEXUS-16539 as of 3.11.0
The side effect is the entire repo status changes for a single failed 401 request, when many/all others may actually work fine:
The value we might have thought this status added is lost - it actually causes more confusion because the repository is still available and ready despite what the UI and logs indicate.