Skip to content
Permalink
Browse files
Merge branch 'master' into extensionlist-listener
* master: (61 commits)
  [JENKINS-28384] Noting merge of #1700.
  update changelog: PR 1682 -> issue 28233, fix markup issue
  Remove duplicated 1.613 section from changelog
  [FIXED JENKINS-28384] NPE when Node.toComputer → null.
  Refactor fingerprint classes: Javadoc and annotations
  fixup ce747f9
  Refactor ArgumentListBuilder#toWindowsCommand
  Improve ArgumentListBuilder#toWindowsCommand test coverage
  Forgotten @test annotation
  updated changelog for release
  updated changelog for release
  [maven-release-plugin] prepare release jenkins-1.613
  [maven-release-plugin] prepare for next development iteration
  Report launcher exited before establishing the channel
  Remove erroneous '+ ' from log message.
  Increase visibility of Java 7 requirement
  Expose SlaveComputer#getLogDir() explicitly
  [FIXED JENKINS-28227] Switch to Enblish locale in RunTest#getDurationString to test messages.
  Noting #1591
  Noting #1682
  ...
  • Loading branch information
tfennelly committed May 15, 2015
2 parents 30ece5f + 98a6c6f commit 2c6bc734b741ab18631973ecd9722322b22616ca
Showing with 1,327 additions and 145 deletions.
  1. +3 −0 CONTRIBUTING.md
  2. +1 −1 README.md
  3. +41 −4 changelog.html
  4. +1 −1 cli/pom.xml
  5. +2 −2 core/pom.xml
  6. +18 −3 core/src/main/java/hudson/model/AbstractBuild.java
  7. +14 −3 core/src/main/java/hudson/model/Computer.java
  8. +16 −4 core/src/main/java/hudson/model/Descriptor.java
  9. +48 −26 core/src/main/java/hudson/model/Fingerprint.java
  10. +10 −7 core/src/main/java/hudson/model/FingerprintMap.java
  11. +9 −4 core/src/main/java/hudson/model/LoadStatistics.java
  12. +3 −0 core/src/main/java/hudson/model/Run.java
  13. +13 −9 core/src/main/java/hudson/slaves/CommandLauncher.java
  14. +25 −2 core/src/main/java/hudson/slaves/OfflineCause.java
  15. +6 −0 core/src/main/java/hudson/slaves/SlaveComputer.java
  16. +12 −4 core/src/main/java/hudson/tasks/Maven.java
  17. +3 −4 core/src/main/java/hudson/tools/DownloadFromUrlInstaller.java
  18. +19 −20 core/src/main/java/hudson/util/ConsistentHash.java
  19. +18 −11 core/src/main/java/hudson/util/KeyedDataStorage.java
  20. +27 −4 core/src/main/java/hudson/util/MaskingClassLoader.java
  21. +7 −4 core/src/main/java/jenkins/model/FingerprintFacet.java
  22. +1 −5 core/src/main/java/jenkins/mvn/GlobalSettingsProvider.java
  23. +111 −0 core/src/main/java/jenkins/security/RSAConfidentialKey.java
  24. +63 −0 core/src/main/java/jenkins/security/RSADigitalSignatureConfidentialKey.java
  25. +1 −1 core/src/main/java/jenkins/slaves/JnlpSlaveAgentProtocol.java
  26. +9 −2 core/src/main/resources/hudson/slaves/OfflineCause/cause.jelly
  27. +2 −2 core/src/main/resources/hudson/slaves/SlaveComputer/slave-agent.jnlp.jelly
  28. +1 −1 core/src/main/resources/lib/form/class-entry.jelly
  29. +1 −1 core/src/main/resources/lib/form/hetero-list/hetero-list.js
  30. +48 −0 core/src/test/groovy/jenkins/security/RSAConfidentialKeyTest.groovy
  31. +55 −0 core/src/test/groovy/jenkins/security/RSADigitalSignatureConfidentialKeyTest.groovy
  32. +41 −0 core/src/test/java/hudson/model/RunTest.java
  33. +47 −0 core/src/test/java/hudson/util/ConsistentHashTest.java
  34. +4 −4 plugins/pom.xml
  35. +5 −4 pom.xml
  36. +1 −1 test/pom.xml
  37. +20 −4 test/src/test/java/hudson/ClassicPluginStrategyTest.java
  38. +55 −0 test/src/test/java/hudson/model/ComputerTest.java
  39. +93 −0 test/src/test/java/hudson/model/DescriptorTest.java
  40. +108 −0 test/src/test/java/hudson/model/FreestyleJobPublisherTest.java
  41. +2 −2 test/src/test/java/hudson/model/NodeTest.java
  42. +35 −0 test/src/test/java/hudson/model/utils/AbortExceptionPublisher.java
  43. +35 −0 test/src/test/java/hudson/model/utils/IOExceptionPublisher.java
  44. +47 −0 test/src/test/java/hudson/model/utils/ResultWriterPublisher.java
  45. +42 −0 test/src/test/java/hudson/model/utils/TrueFalsePublisher.java
  46. +88 −0 test/src/test/java/hudson/slaves/CommandLauncherTest.java
  47. +1 −1 test/src/test/java/hudson/tasks/MavenTest.java
  48. +49 −1 test/src/test/java/hudson/util/ArgumentListBuilder2Test.java
  49. +40 −0 test/src/test/java/hudson/util/EchoCommand.java
  50. BIN test/src/test/resources/hudson/ClassicPluginStrategyTest/testMaskResourceClassLoader.zip
  51. +7 −0 test/src/test/resources/hudson/model/DescriptorTest/B1/config.jelly
  52. +7 −0 test/src/test/resources/hudson/model/DescriptorTest/B2/config.jelly
  53. +3 −0 test/src/test/resources/hudson/model/DescriptorTest/D1/config.jelly
  54. +3 −0 test/src/test/resources/hudson/model/DescriptorTest/D2/config.jelly
  55. +3 −0 test/src/test/resources/hudson/model/DescriptorTest/D3/config.jelly
  56. +3 −3 war/pom.xml
