401 Unauthorized packages.atlassian.com while build Jira from source

Иван Михеев August 5, 2018

Jira Build failed when trying to request follow file:

https://packages.atlassian.com/api/npm/atlassian-npm/@atlassian%2feslint-plugin-onready-checks/-/@atlassian%2feslint-plugin-onready-checks-1.0.1.tgz

Request failed \"401 Unauthorized\"

 

Could you help me with it? 

4 answers

1 vote
David Grierson August 4, 2020

We're seeing the following warnings in our Nexus logs related to this issue (key parts highlighted):

2020-08-04 10:26:01 INFO [RepositoryStatusChecker-atlassian-public] org.sonatype.nexus.proxy.maven.maven2.M2Repository-atlassian-public - Next attempt to auto-unblock the "Atlassian Public" (id=atlassian-public) repository by checking its remote peer health will occur in 1 minute 20 seconds.
2020-08-04 10:26:03 WARN [proxy-3-thread-48] *UNKNOWN org.sonatype.nexus.proxy.maven.maven2.M2Repository - Remote peer of proxy repository "Atlassian Public" [id=atlassian-public] detected as healthy, un-blocking the proxy repository (it was AutoBlocked by Nexus).
2020-08-04 10:26:14 WARN [qtp1015146962-163] anonymous org.sonatype.nexus.proxy.maven.maven2.M2Repository - Remote peer of proxy repository "Atlassian Public" [id=atlassian-public] threw a org.sonatype.nexus.proxy.RemoteAuthenticationNeededException exception. Please set up authorization information for this repository. Auto-blocking this repository to prevent further connection-leaks and known-to-fail outbound connections until administrator fixes the problems, or Nexus detects remote repository as healthy. - Cause(s): Unauthorized

This appears to be because of the issue described above with some artifacts from this repository service being blocked with a 401 response.

This then triggers this Nexus issue (NEXUS-6515) which results in the Nexus service blocking all access to the Atlassian proxied repo ... which in turn gets unblocked because the top level repo is tested and found to be working ... until an artifact is requested when it gets a 401 response ... and round we go again.

The fix for the Nexus issue is to provide authentication credentials to the repository config.

Does anyone know how I can go about requesting credentials for packages.atlassian.com?

0 votes
Jack Dong November 3, 2020

We're seeing the exact same issue when pulling an artifact (com.atlassian.performance.tools:jira-performance-tests:pom:3.5.0) from https://packages.atlassian.com/maven/repository/public.

[ERROR] Failed to execute goal on project btf-test: Could not resolve dependencies for project com.atlassian.performance.tools.btftest:btf-test:jar:1.0-SNAPSHOT: Failed to collect dependencies at com.atlassian.performance.tools:jira-performance-tests:jar:3.5.0: Failed to read artifact descriptor for com.atlassian.performance.tools:jira-performance-tests:jar:3.5.0: Could not transfer artifact com.atlassian.performance.tools:jira-performance-tests:pom:3.5.0 from/to atlassian-public (https://packages.atlassian.com/maven/repository/public): Connect to packages.atlassian.com:443 [packages.atlassian.com] failed: Connection refused (Connection refused) -> [Help 1]

Would appreciate any workarounds or ways to go about it.

0 votes
Ahmed_Bilal January 20, 2020

I have the same issue any idea how to resolve this?

0 votes
Michael Kornatzki
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 11, 2019

I have the same problem.

Has someone a solution?

Try to build jira 8.0.2

Suggest an answer

Log in or Sign up to answer