You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jclouds.apache.org by ad...@apache.org on 2014/10/24 06:10:38 UTC

[5/8] JCLOUDS-757 drop fgcp provider.

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/VSystem.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/VSystem.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/VSystem.java
deleted file mode 100644
index c313a55..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/VSystem.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.domain;
-
-import javax.xml.bind.annotation.XmlElement;
-
-import com.google.common.base.MoreObjects;
-import com.google.common.base.Objects;
-
-/**
- * Represents a virtual system.
- */
-public class VSystem {
-   @XmlElement(name = "vsysId")
-   protected String id;
-   @XmlElement(name = "vsysName")
-   protected String name;
-   protected String creator;
-   @XmlElement(name = "baseDescriptor")
-   protected String template;
-   protected String description;
-
-   public String getId() {
-      return id;
-   }
-
-   public String getName() {
-      return name;
-   }
-
-   public String getCreator() {
-      return creator;
-   }
-
-   public String getTemplate() {
-      return template;
-   }
-
-   public String getDescription() {
-      return description;
-   }
-
-   @Override
-   public int hashCode() {
-      return Objects.hashCode(id);
-   }
-
-   @Override
-   public boolean equals(Object obj) {
-      if (this == obj)
-         return true;
-      if (obj == null)
-         return false;
-      if (getClass() != obj.getClass())
-         return false;
-      VSystem that = VSystem.class.cast(obj);
-      return Objects.equal(this.id, that.id);
-   }
-
-   @Override
-   public String toString() {
-      return MoreObjects.toStringHelper(this).omitNullValues().add("id", id)
-            .add("name", name).add("creator", creator)
-            .add("template", template).add("description", description)
-            .toString();
-   }
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/VSystemDescriptor.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/VSystemDescriptor.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/VSystemDescriptor.java
deleted file mode 100644
index 5edb5fd..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/VSystemDescriptor.java
+++ /dev/null
@@ -1,100 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.domain;
-
-import java.util.Set;
-
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlElementWrapper;
-import javax.xml.bind.annotation.XmlRootElement;
-
-import com.google.common.collect.ImmutableSet;
-import com.google.common.collect.Sets;
-
-/**
- * Describes a virtual system template.
- */
-@XmlRootElement(name = "vsysdescriptor")
-public class VSystemDescriptor {
-   @XmlElement(name = "vsysdescriptorId")
-   private String id;
-
-   @XmlElement(name = "vsysdescriptorName")
-   private String name;
-
-   private String creatorName;
-
-   private String registrant;
-
-   private String description;
-
-   private String keyword;
-
-   @XmlElementWrapper(name = "vservers")
-   @XmlElement(name = "vserver")
-   private Set<VServerWithDetails> servers = Sets.newLinkedHashSet();
-
-   /**
-    * @return the id
-    */
-   public String getId() {
-      return id;
-   }
-
-   /**
-    * @return the name
-    */
-   public String getName() {
-      return name;
-   }
-
-   /**
-    * @return the creatorName
-    */
-   public String getCreatorName() {
-      return creatorName;
-   }
-
-   /**
-    * @return the registrant
-    */
-   public String getRegistrant() {
-      return registrant;
-   }
-
-   /**
-    * @return the description
-    */
-   public String getDescription() {
-      return description;
-   }
-
-   /**
-    * @return the keyword
-    */
-   public String getKeyword() {
-      return keyword;
-   }
-
-   /**
-    * @return the servers
-    */
-   public Set<VServerWithDetails> getServers() {
-      return servers == null ? ImmutableSet.<VServerWithDetails> of()
-            : ImmutableSet.copyOf(servers);
-   }
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/VSystemStatus.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/VSystemStatus.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/VSystemStatus.java
deleted file mode 100644
index bbb648f..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/VSystemStatus.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.domain;
-
-import static com.google.common.base.Preconditions.checkNotNull;
-
-import javax.xml.bind.annotation.XmlRootElement;
-
-import com.google.common.base.CaseFormat;
-
-/**
- * Possible statuses of a virtual system.
- */
-@XmlRootElement(name = "vsysStatus")
-public enum VSystemStatus {
-   NORMAL, RECONFIG_ING, DEPLOYING, ERROR, UNRECOGNIZED;
-
-   public String value() {
-      return CaseFormat.UPPER_UNDERSCORE.to(CaseFormat.UPPER_CAMEL, name());
-   }
-
-   @Override
-   public String toString() {
-      return value();
-   }
-
-   public static VSystemStatus fromValue(String status) {
-      try {
-         return valueOf(CaseFormat.UPPER_CAMEL
-               .to(CaseFormat.UPPER_UNDERSCORE,
-                     checkNotNull(status, "status")));
-      } catch (IllegalArgumentException e) {
-         return UNRECOGNIZED;
-      }
-   }
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/VSystemWithDetails.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/VSystemWithDetails.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/VSystemWithDetails.java
deleted file mode 100644
index 0efb873..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/VSystemWithDetails.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.domain;
-
-import java.util.Set;
-
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlElementWrapper;
-import javax.xml.bind.annotation.XmlRootElement;
-
-import com.google.common.base.MoreObjects;
-import com.google.common.collect.ImmutableSet;
-import com.google.common.collect.Sets;
-
-/**
- * Represents a virtual system with servers, additional storage, public IP
- * addresses and networks.
- */
-@XmlRootElement(name = "vsys")
-public class VSystemWithDetails extends VSystem {
-   @XmlElementWrapper(name = "vservers")
-   @XmlElement(name = "vserver")
-   private Set<VServerWithVNICs> servers = Sets.newLinkedHashSet();
-   @XmlElementWrapper(name = "vdisks")
-   @XmlElement(name = "vdisk")
-   private Set<VDisk> disks = Sets.newLinkedHashSet();
-   @XmlElementWrapper(name = "publicips")
-   @XmlElement(name = "publicip")
-   private Set<PublicIP> publicips = Sets.newLinkedHashSet();
-   @XmlElementWrapper(name = "vnets")
-   @XmlElement(name = "vnet")
-   private Set<VNet> networks = Sets.newLinkedHashSet();
-
-   public Set<VServerWithVNICs> getServers() {
-      return servers == null ? ImmutableSet.<VServerWithVNICs> of() : ImmutableSet
-            .copyOf(servers);
-   }
-
-   public Set<VDisk> getDisks() {
-      return disks == null ? ImmutableSet.<VDisk> of() : ImmutableSet
-            .copyOf(disks);
-   }
-
-   public Set<PublicIP> getPublicips() {
-      return publicips == null ? ImmutableSet.<PublicIP> of() : ImmutableSet
-            .copyOf(publicips);
-   }
-
-   public Set<VNet> getNetworks() {
-      return networks == null ? ImmutableSet.<VNet> of() : ImmutableSet
-            .copyOf(networks);
-   }
-
-   @Override
-   public String toString() {
-      return MoreObjects.toStringHelper(this).omitNullValues().add("id", id)
-            .add("name", name).add("creator", creator)
-            .add("template", template).add("description", description)
-            .add("disks", disks).add("networks", networks)
-            .add("publicips", publicips).add("servers", servers).toString();
-   }
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/package-info.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/package-info.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/package-info.java
deleted file mode 100644
index c49a5c7..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/domain/package-info.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-@XmlSchema(namespace = "http://apioviss.jp.fujitsu.com", elementFormDefault = javax.xml.bind.annotation.XmlNsForm.QUALIFIED)
-@XmlAccessorType(XmlAccessType.FIELD)
-package org.jclouds.fujitsu.fgcp.domain;
-
-import javax.xml.bind.annotation.XmlAccessType;
-import javax.xml.bind.annotation.XmlAccessorType;
-import javax.xml.bind.annotation.XmlSchema;
-

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/filters/RequestAuthenticator.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/filters/RequestAuthenticator.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/filters/RequestAuthenticator.java
deleted file mode 100644
index 4588f08..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/filters/RequestAuthenticator.java
+++ /dev/null
@@ -1,205 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.filters;
-
-import static com.google.common.base.Charsets.UTF_8;
-import static com.google.common.base.Preconditions.checkNotNull;
-import static com.google.common.base.Throwables.propagate;
-import static com.google.common.io.BaseEncoding.base64;
-import static org.jclouds.http.utils.Queries.queryParser;
-
-import java.security.InvalidKeyException;
-import java.security.NoSuchAlgorithmException;
-import java.security.PrivateKey;
-import java.security.Signature;
-import java.security.SignatureException;
-import java.util.Calendar;
-import java.util.Locale;
-import java.util.concurrent.ExecutionException;
-
-import javax.annotation.Resource;
-import javax.inject.Inject;
-import javax.inject.Named;
-import javax.inject.Provider;
-import javax.inject.Singleton;
-import javax.ws.rs.HttpMethod;
-import javax.ws.rs.core.MediaType;
-
-import org.jclouds.Constants;
-import org.jclouds.date.TimeStamp;
-import org.jclouds.fujitsu.fgcp.FGCPCredentials;
-import org.jclouds.fujitsu.fgcp.reference.RequestParameters;
-import org.jclouds.http.HttpException;
-import org.jclouds.http.HttpRequest;
-import org.jclouds.http.HttpRequest.Builder;
-import org.jclouds.http.HttpRequestFilter;
-import org.jclouds.http.HttpUtils;
-import org.jclouds.http.internal.SignatureWire;
-import org.jclouds.logging.Logger;
-import org.jclouds.rest.RequestSigner;
-import org.jclouds.rest.annotations.ApiVersion;
-
-import com.google.common.annotations.VisibleForTesting;
-import com.google.common.base.Supplier;
-import com.google.common.cache.CacheBuilder;
-import com.google.common.cache.CacheLoader;
-import com.google.common.cache.LoadingCache;
-import com.google.common.collect.Multimap;
-import com.google.common.net.HttpHeaders;
-
-/**
- * Generates and signs the access key id and adds the mandatory http header and
- * request parameters to the request.
- */
-@Singleton
-public class RequestAuthenticator implements HttpRequestFilter, RequestSigner {
-
-   @Resource
-   @Named(Constants.LOGGER_SIGNATURE)
-   private Logger signatureLog = Logger.NULL;
-
-   private final Supplier<FGCPCredentials> creds;
-   private final LoadingCache<FGCPCredentials, Signature> signerCache;
-   private final Provider<Calendar> calendarProvider;
-   private final HttpUtils utils;
-   private final String apiVersion;
-
-   static final String SIGNATURE_VERSION = "1.0";
-   static final String SIGNATURE_METHOD = "SHA1withRSA";
-
-   @Inject
-   public RequestAuthenticator(Supplier<FGCPCredentials> creds,
-         SignatureForCredentials loader, @TimeStamp Provider<Calendar> calendarProvider, HttpUtils utils,
-         SignatureWire signatureWire, @ApiVersion String apiVersion) {
-      this.calendarProvider = checkNotNull(calendarProvider);
-      this.creds = checkNotNull(creds, "creds");
-      // throw out the signature related to old keys
-      this.signerCache = CacheBuilder.newBuilder().maximumSize(2).build(checkNotNull(loader, "loader"));
-      this.utils = checkNotNull(utils, "utils");
-      this.apiVersion = checkNotNull(apiVersion, "apiVersion");
-   }
-
-   /**
-    * It is relatively expensive to create a new signing key. Cache the
-    * relationship between current credentials so that the signer is only
-    * recalculated once.
-    */
-   @VisibleForTesting
-   static class SignatureForCredentials extends CacheLoader<FGCPCredentials, Signature> {
-
-      @Override
-      public Signature load(FGCPCredentials creds) {
-         PrivateKey privateKey = checkNotNull(creds.privateKey, "fgcpcredential's privateKey is null");
-         try {
-            Signature signer = Signature.getInstance(RequestAuthenticator.SIGNATURE_METHOD);
-            signer.initSign(privateKey);
-            return signer;
-         } catch (NoSuchAlgorithmException e) {
-            throw propagate(e);
-         } catch (InvalidKeyException e) {
-            throw propagate(e);
-         }
-      }
-   }
-
-   public HttpRequest filter(HttpRequest request) throws HttpException {
-      checkNotNull(request, "request must be present");
-      utils.logRequest(signatureLog, request, ">>");
-
-      // create accesskeyid
-      String accessKeyId = createStringToSign(request);
-      String signature = sign(accessKeyId);
-
-      // only "en" and "ja" are allowed
-      String lang = Locale.JAPANESE.getLanguage().equals(Locale.getDefault().getLanguage()) ? Locale.JAPANESE
-            .getLanguage() : Locale.ENGLISH.getLanguage();
-
-      if (HttpMethod.GET.equals(request.getMethod())) {
-         request = addQueryParamsToRequest(request, accessKeyId, signature, lang);
-      } else {
-
-         String payload = request.getPayload().getRawContent().toString();
-         payload = createXmlElementWithValue(payload, RequestParameters.VERSION, apiVersion);
-         payload = createXmlElementWithValue(payload, RequestParameters.LOCALE, lang);
-         payload = createXmlElementWithValue(payload, RequestParameters.ACCESS_KEY_ID, accessKeyId);
-         payload = createXmlElementWithValue(payload, RequestParameters.SIGNATURE, signature);
-
-         // ensure there are no other query params left
-         request.setPayload(payload);
-         request.getPayload().getContentMetadata().setContentType(MediaType.TEXT_XML);
-      }
-
-      // may need to do this elsewhere (see ConvertToGaeRequest)
-      HttpRequest filteredRequest = request.toBuilder().replaceHeader(HttpHeaders.USER_AGENT, "OViSS-API-CLIENT")
-            .build();
-
-      utils.logRequest(signatureLog, filteredRequest, ">>->");
-      return filteredRequest;
-   }
-
-   @VisibleForTesting
-   HttpRequest addQueryParamsToRequest(HttpRequest request, String accessKeyId, String signature, String lang) {
-      Multimap<String, String> decodedParams = queryParser().apply(request.getEndpoint().getRawQuery());
-      Builder<?> builder = request.toBuilder().endpoint(request.getEndpoint()).method(request.getMethod());
-      if (!decodedParams.containsKey("Version")) {
-         builder.addQueryParam(RequestParameters.VERSION, apiVersion);
-      }
-      builder.addQueryParam(RequestParameters.LOCALE, lang).addQueryParam(RequestParameters.ACCESS_KEY_ID, accessKeyId)
-            .addQueryParam(RequestParameters.SIGNATURE, signature);
-
-      return builder.build();
-   }
-
-   String createXmlElementWithValue(String payload, String tag, String value) {
-      String startTag = String.format("<%s>", tag);
-      String endTag = String.format("</%s>", tag);
-
-      return payload.replace(startTag + endTag, startTag + value + endTag);
-   }
-
-   public String sign(String stringToSign) {
-      String signed;
-      try {
-         Signature signer = signerCache.get(checkNotNull(creds.get(), "credential supplier returned null"));
-         signer.update(stringToSign.getBytes(UTF_8));
-         signed = base64().withSeparator("\n", 61).encode(signer.sign());
-      } catch (SignatureException e) {
-         throw new HttpException("error signing request", e);
-      } catch (ExecutionException e) {
-         throw new HttpException("couldn't load key for signing request", e);
-      }
-      return signed;
-   }
-
-   @VisibleForTesting
-   String generateAccessKeyId() {
-      Calendar cal = calendarProvider.get();
-      String timezone = cal.getTimeZone().getDisplayName(Locale.ENGLISH);
-      String expires = String.valueOf(cal.getTime().getTime());
-
-      String signatureData = String.format("%s&%s&%s&%s", timezone, expires, SIGNATURE_VERSION, SIGNATURE_METHOD);
-      String accessKeyId = base64().withSeparator("\n", 61).encode(signatureData.getBytes(UTF_8));
-
-      return accessKeyId;
-   }
-
-   @Override
-   public String createStringToSign(HttpRequest input) {
-      return generateAccessKeyId();
-   }
-
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/handlers/FGCPBackoffLimitedRetryHandler.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/handlers/FGCPBackoffLimitedRetryHandler.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/handlers/FGCPBackoffLimitedRetryHandler.java
deleted file mode 100644
index cfd4c34..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/handlers/FGCPBackoffLimitedRetryHandler.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.handlers;
-
-import org.jclouds.http.handlers.BackoffLimitedRetryHandler;
-
-public class FGCPBackoffLimitedRetryHandler extends BackoffLimitedRetryHandler {
-
-   public void imposeBackoffExponentialDelay(long period, int pow, int failureCount, int max, String commandDescription) {
-      imposeBackoffExponentialDelay(period, period * 100l, pow, failureCount, max, commandDescription);
-   }
-
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/handlers/FGCPServerErrorRetryHandler.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/handlers/FGCPServerErrorRetryHandler.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/handlers/FGCPServerErrorRetryHandler.java
deleted file mode 100644
index d2933dd..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/handlers/FGCPServerErrorRetryHandler.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.handlers;
-
-import javax.annotation.Resource;
-import javax.inject.Inject;
-import javax.inject.Named;
-
-import org.jclouds.Constants;
-import org.jclouds.http.HttpCommand;
-import org.jclouds.http.HttpResponse;
-import org.jclouds.http.HttpRetryHandler;
-import org.jclouds.http.HttpUtils;
-import org.jclouds.logging.Logger;
-
-import com.google.inject.Singleton;
-
-/**
- * Defines which requests should be retried.
- */
-@Singleton
-public class FGCPServerErrorRetryHandler implements HttpRetryHandler {
-   private final HttpRetryHandler backoffHandler;
-
-   @Inject
-   @Named(Constants.PROPERTY_MAX_RETRIES)
-   private int retryCountLimit = 10;
-   @Resource
-   protected Logger logger = Logger.NULL;
-
-   @Inject
-   public FGCPServerErrorRetryHandler(FGCPBackoffLimitedRetryHandler backoffHandler) {
-      this.backoffHandler = backoffHandler;
-   }
-
-   @Override
-   public boolean shouldRetryRequest(HttpCommand command, HttpResponse response) {
-      if (command.getFailureCount() > retryCountLimit)
-         return false;
-
-      if (response.getStatusCode() == 500) {
-         byte[] content = HttpUtils.closeClientButKeepContentStream(response);
-         if (content != null) {
-            String message = new String(content);
-
-            if (message.contains("<responseStatus>ILLEGAL_STATE</responseStatus>")
-                  && message.contains("RECONFIG_ING")) {
-               return backoffHandler.shouldRetryRequest(command, response);
-            }
-            if (message.contains("<responseStatus>VALIDATION_ERROR</responseStatus>")
-                  && message.contains("verify error")) {
-               return backoffHandler.shouldRetryRequest(command, response);
-            }
-         }
-      }
-      return false;
-   }
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/handlers/ResponseNotSuccessHandler.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/handlers/ResponseNotSuccessHandler.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/handlers/ResponseNotSuccessHandler.java
deleted file mode 100644
index 69e7a1a..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/handlers/ResponseNotSuccessHandler.java
+++ /dev/null
@@ -1,100 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.handlers;
-
-import static org.jclouds.http.HttpUtils.closeClientButKeepContentStream;
-import static org.jclouds.http.HttpUtils.releasePayload;
-
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-import javax.inject.Singleton;
-
-import org.jclouds.http.HttpCommand;
-import org.jclouds.http.HttpErrorHandler;
-import org.jclouds.http.HttpResponse;
-import org.jclouds.http.HttpResponseException;
-import org.jclouds.rest.AuthorizationException;
-import org.jclouds.rest.ResourceNotFoundException;
-
-import com.google.common.base.Charsets;
-
-/**
- * This will parse the XML payload and set an appropriate exception on the
- * command object.
- */
-@Singleton
-public class ResponseNotSuccessHandler implements HttpErrorHandler {
-   private static final Pattern ERROR_STATUS_PATTERN = Pattern.compile("<responseStatus>(.+)</responseStatus>");
-   private static final Pattern ERROR_MESSAGE_PATTERN = Pattern.compile("<responseMessage>(.+)</responseMessage>");
-   private static final Pattern SYSTEM_RECONFIGURING_PATTERN = Pattern.compile("ILLEGAL_STATE.+RECONFIG_ING.*");
-   private static final Pattern AUTH_PATTERN = Pattern.compile(".*(AuthFailure|User not found in selectData).*");
-   private static final Pattern RESOURCE_NOT_FOUND_PATTERN = Pattern.compile(".*RESOURCE_NOT_FOUND.*");
-   private static final Pattern NOT_IMPLEMENTED_PATTERN = Pattern.compile(".*NOTFOUND: API to the Version.*");
-   private static final Pattern ILLEGAL_STATE_PATTERN = Pattern
-         .compile(".*(NEVER_BOOTED|ALREADY_STARTED|ALREADY_STOPPED|ILLEGAL_STATE).*");
-   private static final Pattern ILLEGAL_ARGUMENT_PATTERN = Pattern
-         .compile(".*(SERVER_NAME_ALREADY_EXISTS|VALIDATION_ERROR).*");
-
-   public void handleError(HttpCommand command, HttpResponse response) {
-      Exception exception = null;
-      try {
-         byte[] data = closeClientButKeepContentStream(response);
-         String message = data != null ? new String(data, Charsets.UTF_8) : null;
-         if (message != null) {
-            Matcher ms = ERROR_STATUS_PATTERN.matcher(message);
-            Matcher mm = ERROR_MESSAGE_PATTERN.matcher(message);
-
-            if (ms.find() && mm.find()) {
-               String status = ms.group(1);
-               String errorMessage = mm.group(1);
-               // revert status code to 200 to match actual server's return status
-               response = response.toBuilder().statusCode(200).build();
-               exception = refineException(new HttpResponseException(command, response, status + ": " + errorMessage));
-            }
-         }
-      } finally {
-         if (exception == null) {
-            exception = new HttpResponseException(command, response);
-         }
-         command.setException(exception);
-         releasePayload(response);
-      }
-   }
-
-   private Exception refineException(HttpResponseException exception) {
-      Exception refinedException = exception;
-      String error = exception.getContent();
-
-      // Create custom exception for error messages we know about
-      if (SYSTEM_RECONFIGURING_PATTERN.matcher(error).matches()) {
-         refinedException = new IllegalStateException(exception);
-      } else if (RESOURCE_NOT_FOUND_PATTERN.matcher(error).matches()) {
-         refinedException = new ResourceNotFoundException(error, exception);
-      } else if (ILLEGAL_STATE_PATTERN.matcher(error).matches()) {
-         refinedException = new IllegalStateException(error, exception);
-      } else if (ILLEGAL_ARGUMENT_PATTERN.matcher(error).matches()) {
-         refinedException = new IllegalArgumentException(error, exception);
-      } else if (AUTH_PATTERN.matcher(error).matches()) {
-         refinedException = new AuthorizationException(error, exception);
-      } else if (NOT_IMPLEMENTED_PATTERN.matcher(error).matches()) {
-         refinedException = new UnsupportedOperationException(error, exception);
-      }
-      return refinedException;
-   }
-
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/http/ChangeReturnCodeTo500IfErrorJavaUrlHttpCommandExecutorService.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/http/ChangeReturnCodeTo500IfErrorJavaUrlHttpCommandExecutorService.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/http/ChangeReturnCodeTo500IfErrorJavaUrlHttpCommandExecutorService.java
deleted file mode 100644
index d120c42..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/http/ChangeReturnCodeTo500IfErrorJavaUrlHttpCommandExecutorService.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.http;
-
-import static org.jclouds.http.HttpUtils.closeClientButKeepContentStream;
-
-import java.io.IOException;
-import java.net.HttpURLConnection;
-import java.net.Proxy;
-import java.net.URI;
-
-import javax.inject.Inject;
-import javax.inject.Singleton;
-import javax.net.ssl.HostnameVerifier;
-import javax.net.ssl.SSLContext;
-
-import org.jclouds.http.HttpResponse;
-import org.jclouds.http.HttpUtils;
-import org.jclouds.http.IOExceptionRetryHandler;
-import org.jclouds.http.handlers.DelegatingErrorHandler;
-import org.jclouds.http.handlers.DelegatingRetryHandler;
-import org.jclouds.http.internal.HttpWire;
-import org.jclouds.http.internal.JavaUrlHttpCommandExecutorService;
-import org.jclouds.io.ContentMetadataCodec;
-
-import com.google.common.base.Function;
-import com.google.common.base.Supplier;
-
-/**
- * Changes super class' behaviour to return an HTTP response with status code 500 instead of the 200 returned by
- * the FGCP API endpoint when the XML payload indicates an error with the request.
- */
-@Singleton
-public class ChangeReturnCodeTo500IfErrorJavaUrlHttpCommandExecutorService extends
-      JavaUrlHttpCommandExecutorService {
-
-   @Inject
-   public ChangeReturnCodeTo500IfErrorJavaUrlHttpCommandExecutorService(HttpUtils utils,
-         ContentMetadataCodec contentMetadataCodec, DelegatingRetryHandler retryHandler,
-         IOExceptionRetryHandler ioRetryHandler, DelegatingErrorHandler errorHandler, HttpWire wire,
-         HostnameVerifier verifier, Supplier<SSLContext> untrustedSSLContextProvider, Function<URI, Proxy> proxyForURI)
-         throws SecurityException, NoSuchFieldException {
-      super(utils, contentMetadataCodec, retryHandler, ioRetryHandler, errorHandler, wire, verifier,
-            untrustedSSLContextProvider, proxyForURI);
-   }
-
-   @Override
-   protected HttpResponse invoke(HttpURLConnection connection)
-         throws IOException, InterruptedException {
-      HttpResponse response = super.invoke(connection);
-
-      byte[] data = closeClientButKeepContentStream(response);
-      if (data != null
-            && !new String(data).contains("<responseStatus>SUCCESS</responseStatus>")) {
-         response = response.toBuilder().statusCode(500).build();
-      }
-
-      return response;
-   }
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/location/SystemAndNetworkSegmentToLocationSupplier.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/location/SystemAndNetworkSegmentToLocationSupplier.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/location/SystemAndNetworkSegmentToLocationSupplier.java
deleted file mode 100644
index 220833d..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/location/SystemAndNetworkSegmentToLocationSupplier.java
+++ /dev/null
@@ -1,91 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.location;
-
-import static com.google.common.base.Preconditions.checkNotNull;
-
-import java.util.Set;
-
-import javax.inject.Inject;
-import javax.inject.Singleton;
-
-import org.jclouds.domain.Location;
-import org.jclouds.domain.LocationBuilder;
-import org.jclouds.domain.LocationScope;
-import org.jclouds.fujitsu.fgcp.FGCPApi;
-import org.jclouds.fujitsu.fgcp.domain.VNet;
-import org.jclouds.fujitsu.fgcp.domain.VSystem;
-import org.jclouds.fujitsu.fgcp.domain.VSystemWithDetails;
-import org.jclouds.location.suppliers.LocationsSupplier;
-import org.jclouds.location.suppliers.all.RegionToProviderOrJustProvider;
-
-import com.google.common.collect.ImmutableSet;
-import com.google.common.collect.ImmutableSet.Builder;
-import com.google.common.collect.Iterables;
-
-/**
- * Builds location hierarchy by querying the back-end for the networks of all
- * virtual systems.
- * <p>
- * Example:
- * <p>
- * 
- * <pre>
- * >location provider fgcp(-au)
- * -> location region au/nsw
- * --> location system vsys
- * ---> location network DMZ/SECURE1/SECURE2
- * </pre>
- * 
- * Todo: caching - provider/region won't change. if vsys still exists, network
- * won't change
- */
-@Singleton
-public class SystemAndNetworkSegmentToLocationSupplier implements LocationsSupplier {
-
-   private final RegionToProviderOrJustProvider regionProvider;
-   private FGCPApi api;
-
-   @Inject
-   SystemAndNetworkSegmentToLocationSupplier(RegionToProviderOrJustProvider regionProvider, FGCPApi api) {
-      this.regionProvider = checkNotNull(regionProvider, "regionToProviderOrJustProvider");
-      this.api = checkNotNull(api, "api");
-   }
-
-   @Override
-   public Set<Location> get() {
-      Builder<Location> locations = ImmutableSet.builder();
-
-      for (VSystem system : api.getVirtualDCApi().listVirtualSystems()) {
-
-         VSystemWithDetails systemWithDetails = api.getVirtualSystemApi().getDetails(system.getId());
-
-         Location systemLocation = new LocationBuilder().scope(LocationScope.SYSTEM)
-               .parent(Iterables.getOnlyElement(regionProvider.get())).description(system.getName()).id(system.getId())
-               .build();
-
-         for (VNet net : systemWithDetails.getNetworks()) {
-
-            locations.add(new LocationBuilder().scope(LocationScope.NETWORK).parent(systemLocation)
-                  .description(net.getNetworkId().replaceFirst(".+-N-", "")).id(net.getNetworkId())
-                  .build());
-         }
-      }
-
-      return locations.build();
-   }
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/reference/RequestParameters.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/reference/RequestParameters.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/reference/RequestParameters.java
deleted file mode 100644
index 6bf9acf..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/reference/RequestParameters.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.reference;
-
-/**
- * Configuration parameters and constants used in HTTP requests.
- */
-public final class RequestParameters {
-
-   /**
-    * Indicates the action to perform. Example: ListVSYS
-    */
-   public static final String ACTION = "Action";
-
-   /**
-    * The API version to use. Example: 2011-01-31
-    */
-   public static final String VERSION = "Version";
-
-   /**
-    * The locale to use. Example: en
-    */
-   public static final String LOCALE = "Locale";
-
-   /**
-    * The Access Key ID for the request sender. This identifies the account
-    * which will be charged for usage of the service. The account with which
-    * the Access Key ID is associated must be signed up for FGCP, or requests
-    * will not be accepted. AKIADQKE4SARGYLE
-    */
-   public static final String ACCESS_KEY_ID = "AccessKeyId";
-
-   /**
-    * The date and time at which the request is signed, in the format
-    * YYYY-MM-DDThh:mm:ssZ. For more information, go to ISO 8601. Example:
-    * 2006-07-07T15:04:56Z
-    */
-   public static final String TIMESTAMP = "Timestamp";
-
-   /**
-    * The date and time at which the signer included in the request expires, in
-    * the format YYYY-MM-DDThh:mm:ssZ. Example: 2006-07-07T15:04:56Z
-    */
-   public static final String EXPIRES = "Expires";
-
-   /**
-    * The request signer. For more information, go to the Amazon Elastic
-    * Compute Cloud Developer Guide. Example: Qnpl4Qk/7tINHzfXCiT7VbBatDA=
-    */
-   public static final String SIGNATURE = "Signature";
-
-   /**
-    * The hash algorithm you use to create the request signer. Valid value:
-    * SHA1withRSA.
-    */
-   public static final String SIGNATURE_METHOD = "SignatureMethod";
-
-   /**
-    * The signer version you use to sign the request. Set this value to 1.0.
-    * 
-    */
-   public static final String SIGNATURE_VERSION = "SignatureVersion";
-
-   private RequestParameters() {
-      throw new AssertionError("intentionally unimplemented");
-   }
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/AdditionalDiskApi.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/AdditionalDiskApi.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/AdditionalDiskApi.java
deleted file mode 100644
index f9e2ec2..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/AdditionalDiskApi.java
+++ /dev/null
@@ -1,113 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.services;
-
-import java.io.Closeable;
-
-import javax.inject.Named;
-import javax.ws.rs.Consumes;
-import javax.ws.rs.GET;
-import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
-
-import org.jclouds.fujitsu.fgcp.FGCPApi;
-import org.jclouds.fujitsu.fgcp.binders.BindAlsoToSystemId;
-import org.jclouds.fujitsu.fgcp.compute.functions.SingleElementResponseToElement;
-import org.jclouds.fujitsu.fgcp.domain.VDisk;
-import org.jclouds.fujitsu.fgcp.domain.VDiskStatus;
-import org.jclouds.fujitsu.fgcp.filters.RequestAuthenticator;
-import org.jclouds.fujitsu.fgcp.reference.RequestParameters;
-import org.jclouds.rest.annotations.BinderParam;
-import org.jclouds.rest.annotations.JAXBResponseParser;
-import org.jclouds.rest.annotations.PayloadParams;
-import org.jclouds.rest.annotations.QueryParams;
-import org.jclouds.rest.annotations.RequestFilters;
-import org.jclouds.rest.annotations.Transform;
-
-
-/**
- * API relating to additional storage.
- */
-@RequestFilters(RequestAuthenticator.class)
-@QueryParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@PayloadParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@Consumes(MediaType.TEXT_XML)
-public interface AdditionalDiskApi extends Closeable {
-
-   @Named("GetVDiskStatus")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetVDiskStatus")
-   @Transform(SingleElementResponseToElement.class)
-   VDiskStatus getStatus(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("vdiskId") String id);
-
-   @Named("GetVDiskAttributes")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetVDiskAttributes")
-   @Transform(SingleElementResponseToElement.class)
-   VDisk get(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("vdiskId") String id);
-
-   @Named("UpdateVDiskAttribute")
-   @GET
-   @QueryParams(keys = "Action", values = "UpdateVDiskAttribute")
-   void update(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("vdiskId") String id,
-         @QueryParam("attributeName") String name,
-         @QueryParam("attributeValue") String value);
-
-   @Named("BackupVDisk")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "BackupVDisk")
-   void backup(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("vdiskId") String id);
-
-   @Named("RestoreVDisk")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "RestoreVDisk")
-   void restore(@QueryParam("vsysId") String systemId,
-         @QueryParam("backupId") String backupId);
-
-   @Named("DestroyVDisk")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "DestroyVDisk")
-   void destroy(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("vdiskId") String id);
-
-   @Named("DetachVDisk")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "DetachVDisk")
-   void detach(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("vdiskId") String diskId,
-         @QueryParam("vserverId") String serverId);
-
-   @Named("DestroyVDiskBackup")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "DestroyVDiskBackup")
-   void destroyBackup(@QueryParam("vsysId") String sysId,
-         @QueryParam("backupId") String backupId);
-
-   // Set<> listBackups(String sysId);
-
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/BuiltinServerApi.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/BuiltinServerApi.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/BuiltinServerApi.java
deleted file mode 100644
index 3d9debf..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/BuiltinServerApi.java
+++ /dev/null
@@ -1,151 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.services;
-
-import java.io.Closeable;
-import java.util.Set;
-
-import javax.inject.Named;
-import javax.ws.rs.Consumes;
-import javax.ws.rs.GET;
-import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
-
-import org.jclouds.fujitsu.fgcp.FGCPApi;
-import org.jclouds.fujitsu.fgcp.binders.BindAlsoToSystemId;
-import org.jclouds.fujitsu.fgcp.compute.functions.SingleElementResponseToElement;
-import org.jclouds.fujitsu.fgcp.domain.BuiltinServer;
-import org.jclouds.fujitsu.fgcp.domain.BuiltinServerBackup;
-import org.jclouds.fujitsu.fgcp.domain.BuiltinServerConfiguration;
-import org.jclouds.fujitsu.fgcp.domain.BuiltinServerStatus;
-import org.jclouds.fujitsu.fgcp.filters.RequestAuthenticator;
-import org.jclouds.fujitsu.fgcp.reference.RequestParameters;
-import org.jclouds.rest.annotations.BinderParam;
-import org.jclouds.rest.annotations.JAXBResponseParser;
-import org.jclouds.rest.annotations.PayloadParams;
-import org.jclouds.rest.annotations.QueryParams;
-import org.jclouds.rest.annotations.RequestFilters;
-import org.jclouds.rest.annotations.Transform;
-
-
-/**
- * API relating to built-in servers, also called extended function
- * module (EFM), such as a firewall or load balancer (SLB).
- */
-@RequestFilters(RequestAuthenticator.class)
-@QueryParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@PayloadParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@Consumes(MediaType.TEXT_XML)
-public interface BuiltinServerApi extends Closeable {
-
-   @Named("StartEFM")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "StartEFM")
-   void start(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("efmId") String id);
-
-   @Named("StopEFM")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "StopEFM")
-   void stop(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("efmId") String id);
-
-   @Named("DestroyEFM")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "DestroyEFM")
-   void destroy(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("efmId") String id);
-
-   @Named("BackupEFM")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "BackupEFM")
-   void backup(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("efmId") String id);
-
-   @Named("RestoreEFM")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "RestoreEFM")
-   void restore(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("efmId") String id,
-         @QueryParam("backupId") String backupId);
-
-   @Named("ListEFMBackup")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "ListEFMBackup")
-   Set<BuiltinServerBackup> listBackups(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("efmId") String id);
-
-   @Named("DestroyEFMBackup")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "DestroyEFMBackup")
-   void destroyBackup(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("efmId") String id,
-         @QueryParam("backupId") String backupId);
-
-   @Named("GetEFMAttributes")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetEFMAttributes")
-   @Transform(SingleElementResponseToElement.class)
-   BuiltinServer get(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("efmId") String id);
-
-   @Named("UpdateEFMAttribute")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "UpdateEFMAttribute")
-   void update(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("efmId") String id,
-         @QueryParam("attributeName") String name,
-         @QueryParam("attributeValue") String value);
-
-   @Named("GetEFMStatus")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetEFMStatus")
-   @Transform(SingleElementResponseToElement.class)
-   BuiltinServerStatus getStatus(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("efmId") String id);
-
-   @Named("GetEFMConfiguration")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetEFMConfiguration")
-   @Transform(SingleElementResponseToElement.class)
-   BuiltinServer getConfiguration(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("efmId") String id,
-         @QueryParam("configurationName") BuiltinServerConfiguration configuration);
-
-//  @Named("GetEFMConfiguration")
-//  @POST
-//  @JAXBResponseParser
-//  @QueryParams(keys = "Action", values = "GetEFMConfiguration")
-//  @Transform(SingleElementResponseToElement.class)
-//  Set<Rule> getUpdateDetails(String id);
-
-   // Void
-   // updateConfiguration(@BinderParam(BindAlsoToSystemId.class)
-   // @QueryParam("efmId") String id, xml?);
-//   EFM_UPDATE,       getUpdateStatus(String id);
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/DiskImageApi.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/DiskImageApi.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/DiskImageApi.java
deleted file mode 100644
index 90a83a3..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/DiskImageApi.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.services;
-
-import java.io.Closeable;
-
-import javax.inject.Named;
-import javax.ws.rs.Consumes;
-import javax.ws.rs.GET;
-import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
-
-import org.jclouds.fujitsu.fgcp.FGCPApi;
-import org.jclouds.fujitsu.fgcp.compute.functions.SingleElementResponseToElement;
-import org.jclouds.fujitsu.fgcp.domain.DiskImage;
-import org.jclouds.fujitsu.fgcp.filters.RequestAuthenticator;
-import org.jclouds.fujitsu.fgcp.reference.RequestParameters;
-import org.jclouds.rest.annotations.JAXBResponseParser;
-import org.jclouds.rest.annotations.PayloadParams;
-import org.jclouds.rest.annotations.QueryParams;
-import org.jclouds.rest.annotations.RequestFilters;
-import org.jclouds.rest.annotations.Transform;
-
-
-/**
- * API relating to disk images.
- */
-@RequestFilters(RequestAuthenticator.class)
-@QueryParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@PayloadParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@Consumes(MediaType.TEXT_XML)
-public interface DiskImageApi extends Closeable {
-
-   @Named("GetDiskImageAttributes")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetDiskImageAttributes")
-   @Transform(SingleElementResponseToElement.class)
-   DiskImage get(@QueryParam("diskImageId") String id);
-
-   @Named("UpdateDiskImageAttribute")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "UpdateDiskImageAttribute")
-   void update(
-         @QueryParam("diskImageId") String diskImageId,
-         @QueryParam("updateLcId") String localeId,
-         @QueryParam("attributeName") String name,
-         @QueryParam("attributeValue") String value);
-
-   @Named("UnregisterDiskImage")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "UnregisterDiskImage")
-   void deregister(@QueryParam("diskImageId") String id);
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/FirewallApi.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/FirewallApi.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/FirewallApi.java
deleted file mode 100644
index c8bbbd1..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/FirewallApi.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.services;
-
-import java.util.Set;
-
-import javax.inject.Named;
-import javax.ws.rs.Consumes;
-import javax.ws.rs.POST;
-import javax.ws.rs.core.MediaType;
-
-import org.jclouds.fujitsu.fgcp.FGCPApi;
-import org.jclouds.fujitsu.fgcp.compute.functions.SingleElementResponseToElement;
-import org.jclouds.fujitsu.fgcp.domain.Rule;
-import org.jclouds.fujitsu.fgcp.filters.RequestAuthenticator;
-import org.jclouds.fujitsu.fgcp.reference.RequestParameters;
-import org.jclouds.rest.annotations.JAXBResponseParser;
-import org.jclouds.rest.annotations.PayloadParams;
-import org.jclouds.rest.annotations.QueryParams;
-import org.jclouds.rest.annotations.RequestFilters;
-import org.jclouds.rest.annotations.Transform;
-
-
-/**
- * API relating to a built-in server, also called extended function
- * module (EFM), of type firewall.
- */
-@RequestFilters(RequestAuthenticator.class)
-@QueryParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@PayloadParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@Consumes(MediaType.TEXT_XML)
-public interface FirewallApi extends BuiltinServerApi {
-
-   @Named("GetEFMConfiguration")
-   @POST
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetEFMConfiguration")
-   @Transform(SingleElementResponseToElement.class)
-   Set<Rule> getNATConfiguration(String id);
-
-   /*
-   FW_NAT_RULE,      getNATConfiguration(String id)
-
-   FW_DNS,       getDNSConfiguration(String id)
-   FW_POLICY,        getPolicyConfiguration(String id)
-
-   FW_LOG,       getFirewallLogs(String id);
-   FW_LIMIT_POLICY,
-
-    */
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/LoadBalancerApi.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/LoadBalancerApi.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/LoadBalancerApi.java
deleted file mode 100644
index 1081805..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/LoadBalancerApi.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.services;
-
-import javax.ws.rs.Consumes;
-import javax.ws.rs.core.MediaType;
-
-import org.jclouds.fujitsu.fgcp.FGCPApi;
-import org.jclouds.fujitsu.fgcp.filters.RequestAuthenticator;
-import org.jclouds.fujitsu.fgcp.reference.RequestParameters;
-import org.jclouds.rest.annotations.PayloadParams;
-import org.jclouds.rest.annotations.QueryParams;
-import org.jclouds.rest.annotations.RequestFilters;
-
-/**
- * API relating to a built-in server, also called extended function
- * module (EFM), of type load balancer (SLB).
- */
-@RequestFilters(RequestAuthenticator.class)
-@QueryParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@PayloadParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@Consumes(MediaType.TEXT_XML)
-public interface LoadBalancerApi extends BuiltinServerApi {
-
-   /*
-   SLB_RULE,         getLBConfiguration(String id)
-   SLB_LOAD_STATISTICS,   getLoadBalancerStats(String id)
-   SLB_ERROR_STATISTICS,   getLoadBalancerErrorStats(String id)
-   SLB_CERTIFICATE_LIST,   getLoadBalancerCerts(String id)
-   SLB_CONNECTION,    getLoadBalancerConnection(String id)
-
-    */
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/PublicIPAddressApi.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/PublicIPAddressApi.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/PublicIPAddressApi.java
deleted file mode 100644
index e0335c7..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/PublicIPAddressApi.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.services;
-
-import java.io.Closeable;
-
-import javax.inject.Named;
-import javax.ws.rs.Consumes;
-import javax.ws.rs.GET;
-import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
-
-import org.jclouds.fujitsu.fgcp.FGCPApi;
-import org.jclouds.fujitsu.fgcp.compute.functions.SingleElementResponseToElement;
-import org.jclouds.fujitsu.fgcp.domain.PublicIP;
-import org.jclouds.fujitsu.fgcp.domain.PublicIPStatus;
-import org.jclouds.fujitsu.fgcp.filters.RequestAuthenticator;
-import org.jclouds.fujitsu.fgcp.reference.RequestParameters;
-import org.jclouds.rest.annotations.JAXBResponseParser;
-import org.jclouds.rest.annotations.PayloadParams;
-import org.jclouds.rest.annotations.QueryParams;
-import org.jclouds.rest.annotations.RequestFilters;
-import org.jclouds.rest.annotations.Transform;
-
-
-/**
- * API relating to public IP addresses.
- */
-@RequestFilters(RequestAuthenticator.class)
-@QueryParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@PayloadParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@Consumes(MediaType.TEXT_XML)
-public interface PublicIPAddressApi extends Closeable {
-
-   @Named("AttachPublicIP")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "AttachPublicIP")
-   void attach(@QueryParam("vsysId") String systemId,
-         @QueryParam("publicIp") String ip);
-
-   @Named("DetachPublicIP")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "DetachPublicIP")
-   void detach(@QueryParam("vsysId") String systemId,
-         @QueryParam("publicIp") String ip);
-
-   @Named("GetPublicIPStatus")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetPublicIPStatus")
-   @Transform(SingleElementResponseToElement.class)
-   PublicIPStatus getStatus(
-         @QueryParam("publicIp") String ip);
-
-   @Named("GetPublicIPAttributes")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetPublicIPAttributes")
-   @Transform(SingleElementResponseToElement.class)
-   PublicIP get(@QueryParam("publicIp") String ip);
-
-   @Named("FreePublicIP")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "FreePublicIP")
-   void free(@QueryParam("vsysId") String systemId,
-         @QueryParam("publicIp") String ip);
-
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/SystemTemplateApi.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/SystemTemplateApi.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/SystemTemplateApi.java
deleted file mode 100644
index fb2d696..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/SystemTemplateApi.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.services;
-
-import java.io.Closeable;
-
-import javax.inject.Named;
-import javax.ws.rs.Consumes;
-import javax.ws.rs.GET;
-import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
-
-import org.jclouds.fujitsu.fgcp.FGCPApi;
-import org.jclouds.fujitsu.fgcp.compute.functions.SingleElementResponseToElement;
-import org.jclouds.fujitsu.fgcp.domain.VSystemDescriptor;
-import org.jclouds.fujitsu.fgcp.filters.RequestAuthenticator;
-import org.jclouds.fujitsu.fgcp.reference.RequestParameters;
-import org.jclouds.rest.annotations.JAXBResponseParser;
-import org.jclouds.rest.annotations.PayloadParams;
-import org.jclouds.rest.annotations.QueryParams;
-import org.jclouds.rest.annotations.RequestFilters;
-import org.jclouds.rest.annotations.Transform;
-
-
-/**
- * API relating to system templates, also referred to as virtual
- * system descriptors.
- */
-@RequestFilters(RequestAuthenticator.class)
-@QueryParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@PayloadParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@Consumes(MediaType.TEXT_XML)
-public interface SystemTemplateApi extends Closeable {
-
-   @Named("GetVSYSDescriptorConfiguration")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetVSYSDescriptorConfiguration")
-   @Transform(SingleElementResponseToElement.class)
-   VSystemDescriptor get(
-         @QueryParam("vsysDescriptorId") String id);
-
-   @Named("UpdateVSYSDescriptorAttribute")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "UpdateVSYSDescriptorAttribute")
-   void update(@QueryParam("vsysDescriptorId") String id,
-         @QueryParam("updateLcId") String localeId,
-         @QueryParam("attributeName") String name,
-         @QueryParam("attributeValue") String value);
-
-   @Named("UnregisterVSYSDescriptor")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "UnregisterVSYSDescriptor")
-   void deregister(
-         @QueryParam("vsysDescriptorId") String id);
-
-   @Named("UnregisterPrivateVSYSDescriptor")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "UnregisterPrivateVSYSDescriptor")
-   void deregisterPrivateTemplate(
-         @QueryParam("vsysDescriptorId") String id);
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/VirtualDCApi.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/VirtualDCApi.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/VirtualDCApi.java
deleted file mode 100644
index 113155e..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/VirtualDCApi.java
+++ /dev/null
@@ -1,202 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.services;
-
-import java.io.Closeable;
-import java.util.Map;
-import java.util.Set;
-
-import javax.inject.Named;
-import javax.ws.rs.Consumes;
-import javax.ws.rs.GET;
-import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
-
-import org.jclouds.fujitsu.fgcp.FGCPApi;
-import org.jclouds.fujitsu.fgcp.compute.functions.SingleElementResponseToElement;
-import org.jclouds.fujitsu.fgcp.domain.AddressRange;
-import org.jclouds.fujitsu.fgcp.domain.DiskImage;
-import org.jclouds.fujitsu.fgcp.domain.EventLog;
-import org.jclouds.fujitsu.fgcp.domain.Information;
-import org.jclouds.fujitsu.fgcp.domain.PublicIP;
-import org.jclouds.fujitsu.fgcp.domain.ServerType;
-import org.jclouds.fujitsu.fgcp.domain.UsageInfo;
-import org.jclouds.fujitsu.fgcp.domain.VSystem;
-import org.jclouds.fujitsu.fgcp.domain.VSystemDescriptor;
-import org.jclouds.fujitsu.fgcp.filters.RequestAuthenticator;
-import org.jclouds.fujitsu.fgcp.reference.RequestParameters;
-import org.jclouds.javax.annotation.Nullable;
-import org.jclouds.rest.annotations.JAXBResponseParser;
-import org.jclouds.rest.annotations.PayloadParams;
-import org.jclouds.rest.annotations.QueryParams;
-import org.jclouds.rest.annotations.RequestFilters;
-import org.jclouds.rest.annotations.Transform;
-
-
-/**
- * API relating to the virtual data center.
- */
-@RequestFilters(RequestAuthenticator.class)
-@QueryParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@PayloadParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@Consumes(MediaType.TEXT_XML)
-public interface VirtualDCApi extends Closeable {
-
-   @Named("CreateVSYS")
-   // @POST
-   @GET
-   @JAXBResponseParser
-   // @XMLResponseParser(VSYSCreateHandler.class)
-   @QueryParams(keys = "Action", values = "CreateVSYS")
-   @Transform(SingleElementResponseToElement.class)
-   // @PayloadParams(keys = "Action", values = "CreateVSYS")
-   // @Produces(MediaType.TEXT_XML)
-   // @MapBinder(BindParamsToXmlPayload.class)
-   // String
-   // createVirtualSystem(@PayloadParam("vsysDescriptorId") String
-   // vsysDescriptorId, @PayloadParam("vsysName") String vsysName);
-   String createVirtualSystem(
-         @QueryParam("vsysDescriptorId") String descriptorId,
-         @QueryParam("vsysName") String name);
-
-   @Named("ListVSYS")
-   @GET
-   @JAXBResponseParser
-   // @XMLResponseParser(VSYSListHandler.class)
-   @QueryParams(keys = "Action", values = "ListVSYS")
-   Set<VSystem> listVirtualSystems();
-
-   @Named("ListServerType")
-   @GET
-   @JAXBResponseParser
-   // according to the manual it takes a 'String diskImageId' but value seems
-   // to be ignored
-   @QueryParams(keys = { "Action", "diskImageId" }, values = {
-         "ListServerType", "dummy" })
-   // @XmlJavaTypeAdapter(SetOfServerTypesXMLAdapter.class)
-   // @XmlElement(type = ServerType.class)
-   Set<ServerType> listServerTypes();
-
-   @Named("ListDiskImage")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "ListDiskImage")
-   Set<DiskImage> listDiskImages();
-
-   @Named("ListDiskImage")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "ListDiskImage")
-   Set<DiskImage> listDiskImages(
-         @Nullable @QueryParam("serverCategory") String serverCategory,
-         @QueryParam("vsysDescriptorId") String vsysDescriptorId);
-
-   /**
-    *
-    * @return
-    * @see VirtualSystemApi#listPublicIPs(String)
-    */
-   @Named("ListPublicIP")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "ListPublicIP")
-   Map<PublicIP, String> listPublicIPs();
-
-   @Named("AddAddressRange")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "AddAddressRange")
-   void addAddressRange(
-         @QueryParam("pipFrom") String pipFrom,
-         @QueryParam("pipTo") String pipTo);
-
-   @Named("CreateAddressPool")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "CreateAddressPool")
-   void createAddressPool(
-         @QueryParam("pipFrom") String pipFrom,
-         @QueryParam("pipTo") String pipTo);
-
-   @Named("DeleteAddressRange")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "DeleteAddressRange")
-   void deleteAddressRange(
-         @QueryParam("pipFrom") String pipFrom,
-         @QueryParam("pipTo") String pipTo);
-
-   @Named("GetAddressRange")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetAddressRange")
-   Set<AddressRange> getAddressRange();
-
-   @Named("ListVSYSDescriptor")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "ListVSYSDescriptor")
-   Set<VSystemDescriptor> listVSYSDescriptor();
-
-   @Named("ListVSYSDescriptor")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "ListVSYSDescriptor")
-   Set<VSystemDescriptor> listVSYSDescriptor(
-         @QueryParam("keyword") String keyword,
-         @QueryParam("estimateFrom") int estimateFrom,
-         @QueryParam("estimateTo") int estimateTo);
-
-   @Named("GetEventLog")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetEventLog")
-   Set<EventLog> getEventLogs();
-
-   @Named("GetEventLog")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetEventLog")
-   Set<EventLog> getEventLogs(@QueryParam("all") boolean all);
-
-   @Named("GetInformation")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetInformation")
-   Set<Information> getInformation();
-
-   @Named("GetInformation")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetInformation")
-   Set<Information> getInformation(
-         @QueryParam("all") boolean all);
-
-   @Named("GetSystemUsage")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetSystemUsage")
-   Set<UsageInfo> getSystemUsage();
-
-   @Named("GetSystemUsage")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetSystemUsage")
-   Set<UsageInfo> getSystemUsage(
-         @QueryParam("systemIds") String systemIds);
-
-}