@@ -0,0 +1,3 @@
# Contributing to Jenkins
For information on contributing to Jenkins, check out the https://wiki.jenkins-ci.org/display/JENKINS/contributing and https://wiki.jenkins-ci.org/display/JENKINS/Extend+Jenkins wiki pages over at the official https://wiki.jenkins-ci.org . They will help you get started with contributing to Jenkins.

@@ -10,7 +10,7 @@ Non-source downloads such as WAR files and several Linux packages can be found o
Our latest and greatest source of Jenkins CI can be found on [GitHub]. Fork us!

# Contributing to Jenkins
For information on contributing to Jenkins, check out the [Contributing] and [Extend Jenkins] wiki pages over at the official [wiki]. They will help you get started with contributing to Jenkins.
Follow [contributing](CONTRIBUTING.md) file.

# News and Website
All information about Jenkins CI can be found on our [website]. Follow us on Twitter [@jenkinsci].
@@ -39,11 +39,11 @@
Help other Jenkins users by letting the community know which releases you've used,
and whether they had any significant issues. <br>
Legend: <br>
<img src="http://ci.jenkins-ci.org/images/16x16/health-80plus.gif" width="16" height="16"
<img src="//ci.jenkins-ci.org/images/16x16/health-80plus.gif" width="16" height="16"
alt="Sunny"> = I use it on my production site without major issues. <br>
<img src="http://ci.jenkins-ci.org/images/16x16/health-40to59.gif" width="16" height="16"
<img src="//ci.jenkins-ci.org/images/16x16/health-40to59.gif" width="16" height="16"
alt="Cloudy"> = I don't recommend it. <br>
<img src="http://ci.jenkins-ci.org/images/16x16/health-00to19.gif" width="16" height="16"
<img src="//ci.jenkins-ci.org/images/16x16/health-00to19.gif" width="16" height="16"
alt="Lightning"> = I tried it but rolled back to a previous version. <br>
View ratings below, and click one of the icons next to your version to provide your input.
</div>
@@ -55,6 +55,44 @@
<!-- Record your changes in the trunk here. -->
<div id="trunk" style="display:none"><!--=TRUNK-BEGIN=-->
<ul class=image>
<li class=bug>
<code>NullPointerException</code> computing load statistics under some conditions.
(<a href="https://issues.jenkins-ci.org/browse/JENKINS-28384">issue 28384</a>)
<li class=bug>
Plugins using class loader masking did not work properly over the slave channel.
(<a href="https://issues.jenkins-ci.org/browse/JENKINS-27289">issue 27289</a>)
</ul>
</div><!--=TRUNK-END=-->
<h3><a name=v1.613>What's new in 1.613</a> (2015/05/10)</h3>
<ul class=image>
<li class=bug>
Update bundled LDAP plugin in order to restore missing help files
(<a href="https://issues.jenkins-ci.org/browse/JENKINS-28233">issue 28233</a>)
<li class=bug>
hudson.model.Run.getLog() throws IndexOutOfBoundsException when called with maxLines=0
(<a href="https://issues.jenkins-ci.org/browse/JENKINS-27441">issue 27441</a>)
</ul>
<h3><a name=v1.612>What's new in 1.612</a> (2015/05/03)</h3>
<ul class=image>
<li class=rfe>
<strong>Jenkins now requires Java 7</strong>.
(<a href="http://jenkins-ci.org/content/good-bye-java6">announcement</a>,
<a href="https://issues.jenkins-ci.org/browse/JENKINS-28120">issue 28120</a>)
<li class=bug>
Handle AbortException publisher status in the same way as deprecated false boolean status
(<a href="https://issues.jenkins-ci.org/browse/JENKINS-26964">issue 26964</a>)
<li class=bug>
Ensures GlobalSettingsProvider does not swallow fatal exceptions
(<a href="https://issues.jenkins-ci.org/browse/JENKINS-26604">issue 26604</a>)
<li class=rfe>
add datestamp to node-offline message
(<a href="https://issues.jenkins-ci.org/browse/JENKINS-23917">issue 23917</a>)
<li class=rfe>
Larger minimum popup menu height.
(<a href="https://issues.jenkins-ci.org/browse/JENKINS-27067">issue 27067</a>)
<li class=bug>
<code>Descriptor.getId</code> fix in 1.610 introduced regressions affecting at least the Performance and NodeJS plugins.
(<a href="https://issues.jenkins-ci.org/browse/JENKINS-28093">issue 28093</a> and <a href="https://issues.jenkins-ci.org/browse/JENKINS-28110">issue 28110</a>)
<li class=bug>
Under rare conditions Executor.getProgress() can throw a Division by zero exception.
(<a href="https://issues.jenkins-ci.org/browse/JENKINS-28115">issue 28115</a>)
@@ -63,7 +101,6 @@
configured JVM options.
(<a href="https://issues.jenkins-ci.org/browse/JENKINS-28111">issue 28111</a>)
</ul>
</div><!--=TRUNK-END=-->
<h3><a name=v1.611>What's new in 1.611</a> (2015/04/26)</h3>
<ul class=image>
<li class=bug>
@@ -5,7 +5,7 @@
<parent>
<groupId>org.jenkins-ci.main</groupId>
<artifactId>pom</artifactId>
<version>1.612-SNAPSHOT</version>
<version>1.614-SNAPSHOT</version>
</parent>

