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

caching the same repository avoid reload multiple time on the same build #340

Open
wants to merge 15 commits into
base: main
Choose a base branch
from

Conversation

arechavarria
Copy link

@arechavarria arechavarria commented Sep 12, 2024

PR Details

Description

It has been observed that the library makes more repository queries than necessary, which is redundant unless the libraries are stored in different remote repositories. However, each repository only needs to be queried once, and its content should be cached and associated with the execution to avoid impacting future or concurrent runs. This will shorten the initialization time for pipelines using the library

How Has This Been Tested

Tests are conducted on different types of pipelines, including multibranch and simple pipelines, to analyze the previous behavior. The results show a significant reduction in pipeline initialization time

  • Java 21
  • Jenkins 2.462.2

This behavior only affects how remote repositories are queried when the libraries come from a source control management (SCM) system.

Types of Changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Added Unit Testing
  • Docs change / refactoring / dependency upgrade
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist

  • I have added the appropriate label for this PR
  • If necessary, I have updated the documentation accordingly.
  • All new and existing tests passed.

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

Successfully merging this pull request may close these issues.

1 participant