http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/ba795261/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/VirtualServerApi.java
----------------------------------------------------------------------
diff --git a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/VirtualServerApi.java b/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/VirtualServerApi.java
deleted file mode 100644
index ad6de39..0000000
--- a/fgcp/src/main/java/org/jclouds/fujitsu/fgcp/services/VirtualServerApi.java
+++ /dev/null
@@ -1,155 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jclouds.fujitsu.fgcp.services;
-
-import java.io.Closeable;
-import java.util.Set;
-
-import javax.inject.Named;
-import javax.ws.rs.Consumes;
-import javax.ws.rs.GET;
-import javax.ws.rs.POST;
-import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
-
-import org.jclouds.fujitsu.fgcp.FGCPApi;
-import org.jclouds.fujitsu.fgcp.binders.BindAlsoToSystemId;
-import org.jclouds.fujitsu.fgcp.compute.functions.SingleElementResponseToElement;
-import org.jclouds.fujitsu.fgcp.domain.PerformanceInfo;
-import org.jclouds.fujitsu.fgcp.domain.VServer;
-import org.jclouds.fujitsu.fgcp.domain.VServerStatus;
-import org.jclouds.fujitsu.fgcp.domain.VServerWithDetails;
-import org.jclouds.fujitsu.fgcp.filters.RequestAuthenticator;
-import org.jclouds.fujitsu.fgcp.reference.RequestParameters;
-import org.jclouds.rest.annotations.BinderParam;
-import org.jclouds.rest.annotations.JAXBResponseParser;
-import org.jclouds.rest.annotations.PayloadParams;
-import org.jclouds.rest.annotations.QueryParams;
-import org.jclouds.rest.annotations.RequestFilters;
-import org.jclouds.rest.annotations.Transform;
-
-
-/**
- * API relating to virtual servers.
- */
-@RequestFilters(RequestAuthenticator.class)
-@QueryParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@PayloadParams(keys = RequestParameters.VERSION, values = FGCPApi.VERSION)
-@Consumes(MediaType.TEXT_XML)
-public interface VirtualServerApi extends Closeable {
-
-   @Named("StartVServer")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "StartVServer")
-   void start(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("vserverId") String id);
-
-   @Named("StopVServer")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "StopVServer")
-   void stop(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("vserverId") String id);
-
-   @Named("StopVServer")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = { "Action", "force" }, values = { "StopVServer", "true" })
-   void stopForcefully(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("vserverId") String id);
-
-   @Named("DestroyVServer")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "DestroyVServer")
-   void destroy(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("vserverId") String id);
-
-   @Named("GetVServerAttributes")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetVServerAttributes")
-   @Transform(SingleElementResponseToElement.class)
-   VServer get(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("vserverId") String id);
-
-   @Named("GetVServerConfiguration")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetVServerConfiguration")
-   @Transform(SingleElementResponseToElement.class)
-   VServerWithDetails getDetails(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("vserverId") String id);
-
-   @Named("UpdateVServerAttribute")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "UpdateVServerAttribute")
-   void update(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("vserverId") String id,
-         @QueryParam("attributeName") String name,
-         @QueryParam("attributeValue") String value);
-
-   @Named("GetVServerStatus")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetVServerStatus")
-   // @Transform(StringToVServerStatus.class)
-   @Transform(SingleElementResponseToElement.class)
-   VServerStatus getStatus(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("vserverId") String id);
-
-   @Named("GetVServerInitialPassword")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetVServerInitialPassword")
-   @Transform(SingleElementResponseToElement.class)
-   String getInitialPassword(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("vserverId") String id);
-
-   @Named("AttachVDisk")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "AttachVDisk")
-   void attachDisk(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("vserverId") String serverId,
-         @QueryParam("vdiskId") String diskId);
-
-   @Named("GetPerformanceInformation")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetPerformanceInformation")
-   Set<PerformanceInfo> getPerformanceInformation(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("serverId") String id,
-         @QueryParam("interval") String interval);
-
-   @Named("GetPerformanceInformation")
-   @GET
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "GetPerformanceInformation")
-   Set<PerformanceInfo> getPerformanceInformation(
-         @BinderParam(BindAlsoToSystemId.class) @QueryParam("serverId") String id,
-         @QueryParam("dataType") String dataType,
-         @QueryParam("interval") String interval);
-
-   @Named("RegisterPrivateDiskImage")
-   @POST
-   @JAXBResponseParser
-   @QueryParams(keys = "Action", values = "RegisterPrivateDiskImage")
-   void registerAsPrivateDiskImage(String xml);
-}