<artifactId>cli</artifactId>
@@ -29,7 +29,7 @@ THE SOFTWARE.
<parent>
<groupId>org.jenkins-ci.main</groupId>
<artifactId>pom</artifactId>
<version>1.612-SNAPSHOT</version>
<version>1.614-SNAPSHOT</version>
</parent>

<artifactId>jenkins-core</artifactId>
@@ -749,7 +749,7 @@ THE SOFTWARE.
<configuration>
<forkCount>0.5C</forkCount>
<reuseForks>true</reuseForks>
<argLine>-XX:MaxPermSize=128m</argLine>
<argLine>-XX:MaxPermSize=128m -noverify</argLine> <!-- some versions of JDK7/8 causes VerifyError during mock tests: http://code.google.com/p/powermock/issues/detail?id=504 -->
</configuration>
</plugin>
<plugin><!-- set main class -->
@@ -715,6 +715,8 @@ protected final void performAllBuildStep(BuildListener listener, Iterable<? exte
*
* @param phase
* true for the post build processing, and false for the final "run after finished" execution.
*
* @return false if any build step failed
*/
protected final boolean performAllBuildSteps(BuildListener listener, Iterable<? extends BuildStep> buildSteps, boolean phase) throws InterruptedException, IOException {
boolean r = true;
@@ -724,20 +726,33 @@ protected final boolean performAllBuildSteps(BuildListener listener, Iterable<?
if (!perform(bs,listener)) {
LOGGER.log(Level.FINE, "{0} : {1} failed", new Object[] {AbstractBuild.this, bs});
r = false;
if (phase) {
setResult(Result.FAILURE);
}
}
} catch (Exception e) {
reportError(bs, e, listener, phase);
r = false;
} catch (LinkageError e) {
reportError(bs, e, listener, phase);
r = false;
}
}
return r;
}

