Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Please add Jitpack to repositories available when useArtifactCachingProxy=true #3591

Closed
jimklimov opened this issue May 23, 2023 · 4 comments

Comments

@jimklimov
Copy link

The https://github.com/jenkinsci/ircbot-plugin relies on https://github.com/pircbotx/pircbotx/ whose binary releases (and snapshots) are published to https://jitpack.io/#pircbotx/pircbotx/

The plugin's pom.xml refers to that repository (via root URL https://jitpack.io and no sub-URIs), and it works for local builds as well as it did work for Jenkins CI builds until jenkins-infra/pipeline-library#577 here got merged, I suppose. In fact, with that plugin's Jenkinsfile updated to opt-out of caching with jenkinsci/ircbot-plugin#190 it seems to work on CI again, at the cost of causing occasional potentially-avoidable traffic for the Jenkins project.

However, this library's README "face value" implies that this situation may be a temporary success, if opting-out means going to repo.j.o directly (and if that would become the only allowed destination at some point):

useArtifactCachingProxy: (default: true) - if set to false, artifacts will not use one of the artifact caching proxy depending on the agent provider (Azure, DigitalOcean or AWS), and will directly use https://repo.jenkins-ci.org/ instead (discouraged as less reliable and consuming bandwidth)

Per this issue, I ask for Jitpack to be added to resources cached by aws-proxy/do-proxy/azure-proxy/... and so allow avoiding both the possible lack of direct access to it (per README FUD) and the use of internet traffic instead of hosting-provider traffic for CI builds (and presumably lags/costs associated with it).

@jimklimov
Copy link
Author

Note: a half-practical initial workaround in jenkinsci/ircbot-plugin#164 was to add a JAR of the dependency to repo.j.o (snapshot area) which I could as a plugin maintainer. This caused further mess in the plugin recipe and is generally not easily maintainable nor scalable, but seems viable as a last straw.

I could not upload that JAR as a release (initially to avoid maven enforcer checks) - maybe due to my rights, maybe because of its metadata (name says SNAPSHOT), did not investigate further.

@timja timja transferred this issue from jenkins-infra/pipeline-library May 23, 2023
@timja timja added the triage Incoming issues that need review label May 23, 2023
@dduportal dduportal added this to the infra-team-sync-2023-05-30 milestone May 23, 2023
@jimklimov
Copy link
Author

jimklimov commented May 24, 2023

As a possible solution idea, I wonder if Artifactory (the original repo.j.o) can serve as a proxy to other repos that are used for Jenkins plugin dependencies, such as this Jitpack, and if it would help to add the link there (and so have it "inherited" by aws/do/azure/... proxies). Effectively the pom.xml in ircbot-plugin could get simplified too, to just look at repo.j.o then. Just a thought...

@lemeurherve
Copy link
Member

lemeurherve commented Jun 8, 2023

Hello @jimklimov,

As a short term solution, I've added jitpack.io 3rd party Maven repository to ci.jenkins.io mirror settings exceptions in jenkins-infra/jenkins-infra#2895, and opened a PR to restore artifact caching proxy use on the plugin: jenkinsci/ircbot-plugin#196

As a long term solution we will certainly mirror all these 3rd party repositories in our Artifactory, but this has to wait until #3599 has progressed (at least).

@lemeurherve
Copy link
Member

@jimklimov I'll let you restore the artifact caching proxy by merging (or not) my pull request, closing this issue as completed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants