Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWinston Prakash2012-10-16 17:58:37 -0400
committerWinston Prakash2012-10-16 17:58:37 -0400
commitcbf196f2f4784505a3f973149ac2e0ab4713da52 (patch)
tree9a4d75c3de5840c26edf2792fa34244ec87e458d
parent0b03758a71d2d4237c0d0c52daa3bc02b8e02923 (diff)
downloadorg.eclipse.hudson.core-cbf196f2f4784505a3f973149ac2e0ab4713da52.tar.gz
org.eclipse.hudson.core-cbf196f2f4784505a3f973149ac2e0ab4713da52.tar.xz
org.eclipse.hudson.core-cbf196f2f4784505a3f973149ac2e0ab4713da52.zip
Make sure all update center downloads points to update-center3 in hudson-ci.org
-rw-r--r--hudson-core/src/main/java/hudson/model/DownloadService.java4
-rw-r--r--hudson-core/src/main/java/hudson/model/UpdateCenter.java4
-rw-r--r--hudson-core/src/test/java/hudson/model/UpdateCenterTest.java2
3 files changed, 5 insertions, 5 deletions
diff --git a/hudson-core/src/main/java/hudson/model/DownloadService.java b/hudson-core/src/main/java/hudson/model/DownloadService.java
index 2f2a5bed..e29c5a9c 100644
--- a/hudson-core/src/main/java/hudson/model/DownloadService.java
+++ b/hudson-core/src/main/java/hudson/model/DownloadService.java
@@ -119,7 +119,7 @@ public class DownloadService extends PageDecorator {
*
* @param url URL relative to {@link UpdateCenter#getUrl()}. So if this
* string is "foo.json", the ultimate URL will be something like
- * "https://hudson.java.net/foo.json"
+ * "https://hudson-ci.org/update-center3/foo.json"
*
* For security and privacy reasons, we don't allow the retrieval from
* random locations.
@@ -153,7 +153,7 @@ public class DownloadService extends PageDecorator {
* URL to download.
*/
public String getUrl() {
- return Hudson.getInstance().getUpdateCenter().getDefaultBaseUrl() + "updates/" + url;
+ return Hudson.getInstance().getUpdateCenter().getDefaultBaseUrl() + url;
}
/**
diff --git a/hudson-core/src/main/java/hudson/model/UpdateCenter.java b/hudson-core/src/main/java/hudson/model/UpdateCenter.java
index efdd1243..8e3618d8 100644
--- a/hudson-core/src/main/java/hudson/model/UpdateCenter.java
+++ b/hudson-core/src/main/java/hudson/model/UpdateCenter.java
@@ -471,7 +471,7 @@ public class UpdateCenter extends AbstractModelObject implements Saveable {
@SuppressWarnings({"UnusedDeclaration"})
public static class UpdateCenterConfiguration implements ExtensionPoint {
- private final String updateServer = System.getProperty("updateServer", "http://hudson-ci.org/");
+ private final String updateServer = System.getProperty("updateServer", "http://hudson-ci.org/update-center3/");
/**
* Creates default update center configuration - uses settings for
@@ -647,7 +647,7 @@ public class UpdateCenter extends AbstractModelObject implements Saveable {
* @return Absolute URL that ends with '/'.
*/
public String getUpdateCenterUrl() {
- return updateServer + "update-center3/update-center.json";
+ return updateServer + "update-center.json";
}
/**
diff --git a/hudson-core/src/test/java/hudson/model/UpdateCenterTest.java b/hudson-core/src/test/java/hudson/model/UpdateCenterTest.java
index 27d57744..0b98b253 100644
--- a/hudson-core/src/test/java/hudson/model/UpdateCenterTest.java
+++ b/hudson-core/src/test/java/hudson/model/UpdateCenterTest.java
@@ -51,7 +51,7 @@ public class UpdateCenterTest {
return;
}
- URL url = new URL("http://hudson-ci.org/update-center.json?version=build");
+ URL url = new URL("http://hudson-ci.org/update-center3/update-center.json?version=build");
String jsonp = IOUtils.toString(url.openStream());
String json = jsonp.substring(jsonp.indexOf('(')+1,jsonp.lastIndexOf(')'));

Back to the top