You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jclouds.apache.org by an...@apache.org on 2013/11/06 23:39:10 UTC
[1/2] git commit: JCLOUDS-362 inferring project-id from identity when
there is a hyphen
Updated Branches:
refs/heads/remove-sonatype-repo 76bb6fea8 -> 665d03812 (forced update)
JCLOUDS-362 inferring project-id from identity when there is a hyphen
Project: http://git-wip-us.apache.org/repos/asf/jclouds-labs-google/repo
Commit: http://git-wip-us.apache.org/repos/asf/jclouds-labs-google/commit/cec667a8
Tree: http://git-wip-us.apache.org/repos/asf/jclouds-labs-google/tree/cec667a8
Diff: http://git-wip-us.apache.org/repos/asf/jclouds-labs-google/diff/cec667a8
Branch: refs/heads/remove-sonatype-repo
Commit: cec667a8aed54ebd0c976758181ca7e9899008cf
Parents: 5ec13c9
Author: Alex Heneveld <al...@cloudsoftcorp.com>
Authored: Sat Nov 2 13:33:25 2013 -0700
Committer: Andrew Phillips <an...@apache.org>
Committed: Wed Nov 6 17:34:55 2013 -0500
----------------------------------------------------------------------
.../config/GoogleComputeEngineHttpApiModule.java | 18 ++++++++++++++----
1 file changed, 14 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/jclouds-labs-google/blob/cec667a8/google-compute-engine/src/main/java/org/jclouds/googlecomputeengine/config/GoogleComputeEngineHttpApiModule.java
----------------------------------------------------------------------
diff --git a/google-compute-engine/src/main/java/org/jclouds/googlecomputeengine/config/GoogleComputeEngineHttpApiModule.java b/google-compute-engine/src/main/java/org/jclouds/googlecomputeengine/config/GoogleComputeEngineHttpApiModule.java
index 31f3786..bbf10f0 100644
--- a/google-compute-engine/src/main/java/org/jclouds/googlecomputeengine/config/GoogleComputeEngineHttpApiModule.java
+++ b/google-compute-engine/src/main/java/org/jclouds/googlecomputeengine/config/GoogleComputeEngineHttpApiModule.java
@@ -101,10 +101,20 @@ public class GoogleComputeEngineHttpApiModule extends HttpApiModule<GoogleComput
return MemoizedRetryOnTimeOutButNotOnAuthorizationExceptionSupplier.create(authException,
compose(new Function<Credentials, String>() {
public String apply(Credentials in) {
- checkState(in.identity.indexOf("@") != 1,
- "identity should be in project_id@developer.gserviceaccount.com format");
-
- Project project = api.getProjectApi().get(Iterables.get(Splitter.on("@").split(in.identity), 0));
+ // ID should be of the form project_id@developer.gserviceaccount.com
+ // OR (increasingly often) project_id-extended_uid@developer.gserviceaccount.com
+ // where project_id is the NUMBER;
+ // HERE we also accept simply "project" as the identity, if no "@" is present;
+ // this is used in tests, but not sure if it is valid in the wild.
+ String projectName = in.identity;
+ if (projectName.indexOf("@") != -1) {
+ projectName = Iterables.get(Splitter.on("@").split(projectName), 0);
+ if (projectName.indexOf("-") != -1) {
+ // if ID is of the form project_id-extended_uid@developer.gserviceaccount.com
+ projectName = Iterables.get(Splitter.on("-").split(projectName), 0);
+ }
+ }
+ Project project = api.getProjectApi().get(projectName);
return project.getName();
}
}, creds), seconds, TimeUnit.SECONDS);
[2/2] git commit: Removing Sonatype OSS snapshot repo
Posted by an...@apache.org.
Removing Sonatype OSS snapshot repo
Project: http://git-wip-us.apache.org/repos/asf/jclouds-labs-google/repo
Commit: http://git-wip-us.apache.org/repos/asf/jclouds-labs-google/commit/665d0381
Tree: http://git-wip-us.apache.org/repos/asf/jclouds-labs-google/tree/665d0381
Diff: http://git-wip-us.apache.org/repos/asf/jclouds-labs-google/diff/665d0381
Branch: refs/heads/remove-sonatype-repo
Commit: 665d03812fc5737f9d56b46f50749ffb931cb8f0
Parents: cec667a
Author: Andrew Phillips <de...@yahoo.co.uk>
Authored: Tue Nov 5 14:10:31 2013 -0500
Committer: Andrew Phillips <an...@apache.org>
Committed: Wed Nov 6 17:38:46 2013 -0500
----------------------------------------------------------------------
pom.xml | 10 ----------
1 file changed, 10 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/jclouds-labs-google/blob/665d0381/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index 7d3b4ae..ff04cf3 100644
--- a/pom.xml
+++ b/pom.xml
@@ -51,16 +51,6 @@
<enabled>true</enabled>
</snapshots>
</repository>
- <repository>
- <id>sonatype-nexus-snapshots</id>
- <url>https://oss.sonatype.org/content/repositories/snapshots</url>
- <releases>
- <enabled>false</enabled>
- </releases>
- <snapshots>
- <enabled>true</enabled>
- </snapshots>
- </repository>
</repositories>
<modules>