Skip to content
Permalink
Browse files

Merge remote-tracking branch 'primary/master' into

JENKINS-34174-plugin-download-timeout

# Conflicts:
#	core/src/main/resources/jenkins/install/pluginSetupWizard.properties
  • Loading branch information
kzantow committed Apr 22, 2016
2 parents 6974d2b + 5d90f81 commit e612f4163a0e1acedfed9baed6e79cf2bad6fabe
@@ -1009,6 +1009,7 @@ public HttpResponse doPlugins() {
pluginInfo.put("bundled", plugin.isBundled);
pluginInfo.put("deleted", plugin.isDeleted());
pluginInfo.put("downgradable", plugin.isDowngradable());
pluginInfo.put("website", plugin.getUrl());
List<Dependency> dependencies = plugin.getDependencies();
if (dependencies != null && !dependencies.isEmpty()) {
Map<String, String> dependencyMap = new HashMap<>();
@@ -1033,6 +1034,7 @@ public HttpResponse doPlugins() {
pluginInfo.put("excerpt", plugin.excerpt);
pluginInfo.put("site", site.getId());
pluginInfo.put("dependencies", plugin.dependencies);
pluginInfo.put("website", plugin.wiki);
response.add(pluginInfo);
}
}
@@ -1198,19 +1200,19 @@ private void trackInitialPluginInstall(@Nonnull final List<Future<UpdateCenter.U
new Thread() {
@Override
public void run() {
final boolean failures[] = { false };
boolean failures = false;
INSTALLING: while (true) {
try {
updateCenter.persistInstallStatus();
Thread.sleep(500);
failures[0] = false;
failures = false;
for (Future<UpdateCenter.UpdateCenterJob> jobFuture : installJobs) {
if(!jobFuture.isDone() && !jobFuture.isCancelled()) {
continue INSTALLING;
}
UpdateCenter.UpdateCenterJob job = jobFuture.get();
if(job instanceof InstallationJob && ((InstallationJob)job).status instanceof DownloadJob.Failure) {
failures[0] = true;
failures = true;
}
}
} catch (Exception e) {
@@ -1219,7 +1221,7 @@ public void run() {
break;
}
updateCenter.persistInstallStatus();
if(!failures[0]) {
if(!failures) {
jenkins.setInstallState(InstallState.INITIAL_PLUGINS_INSTALLING.getNextState());
}
}
@@ -50,6 +50,7 @@ installWizard_configureProxy_save=Save and Continue
installWizard_skipPluginInstallations=Skip Plugin Installations
installWizard_installIncomplete_dependenciesLabel=Dependencies
installWizard_installingConsole_dependencyIndicatorNote=** - required dependency
installWizard_websiteLinkLabel=Website
installWizard_pluginInstallFailure_title=Installation Failures
installWizard_pluginInstallFailure_message=Some plugins failed to install properly, you may retry installing them or continue \
with the failed plugins
@@ -208,7 +208,7 @@ var createPluginSetupWizard = function(appendTarget) {
decorate($container);

var $modalHeader = $container.find('.modal-header');
if($modalHeader.length > 0) {
if($modalHeader.length > 0 && $modalHeader.is('.closeable')) {
$modalHeader.prepend(
'<button type="button" class="close" aria-label="Close"><span aria-hidden="true">&times;</span></button>');
}
@@ -852,7 +852,7 @@ var createPluginSetupWizard = function(appendTarget) {
'.plugin-select-recommended': function() { selectedPluginNames = pluginManager.recommendedPluginNames(); refreshPluginSelectionPanel(); },
'.plugin-show-selected': toggleSelectedSearch,
'.select-category': selectCategory,
'.close': closeInstaller,
'.close': skipFirstUser,
'.resume-installation': resumeInstallation,
'.install-done-restart': restartJenkins,
'.save-first-user:not([disabled])': saveFirstUser,
@@ -1,4 +1,4 @@
<div class="modal-header">
<div class="modal-header closeable">
<h4 class="modal-title">{{translations.installWizard_installCustom_title}}</h4>
</div>
<div class="modal-body plugin-selector">
@@ -40,16 +40,17 @@
<span class="title">
<input type="checkbox" id="chk-{{plugin.name}}" name="{{plugin.name}}" value="{{searchTerm}}" {{#inSelectedPlugins plugin.name}}checked="checked"{{/inSelectedPlugins}}/>
{{plugin.title}}
<a href="{{plugin.website}}" target="_blank">{{../../translations.installWizard_websiteLinkLabel}}</a>
</span>
<span class="description">
{{{plugin.excerpt}}}
</span>
{{#hasDependencies plugin.name}}
<div class="dep-list">
{{#eachDependency ../plugin.name}}
<span class="dep badge">
<a class="dep badge" href="{{website}}" target="_blank">
{{title}}
</span>
</a>
{{/eachDependency}}
</div>
{{/hasDependencies}}
@@ -1,4 +1,4 @@
<div class="modal-header">
<div class="modal-header closeable">
<h4 class="modal-title">{{translations.installWizard_welcomePanel_title}}</h4>
</div>
<div class="modal-body">
@@ -432,6 +432,10 @@
.badge {
padding: 4px 8px;
margin: 5px 3px 0 0;

&:hover, &:active, &:focus {
color: #fff;
}
}
}

0 comments on commit e612f41

Please sign in to comment.
You can’t perform that action at this time.