diff --git a/core/src/main/java/hudson/util/HttpResponses.java b/core/src/main/java/hudson/util/HttpResponses.java new file mode 100644 index 0000000000000000000000000000000000000000..16755adc4c981e40e711407aca06cb778dc77fe6 --- /dev/null +++ b/core/src/main/java/hudson/util/HttpResponses.java @@ -0,0 +1,43 @@ +/* + * The MIT License + * + * Copyright (c) 2011, CloudBees, Inc. + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ +package hudson.util; + +import org.kohsuke.stapler.HttpResponse; + +import java.io.File; +import java.io.IOException; + +/** + * Various {@link HttpResponse} implementations. + * + *
+ * This class extends from Stapler so that we can move implementations from here to Stapler periodically.
+ *
+ * @author Kohsuke Kawaguchi
+ */
+public class HttpResponses extends org.kohsuke.stapler.HttpResponses {
+ public static HttpResponse staticResource(File f) throws IOException {
+ return staticResource(f.toURI().toURL());
+ }
+}
diff --git a/maven-plugin/src/main/java/hudson/maven/MavenBuild.java b/maven-plugin/src/main/java/hudson/maven/MavenBuild.java
index 1b9eb438934c1bfff0de17540727e557eb64bb5a..4ea982a79f8c68d96053d9c6b5f41292c3571837 100644
--- a/maven-plugin/src/main/java/hudson/maven/MavenBuild.java
+++ b/maven-plugin/src/main/java/hudson/maven/MavenBuild.java
@@ -25,7 +25,6 @@ package hudson.maven;
import hudson.FilePath;
import hudson.EnvVars;
-import hudson.maven.reporters.MavenArtifact;
import hudson.maven.reporters.MavenArtifactRecord;
import hudson.maven.reporters.SurefireArchiver;
import hudson.slaves.WorkspaceList;
@@ -184,6 +183,14 @@ public class MavenBuild extends AbstractMavenBuild
+ Information about Maven artifacts produced by this are exposed
+ in a machine readable form. This allows programmatic retrieval of the artifacts.
+ Artifact Information
+