private void reportError(BuildStep bs, Throwable e, BuildListener listener, boolean phase) {
String msg = "Publisher " + bs.getClass().getName() + " aborted due to exception";
e.printStackTrace(listener.error(msg));
LOGGER.log(WARNING, msg, e);
final String publisher = ((Publisher) bs).getDescriptor().getDisplayName();

if (e instanceof AbortException) {
LOGGER.log(Level.FINE, "{0} : {1} failed", new Object[] {AbstractBuild.this, publisher});
listener.error("Publisher '" + publisher + "' failed: " + e.getMessage());
} else {
String msg = "Publisher '" + publisher + "' aborted due to exception: ";
e.printStackTrace(listener.error(msg));
LOGGER.log(WARNING, msg, e);
}

if (phase) {
setResult(Result.FAILURE);
}
@@ -271,14 +271,25 @@ public void addAction(Action a) {
/**
* This is where the log from the remote agent goes.
* The method also creates a log directory if required.
* @see #relocateOldLogs()
* @see #getLogDir(), #relocateOldLogs()
*/
public File getLogFile() {
public @Nonnull File getLogFile() {
return new File(getLogDir(),"slave.log");
}

/**
* Directory where rotated slave logs are stored.
*
* The method also creates a log directory if required.
*
* @since 1.613
*/
protected @Nonnull File getLogDir() {
File dir = new File(Jenkins.getInstance().getRootDir(),"logs/slaves/"+nodeName);
if (!dir.exists() && !dir.mkdirs()) {
LOGGER.severe("Failed to create slave log directory " + dir.getAbsolutePath());
}
return new File(dir,"slave.log");
return dir;
}

/**
@@ -918,17 +918,29 @@ private URL getStaticHelpUrl(Klass<?> c, String suffix) {
// Descriptors, so we prefer 'kind' if it's present.
String kind = jo.optString("kind", null);
if (kind != null) {
// Only applies when Descriptor.getId is overridden.
// Note that kind is only supported here,
// *not* inside the StaplerRequest.bindJSON which is normally called by newInstance
// (since Descriptor.newInstance is not itself available to Stapler).
// If you merely override getId for some reason, but use @DataBoundConstructor on your Describable,
// there is no problem; but you can only rely on newInstance being called at top level.
d = findById(descriptors, kind);
}
if (d == null) {
kind = jo.getString("$class");
d = findByDescribableClassName(descriptors, kind);
if (d == null) d = findByClassName(descriptors, kind);
kind = jo.optString("$class");
if (kind != null) { // else we will fall through to the warning
// This is the normal case.
d = findByDescribableClassName(descriptors, kind);
if (d == null) {
// Deprecated system where stapler-class was the Descriptor class name (rather than Describable class name).
d = findByClassName(descriptors, kind);
}
}
}
if (d != null) {
items.add(d.newInstance(req, jo));
} else {
LOGGER.warning("Received unexpected formData for descriptor " + kind);
LOGGER.log(Level.WARNING, "Received unexpected form data element: {0}", jo);
}
}
}

0 comments on commit 2c6bc73

Please sign in to comment.