-
Notifications
You must be signed in to change notification settings - Fork 214
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
Stop cleaning the plugin directory by default + Add an opt-in flag for cleaning the target plugin directory + Restore the --list
command
#239
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this needs to be done to a temp directory, or at least change the code to remove broken plugin downloads, they are kept for debugging currently i think
scenario:
- broken plugin download, checksum mismatch
- re-run download, code will find plugin already exists and skip the download
- dodgy plugin is used
…le skipFailed correctly
plugin-management-library/src/main/java/io/jenkins/tools/pluginmanager/impl/PluginManager.java
Outdated
Show resolved
Hide resolved
plugin-management-library/src/main/java/io/jenkins/tools/pluginmanager/impl/PluginManager.java
Outdated
Show resolved
Hide resolved
plugin-management-library/src/main/java/io/jenkins/tools/pluginmanager/impl/PluginManager.java
Show resolved
Hide resolved
plugin-management-library/src/main/java/io/jenkins/tools/pluginmanager/impl/PluginManager.java
Outdated
Show resolved
Hide resolved
@@ -191,4 +195,42 @@ public void allowsLatestTopLevelDependency() throws IOException { | |||
pluginManager.findPluginsAndDependencies(requestedPlugins); | |||
assertThatNoException(); | |||
} | |||
|
|||
//TODO: Enable as auto-test once it can run without massive traffic overhead |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this a problem because you used workflow-job? could you use a small simple plugin instead and it would be ok?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Workflow-job also emulates dependency updates, so it is useful for deeper tests. Will create a simple fork
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, some super minor nits
plugin-management-library/src/main/java/io/jenkins/tools/pluginmanager/impl/PluginManager.java
Outdated
Show resolved
Hide resolved
...-library/src/test/java/io/jenkins/tools/pluginmanager/impl/PluginManagerIntegrationTest.java
Show resolved
Hide resolved
Co-authored-by: Joseph Petersen <[email protected]>
--list
command
The option has been added via jenkinsci#239 in 2020. Add it to the `README.md` for those reading the documentation from the GitHub repo page.
The option has been added via #239 in 2020. Add it to the `README.md` for those reading the documentation from the GitHub repo page.
After #94 , the plugin directory was always emptied before downloading the plugins. This patch makes the plugin dir cleaning an optional behavior.
Sample output on a second run: