You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airavata.apache.org by sm...@apache.org on 2015/03/06 05:29:30 UTC

[1/4] airavata git commit: Reorganizing duplicate generated classed and instead using the stubs artifact - AIRAVATA-1621

Repository: airavata
Updated Branches:
  refs/heads/master 58c58cf20 -> b25e0a5db


http://git-wip-us.apache.org/repos/asf/airavata/blob/b25e0a5d/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/SSHCredential.java
----------------------------------------------------------------------
diff --git a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/SSHCredential.java b/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/SSHCredential.java
deleted file mode 100644
index 9fc373a..0000000
--- a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/SSHCredential.java
+++ /dev/null
@@ -1,998 +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.
-     */
-/**
- * Autogenerated by Thrift Compiler (0.9.1)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- *  @generated
- */
-package org.apache.airavata.credential.store.datamodel;
-
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-import org.apache.thrift.protocol.TTupleProtocol;
-import org.apache.thrift.protocol.TProtocolException;
-import org.apache.thrift.EncodingUtils;
-import org.apache.thrift.TException;
-import org.apache.thrift.async.AsyncMethodCallback;
-import org.apache.thrift.server.AbstractNonblockingServer.*;
-import java.util.List;
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-import java.util.Collections;
-import java.util.BitSet;
-import java.nio.ByteBuffer;
-import java.util.Arrays;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings("all") public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSHCredential._Fields>, java.io.Serializable, Cloneable, Comparable<SSHCredential> {
-  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("SSHCredential");
-
-  private static final org.apache.thrift.protocol.TField GATEWAY_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("gatewayId", org.apache.thrift.protocol.TType.STRING, (short)1);
-  private static final org.apache.thrift.protocol.TField USERNAME_FIELD_DESC = new org.apache.thrift.protocol.TField("username", org.apache.thrift.protocol.TType.STRING, (short)2);
-  private static final org.apache.thrift.protocol.TField PASSPHRASE_FIELD_DESC = new org.apache.thrift.protocol.TField("passphrase", org.apache.thrift.protocol.TType.STRING, (short)3);
-  private static final org.apache.thrift.protocol.TField PUBLIC_KEY_FIELD_DESC = new org.apache.thrift.protocol.TField("publicKey", org.apache.thrift.protocol.TType.STRING, (short)4);
-  private static final org.apache.thrift.protocol.TField PRIVATE_KEY_FIELD_DESC = new org.apache.thrift.protocol.TField("privateKey", org.apache.thrift.protocol.TType.STRING, (short)5);
-  private static final org.apache.thrift.protocol.TField PERSISTED_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("persistedTime", org.apache.thrift.protocol.TType.I64, (short)6);
-  private static final org.apache.thrift.protocol.TField TOKEN_FIELD_DESC = new org.apache.thrift.protocol.TField("token", org.apache.thrift.protocol.TType.STRING, (short)7);
-
-  private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
-  static {
-    schemes.put(StandardScheme.class, new SSHCredentialStandardSchemeFactory());
-    schemes.put(TupleScheme.class, new SSHCredentialTupleSchemeFactory());
-  }
-
-  public String gatewayId; // required
-  public String username; // required
-  public String passphrase; // required
-  public String publicKey; // optional
-  public String privateKey; // optional
-  public long persistedTime; // optional
-  public String token; // optional
-
-  /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-  @SuppressWarnings("all") public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-    GATEWAY_ID((short)1, "gatewayId"),
-    USERNAME((short)2, "username"),
-    PASSPHRASE((short)3, "passphrase"),
-    PUBLIC_KEY((short)4, "publicKey"),
-    PRIVATE_KEY((short)5, "privateKey"),
-    PERSISTED_TIME((short)6, "persistedTime"),
-    TOKEN((short)7, "token");
-
-    private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
-    static {
-      for (_Fields field : EnumSet.allOf(_Fields.class)) {
-        byName.put(field.getFieldName(), field);
-      }
-    }
-
-    /**
-     * Find the _Fields constant that matches fieldId, or null if its not found.
-     */
-    public static _Fields findByThriftId(int fieldId) {
-      switch(fieldId) {
-        case 1: // GATEWAY_ID
-          return GATEWAY_ID;
-        case 2: // USERNAME
-          return USERNAME;
-        case 3: // PASSPHRASE
-          return PASSPHRASE;
-        case 4: // PUBLIC_KEY
-          return PUBLIC_KEY;
-        case 5: // PRIVATE_KEY
-          return PRIVATE_KEY;
-        case 6: // PERSISTED_TIME
-          return PERSISTED_TIME;
-        case 7: // TOKEN
-          return TOKEN;
-        default:
-          return null;
-      }
-    }
-
-    /**
-     * Find the _Fields constant that matches fieldId, throwing an exception
-     * if it is not found.
-     */
-    public static _Fields findByThriftIdOrThrow(int fieldId) {
-      _Fields fields = findByThriftId(fieldId);
-      if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-      return fields;
-    }
-
-    /**
-     * Find the _Fields constant that matches name, or null if its not found.
-     */
-    public static _Fields findByName(String name) {
-      return byName.get(name);
-    }
-
-    private final short _thriftId;
-    private final String _fieldName;
-
-    _Fields(short thriftId, String fieldName) {
-      _thriftId = thriftId;
-      _fieldName = fieldName;
-    }
-
-    public short getThriftFieldId() {
-      return _thriftId;
-    }
-
-    public String getFieldName() {
-      return _fieldName;
-    }
-  }
-
-  // isset id assignments
-  private static final int __PERSISTEDTIME_ISSET_ID = 0;
-  private byte __isset_bitfield = 0;
-  private _Fields optionals[] = {_Fields.PUBLIC_KEY,_Fields.PRIVATE_KEY,_Fields.PERSISTED_TIME,_Fields.TOKEN};
-  public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-  static {
-    Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-    tmpMap.put(_Fields.GATEWAY_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayId", org.apache.thrift.TFieldRequirementType.REQUIRED, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    tmpMap.put(_Fields.USERNAME, new org.apache.thrift.meta_data.FieldMetaData("username", org.apache.thrift.TFieldRequirementType.REQUIRED, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    tmpMap.put(_Fields.PASSPHRASE, new org.apache.thrift.meta_data.FieldMetaData("passphrase", org.apache.thrift.TFieldRequirementType.REQUIRED, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    tmpMap.put(_Fields.PUBLIC_KEY, new org.apache.thrift.meta_data.FieldMetaData("publicKey", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    tmpMap.put(_Fields.PRIVATE_KEY, new org.apache.thrift.meta_data.FieldMetaData("privateKey", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    tmpMap.put(_Fields.PERSISTED_TIME, new org.apache.thrift.meta_data.FieldMetaData("persistedTime", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-    tmpMap.put(_Fields.TOKEN, new org.apache.thrift.meta_data.FieldMetaData("token", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    metaDataMap = Collections.unmodifiableMap(tmpMap);
-    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(SSHCredential.class, metaDataMap);
-  }
-
-  public SSHCredential() {
-  }
-
-  public SSHCredential(
-    String gatewayId,
-    String username,
-    String passphrase)
-  {
-    this();
-    this.gatewayId = gatewayId;
-    this.username = username;
-    this.passphrase = passphrase;
-  }
-
-  /**
-   * Performs a deep copy on <i>other</i>.
-   */
-  public SSHCredential(SSHCredential other) {
-    __isset_bitfield = other.__isset_bitfield;
-    if (other.isSetGatewayId()) {
-      this.gatewayId = other.gatewayId;
-    }
-    if (other.isSetUsername()) {
-      this.username = other.username;
-    }
-    if (other.isSetPassphrase()) {
-      this.passphrase = other.passphrase;
-    }
-    if (other.isSetPublicKey()) {
-      this.publicKey = other.publicKey;
-    }
-    if (other.isSetPrivateKey()) {
-      this.privateKey = other.privateKey;
-    }
-    this.persistedTime = other.persistedTime;
-    if (other.isSetToken()) {
-      this.token = other.token;
-    }
-  }
-
-  public SSHCredential deepCopy() {
-    return new SSHCredential(this);
-  }
-
-  @Override
-  public void clear() {
-    this.gatewayId = null;
-    this.username = null;
-    this.passphrase = null;
-    this.publicKey = null;
-    this.privateKey = null;
-    setPersistedTimeIsSet(false);
-    this.persistedTime = 0;
-    this.token = null;
-  }
-
-  public String getGatewayId() {
-    return this.gatewayId;
-  }
-
-  public SSHCredential setGatewayId(String gatewayId) {
-    this.gatewayId = gatewayId;
-    return this;
-  }
-
-  public void unsetGatewayId() {
-    this.gatewayId = null;
-  }
-
-  /** Returns true if field gatewayId is set (has been assigned a value) and false otherwise */
-  public boolean isSetGatewayId() {
-    return this.gatewayId != null;
-  }
-
-  public void setGatewayIdIsSet(boolean value) {
-    if (!value) {
-      this.gatewayId = null;
-    }
-  }
-
-  public String getUsername() {
-    return this.username;
-  }
-
-  public SSHCredential setUsername(String username) {
-    this.username = username;
-    return this;
-  }
-
-  public void unsetUsername() {
-    this.username = null;
-  }
-
-  /** Returns true if field username is set (has been assigned a value) and false otherwise */
-  public boolean isSetUsername() {
-    return this.username != null;
-  }
-
-  public void setUsernameIsSet(boolean value) {
-    if (!value) {
-      this.username = null;
-    }
-  }
-
-  public String getPassphrase() {
-    return this.passphrase;
-  }
-
-  public SSHCredential setPassphrase(String passphrase) {
-    this.passphrase = passphrase;
-    return this;
-  }
-
-  public void unsetPassphrase() {
-    this.passphrase = null;
-  }
-
-  /** Returns true if field passphrase is set (has been assigned a value) and false otherwise */
-  public boolean isSetPassphrase() {
-    return this.passphrase != null;
-  }
-
-  public void setPassphraseIsSet(boolean value) {
-    if (!value) {
-      this.passphrase = null;
-    }
-  }
-
-  public String getPublicKey() {
-    return this.publicKey;
-  }
-
-  public SSHCredential setPublicKey(String publicKey) {
-    this.publicKey = publicKey;
-    return this;
-  }
-
-  public void unsetPublicKey() {
-    this.publicKey = null;
-  }
-
-  /** Returns true if field publicKey is set (has been assigned a value) and false otherwise */
-  public boolean isSetPublicKey() {
-    return this.publicKey != null;
-  }
-
-  public void setPublicKeyIsSet(boolean value) {
-    if (!value) {
-      this.publicKey = null;
-    }
-  }
-
-  public String getPrivateKey() {
-    return this.privateKey;
-  }
-
-  public SSHCredential setPrivateKey(String privateKey) {
-    this.privateKey = privateKey;
-    return this;
-  }
-
-  public void unsetPrivateKey() {
-    this.privateKey = null;
-  }
-
-  /** Returns true if field privateKey is set (has been assigned a value) and false otherwise */
-  public boolean isSetPrivateKey() {
-    return this.privateKey != null;
-  }
-
-  public void setPrivateKeyIsSet(boolean value) {
-    if (!value) {
-      this.privateKey = null;
-    }
-  }
-
-  public long getPersistedTime() {
-    return this.persistedTime;
-  }
-
-  public SSHCredential setPersistedTime(long persistedTime) {
-    this.persistedTime = persistedTime;
-    setPersistedTimeIsSet(true);
-    return this;
-  }
-
-  public void unsetPersistedTime() {
-    __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID);
-  }
-
-  /** Returns true if field persistedTime is set (has been assigned a value) and false otherwise */
-  public boolean isSetPersistedTime() {
-    return EncodingUtils.testBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID);
-  }
-
-  public void setPersistedTimeIsSet(boolean value) {
-    __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID, value);
-  }
-
-  public String getToken() {
-    return this.token;
-  }
-
-  public SSHCredential setToken(String token) {
-    this.token = token;
-    return this;
-  }
-
-  public void unsetToken() {
-    this.token = null;
-  }
-
-  /** Returns true if field token is set (has been assigned a value) and false otherwise */
-  public boolean isSetToken() {
-    return this.token != null;
-  }
-
-  public void setTokenIsSet(boolean value) {
-    if (!value) {
-      this.token = null;
-    }
-  }
-
-  public void setFieldValue(_Fields field, Object value) {
-    switch (field) {
-    case GATEWAY_ID:
-      if (value == null) {
-        unsetGatewayId();
-      } else {
-        setGatewayId((String)value);
-      }
-      break;
-
-    case USERNAME:
-      if (value == null) {
-        unsetUsername();
-      } else {
-        setUsername((String)value);
-      }
-      break;
-
-    case PASSPHRASE:
-      if (value == null) {
-        unsetPassphrase();
-      } else {
-        setPassphrase((String)value);
-      }
-      break;
-
-    case PUBLIC_KEY:
-      if (value == null) {
-        unsetPublicKey();
-      } else {
-        setPublicKey((String)value);
-      }
-      break;
-
-    case PRIVATE_KEY:
-      if (value == null) {
-        unsetPrivateKey();
-      } else {
-        setPrivateKey((String)value);
-      }
-      break;
-
-    case PERSISTED_TIME:
-      if (value == null) {
-        unsetPersistedTime();
-      } else {
-        setPersistedTime((Long)value);
-      }
-      break;
-
-    case TOKEN:
-      if (value == null) {
-        unsetToken();
-      } else {
-        setToken((String)value);
-      }
-      break;
-
-    }
-  }
-
-  public Object getFieldValue(_Fields field) {
-    switch (field) {
-    case GATEWAY_ID:
-      return getGatewayId();
-
-    case USERNAME:
-      return getUsername();
-
-    case PASSPHRASE:
-      return getPassphrase();
-
-    case PUBLIC_KEY:
-      return getPublicKey();
-
-    case PRIVATE_KEY:
-      return getPrivateKey();
-
-    case PERSISTED_TIME:
-      return Long.valueOf(getPersistedTime());
-
-    case TOKEN:
-      return getToken();
-
-    }
-    throw new IllegalStateException();
-  }
-
-  /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-  public boolean isSet(_Fields field) {
-    if (field == null) {
-      throw new IllegalArgumentException();
-    }
-
-    switch (field) {
-    case GATEWAY_ID:
-      return isSetGatewayId();
-    case USERNAME:
-      return isSetUsername();
-    case PASSPHRASE:
-      return isSetPassphrase();
-    case PUBLIC_KEY:
-      return isSetPublicKey();
-    case PRIVATE_KEY:
-      return isSetPrivateKey();
-    case PERSISTED_TIME:
-      return isSetPersistedTime();
-    case TOKEN:
-      return isSetToken();
-    }
-    throw new IllegalStateException();
-  }
-
-  @Override
-  public boolean equals(Object that) {
-    if (that == null)
-      return false;
-    if (that instanceof SSHCredential)
-      return this.equals((SSHCredential)that);
-    return false;
-  }
-
-  public boolean equals(SSHCredential that) {
-    if (that == null)
-      return false;
-
-    boolean this_present_gatewayId = true && this.isSetGatewayId();
-    boolean that_present_gatewayId = true && that.isSetGatewayId();
-    if (this_present_gatewayId || that_present_gatewayId) {
-      if (!(this_present_gatewayId && that_present_gatewayId))
-        return false;
-      if (!this.gatewayId.equals(that.gatewayId))
-        return false;
-    }
-
-    boolean this_present_username = true && this.isSetUsername();
-    boolean that_present_username = true && that.isSetUsername();
-    if (this_present_username || that_present_username) {
-      if (!(this_present_username && that_present_username))
-        return false;
-      if (!this.username.equals(that.username))
-        return false;
-    }
-
-    boolean this_present_passphrase = true && this.isSetPassphrase();
-    boolean that_present_passphrase = true && that.isSetPassphrase();
-    if (this_present_passphrase || that_present_passphrase) {
-      if (!(this_present_passphrase && that_present_passphrase))
-        return false;
-      if (!this.passphrase.equals(that.passphrase))
-        return false;
-    }
-
-    boolean this_present_publicKey = true && this.isSetPublicKey();
-    boolean that_present_publicKey = true && that.isSetPublicKey();
-    if (this_present_publicKey || that_present_publicKey) {
-      if (!(this_present_publicKey && that_present_publicKey))
-        return false;
-      if (!this.publicKey.equals(that.publicKey))
-        return false;
-    }
-
-    boolean this_present_privateKey = true && this.isSetPrivateKey();
-    boolean that_present_privateKey = true && that.isSetPrivateKey();
-    if (this_present_privateKey || that_present_privateKey) {
-      if (!(this_present_privateKey && that_present_privateKey))
-        return false;
-      if (!this.privateKey.equals(that.privateKey))
-        return false;
-    }
-
-    boolean this_present_persistedTime = true && this.isSetPersistedTime();
-    boolean that_present_persistedTime = true && that.isSetPersistedTime();
-    if (this_present_persistedTime || that_present_persistedTime) {
-      if (!(this_present_persistedTime && that_present_persistedTime))
-        return false;
-      if (this.persistedTime != that.persistedTime)
-        return false;
-    }
-
-    boolean this_present_token = true && this.isSetToken();
-    boolean that_present_token = true && that.isSetToken();
-    if (this_present_token || that_present_token) {
-      if (!(this_present_token && that_present_token))
-        return false;
-      if (!this.token.equals(that.token))
-        return false;
-    }
-
-    return true;
-  }
-
-  @Override
-  public int hashCode() {
-    return 0;
-  }
-
-  @Override
-  public int compareTo(SSHCredential other) {
-    if (!getClass().equals(other.getClass())) {
-      return getClass().getName().compareTo(other.getClass().getName());
-    }
-
-    int lastComparison = 0;
-
-    lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(other.isSetGatewayId());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetGatewayId()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayId, other.gatewayId);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetUsername()).compareTo(other.isSetUsername());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetUsername()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.username, other.username);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetPassphrase()).compareTo(other.isSetPassphrase());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetPassphrase()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.passphrase, other.passphrase);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetPublicKey()).compareTo(other.isSetPublicKey());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetPublicKey()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.publicKey, other.publicKey);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetPrivateKey()).compareTo(other.isSetPrivateKey());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetPrivateKey()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.privateKey, other.privateKey);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetPersistedTime()).compareTo(other.isSetPersistedTime());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetPersistedTime()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.persistedTime, other.persistedTime);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetToken()).compareTo(other.isSetToken());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetToken()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.token, other.token);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    return 0;
-  }
-
-  public _Fields fieldForId(int fieldId) {
-    return _Fields.findByThriftId(fieldId);
-  }
-
-  public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-    schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
-  }
-
-  public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-    schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
-  }
-
-  @Override
-  public String toString() {
-    StringBuilder sb = new StringBuilder("SSHCredential(");
-    boolean first = true;
-
-    sb.append("gatewayId:");
-    if (this.gatewayId == null) {
-      sb.append("null");
-    } else {
-      sb.append(this.gatewayId);
-    }
-    first = false;
-    if (!first) sb.append(", ");
-    sb.append("username:");
-    if (this.username == null) {
-      sb.append("null");
-    } else {
-      sb.append(this.username);
-    }
-    first = false;
-    if (!first) sb.append(", ");
-    sb.append("passphrase:");
-    if (this.passphrase == null) {
-      sb.append("null");
-    } else {
-      sb.append(this.passphrase);
-    }
-    first = false;
-    if (isSetPublicKey()) {
-      if (!first) sb.append(", ");
-      sb.append("publicKey:");
-      if (this.publicKey == null) {
-        sb.append("null");
-      } else {
-        sb.append(this.publicKey);
-      }
-      first = false;
-    }
-    if (isSetPrivateKey()) {
-      if (!first) sb.append(", ");
-      sb.append("privateKey:");
-      if (this.privateKey == null) {
-        sb.append("null");
-      } else {
-        sb.append(this.privateKey);
-      }
-      first = false;
-    }
-    if (isSetPersistedTime()) {
-      if (!first) sb.append(", ");
-      sb.append("persistedTime:");
-      sb.append(this.persistedTime);
-      first = false;
-    }
-    if (isSetToken()) {
-      if (!first) sb.append(", ");
-      sb.append("token:");
-      if (this.token == null) {
-        sb.append("null");
-      } else {
-        sb.append(this.token);
-      }
-      first = false;
-    }
-    sb.append(")");
-    return sb.toString();
-  }
-
-  public void validate() throws org.apache.thrift.TException {
-    // check for required fields
-    if (gatewayId == null) {
-      throw new org.apache.thrift.protocol.TProtocolException("Required field 'gatewayId' was not present! Struct: " + toString());
-    }
-    if (username == null) {
-      throw new org.apache.thrift.protocol.TProtocolException("Required field 'username' was not present! Struct: " + toString());
-    }
-    if (passphrase == null) {
-      throw new org.apache.thrift.protocol.TProtocolException("Required field 'passphrase' was not present! Struct: " + toString());
-    }
-    // check for sub-struct validity
-  }
-
-  private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-    try {
-      write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-    } catch (org.apache.thrift.TException te) {
-      throw new java.io.IOException(te);
-    }
-  }
-
-  private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-    try {
-      // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
-      __isset_bitfield = 0;
-      read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-    } catch (org.apache.thrift.TException te) {
-      throw new java.io.IOException(te);
-    }
-  }
-
-  private static class SSHCredentialStandardSchemeFactory implements SchemeFactory {
-    public SSHCredentialStandardScheme getScheme() {
-      return new SSHCredentialStandardScheme();
-    }
-  }
-
-  private static class SSHCredentialStandardScheme extends StandardScheme<SSHCredential> {
-
-    public void read(org.apache.thrift.protocol.TProtocol iprot, SSHCredential struct) throws org.apache.thrift.TException {
-      org.apache.thrift.protocol.TField schemeField;
-      iprot.readStructBegin();
-      while (true)
-      {
-        schemeField = iprot.readFieldBegin();
-        if (schemeField.type == org.apache.thrift.protocol.TType.STOP) { 
-          break;
-        }
-        switch (schemeField.id) {
-          case 1: // GATEWAY_ID
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.gatewayId = iprot.readString();
-              struct.setGatewayIdIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 2: // USERNAME
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.username = iprot.readString();
-              struct.setUsernameIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 3: // PASSPHRASE
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.passphrase = iprot.readString();
-              struct.setPassphraseIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 4: // PUBLIC_KEY
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.publicKey = iprot.readString();
-              struct.setPublicKeyIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 5: // PRIVATE_KEY
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.privateKey = iprot.readString();
-              struct.setPrivateKeyIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 6: // PERSISTED_TIME
-            if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
-              struct.persistedTime = iprot.readI64();
-              struct.setPersistedTimeIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 7: // TOKEN
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.token = iprot.readString();
-              struct.setTokenIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          default:
-            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-        }
-        iprot.readFieldEnd();
-      }
-      iprot.readStructEnd();
-
-      // check for required fields of primitive type, which can't be checked in the validate method
-      struct.validate();
-    }
-
-    public void write(org.apache.thrift.protocol.TProtocol oprot, SSHCredential struct) throws org.apache.thrift.TException {
-      struct.validate();
-
-      oprot.writeStructBegin(STRUCT_DESC);
-      if (struct.gatewayId != null) {
-        oprot.writeFieldBegin(GATEWAY_ID_FIELD_DESC);
-        oprot.writeString(struct.gatewayId);
-        oprot.writeFieldEnd();
-      }
-      if (struct.username != null) {
-        oprot.writeFieldBegin(USERNAME_FIELD_DESC);
-        oprot.writeString(struct.username);
-        oprot.writeFieldEnd();
-      }
-      if (struct.passphrase != null) {
-        oprot.writeFieldBegin(PASSPHRASE_FIELD_DESC);
-        oprot.writeString(struct.passphrase);
-        oprot.writeFieldEnd();
-      }
-      if (struct.publicKey != null) {
-        if (struct.isSetPublicKey()) {
-          oprot.writeFieldBegin(PUBLIC_KEY_FIELD_DESC);
-          oprot.writeString(struct.publicKey);
-          oprot.writeFieldEnd();
-        }
-      }
-      if (struct.privateKey != null) {
-        if (struct.isSetPrivateKey()) {
-          oprot.writeFieldBegin(PRIVATE_KEY_FIELD_DESC);
-          oprot.writeString(struct.privateKey);
-          oprot.writeFieldEnd();
-        }
-      }
-      if (struct.isSetPersistedTime()) {
-        oprot.writeFieldBegin(PERSISTED_TIME_FIELD_DESC);
-        oprot.writeI64(struct.persistedTime);
-        oprot.writeFieldEnd();
-      }
-      if (struct.token != null) {
-        if (struct.isSetToken()) {
-          oprot.writeFieldBegin(TOKEN_FIELD_DESC);
-          oprot.writeString(struct.token);
-          oprot.writeFieldEnd();
-        }
-      }
-      oprot.writeFieldStop();
-      oprot.writeStructEnd();
-    }
-
-  }
-
-  private static class SSHCredentialTupleSchemeFactory implements SchemeFactory {
-    public SSHCredentialTupleScheme getScheme() {
-      return new SSHCredentialTupleScheme();
-    }
-  }
-
-  private static class SSHCredentialTupleScheme extends TupleScheme<SSHCredential> {
-
-    @Override
-    public void write(org.apache.thrift.protocol.TProtocol prot, SSHCredential struct) throws org.apache.thrift.TException {
-      TTupleProtocol oprot = (TTupleProtocol) prot;
-      oprot.writeString(struct.gatewayId);
-      oprot.writeString(struct.username);
-      oprot.writeString(struct.passphrase);
-      BitSet optionals = new BitSet();
-      if (struct.isSetPublicKey()) {
-        optionals.set(0);
-      }
-      if (struct.isSetPrivateKey()) {
-        optionals.set(1);
-      }
-      if (struct.isSetPersistedTime()) {
-        optionals.set(2);
-      }
-      if (struct.isSetToken()) {
-        optionals.set(3);
-      }
-      oprot.writeBitSet(optionals, 4);
-      if (struct.isSetPublicKey()) {
-        oprot.writeString(struct.publicKey);
-      }
-      if (struct.isSetPrivateKey()) {
-        oprot.writeString(struct.privateKey);
-      }
-      if (struct.isSetPersistedTime()) {
-        oprot.writeI64(struct.persistedTime);
-      }
-      if (struct.isSetToken()) {
-        oprot.writeString(struct.token);
-      }
-    }
-
-    @Override
-    public void read(org.apache.thrift.protocol.TProtocol prot, SSHCredential struct) throws org.apache.thrift.TException {
-      TTupleProtocol iprot = (TTupleProtocol) prot;
-      struct.gatewayId = iprot.readString();
-      struct.setGatewayIdIsSet(true);
-      struct.username = iprot.readString();
-      struct.setUsernameIsSet(true);
-      struct.passphrase = iprot.readString();
-      struct.setPassphraseIsSet(true);
-      BitSet incoming = iprot.readBitSet(4);
-      if (incoming.get(0)) {
-        struct.publicKey = iprot.readString();
-        struct.setPublicKeyIsSet(true);
-      }
-      if (incoming.get(1)) {
-        struct.privateKey = iprot.readString();
-        struct.setPrivateKeyIsSet(true);
-      }
-      if (incoming.get(2)) {
-        struct.persistedTime = iprot.readI64();
-        struct.setPersistedTimeIsSet(true);
-      }
-      if (incoming.get(3)) {
-        struct.token = iprot.readString();
-        struct.setTokenIsSet(true);
-      }
-    }
-  }
-
-}
-

http://git-wip-us.apache.org/repos/asf/airavata/blob/b25e0a5d/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/csDataModelConstants.java
----------------------------------------------------------------------
diff --git a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/csDataModelConstants.java b/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/csDataModelConstants.java
deleted file mode 100644
index b17513a..0000000
--- a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/csDataModelConstants.java
+++ /dev/null
@@ -1,55 +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.
-     */
-/**
- * Autogenerated by Thrift Compiler (0.9.1)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- *  @generated
- */
-package org.apache.airavata.credential.store.datamodel;
-
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-import org.apache.thrift.protocol.TTupleProtocol;
-import org.apache.thrift.protocol.TProtocolException;
-import org.apache.thrift.EncodingUtils;
-import org.apache.thrift.TException;
-import org.apache.thrift.async.AsyncMethodCallback;
-import org.apache.thrift.server.AbstractNonblockingServer.*;
-import java.util.List;
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-import java.util.Collections;
-import java.util.BitSet;
-import java.nio.ByteBuffer;
-import java.util.Arrays;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings("all") public class csDataModelConstants {
-
-  public static final String DEFAULT_ID = "DO_NOT_SET_AT_CLIENTS";
-
-}

http://git-wip-us.apache.org/repos/asf/airavata/blob/b25e0a5d/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/exception/CredentialStoreException.java
----------------------------------------------------------------------
diff --git a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/exception/CredentialStoreException.java b/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/exception/CredentialStoreException.java
deleted file mode 100644
index 7be01da..0000000
--- a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/exception/CredentialStoreException.java
+++ /dev/null
@@ -1,397 +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.
-     */
-/**
- * Autogenerated by Thrift Compiler (0.9.1)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- *  @generated
- */
-package org.apache.airavata.credential.store.exception;
-
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-import org.apache.thrift.protocol.TTupleProtocol;
-import org.apache.thrift.protocol.TProtocolException;
-import org.apache.thrift.EncodingUtils;
-import org.apache.thrift.TException;
-import org.apache.thrift.async.AsyncMethodCallback;
-import org.apache.thrift.server.AbstractNonblockingServer.*;
-import java.util.List;
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-import java.util.Collections;
-import java.util.BitSet;
-import java.nio.ByteBuffer;
-import java.util.Arrays;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings("all") public class CredentialStoreException extends TException implements org.apache.thrift.TBase<CredentialStoreException, CredentialStoreException._Fields>, java.io.Serializable, Cloneable, Comparable<CredentialStoreException> {
-  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("CredentialStoreException");
-
-  private static final org.apache.thrift.protocol.TField MESSAGE_FIELD_DESC = new org.apache.thrift.protocol.TField("message", org.apache.thrift.protocol.TType.STRING, (short)1);
-
-  private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
-  static {
-    schemes.put(StandardScheme.class, new CredentialStoreExceptionStandardSchemeFactory());
-    schemes.put(TupleScheme.class, new CredentialStoreExceptionTupleSchemeFactory());
-  }
-
-  public String message; // required
-
-  /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-  @SuppressWarnings("all") public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-    MESSAGE((short)1, "message");
-
-    private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
-    static {
-      for (_Fields field : EnumSet.allOf(_Fields.class)) {
-        byName.put(field.getFieldName(), field);
-      }
-    }
-
-    /**
-     * Find the _Fields constant that matches fieldId, or null if its not found.
-     */
-    public static _Fields findByThriftId(int fieldId) {
-      switch(fieldId) {
-        case 1: // MESSAGE
-          return MESSAGE;
-        default:
-          return null;
-      }
-    }
-
-    /**
-     * Find the _Fields constant that matches fieldId, throwing an exception
-     * if it is not found.
-     */
-    public static _Fields findByThriftIdOrThrow(int fieldId) {
-      _Fields fields = findByThriftId(fieldId);
-      if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-      return fields;
-    }
-
-    /**
-     * Find the _Fields constant that matches name, or null if its not found.
-     */
-    public static _Fields findByName(String name) {
-      return byName.get(name);
-    }
-
-    private final short _thriftId;
-    private final String _fieldName;
-
-    _Fields(short thriftId, String fieldName) {
-      _thriftId = thriftId;
-      _fieldName = fieldName;
-    }
-
-    public short getThriftFieldId() {
-      return _thriftId;
-    }
-
-    public String getFieldName() {
-      return _fieldName;
-    }
-  }
-
-  // isset id assignments
-  public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-  static {
-    Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-    tmpMap.put(_Fields.MESSAGE, new org.apache.thrift.meta_data.FieldMetaData("message", org.apache.thrift.TFieldRequirementType.REQUIRED, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    metaDataMap = Collections.unmodifiableMap(tmpMap);
-    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(CredentialStoreException.class, metaDataMap);
-  }
-
-  public CredentialStoreException() {
-  }
-
-  public CredentialStoreException(
-    String message)
-  {
-    this();
-    this.message = message;
-  }
-
-  /**
-   * Performs a deep copy on <i>other</i>.
-   */
-  public CredentialStoreException(CredentialStoreException other) {
-    if (other.isSetMessage()) {
-      this.message = other.message;
-    }
-  }
-
-  public CredentialStoreException deepCopy() {
-    return new CredentialStoreException(this);
-  }
-
-  @Override
-  public void clear() {
-    this.message = null;
-  }
-
-  public String getMessage() {
-    return this.message;
-  }
-
-  public CredentialStoreException setMessage(String message) {
-    this.message = message;
-    return this;
-  }
-
-  public void unsetMessage() {
-    this.message = null;
-  }
-
-  /** Returns true if field message is set (has been assigned a value) and false otherwise */
-  public boolean isSetMessage() {
-    return this.message != null;
-  }
-
-  public void setMessageIsSet(boolean value) {
-    if (!value) {
-      this.message = null;
-    }
-  }
-
-  public void setFieldValue(_Fields field, Object value) {
-    switch (field) {
-    case MESSAGE:
-      if (value == null) {
-        unsetMessage();
-      } else {
-        setMessage((String)value);
-      }
-      break;
-
-    }
-  }
-
-  public Object getFieldValue(_Fields field) {
-    switch (field) {
-    case MESSAGE:
-      return getMessage();
-
-    }
-    throw new IllegalStateException();
-  }
-
-  /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-  public boolean isSet(_Fields field) {
-    if (field == null) {
-      throw new IllegalArgumentException();
-    }
-
-    switch (field) {
-    case MESSAGE:
-      return isSetMessage();
-    }
-    throw new IllegalStateException();
-  }
-
-  @Override
-  public boolean equals(Object that) {
-    if (that == null)
-      return false;
-    if (that instanceof CredentialStoreException)
-      return this.equals((CredentialStoreException)that);
-    return false;
-  }
-
-  public boolean equals(CredentialStoreException that) {
-    if (that == null)
-      return false;
-
-    boolean this_present_message = true && this.isSetMessage();
-    boolean that_present_message = true && that.isSetMessage();
-    if (this_present_message || that_present_message) {
-      if (!(this_present_message && that_present_message))
-        return false;
-      if (!this.message.equals(that.message))
-        return false;
-    }
-
-    return true;
-  }
-
-  @Override
-  public int hashCode() {
-    return 0;
-  }
-
-  @Override
-  public int compareTo(CredentialStoreException other) {
-    if (!getClass().equals(other.getClass())) {
-      return getClass().getName().compareTo(other.getClass().getName());
-    }
-
-    int lastComparison = 0;
-
-    lastComparison = Boolean.valueOf(isSetMessage()).compareTo(other.isSetMessage());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetMessage()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.message, other.message);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    return 0;
-  }
-
-  public _Fields fieldForId(int fieldId) {
-    return _Fields.findByThriftId(fieldId);
-  }
-
-  public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-    schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
-  }
-
-  public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-    schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
-  }
-
-  @Override
-  public String toString() {
-    StringBuilder sb = new StringBuilder("CredentialStoreException(");
-    boolean first = true;
-
-    sb.append("message:");
-    if (this.message == null) {
-      sb.append("null");
-    } else {
-      sb.append(this.message);
-    }
-    first = false;
-    sb.append(")");
-    return sb.toString();
-  }
-
-  public void validate() throws org.apache.thrift.TException {
-    // check for required fields
-    if (message == null) {
-      throw new org.apache.thrift.protocol.TProtocolException("Required field 'message' was not present! Struct: " + toString());
-    }
-    // check for sub-struct validity
-  }
-
-  private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-    try {
-      write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-    } catch (org.apache.thrift.TException te) {
-      throw new java.io.IOException(te);
-    }
-  }
-
-  private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-    try {
-      read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-    } catch (org.apache.thrift.TException te) {
-      throw new java.io.IOException(te);
-    }
-  }
-
-  private static class CredentialStoreExceptionStandardSchemeFactory implements SchemeFactory {
-    public CredentialStoreExceptionStandardScheme getScheme() {
-      return new CredentialStoreExceptionStandardScheme();
-    }
-  }
-
-  private static class CredentialStoreExceptionStandardScheme extends StandardScheme<CredentialStoreException> {
-
-    public void read(org.apache.thrift.protocol.TProtocol iprot, CredentialStoreException struct) throws org.apache.thrift.TException {
-      org.apache.thrift.protocol.TField schemeField;
-      iprot.readStructBegin();
-      while (true)
-      {
-        schemeField = iprot.readFieldBegin();
-        if (schemeField.type == org.apache.thrift.protocol.TType.STOP) { 
-          break;
-        }
-        switch (schemeField.id) {
-          case 1: // MESSAGE
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.message = iprot.readString();
-              struct.setMessageIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          default:
-            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-        }
-        iprot.readFieldEnd();
-      }
-      iprot.readStructEnd();
-
-      // check for required fields of primitive type, which can't be checked in the validate method
-      struct.validate();
-    }
-
-    public void write(org.apache.thrift.protocol.TProtocol oprot, CredentialStoreException struct) throws org.apache.thrift.TException {
-      struct.validate();
-
-      oprot.writeStructBegin(STRUCT_DESC);
-      if (struct.message != null) {
-        oprot.writeFieldBegin(MESSAGE_FIELD_DESC);
-        oprot.writeString(struct.message);
-        oprot.writeFieldEnd();
-      }
-      oprot.writeFieldStop();
-      oprot.writeStructEnd();
-    }
-
-  }
-
-  private static class CredentialStoreExceptionTupleSchemeFactory implements SchemeFactory {
-    public CredentialStoreExceptionTupleScheme getScheme() {
-      return new CredentialStoreExceptionTupleScheme();
-    }
-  }
-
-  private static class CredentialStoreExceptionTupleScheme extends TupleScheme<CredentialStoreException> {
-
-    @Override
-    public void write(org.apache.thrift.protocol.TProtocol prot, CredentialStoreException struct) throws org.apache.thrift.TException {
-      TTupleProtocol oprot = (TTupleProtocol) prot;
-      oprot.writeString(struct.message);
-    }
-
-    @Override
-    public void read(org.apache.thrift.protocol.TProtocol prot, CredentialStoreException struct) throws org.apache.thrift.TException {
-      TTupleProtocol iprot = (TTupleProtocol) prot;
-      struct.message = iprot.readString();
-      struct.setMessageIsSet(true);
-    }
-  }
-
-}
-

http://git-wip-us.apache.org/repos/asf/airavata/blob/b25e0a5d/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/server/CredentialStoreServer.java
----------------------------------------------------------------------
diff --git a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/server/CredentialStoreServer.java b/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/server/CredentialStoreServer.java
index f0e14d5..ebed9a1 100644
--- a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/server/CredentialStoreServer.java
+++ b/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/server/CredentialStoreServer.java
@@ -67,8 +67,8 @@ public class CredentialStoreServer  implements IServer {
                         new TSSLTransportFactory.TSSLTransportParameters();
                 String keystorePath = ServerSettings.getCredentialStoreThriftServerKeyStorePath();
                 String keystorePWD = ServerSettings.getCredentialStoreThriftServerKeyStorePassword();
-                final int serverPort = Integer.parseInt(ServerSettings.getSetting(Constants.CREDNETIAL_SERVER_PORT, "8960"));
-                final String serverHost = ServerSettings.getSetting(Constants.CREDNETIAL_SERVER_HOST, null);
+                final int serverPort = Integer.parseInt(ServerSettings.getSetting(Constants.CREDENTIAL_SERVER_PORT, "8960"));
+                final String serverHost = ServerSettings.getSetting(Constants.CREDENTIAL_SERVER_HOST, null);
                 params.setKeyStore(keystorePath, keystorePWD);
 
                 TServerSocket serverTransport = TSSLTransportFactory.getServerSocket(serverPort, 100, InetAddress.getByName(serverHost), params);

http://git-wip-us.apache.org/repos/asf/airavata/blob/b25e0a5d/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/server/CredentialStoreServerHandler.java
----------------------------------------------------------------------
diff --git a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/server/CredentialStoreServerHandler.java b/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/server/CredentialStoreServerHandler.java
index b5b1ac0..8205a22 100644
--- a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/server/CredentialStoreServerHandler.java
+++ b/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/server/CredentialStoreServerHandler.java
@@ -24,7 +24,7 @@ import org.apache.airavata.common.exception.ApplicationSettingsException;
 import org.apache.airavata.common.utils.DBUtil;
 import org.apache.airavata.common.utils.ServerSettings;
 import org.apache.airavata.credential.store.cpi.CredentialStoreService;
-import org.apache.airavata.credential.store.cpi.cs_cpi_serviceConstants;
+import org.apache.airavata.credential.store.cpi.credentialStoreCPIConstants;
 import org.apache.airavata.credential.store.credential.CommunityUser;
 import org.apache.airavata.credential.store.credential.Credential;
 import org.apache.airavata.credential.store.datamodel.CertificateCredential;
@@ -69,7 +69,7 @@ public class CredentialStoreServerHandler implements CredentialStoreService.Ifac
 
     @Override
     public String getCSServiceVersion() throws TException {
-        return cs_cpi_serviceConstants.CS_CPI_VERSION;
+        return credentialStoreCPIConstants.CS_CPI_VERSION;
     }
 
     @Override
@@ -107,9 +107,9 @@ public class CredentialStoreServerHandler implements CredentialStoreService.Ifac
         try {
             org.apache.airavata.credential.store.credential.impl.certificate.CertificateCredential credential = new org.apache.airavata.credential.store.credential.impl.certificate.CertificateCredential();
             credential.setPortalUserName(certificateCredential.getCommunityUser().getUsername());
-            credential.setCommunityUser(new CommunityUser(certificateCredential.getCommunityUser().getGatewayNmae(),
+            credential.setCommunityUser(new CommunityUser(certificateCredential.getCommunityUser().getGatewayName(),
                     certificateCredential.getCommunityUser().getUsername(), certificateCredential.getCommunityUser().getUserEmail()));
-            String token = TokenGenerator.generateToken(certificateCredential.getCommunityUser().getGatewayNmae(), null);
+            String token = TokenGenerator.generateToken(certificateCredential.getCommunityUser().getGatewayName(), null);
             credential.setToken(token);
             Base64 encoder = new Base64(64);
             byte [] decoded = encoder.decode(certificateCredential.getX509Cert().replaceAll(X509Factory.BEGIN_CERT, "").replaceAll(X509Factory.END_CERT, ""));
@@ -168,7 +168,7 @@ public class CredentialStoreServerHandler implements CredentialStoreService.Ifac
                 org.apache.airavata.credential.store.credential.impl.certificate.CertificateCredential credential1 = (org.apache.airavata.credential.store.credential.impl.certificate.CertificateCredential) credential;
                 CertificateCredential certificateCredential = new CertificateCredential();
                 org.apache.airavata.credential.store.datamodel.CommunityUser communityUser = new org.apache.airavata.credential.store.datamodel.CommunityUser();
-                communityUser.setGatewayNmae(credential1.getCommunityUser().getGatewayName());
+                communityUser.setGatewayName(credential1.getCommunityUser().getGatewayName());
                 communityUser.setUsername(credential1.getCommunityUser().getUserName());
                 communityUser.setUserEmail(credential1.getCommunityUser().getUserEmail());
                 certificateCredential.setCommunityUser(communityUser);


[3/4] airavata git commit: Reorganizing duplicate generated classed and instead using the stubs artifact - AIRAVATA-1621

Posted by sm...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/b25e0a5d/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/cpi/CredentialStoreService.java
----------------------------------------------------------------------
diff --git a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/cpi/CredentialStoreService.java b/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/cpi/CredentialStoreService.java
deleted file mode 100644
index 5d9c05c..0000000
--- a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/cpi/CredentialStoreService.java
+++ /dev/null
@@ -1,6888 +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.
-     */
-/**
- * Autogenerated by Thrift Compiler (0.9.1)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- *  @generated
- */
-package org.apache.airavata.credential.store.cpi;
-
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-import org.apache.thrift.protocol.TTupleProtocol;
-import org.apache.thrift.protocol.TProtocolException;
-import org.apache.thrift.EncodingUtils;
-import org.apache.thrift.TException;
-import org.apache.thrift.async.AsyncMethodCallback;
-import org.apache.thrift.server.AbstractNonblockingServer.*;
-import java.util.List;
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-import java.util.Collections;
-import java.util.BitSet;
-import java.nio.ByteBuffer;
-import java.util.Arrays;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings("all") public class CredentialStoreService {
-
-  public interface Iface {
-
-    /**
-     * Query CS server to fetch the CPI version
-     */
-    public String getCSServiceVersion() throws org.apache.thrift.TException;
-
-    /**
-     * This method is to add SSHCredential which will return the token Id in success
-     * 
-     * 
-     * @param sshCredential
-     */
-    public String addSSHCredential(org.apache.airavata.credential.store.datamodel.SSHCredential sshCredential) throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException;
-
-    public String addCertificateCredential(org.apache.airavata.credential.store.datamodel.CertificateCredential certificateCredential) throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException;
-
-    public String addPasswordCredential(org.apache.airavata.credential.store.datamodel.PasswordCredential passwordCredential) throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException;
-
-    public org.apache.airavata.credential.store.datamodel.SSHCredential getSSHCredential(String tokenId, String gatewayId) throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException;
-
-    public org.apache.airavata.credential.store.datamodel.CertificateCredential getCertificateCredential(String tokenId, String gatewayId) throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException;
-
-    public org.apache.airavata.credential.store.datamodel.PasswordCredential getPasswordCredential(String tokenId, String gatewayId) throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException;
-
-  }
-
-  public interface AsyncIface {
-
-    public void getCSServiceVersion(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
-
-    public void addSSHCredential(org.apache.airavata.credential.store.datamodel.SSHCredential sshCredential, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
-
-    public void addCertificateCredential(org.apache.airavata.credential.store.datamodel.CertificateCredential certificateCredential, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
-
-    public void addPasswordCredential(org.apache.airavata.credential.store.datamodel.PasswordCredential passwordCredential, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
-
-    public void getSSHCredential(String tokenId, String gatewayId, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
-
-    public void getCertificateCredential(String tokenId, String gatewayId, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
-
-    public void getPasswordCredential(String tokenId, String gatewayId, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
-
-  }
-
-  public static class Client extends org.apache.thrift.TServiceClient implements Iface {
-    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
-      public Factory() {}
-      public Client getClient(org.apache.thrift.protocol.TProtocol prot) {
-        return new Client(prot);
-      }
-      public Client getClient(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
-        return new Client(iprot, oprot);
-      }
-    }
-
-    public Client(org.apache.thrift.protocol.TProtocol prot)
-    {
-      super(prot, prot);
-    }
-
-    public Client(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
-      super(iprot, oprot);
-    }
-
-    public String getCSServiceVersion() throws org.apache.thrift.TException
-    {
-      send_getCSServiceVersion();
-      return recv_getCSServiceVersion();
-    }
-
-    public void send_getCSServiceVersion() throws org.apache.thrift.TException
-    {
-      getCSServiceVersion_args args = new getCSServiceVersion_args();
-      sendBase("getCSServiceVersion", args);
-    }
-
-    public String recv_getCSServiceVersion() throws org.apache.thrift.TException
-    {
-      getCSServiceVersion_result result = new getCSServiceVersion_result();
-      receiveBase(result, "getCSServiceVersion");
-      if (result.isSetSuccess()) {
-        return result.success;
-      }
-      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getCSServiceVersion failed: unknown result");
-    }
-
-    public String addSSHCredential(org.apache.airavata.credential.store.datamodel.SSHCredential sshCredential) throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException
-    {
-      send_addSSHCredential(sshCredential);
-      return recv_addSSHCredential();
-    }
-
-    public void send_addSSHCredential(org.apache.airavata.credential.store.datamodel.SSHCredential sshCredential) throws org.apache.thrift.TException
-    {
-      addSSHCredential_args args = new addSSHCredential_args();
-      args.setSshCredential(sshCredential);
-      sendBase("addSSHCredential", args);
-    }
-
-    public String recv_addSSHCredential() throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException
-    {
-      addSSHCredential_result result = new addSSHCredential_result();
-      receiveBase(result, "addSSHCredential");
-      if (result.isSetSuccess()) {
-        return result.success;
-      }
-      if (result.csException != null) {
-        throw result.csException;
-      }
-      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "addSSHCredential failed: unknown result");
-    }
-
-    public String addCertificateCredential(org.apache.airavata.credential.store.datamodel.CertificateCredential certificateCredential) throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException
-    {
-      send_addCertificateCredential(certificateCredential);
-      return recv_addCertificateCredential();
-    }
-
-    public void send_addCertificateCredential(org.apache.airavata.credential.store.datamodel.CertificateCredential certificateCredential) throws org.apache.thrift.TException
-    {
-      addCertificateCredential_args args = new addCertificateCredential_args();
-      args.setCertificateCredential(certificateCredential);
-      sendBase("addCertificateCredential", args);
-    }
-
-    public String recv_addCertificateCredential() throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException
-    {
-      addCertificateCredential_result result = new addCertificateCredential_result();
-      receiveBase(result, "addCertificateCredential");
-      if (result.isSetSuccess()) {
-        return result.success;
-      }
-      if (result.csException != null) {
-        throw result.csException;
-      }
-      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "addCertificateCredential failed: unknown result");
-    }
-
-    public String addPasswordCredential(org.apache.airavata.credential.store.datamodel.PasswordCredential passwordCredential) throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException
-    {
-      send_addPasswordCredential(passwordCredential);
-      return recv_addPasswordCredential();
-    }
-
-    public void send_addPasswordCredential(org.apache.airavata.credential.store.datamodel.PasswordCredential passwordCredential) throws org.apache.thrift.TException
-    {
-      addPasswordCredential_args args = new addPasswordCredential_args();
-      args.setPasswordCredential(passwordCredential);
-      sendBase("addPasswordCredential", args);
-    }
-
-    public String recv_addPasswordCredential() throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException
-    {
-      addPasswordCredential_result result = new addPasswordCredential_result();
-      receiveBase(result, "addPasswordCredential");
-      if (result.isSetSuccess()) {
-        return result.success;
-      }
-      if (result.csException != null) {
-        throw result.csException;
-      }
-      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "addPasswordCredential failed: unknown result");
-    }
-
-    public org.apache.airavata.credential.store.datamodel.SSHCredential getSSHCredential(String tokenId, String gatewayId) throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException
-    {
-      send_getSSHCredential(tokenId, gatewayId);
-      return recv_getSSHCredential();
-    }
-
-    public void send_getSSHCredential(String tokenId, String gatewayId) throws org.apache.thrift.TException
-    {
-      getSSHCredential_args args = new getSSHCredential_args();
-      args.setTokenId(tokenId);
-      args.setGatewayId(gatewayId);
-      sendBase("getSSHCredential", args);
-    }
-
-    public org.apache.airavata.credential.store.datamodel.SSHCredential recv_getSSHCredential() throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException
-    {
-      getSSHCredential_result result = new getSSHCredential_result();
-      receiveBase(result, "getSSHCredential");
-      if (result.isSetSuccess()) {
-        return result.success;
-      }
-      if (result.csException != null) {
-        throw result.csException;
-      }
-      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getSSHCredential failed: unknown result");
-    }
-
-    public org.apache.airavata.credential.store.datamodel.CertificateCredential getCertificateCredential(String tokenId, String gatewayId) throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException
-    {
-      send_getCertificateCredential(tokenId, gatewayId);
-      return recv_getCertificateCredential();
-    }
-
-    public void send_getCertificateCredential(String tokenId, String gatewayId) throws org.apache.thrift.TException
-    {
-      getCertificateCredential_args args = new getCertificateCredential_args();
-      args.setTokenId(tokenId);
-      args.setGatewayId(gatewayId);
-      sendBase("getCertificateCredential", args);
-    }
-
-    public org.apache.airavata.credential.store.datamodel.CertificateCredential recv_getCertificateCredential() throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException
-    {
-      getCertificateCredential_result result = new getCertificateCredential_result();
-      receiveBase(result, "getCertificateCredential");
-      if (result.isSetSuccess()) {
-        return result.success;
-      }
-      if (result.csException != null) {
-        throw result.csException;
-      }
-      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getCertificateCredential failed: unknown result");
-    }
-
-    public org.apache.airavata.credential.store.datamodel.PasswordCredential getPasswordCredential(String tokenId, String gatewayId) throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException
-    {
-      send_getPasswordCredential(tokenId, gatewayId);
-      return recv_getPasswordCredential();
-    }
-
-    public void send_getPasswordCredential(String tokenId, String gatewayId) throws org.apache.thrift.TException
-    {
-      getPasswordCredential_args args = new getPasswordCredential_args();
-      args.setTokenId(tokenId);
-      args.setGatewayId(gatewayId);
-      sendBase("getPasswordCredential", args);
-    }
-
-    public org.apache.airavata.credential.store.datamodel.PasswordCredential recv_getPasswordCredential() throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException
-    {
-      getPasswordCredential_result result = new getPasswordCredential_result();
-      receiveBase(result, "getPasswordCredential");
-      if (result.isSetSuccess()) {
-        return result.success;
-      }
-      if (result.csException != null) {
-        throw result.csException;
-      }
-      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPasswordCredential failed: unknown result");
-    }
-
-  }
-  public static class AsyncClient extends org.apache.thrift.async.TAsyncClient implements AsyncIface {
-    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
-      private org.apache.thrift.async.TAsyncClientManager clientManager;
-      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
-      public Factory(org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.protocol.TProtocolFactory protocolFactory) {
-        this.clientManager = clientManager;
-        this.protocolFactory = protocolFactory;
-      }
-      public AsyncClient getAsyncClient(org.apache.thrift.transport.TNonblockingTransport transport) {
-        return new AsyncClient(protocolFactory, clientManager, transport);
-      }
-    }
-
-    public AsyncClient(org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.transport.TNonblockingTransport transport) {
-      super(protocolFactory, clientManager, transport);
-    }
-
-    public void getCSServiceVersion(org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
-      checkReady();
-      getCSServiceVersion_call method_call = new getCSServiceVersion_call(resultHandler, this, ___protocolFactory, ___transport);
-      this.___currentMethod = method_call;
-      ___manager.call(method_call);
-    }
-
-    public static class getCSServiceVersion_call extends org.apache.thrift.async.TAsyncMethodCall {
-      public getCSServiceVersion_call(org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
-        super(client, protocolFactory, transport, resultHandler, false);
-      }
-
-      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
-        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getCSServiceVersion", org.apache.thrift.protocol.TMessageType.CALL, 0));
-        getCSServiceVersion_args args = new getCSServiceVersion_args();
-        args.write(prot);
-        prot.writeMessageEnd();
-      }
-
-      public String getResult() throws org.apache.thrift.TException {
-        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
-          throw new IllegalStateException("Method call not finished!");
-        }
-        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
-        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
-        return (new Client(prot)).recv_getCSServiceVersion();
-      }
-    }
-
-    public void addSSHCredential(org.apache.airavata.credential.store.datamodel.SSHCredential sshCredential, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
-      checkReady();
-      addSSHCredential_call method_call = new addSSHCredential_call(sshCredential, resultHandler, this, ___protocolFactory, ___transport);
-      this.___currentMethod = method_call;
-      ___manager.call(method_call);
-    }
-
-    public static class addSSHCredential_call extends org.apache.thrift.async.TAsyncMethodCall {
-      private org.apache.airavata.credential.store.datamodel.SSHCredential sshCredential;
-      public addSSHCredential_call(org.apache.airavata.credential.store.datamodel.SSHCredential sshCredential, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
-        super(client, protocolFactory, transport, resultHandler, false);
-        this.sshCredential = sshCredential;
-      }
-
-      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
-        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addSSHCredential", org.apache.thrift.protocol.TMessageType.CALL, 0));
-        addSSHCredential_args args = new addSSHCredential_args();
-        args.setSshCredential(sshCredential);
-        args.write(prot);
-        prot.writeMessageEnd();
-      }
-
-      public String getResult() throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException {
-        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
-          throw new IllegalStateException("Method call not finished!");
-        }
-        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
-        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
-        return (new Client(prot)).recv_addSSHCredential();
-      }
-    }
-
-    public void addCertificateCredential(org.apache.airavata.credential.store.datamodel.CertificateCredential certificateCredential, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
-      checkReady();
-      addCertificateCredential_call method_call = new addCertificateCredential_call(certificateCredential, resultHandler, this, ___protocolFactory, ___transport);
-      this.___currentMethod = method_call;
-      ___manager.call(method_call);
-    }
-
-    public static class addCertificateCredential_call extends org.apache.thrift.async.TAsyncMethodCall {
-      private org.apache.airavata.credential.store.datamodel.CertificateCredential certificateCredential;
-      public addCertificateCredential_call(org.apache.airavata.credential.store.datamodel.CertificateCredential certificateCredential, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
-        super(client, protocolFactory, transport, resultHandler, false);
-        this.certificateCredential = certificateCredential;
-      }
-
-      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
-        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addCertificateCredential", org.apache.thrift.protocol.TMessageType.CALL, 0));
-        addCertificateCredential_args args = new addCertificateCredential_args();
-        args.setCertificateCredential(certificateCredential);
-        args.write(prot);
-        prot.writeMessageEnd();
-      }
-
-      public String getResult() throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException {
-        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
-          throw new IllegalStateException("Method call not finished!");
-        }
-        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
-        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
-        return (new Client(prot)).recv_addCertificateCredential();
-      }
-    }
-
-    public void addPasswordCredential(org.apache.airavata.credential.store.datamodel.PasswordCredential passwordCredential, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
-      checkReady();
-      addPasswordCredential_call method_call = new addPasswordCredential_call(passwordCredential, resultHandler, this, ___protocolFactory, ___transport);
-      this.___currentMethod = method_call;
-      ___manager.call(method_call);
-    }
-
-    public static class addPasswordCredential_call extends org.apache.thrift.async.TAsyncMethodCall {
-      private org.apache.airavata.credential.store.datamodel.PasswordCredential passwordCredential;
-      public addPasswordCredential_call(org.apache.airavata.credential.store.datamodel.PasswordCredential passwordCredential, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
-        super(client, protocolFactory, transport, resultHandler, false);
-        this.passwordCredential = passwordCredential;
-      }
-
-      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
-        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addPasswordCredential", org.apache.thrift.protocol.TMessageType.CALL, 0));
-        addPasswordCredential_args args = new addPasswordCredential_args();
-        args.setPasswordCredential(passwordCredential);
-        args.write(prot);
-        prot.writeMessageEnd();
-      }
-
-      public String getResult() throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException {
-        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
-          throw new IllegalStateException("Method call not finished!");
-        }
-        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
-        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
-        return (new Client(prot)).recv_addPasswordCredential();
-      }
-    }
-
-    public void getSSHCredential(String tokenId, String gatewayId, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
-      checkReady();
-      getSSHCredential_call method_call = new getSSHCredential_call(tokenId, gatewayId, resultHandler, this, ___protocolFactory, ___transport);
-      this.___currentMethod = method_call;
-      ___manager.call(method_call);
-    }
-
-    public static class getSSHCredential_call extends org.apache.thrift.async.TAsyncMethodCall {
-      private String tokenId;
-      private String gatewayId;
-      public getSSHCredential_call(String tokenId, String gatewayId, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
-        super(client, protocolFactory, transport, resultHandler, false);
-        this.tokenId = tokenId;
-        this.gatewayId = gatewayId;
-      }
-
-      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
-        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getSSHCredential", org.apache.thrift.protocol.TMessageType.CALL, 0));
-        getSSHCredential_args args = new getSSHCredential_args();
-        args.setTokenId(tokenId);
-        args.setGatewayId(gatewayId);
-        args.write(prot);
-        prot.writeMessageEnd();
-      }
-
-      public org.apache.airavata.credential.store.datamodel.SSHCredential getResult() throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException {
-        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
-          throw new IllegalStateException("Method call not finished!");
-        }
-        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
-        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
-        return (new Client(prot)).recv_getSSHCredential();
-      }
-    }
-
-    public void getCertificateCredential(String tokenId, String gatewayId, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
-      checkReady();
-      getCertificateCredential_call method_call = new getCertificateCredential_call(tokenId, gatewayId, resultHandler, this, ___protocolFactory, ___transport);
-      this.___currentMethod = method_call;
-      ___manager.call(method_call);
-    }
-
-    public static class getCertificateCredential_call extends org.apache.thrift.async.TAsyncMethodCall {
-      private String tokenId;
-      private String gatewayId;
-      public getCertificateCredential_call(String tokenId, String gatewayId, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
-        super(client, protocolFactory, transport, resultHandler, false);
-        this.tokenId = tokenId;
-        this.gatewayId = gatewayId;
-      }
-
-      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
-        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getCertificateCredential", org.apache.thrift.protocol.TMessageType.CALL, 0));
-        getCertificateCredential_args args = new getCertificateCredential_args();
-        args.setTokenId(tokenId);
-        args.setGatewayId(gatewayId);
-        args.write(prot);
-        prot.writeMessageEnd();
-      }
-
-      public org.apache.airavata.credential.store.datamodel.CertificateCredential getResult() throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException {
-        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
-          throw new IllegalStateException("Method call not finished!");
-        }
-        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
-        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
-        return (new Client(prot)).recv_getCertificateCredential();
-      }
-    }
-
-    public void getPasswordCredential(String tokenId, String gatewayId, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
-      checkReady();
-      getPasswordCredential_call method_call = new getPasswordCredential_call(tokenId, gatewayId, resultHandler, this, ___protocolFactory, ___transport);
-      this.___currentMethod = method_call;
-      ___manager.call(method_call);
-    }
-
-    public static class getPasswordCredential_call extends org.apache.thrift.async.TAsyncMethodCall {
-      private String tokenId;
-      private String gatewayId;
-      public getPasswordCredential_call(String tokenId, String gatewayId, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
-        super(client, protocolFactory, transport, resultHandler, false);
-        this.tokenId = tokenId;
-        this.gatewayId = gatewayId;
-      }
-
-      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
-        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPasswordCredential", org.apache.thrift.protocol.TMessageType.CALL, 0));
-        getPasswordCredential_args args = new getPasswordCredential_args();
-        args.setTokenId(tokenId);
-        args.setGatewayId(gatewayId);
-        args.write(prot);
-        prot.writeMessageEnd();
-      }
-
-      public org.apache.airavata.credential.store.datamodel.PasswordCredential getResult() throws org.apache.airavata.credential.store.exception.CredentialStoreException, org.apache.thrift.TException {
-        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
-          throw new IllegalStateException("Method call not finished!");
-        }
-        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
-        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
-        return (new Client(prot)).recv_getPasswordCredential();
-      }
-    }
-
-  }
-
-  public static class Processor<I extends Iface> extends org.apache.thrift.TBaseProcessor<I> implements org.apache.thrift.TProcessor {
-    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
-    public Processor(I iface) {
-      super(iface, getProcessMap(new HashMap<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));
-    }
-
-    protected Processor(I iface, Map<String,  org.apache.thrift.ProcessFunction<I, ? extends  org.apache.thrift.TBase>> processMap) {
-      super(iface, getProcessMap(processMap));
-    }
-
-    private static <I extends Iface> Map<String,  org.apache.thrift.ProcessFunction<I, ? extends  org.apache.thrift.TBase>> getProcessMap(Map<String,  org.apache.thrift.ProcessFunction<I, ? extends  org.apache.thrift.TBase>> processMap) {
-      processMap.put("getCSServiceVersion", new getCSServiceVersion());
-      processMap.put("addSSHCredential", new addSSHCredential());
-      processMap.put("addCertificateCredential", new addCertificateCredential());
-      processMap.put("addPasswordCredential", new addPasswordCredential());
-      processMap.put("getSSHCredential", new getSSHCredential());
-      processMap.put("getCertificateCredential", new getCertificateCredential());
-      processMap.put("getPasswordCredential", new getPasswordCredential());
-      return processMap;
-    }
-
-    public static class getCSServiceVersion<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getCSServiceVersion_args> {
-      public getCSServiceVersion() {
-        super("getCSServiceVersion");
-      }
-
-      public getCSServiceVersion_args getEmptyArgsInstance() {
-        return new getCSServiceVersion_args();
-      }
-
-      protected boolean isOneway() {
-        return false;
-      }
-
-      public getCSServiceVersion_result getResult(I iface, getCSServiceVersion_args args) throws org.apache.thrift.TException {
-        getCSServiceVersion_result result = new getCSServiceVersion_result();
-        result.success = iface.getCSServiceVersion();
-        return result;
-      }
-    }
-
-    public static class addSSHCredential<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addSSHCredential_args> {
-      public addSSHCredential() {
-        super("addSSHCredential");
-      }
-
-      public addSSHCredential_args getEmptyArgsInstance() {
-        return new addSSHCredential_args();
-      }
-
-      protected boolean isOneway() {
-        return false;
-      }
-
-      public addSSHCredential_result getResult(I iface, addSSHCredential_args args) throws org.apache.thrift.TException {
-        addSSHCredential_result result = new addSSHCredential_result();
-        try {
-          result.success = iface.addSSHCredential(args.sshCredential);
-        } catch (org.apache.airavata.credential.store.exception.CredentialStoreException csException) {
-          result.csException = csException;
-        }
-        return result;
-      }
-    }
-
-    public static class addCertificateCredential<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addCertificateCredential_args> {
-      public addCertificateCredential() {
-        super("addCertificateCredential");
-      }
-
-      public addCertificateCredential_args getEmptyArgsInstance() {
-        return new addCertificateCredential_args();
-      }
-
-      protected boolean isOneway() {
-        return false;
-      }
-
-      public addCertificateCredential_result getResult(I iface, addCertificateCredential_args args) throws org.apache.thrift.TException {
-        addCertificateCredential_result result = new addCertificateCredential_result();
-        try {
-          result.success = iface.addCertificateCredential(args.certificateCredential);
-        } catch (org.apache.airavata.credential.store.exception.CredentialStoreException csException) {
-          result.csException = csException;
-        }
-        return result;
-      }
-    }
-
-    public static class addPasswordCredential<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addPasswordCredential_args> {
-      public addPasswordCredential() {
-        super("addPasswordCredential");
-      }
-
-      public addPasswordCredential_args getEmptyArgsInstance() {
-        return new addPasswordCredential_args();
-      }
-
-      protected boolean isOneway() {
-        return false;
-      }
-
-      public addPasswordCredential_result getResult(I iface, addPasswordCredential_args args) throws org.apache.thrift.TException {
-        addPasswordCredential_result result = new addPasswordCredential_result();
-        try {
-          result.success = iface.addPasswordCredential(args.passwordCredential);
-        } catch (org.apache.airavata.credential.store.exception.CredentialStoreException csException) {
-          result.csException = csException;
-        }
-        return result;
-      }
-    }
-
-    public static class getSSHCredential<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getSSHCredential_args> {
-      public getSSHCredential() {
-        super("getSSHCredential");
-      }
-
-      public getSSHCredential_args getEmptyArgsInstance() {
-        return new getSSHCredential_args();
-      }
-
-      protected boolean isOneway() {
-        return false;
-      }
-
-      public getSSHCredential_result getResult(I iface, getSSHCredential_args args) throws org.apache.thrift.TException {
-        getSSHCredential_result result = new getSSHCredential_result();
-        try {
-          result.success = iface.getSSHCredential(args.tokenId, args.gatewayId);
-        } catch (org.apache.airavata.credential.store.exception.CredentialStoreException csException) {
-          result.csException = csException;
-        }
-        return result;
-      }
-    }
-
-    public static class getCertificateCredential<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getCertificateCredential_args> {
-      public getCertificateCredential() {
-        super("getCertificateCredential");
-      }
-
-      public getCertificateCredential_args getEmptyArgsInstance() {
-        return new getCertificateCredential_args();
-      }
-
-      protected boolean isOneway() {
-        return false;
-      }
-
-      public getCertificateCredential_result getResult(I iface, getCertificateCredential_args args) throws org.apache.thrift.TException {
-        getCertificateCredential_result result = new getCertificateCredential_result();
-        try {
-          result.success = iface.getCertificateCredential(args.tokenId, args.gatewayId);
-        } catch (org.apache.airavata.credential.store.exception.CredentialStoreException csException) {
-          result.csException = csException;
-        }
-        return result;
-      }
-    }
-
-    public static class getPasswordCredential<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPasswordCredential_args> {
-      public getPasswordCredential() {
-        super("getPasswordCredential");
-      }
-
-      public getPasswordCredential_args getEmptyArgsInstance() {
-        return new getPasswordCredential_args();
-      }
-
-      protected boolean isOneway() {
-        return false;
-      }
-
-      public getPasswordCredential_result getResult(I iface, getPasswordCredential_args args) throws org.apache.thrift.TException {
-        getPasswordCredential_result result = new getPasswordCredential_result();
-        try {
-          result.success = iface.getPasswordCredential(args.tokenId, args.gatewayId);
-        } catch (org.apache.airavata.credential.store.exception.CredentialStoreException csException) {
-          result.csException = csException;
-        }
-        return result;
-      }
-    }
-
-  }
-
-  public static class AsyncProcessor<I extends AsyncIface> extends org.apache.thrift.TBaseAsyncProcessor<I> {
-    private static final Logger LOGGER = LoggerFactory.getLogger(AsyncProcessor.class.getName());
-    public AsyncProcessor(I iface) {
-      super(iface, getProcessMap(new HashMap<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase, ?>>()));
-    }
-
-    protected AsyncProcessor(I iface, Map<String,  org.apache.thrift.AsyncProcessFunction<I, ? extends  org.apache.thrift.TBase, ?>> processMap) {
-      super(iface, getProcessMap(processMap));
-    }
-
-    private static <I extends AsyncIface> Map<String,  org.apache.thrift.AsyncProcessFunction<I, ? extends  org.apache.thrift.TBase,?>> getProcessMap(Map<String,  org.apache.thrift.AsyncProcessFunction<I, ? extends  org.apache.thrift.TBase, ?>> processMap) {
-      processMap.put("getCSServiceVersion", new getCSServiceVersion());
-      processMap.put("addSSHCredential", new addSSHCredential());
-      processMap.put("addCertificateCredential", new addCertificateCredential());
-      processMap.put("addPasswordCredential", new addPasswordCredential());
-      processMap.put("getSSHCredential", new getSSHCredential());
-      processMap.put("getCertificateCredential", new getCertificateCredential());
-      processMap.put("getPasswordCredential", new getPasswordCredential());
-      return processMap;
-    }
-
-    public static class getCSServiceVersion<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, getCSServiceVersion_args, String> {
-      public getCSServiceVersion() {
-        super("getCSServiceVersion");
-      }
-
-      public getCSServiceVersion_args getEmptyArgsInstance() {
-        return new getCSServiceVersion_args();
-      }
-
-      public AsyncMethodCallback<String> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
-        final org.apache.thrift.AsyncProcessFunction fcall = this;
-        return new AsyncMethodCallback<String>() { 
-          public void onComplete(String o) {
-            getCSServiceVersion_result result = new getCSServiceVersion_result();
-            result.success = o;
-            try {
-              fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
-              return;
-            } catch (Exception e) {
-              LOGGER.error("Exception writing to internal frame buffer", e);
-            }
-            fb.close();
-          }
-          public void onError(Exception e) {
-            byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
-            org.apache.thrift.TBase msg;
-            getCSServiceVersion_result result = new getCSServiceVersion_result();
-            {
-              msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
-              msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
-            }
-            try {
-              fcall.sendResponse(fb,msg,msgType,seqid);
-              return;
-            } catch (Exception ex) {
-              LOGGER.error("Exception writing to internal frame buffer", ex);
-            }
-            fb.close();
-          }
-        };
-      }
-
-      protected boolean isOneway() {
-        return false;
-      }
-
-      public void start(I iface, getCSServiceVersion_args args, org.apache.thrift.async.AsyncMethodCallback<String> resultHandler) throws TException {
-        iface.getCSServiceVersion(resultHandler);
-      }
-    }
-
-    public static class addSSHCredential<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, addSSHCredential_args, String> {
-      public addSSHCredential() {
-        super("addSSHCredential");
-      }
-
-      public addSSHCredential_args getEmptyArgsInstance() {
-        return new addSSHCredential_args();
-      }
-
-      public AsyncMethodCallback<String> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
-        final org.apache.thrift.AsyncProcessFunction fcall = this;
-        return new AsyncMethodCallback<String>() { 
-          public void onComplete(String o) {
-            addSSHCredential_result result = new addSSHCredential_result();
-            result.success = o;
-            try {
-              fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
-              return;
-            } catch (Exception e) {
-              LOGGER.error("Exception writing to internal frame buffer", e);
-            }
-            fb.close();
-          }
-          public void onError(Exception e) {
-            byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
-            org.apache.thrift.TBase msg;
-            addSSHCredential_result result = new addSSHCredential_result();
-            if (e instanceof org.apache.airavata.credential.store.exception.CredentialStoreException) {
-                        result.csException = (org.apache.airavata.credential.store.exception.CredentialStoreException) e;
-                        result.setCsExceptionIsSet(true);
-                        msg = result;
-            }
-             else 
-            {
-              msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
-              msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
-            }
-            try {
-              fcall.sendResponse(fb,msg,msgType,seqid);
-              return;
-            } catch (Exception ex) {
-              LOGGER.error("Exception writing to internal frame buffer", ex);
-            }
-            fb.close();
-          }
-        };
-      }
-
-      protected boolean isOneway() {
-        return false;
-      }
-
-      public void start(I iface, addSSHCredential_args args, org.apache.thrift.async.AsyncMethodCallback<String> resultHandler) throws TException {
-        iface.addSSHCredential(args.sshCredential,resultHandler);
-      }
-    }
-
-    public static class addCertificateCredential<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, addCertificateCredential_args, String> {
-      public addCertificateCredential() {
-        super("addCertificateCredential");
-      }
-
-      public addCertificateCredential_args getEmptyArgsInstance() {
-        return new addCertificateCredential_args();
-      }
-
-      public AsyncMethodCallback<String> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
-        final org.apache.thrift.AsyncProcessFunction fcall = this;
-        return new AsyncMethodCallback<String>() { 
-          public void onComplete(String o) {
-            addCertificateCredential_result result = new addCertificateCredential_result();
-            result.success = o;
-            try {
-              fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
-              return;
-            } catch (Exception e) {
-              LOGGER.error("Exception writing to internal frame buffer", e);
-            }
-            fb.close();
-          }
-          public void onError(Exception e) {
-            byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
-            org.apache.thrift.TBase msg;
-            addCertificateCredential_result result = new addCertificateCredential_result();
-            if (e instanceof org.apache.airavata.credential.store.exception.CredentialStoreException) {
-                        result.csException = (org.apache.airavata.credential.store.exception.CredentialStoreException) e;
-                        result.setCsExceptionIsSet(true);
-                        msg = result;
-            }
-             else 
-            {
-              msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
-              msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
-            }
-            try {
-              fcall.sendResponse(fb,msg,msgType,seqid);
-              return;
-            } catch (Exception ex) {
-              LOGGER.error("Exception writing to internal frame buffer", ex);
-            }
-            fb.close();
-          }
-        };
-      }
-
-      protected boolean isOneway() {
-        return false;
-      }
-
-      public void start(I iface, addCertificateCredential_args args, org.apache.thrift.async.AsyncMethodCallback<String> resultHandler) throws TException {
-        iface.addCertificateCredential(args.certificateCredential,resultHandler);
-      }
-    }
-
-    public static class addPasswordCredential<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, addPasswordCredential_args, String> {
-      public addPasswordCredential() {
-        super("addPasswordCredential");
-      }
-
-      public addPasswordCredential_args getEmptyArgsInstance() {
-        return new addPasswordCredential_args();
-      }
-
-      public AsyncMethodCallback<String> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
-        final org.apache.thrift.AsyncProcessFunction fcall = this;
-        return new AsyncMethodCallback<String>() { 
-          public void onComplete(String o) {
-            addPasswordCredential_result result = new addPasswordCredential_result();
-            result.success = o;
-            try {
-              fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
-              return;
-            } catch (Exception e) {
-              LOGGER.error("Exception writing to internal frame buffer", e);
-            }
-            fb.close();
-          }
-          public void onError(Exception e) {
-            byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
-            org.apache.thrift.TBase msg;
-            addPasswordCredential_result result = new addPasswordCredential_result();
-            if (e instanceof org.apache.airavata.credential.store.exception.CredentialStoreException) {
-                        result.csException = (org.apache.airavata.credential.store.exception.CredentialStoreException) e;
-                        result.setCsExceptionIsSet(true);
-                        msg = result;
-            }
-             else 
-            {
-              msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
-              msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
-            }
-            try {
-              fcall.sendResponse(fb,msg,msgType,seqid);
-              return;
-            } catch (Exception ex) {
-              LOGGER.error("Exception writing to internal frame buffer", ex);
-            }
-            fb.close();
-          }
-        };
-      }
-
-      protected boolean isOneway() {
-        return false;
-      }
-
-      public void start(I iface, addPasswordCredential_args args, org.apache.thrift.async.AsyncMethodCallback<String> resultHandler) throws TException {
-        iface.addPasswordCredential(args.passwordCredential,resultHandler);
-      }
-    }
-
-    public static class getSSHCredential<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, getSSHCredential_args, org.apache.airavata.credential.store.datamodel.SSHCredential> {
-      public getSSHCredential() {
-        super("getSSHCredential");
-      }
-
-      public getSSHCredential_args getEmptyArgsInstance() {
-        return new getSSHCredential_args();
-      }
-
-      public AsyncMethodCallback<org.apache.airavata.credential.store.datamodel.SSHCredential> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
-        final org.apache.thrift.AsyncProcessFunction fcall = this;
-        return new AsyncMethodCallback<org.apache.airavata.credential.store.datamodel.SSHCredential>() { 
-          public void onComplete(org.apache.airavata.credential.store.datamodel.SSHCredential o) {
-            getSSHCredential_result result = new getSSHCredential_result();
-            result.success = o;
-            try {
-              fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
-              return;
-            } catch (Exception e) {
-              LOGGER.error("Exception writing to internal frame buffer", e);
-            }
-            fb.close();
-          }
-          public void onError(Exception e) {
-            byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
-            org.apache.thrift.TBase msg;
-            getSSHCredential_result result = new getSSHCredential_result();
-            if (e instanceof org.apache.airavata.credential.store.exception.CredentialStoreException) {
-                        result.csException = (org.apache.airavata.credential.store.exception.CredentialStoreException) e;
-                        result.setCsExceptionIsSet(true);
-                        msg = result;
-            }
-             else 
-            {
-              msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
-              msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
-            }
-            try {
-              fcall.sendResponse(fb,msg,msgType,seqid);
-              return;
-            } catch (Exception ex) {
-              LOGGER.error("Exception writing to internal frame buffer", ex);
-            }
-            fb.close();
-          }
-        };
-      }
-
-      protected boolean isOneway() {
-        return false;
-      }
-
-      public void start(I iface, getSSHCredential_args args, org.apache.thrift.async.AsyncMethodCallback<org.apache.airavata.credential.store.datamodel.SSHCredential> resultHandler) throws TException {
-        iface.getSSHCredential(args.tokenId, args.gatewayId,resultHandler);
-      }
-    }
-
-    public static class getCertificateCredential<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, getCertificateCredential_args, org.apache.airavata.credential.store.datamodel.CertificateCredential> {
-      public getCertificateCredential() {
-        super("getCertificateCredential");
-      }
-
-      public getCertificateCredential_args getEmptyArgsInstance() {
-        return new getCertificateCredential_args();
-      }
-
-      public AsyncMethodCallback<org.apache.airavata.credential.store.datamodel.CertificateCredential> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
-        final org.apache.thrift.AsyncProcessFunction fcall = this;
-        return new AsyncMethodCallback<org.apache.airavata.credential.store.datamodel.CertificateCredential>() { 
-          public void onComplete(org.apache.airavata.credential.store.datamodel.CertificateCredential o) {
-            getCertificateCredential_result result = new getCertificateCredential_result();
-            result.success = o;
-            try {
-              fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
-              return;
-            } catch (Exception e) {
-              LOGGER.error("Exception writing to internal frame buffer", e);
-            }
-            fb.close();
-          }
-          public void onError(Exception e) {
-            byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
-            org.apache.thrift.TBase msg;
-            getCertificateCredential_result result = new getCertificateCredential_result();
-            if (e instanceof org.apache.airavata.credential.store.exception.CredentialStoreException) {
-                        result.csException = (org.apache.airavata.credential.store.exception.CredentialStoreException) e;
-                        result.setCsExceptionIsSet(true);
-                        msg = result;
-            }
-             else 
-            {
-              msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
-              msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
-            }
-            try {
-              fcall.sendResponse(fb,msg,msgType,seqid);
-              return;
-            } catch (Exception ex) {
-              LOGGER.error("Exception writing to internal frame buffer", ex);
-            }
-            fb.close();
-          }
-        };
-      }
-
-      protected boolean isOneway() {
-        return false;
-      }
-
-      public void start(I iface, getCertificateCredential_args args, org.apache.thrift.async.AsyncMethodCallback<org.apache.airavata.credential.store.datamodel.CertificateCredential> resultHandler) throws TException {
-        iface.getCertificateCredential(args.tokenId, args.gatewayId,resultHandler);
-      }
-    }
-
-    public static class getPasswordCredential<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, getPasswordCredential_args, org.apache.airavata.credential.store.datamodel.PasswordCredential> {
-      public getPasswordCredential() {
-        super("getPasswordCredential");
-      }
-
-      public getPasswordCredential_args getEmptyArgsInstance() {
-        return new getPasswordCredential_args();
-      }
-
-      public AsyncMethodCallback<org.apache.airavata.credential.store.datamodel.PasswordCredential> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
-        final org.apache.thrift.AsyncProcessFunction fcall = this;
-        return new AsyncMethodCallback<org.apache.airavata.credential.store.datamodel.PasswordCredential>() { 
-          public void onComplete(org.apache.airavata.credential.store.datamodel.PasswordCredential o) {
-            getPasswordCredential_result result = new getPasswordCredential_result();
-            result.success = o;
-            try {
-              fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
-              return;
-            } catch (Exception e) {
-              LOGGER.error("Exception writing to internal frame buffer", e);
-            }
-            fb.close();
-          }
-          public void onError(Exception e) {
-            byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
-            org.apache.thrift.TBase msg;
-            getPasswordCredential_result result = new getPasswordCredential_result();
-            if (e instanceof org.apache.airavata.credential.store.exception.CredentialStoreException) {
-                        result.csException = (org.apache.airavata.credential.store.exception.CredentialStoreException) e;
-                        result.setCsExceptionIsSet(true);
-                        msg = result;
-            }
-             else 
-            {
-              msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
-              msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
-            }
-            try {
-              fcall.sendResponse(fb,msg,msgType,seqid);
-              return;
-            } catch (Exception ex) {
-              LOGGER.error("Exception writing to internal frame buffer", ex);
-            }
-            fb.close();
-          }
-        };
-      }
-
-      protected boolean isOneway() {
-        return false;
-      }
-
-      public void start(I iface, getPasswordCredential_args args, org.apache.thrift.async.AsyncMethodCallback<org.apache.airavata.credential.store.datamodel.PasswordCredential> resultHandler) throws TException {
-        iface.getPasswordCredential(args.tokenId, args.gatewayId,resultHandler);
-      }
-    }
-
-  }
-
-  public static class getCSServiceVersion_args implements org.apache.thrift.TBase<getCSServiceVersion_args, getCSServiceVersion_args._Fields>, java.io.Serializable, Cloneable, Comparable<getCSServiceVersion_args>   {
-    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getCSServiceVersion_args");
-
-
-    private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
-    static {
-      schemes.put(StandardScheme.class, new getCSServiceVersion_argsStandardSchemeFactory());
-      schemes.put(TupleScheme.class, new getCSServiceVersion_argsTupleSchemeFactory());
-    }
-
-
-    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-    @SuppressWarnings("all") public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-;
-
-      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
-      static {
-        for (_Fields field : EnumSet.allOf(_Fields.class)) {
-          byName.put(field.getFieldName(), field);
-        }
-      }
-
-      /**
-       * Find the _Fields constant that matches fieldId, or null if its not found.
-       */
-      public static _Fields findByThriftId(int fieldId) {
-        switch(fieldId) {
-          default:
-            return null;
-        }
-      }
-
-      /**
-       * Find the _Fields constant that matches fieldId, throwing an exception
-       * if it is not found.
-       */
-      public static _Fields findByThriftIdOrThrow(int fieldId) {
-        _Fields fields = findByThriftId(fieldId);
-        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-        return fields;
-      }
-
-      /**
-       * Find the _Fields constant that matches name, or null if its not found.
-       */
-      public static _Fields findByName(String name) {
-        return byName.get(name);
-      }
-
-      private final short _thriftId;
-      private final String _fieldName;
-
-      _Fields(short thriftId, String fieldName) {
-        _thriftId = thriftId;
-        _fieldName = fieldName;
-      }
-
-      public short getThriftFieldId() {
-        return _thriftId;
-      }
-
-      public String getFieldName() {
-        return _fieldName;
-      }
-    }
-    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-    static {
-      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-      metaDataMap = Collections.unmodifiableMap(tmpMap);
-      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getCSServiceVersion_args.class, metaDataMap);
-    }
-
-    public getCSServiceVersion_args() {
-    }
-
-    /**
-     * Performs a deep copy on <i>other</i>.
-     */
-    public getCSServiceVersion_args(getCSServiceVersion_args other) {
-    }
-
-    public getCSServiceVersion_args deepCopy() {
-      return new getCSServiceVersion_args(this);
-    }
-
-    @Override
-    public void clear() {
-    }
-
-    public void setFieldValue(_Fields field, Object value) {
-      switch (field) {
-      }
-    }
-
-    public Object getFieldValue(_Fields field) {
-      switch (field) {
-      }
-      throw new IllegalStateException();
-    }
-
-    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-    public boolean isSet(_Fields field) {
-      if (field == null) {
-        throw new IllegalArgumentException();
-      }
-
-      switch (field) {
-      }
-      throw new IllegalStateException();
-    }
-
-    @Override
-    public boolean equals(Object that) {
-      if (that == null)
-        return false;
-      if (that instanceof getCSServiceVersion_args)
-        return this.equals((getCSServiceVersion_args)that);
-      return false;
-    }
-
-    public boolean equals(getCSServiceVersion_args that) {
-      if (that == null)
-        return false;
-
-      return true;
-    }
-
-    @Override
-    public int hashCode() {
-      return 0;
-    }
-
-    @Override
-    public int compareTo(getCSServiceVersion_args other) {
-      if (!getClass().equals(other.getClass())) {
-        return getClass().getName().compareTo(other.getClass().getName());
-      }
-
-      int lastComparison = 0;
-
-      return 0;
-    }
-
-    public _Fields fieldForId(int fieldId) {
-      return _Fields.findByThriftId(fieldId);
-    }
-
-    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-      schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
-    }
-
-    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-      schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
-    }
-
-    @Override
-    public String toString() {
-      StringBuilder sb = new StringBuilder("getCSServiceVersion_args(");
-      boolean first = true;
-
-      sb.append(")");
-      return sb.toString();
-    }
-
-    public void validate() throws org.apache.thrift.TException {
-      // check for required fields
-      // check for sub-struct validity
-    }
-
-    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-      try {
-        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-      } catch (org.apache.thrift.TException te) {
-        throw new java.io.IOException(te);
-      }
-    }
-
-    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-      try {
-        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-      } catch (org.apache.thrift.TException te) {
-        throw new java.io.IOException(te);
-      }
-    }
-
-    private static class getCSServiceVersion_argsStandardSchemeFactory implements SchemeFactory {
-      public getCSServiceVersion_argsStandardScheme getScheme() {
-        return new getCSServiceVersion_argsStandardScheme();
-      }
-    }
-
-    private static class getCSServiceVersion_argsStandardScheme extends StandardScheme<getCSServiceVersion_args> {
-
-      public void read(org.apache.thrift.protocol.TProtocol iprot, getCSServiceVersion_args struct) throws org.apache.thrift.TException {
-        org.apache.thrift.protocol.TField schemeField;
-        iprot.readStructBegin();
-        while (true)
-        {
-          schemeField = iprot.readFieldBegin();
-          if (schemeField.type == org.apache.thrift.protocol.TType.STOP) { 
-            break;
-          }
-          switch (schemeField.id) {
-            default:
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-          }
-          iprot.readFieldEnd();
-        }
-        iprot.readStructEnd();
-
-        // check for required fields of primitive type, which can't be checked in the validate method
-        struct.validate();
-      }
-
-      public void write(org.apache.thrift.protocol.TProtocol oprot, getCSServiceVersion_args struct) throws org.apache.thrift.TException {
-        struct.validate();
-
-        oprot.writeStructBegin(STRUCT_DESC);
-        oprot.writeFieldStop();
-        oprot.writeStructEnd();
-      }
-
-    }
-
-    private static class getCSServiceVersion_argsTupleSchemeFactory implements SchemeFactory {
-      public getCSServiceVersion_argsTupleScheme getScheme() {
-        return new getCSServiceVersion_argsTupleScheme();
-      }
-    }
-
-    private static class getCSServiceVersion_argsTupleScheme extends TupleScheme<getCSServiceVersion_args> {
-
-      @Override
-      public void write(org.apache.thrift.protocol.TProtocol prot, getCSServiceVersion_args struct) throws org.apache.thrift.TException {
-        TTupleProtocol oprot = (TTupleProtocol) prot;
-      }
-
-      @Override
-      public void read(org.apache.thrift.protocol.TProtocol prot, getCSServiceVersion_args struct) throws org.apache.thrift.TException {
-        TTupleProtocol iprot = (TTupleProtocol) prot;
-      }
-    }
-
-  }
-
-  public static class getCSServiceVersion_result implements org.apache.thrift.TBase<getCSServiceVersion_result, getCSServiceVersion_result._Fields>, java.io.Serializable, Cloneable, Comparable<getCSServiceVersion_result>   {
-    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getCSServiceVersion_result");
-
-    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRING, (short)0);
-
-    private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
-    static {
-      schemes.put(StandardScheme.class, new getCSServiceVersion_resultStandardSchemeFactory());
-      schemes.put(TupleScheme.class, new getCSServiceVersion_resultTupleSchemeFactory());
-    }
-
-    public String success; // required
-
-    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-    @SuppressWarnings("all") public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-      SUCCESS((short)0, "success");
-
-      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
-      static {
-        for (_Fields field : EnumSet.allOf(_Fields.class)) {
-          byName.put(field.getFieldName(), field);
-        }
-      }
-
-      /**
-       * Find the _Fields constant that matches fieldId, or null if its not found.
-       */
-      public static _Fields findByThriftId(int fieldId) {
-        switch(fieldId) {
-          case 0: // SUCCESS
-            return SUCCESS;
-          default:
-            return null;
-        }
-      }
-
-      /**
-       * Find the _Fields constant that matches fieldId, throwing an exception
-       * if it is not found.
-       */
-      public static _Fields findByThriftIdOrThrow(int fieldId) {
-        _Fields fields = findByThriftId(fieldId);
-        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-        return fields;
-      }
-
-      /**
-       * Find the _Fields constant that matches name, or null if its not found.
-       */
-      public static _Fields findByName(String name) {
-        return byName.get(name);
-      }
-
-      private final short _thriftId;
-      private final String _fieldName;
-
-      _Fields(short thriftId, String fieldName) {
-        _thriftId = thriftId;
-        _fieldName = fieldName;
-      }
-
-      public short getThriftFieldId() {
-        return _thriftId;
-      }
-
-      public String getFieldName() {
-        return _fieldName;
-      }
-    }
-
-    // isset id assignments
-    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-    static {
-      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-      metaDataMap = Collections.unmodifiableMap(tmpMap);
-      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getCSServiceVersion_result.class, metaDataMap);
-    }
-
-    public getCSServiceVersion_result() {
-    }
-
-    public getCSServiceVersion_result(
-      String success)
-    {
-      this();
-      this.success = success;
-    }
-
-    /**
-     * Performs a deep copy on <i>other</i>.
-     */
-    public getCSServiceVersion_result(getCSServiceVersion_result other) {
-      if (other.isSetSuccess()) {
-        this.success = other.success;
-      }
-    }
-
-    public getCSServiceVersion_result deepCopy() {
-      return new getCSServiceVersion_result(this);
-    }
-
-    @Override
-    public void clear() {
-      this.success = null;
-    }
-
-    public String getSuccess() {
-      return this.success;
-    }
-
-    public getCSServiceVersion_result setSuccess(String success) {
-      this.success = success;
-      return this;
-    }
-
-    public void unsetSuccess() {
-      this.success = null;
-    }
-
-    /** Returns true if field success is set (has been assigned a value) and false otherwise */
-    public boolean isSetSuccess() {
-      return this.success != null;
-    }
-
-    public void setSuccessIsSet(boolean value) {
-      if (!value) {
-        this.success = null;
-      }
-    }
-
-    public void setFieldValue(_Fields field, Object value) {
-      switch (field) {
-      case SUCCESS:
-        if (value == null) {
-          unsetSuccess();
-        } else {
-          setSuccess((String)value);
-        }
-        break;
-
-      }
-    }
-
-    public Object getFieldValue(_Fields field) {
-      switch (field) {
-      case SUCCESS:
-        return getSuccess();
-
-      }
-      throw new IllegalStateException();
-    }
-
-    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-    public boolean isSet(_Fields field) {
-      if (field == null) {
-        throw new IllegalArgumentException();
-      }
-
-      switch (field) {
-      case SUCCESS:
-        return isSetSuccess();
-      }
-      throw new IllegalStateException();
-    }
-
-    @Override
-    public boolean equals(Object that) {
-      if (that == null)
-        return false;
-      if (that instanceof getCSServiceVersion_result)
-        return this.equals((getCSServiceVersion_result)that);
-      return false;
-    }
-
-    public boolean equals(getCSServiceVersion_result that) {
-      if (that == null)
-        return false;
-
-      boolean this_present_success = true && this.isSetSuccess();
-      boolean that_present_success = true && that.isSetSuccess();
-      if (this_present_success || that_present_success) {
-        if (!(this_present_success && that_present_success))
-          return false;
-        if (!this.success.equals(that.success))
-          return false;
-      }
-
-      return true;
-    }
-
-    @Override
-    public int hashCode() {
-      return 0;
-    }
-
-    @Override
-    public int compareTo(getCSServiceVersion_result other) {
-      if (!getClass().equals(other.getClass())) {
-        return getClass().getName().compareTo(other.getClass().getName());
-      }
-
-      int lastComparison = 0;
-
-      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess());
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-      if (isSetSuccess()) {
-        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, other.success);
-        if (lastComparison != 0) {
-          return lastComparison;
-        }
-      }
-      return 0;
-    }
-
-    public _Fields fieldForId(int fieldId) {
-      return _Fields.findByThriftId(fieldId);
-    }
-
-    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-      schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
-    }
-
-    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-      schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
-      }
-
-    @Override
-    public String toString() {
-      StringBuilder sb = new StringBuilder("getCSServiceVersion_result(");
-      boolean first = true;
-
-      sb.append("success:");
-      if (this.success == null) {
-        sb.append("null");
-      } else {
-        sb.append(this.success);
-      }
-      first = false;
-      sb.append(")");
-      return sb.toString();
-    }
-
-    public void validate() throws org.apache.thrift.TException {
-      // check for required fields
-      // check for sub-struct validity
-    }
-
-    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-      try {
-        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-      } catch (org.apache.thrift.TException te) {
-        throw new java.io.IOException(te);
-      }
-    }
-
-    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-      try {
-        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-      } catch (org.apache.thrift.TException te) {
-        throw new java.io.IOException(te);
-      }
-    }
-
-    private static class getCSServiceVersion_resultStandardSchemeFactory implements SchemeFactory {
-      public getCSServiceVersion_resultStandardScheme getScheme() {
-        return new getCSServiceVersion_resultStandardScheme();
-      }
-    }
-
-    private static class getCSServiceVersion_resultStandardScheme extends StandardScheme<getCSServiceVersion_result> {
-
-      public void read(org.apache.thrift.protocol.TProtocol iprot, getCSServiceVersion_result struct) throws org.apache.thrift.TException {
-        org.apache.thrift.protocol.TField schemeField;
-        iprot.readStructBegin();
-        while (true)
-        {
-          schemeField = iprot.readFieldBegin();
-          if (schemeField.type == org.apache.thrift.protocol.TType.STOP) { 
-            break;
-          }
-          switch (schemeField.id) {
-            case 0: // SUCCESS
-              if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-                struct.success = iprot.readString();
-                struct.setSuccessIsSet(true);
-              } else { 
-                org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-              }
-              break;
-            default:
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-          }
-          iprot.readFieldEnd();
-        }
-        iprot.readStructEnd();
-
-        // check for required fields of primitive type, which can't be checked in the validate method
-        struct.validate();
-      }
-
-      public void write(org.apache.thrift.protocol.TProtocol oprot, getCSServiceVersion_result struct) throws org.apache.thrift.TException {
-        struct.validate();
-
-        oprot.writeStructBegin(STRUCT_DESC);
-        if (struct.success != null) {
-          oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
-          oprot.writeString(struct.success);
-          oprot.writeFieldEnd();
-        }
-        oprot.writeFieldStop();
-        oprot.writeStructEnd();
-      }
-
-    }
-
-    private static class getCSServiceVersion_resultTupleSchemeFactory implements SchemeFactory {
-      public getCSServiceVersion_resultTupleScheme getScheme() {
-        return new getCSServiceVersion_resultTupleScheme();
-      }
-    }
-
-    private static class getCSServiceVersion_resultTupleScheme extends TupleScheme<getCSServiceVersion_result> {
-
-      @Override
-      public void write(org.apache.thrift.protocol.TProtocol prot, getCSServiceVersion_result struct) throws org.apache.thrift.TException {
-        TTupleProtocol oprot = (TTupleProtocol) prot;
-        BitSet optionals = new BitSet();
-        if (struct.isSetSuccess()) {
-          optionals.set(0);
-        }
-        oprot.writeBitSet(optionals, 1);
-        if (struct.isSetSuccess()) {
-          oprot.writeString(struct.success);
-        }
-      }
-
-      @Override
-      public void read(org.apache.thrift.protocol.TProtocol prot, getCSServiceVersion_result struct) throws org.apache.thrift.TException {
-        TTupleProtocol iprot = (TTupleProtocol) prot;
-        BitSet incoming = iprot.readBitSet(1);
-        if (incoming.get(0)) {
-          struct.success = iprot.readString();
-          struct.setSuccessIsSet(true);
-        }
-      }
-    }
-
-  }
-
-  public static class addSSHCredential_args implements org.apache.thrift.TBase<addSSHCredential_args, addSSHCredential_args._Fields>, java.io.Serializable, Cloneable, Comparable<addSSHCredential_args>   {
-    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addSSHCredential_args");
-
-    private static final org.apache.thrift.protocol.TField SSH_CREDENTIAL_FIELD_DESC = new org.apache.thrift.protocol.TField("sshCredential", org.apache.thrift.protocol.TType.STRUCT, (short)1);
-
-    private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
-    static {
-      schemes.put(StandardScheme.class, new addSSHCredential_argsStandardSchemeFactory());
-      schemes.put(TupleScheme.class, new addSSHCredential_argsTupleSchemeFactory());
-    }
-
-    public org.apache.airavata.credential.store.datamodel.SSHCredential sshCredential; // required
-
-    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-    @SuppressWarnings("all") public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-      SSH_CREDENTIAL((short)1, "sshCredential");
-
-      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
-      static {
-        for (_Fields field : EnumSet.allOf(_Fields.class)) {
-          byName.put(field.getFieldName(), field);
-        }
-      }
-
-      /**
-       * Find the _Fields constant that matches fieldId, or null if its not found.
-       */
-      public static _Fields findByThriftId(int fieldId) {
-        switch(fieldId) {
-          case 1: // SSH_CREDENTIAL
-            return SSH_CREDENTIAL;
-          default:
-            return null;
-        }
-      }
-
-      /**
-       * Find the _Fields constant that matches fieldId, throwing an exception
-       * if it is not found.
-       */
-      public static _Fields findByThriftIdOrThrow(int fieldId) {
-        _Fields fields = findByThriftId(fieldId);
-        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-        return fields;
-      }
-
-      /**
-       * Find the _Fields constant that matches name, or null if its not found.
-       */
-      public static _Fields findByName(String name) {
-        return byName.get(name);
-      }
-
-      private final short _thriftId;
-      private final String _fieldName;
-
-      _Fields(short thriftId, String fieldName) {
-        _thriftId = thriftId;
-        _fieldName = fieldName;
-      }
-
-      public short getThriftFieldId() {
-        return _thriftId;
-      }
-
-      public String getFieldName() {
-        return _fieldName;
-      }
-    }
-
-    // isset id assignments
-    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-    static {
-      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-      tmpMap.put(_Fields.SSH_CREDENTIAL, new org.apache.thrift.meta_data.FieldMetaData("sshCredential", org.apache.thrift.TFieldRequirementType.REQUIRED, 
-          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, org.apache.airavata.credential.store.datamodel.SSHCredential.class)));
-      metaDataMap = Collections.unmodifiableMap(tmpMap);
-      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addSSHCredential_args.class, metaDataMap);
-    }
-
-    public addSSHCredential_args() {
-    }
-
-    public addSSHCredential_args(
-      org.apache.airavata.credential.store.datamodel.SSHCredential sshCredential)
-    {
-      this();
-      this.sshCredential = sshCredential;
-    }
-
-    /**
-     * Performs a deep copy on <i>other</i>.
-     */
-    public addSSHCredential_args(addSSHCredential_args other) {
-      if (other.isSetSshCredential()) {
-        this.sshCredential = new org.apache.airavata.credential.store.datamodel.SSHCredential(other.sshCredential);
-      }
-    }
-
-    public addSSHCredential_args deepCopy() {
-      return new addSSHCredential_args(this);
-    }
-
-    @Override
-    public void clear() {
-      this.sshCredential = null;
-    }
-
-    public org.apache.airavata.credential.store.datamodel.SSHCredential getSshCredential() {
-      return this.sshCredential;
-    }
-
-    public addSSHCredential_args setSshCredential(org.apache.airavata.credential.store.datamodel.SSHCredential sshCredential) {
-      this.sshCredential = sshCredential;
-      return this;
-    }
-
-    public void unsetSshCredential() {
-      this.sshCredential = null;
-    }
-
-    /** Returns true if field sshCredential is set (has been assigned a value) and false otherwise */
-    public boolean isSetSshCredential() {
-      return this.sshCredential != null;
-    }
-
-    public void setSshCredentialIsSet(boolean value) {
-      if (!value) {
-        this.sshCredential = null;
-      }
-    }
-
-    public void setFieldValue(_Fields field, Object value) {
-      switch (field) {
-      case SSH_CREDENTIAL:
-        if (value == null) {
-          unsetSshCredential();
-        } else {
-          setSshCredential((org.apache.airavata.credential.store.datamodel.SSHCredential)value);
-        }
-        break;
-
-      }
-    }
-
-    public Object getFieldValue(_Fields field) {
-      switch (field) {
-      case SSH_CREDENTIAL:
-        return getSshCredential();
-
-      }
-      throw new IllegalStateException();
-    }
-
-    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-    public boolean isSet(_Fields field) {
-      if (field == null) {
-        throw new IllegalArgumentException();
-      }
-
-      switch (field) {
-      case SSH_CREDENTIAL:
-        return isSetSshCredential();
-      }
-      throw new IllegalStateException();
-    }
-
-    @Override
-    public boolean equals(Object that) {
-      if (that == null)
-        return false;
-      if (that instanceof addSSHCredential_args)
-        return this.equals((addSSHCredential_args)that);
-      return false;
-    }
-
-    public boolean equals(addSSHCredential_args that) {
-      if (that == null)
-        return false;
-
-      boolean this_present_sshCredential = true && this.isSetSshCredential();
-      boolean that_present_sshCredential = true && that.isSetSshCredential();
-      if (this_present_sshCredential || that_present_sshCredential) {
-        if (!(this_present_sshCredential && that_present_sshCredential))
-          return false;
-        if (!this.sshCredential.equals(that.sshCredential))
-          return false;
-      }
-
-      return true;
-    }
-
-    @Override
-    public int hashCode() {
-      return 0;
-    }
-
-    @Override
-    public int compareTo(addSSHCredential_args other) {
-      if (!getClass().equals(other.getClass())) {
-        return getClass().getName().compareTo(other.getClass().getName());
-      }
-
-      int lastComparison = 0;
-
-      lastComparison = Boolean.valueOf(isSetSshCredential()).compareTo(other.isSetSshCredential());
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-      if (isSetSshCredential()) {
-        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sshCredential, other.sshCredential);
-        if (lastComparison != 0) {
-          return lastComparison;
-        }
-      }
-      return 0;
-    }
-
-    public _Fields fieldForId(int fieldId) {
-      return _Fields.findByThriftId(fieldId);
-    }
-
-    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-      schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
-    }
-
-    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-      schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
-    }
-
-    @Override
-    public String toString() {
-      StringBuilder sb = new StringBuilder("addSSHCredential_args(");
-      boolean first = true;
-
-      sb.append("sshCredential:");
-      if (this.sshCredential == null) {
-        sb.append("null");
-      } else {
-        sb.append(this.sshCredential);
-      }
-      first = false;
-      sb.append(")");
-      return sb.toString();
-    }
-
-    public void validate() throws org.apache.thrift.TException {
-      // check for required fields
-      if (sshCredential == null) {
-        throw new org.apache.thrift.protocol.TProtocolException("Required field 'sshCredential' was not present! Struct: " + toString());
-      }
-      // check for sub-struct validity
-      if (sshCredential != null) {
-        sshCredential.validate();
-      }
-    }
-
-    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-      try {
-        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-      } catch (org.apache.thrift.TException te) {
-        throw new java.io.IOException(te);
-      }
-    }
-
-    p

<TRUNCATED>

[4/4] airavata git commit: Reorganizing duplicate generated classed and instead using the stubs artifact - AIRAVATA-1621

Posted by sm...@apache.org.
Reorganizing duplicate generated classed and instead using the  stubs artifact - AIRAVATA-1621


Project: http://git-wip-us.apache.org/repos/asf/airavata/repo
Commit: http://git-wip-us.apache.org/repos/asf/airavata/commit/b25e0a5d
Tree: http://git-wip-us.apache.org/repos/asf/airavata/tree/b25e0a5d
Diff: http://git-wip-us.apache.org/repos/asf/airavata/diff/b25e0a5d

Branch: refs/heads/master
Commit: b25e0a5db9d137731a2bd0f9a7c2ed1368e6f0e7
Parents: 58c58cf
Author: Suresh Marru <sm...@apache.org>
Authored: Thu Mar 5 23:29:26 2015 -0500
Committer: Suresh Marru <sm...@apache.org>
Committed: Thu Mar 5 23:29:26 2015 -0500

----------------------------------------------------------------------
 .../apache/airavata/common/utils/Constants.java |    4 +-
 .../credential-store-service/pom.xml            |  268 +-
 .../credential/store/client/TestSSLClient.java  |    8 +-
 .../store/cpi/CredentialStoreService.java       | 6888 ------------------
 .../store/cpi/cs_cpi_serviceConstants.java      |   55 -
 .../store/datamodel/CertificateCredential.java  | 1104 ---
 .../store/datamodel/CommunityUser.java          |  589 --
 .../store/datamodel/PasswordCredential.java     |  698 --
 .../store/datamodel/SSHCredential.java          |  998 ---
 .../store/datamodel/csDataModelConstants.java   |   55 -
 .../exception/CredentialStoreException.java     |  397 -
 .../store/server/CredentialStoreServer.java     |    4 +-
 .../server/CredentialStoreServerHandler.java    |   10 +-
 13 files changed, 150 insertions(+), 10928 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/airavata/blob/b25e0a5d/modules/commons/utils/src/main/java/org/apache/airavata/common/utils/Constants.java
----------------------------------------------------------------------
diff --git a/modules/commons/utils/src/main/java/org/apache/airavata/common/utils/Constants.java b/modules/commons/utils/src/main/java/org/apache/airavata/common/utils/Constants.java
index fd17064..154bea1 100644
--- a/modules/commons/utils/src/main/java/org/apache/airavata/common/utils/Constants.java
+++ b/modules/commons/utils/src/main/java/org/apache/airavata/common/utils/Constants.java
@@ -41,8 +41,8 @@ public final class Constants {
     public static final String ORCHESTRATOR_SERVER_PORT = "orchestrator.server.port";
     public static final String GFAC_SERVER_HOST = "gfac.server.host";
     public static final String GFAC_SERVER_PORT = "gfac.server.port";
-    public static final String CREDNETIAL_SERVER_HOST = "credential.store.server.host";
-    public static final String CREDNETIAL_SERVER_PORT = "credential.store.server.port";
+    public static final String CREDENTIAL_SERVER_HOST = "credential.store.server.host";
+    public static final String CREDENTIAL_SERVER_PORT = "credential.store.server.port";
     public static final String ZOOKEEPER_EXPERIMENT_CATALOG = "experiment-catalog";
     public static final String ZOOKEEPER_APPCATALOG = "app-catalog";
     public static final String ZOOKEEPER_RABBITMQ = "rabbit-mq";

http://git-wip-us.apache.org/repos/asf/airavata/blob/b25e0a5d/modules/credential-store/credential-store-service/pom.xml
----------------------------------------------------------------------
diff --git a/modules/credential-store/credential-store-service/pom.xml b/modules/credential-store/credential-store-service/pom.xml
index d8af25f..1595ed6 100644
--- a/modules/credential-store/credential-store-service/pom.xml
+++ b/modules/credential-store/credential-store-service/pom.xml
@@ -11,144 +11,150 @@
 	OF ANY ~ KIND, either express or implied. See the License for the specific 
 	language governing permissions and limitations under the License. -->
 
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
-	<parent>
-		<groupId>org.apache.airavata</groupId>
-		<artifactId>airavata</artifactId>
-		<version>0.15-SNAPSHOT</version>
-		<relativePath>../../../pom.xml</relativePath>
-	</parent>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+    <parent>
+        <groupId>org.apache.airavata</groupId>
+        <artifactId>airavata</artifactId>
+        <version>0.15-SNAPSHOT</version>
+        <relativePath>../../../pom.xml</relativePath>
+    </parent>
 
-	<modelVersion>4.0.0</modelVersion>
-	<artifactId>airavata-credential-store</artifactId>
-	<name>Airavata Credential Store</name>
-	<description>Module to manage credentials</description>
+    <modelVersion>4.0.0</modelVersion>
+    <artifactId>airavata-credential-store</artifactId>
+    <name>Airavata Credential Store</name>
+    <description>Module to manage credentials</description>
 
-	<dependencies>
-		<dependency>
-			<groupId>edu.uiuc.ncsa.myproxy</groupId>
-			<artifactId>oa4mp-client-api</artifactId>
-			<version>${oa4mp.version}</version>
-		</dependency>
-		<dependency>
+    <dependencies>
+        <dependency>
+            <groupId>org.apache.airavata</groupId>
+            <artifactId>airavata-credential-store-stubs</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>edu.uiuc.ncsa.myproxy</groupId>
+            <artifactId>oa4mp-client-api</artifactId>
+            <version>${oa4mp.version}</version>
+        </dependency>
+        <dependency>
             <groupId>edu.uiuc.ncsa.myproxy</groupId>
             <artifactId>oa4mp-client-loader-oauth1</artifactId>
             <version>${oa4mp.version}</version>
             <exclusions>
-        	<exclusion>
-          		<groupId>net.oauth.core</groupId> 
-          		<artifactId>oauth-httpclient4</artifactId>
-        	</exclusion>
-			<exclusion>
-				<groupId>net.oauth.core</groupId>
-				<artifactId>oauth-consumer</artifactId>
-			</exclusion>
-			<exclusion>
-				<groupId>mysql</groupId>
-				<artifactId>mysql-connector-java</artifactId>
-			</exclusion>
-			<exclusion>
-				<groupId>postgresql</groupId>
-				<artifactId>postgresql</artifactId>
-			</exclusion>
+                <exclusion>
+                    <groupId>net.oauth.core</groupId>
+                    <artifactId>oauth-httpclient4</artifactId>
+                </exclusion>
+                <exclusion>
+                    <groupId>net.oauth.core</groupId>
+                    <artifactId>oauth-consumer</artifactId>
+                </exclusion>
+                <exclusion>
+                    <groupId>mysql</groupId>
+                    <artifactId>mysql-connector-java</artifactId>
+                </exclusion>
+                <exclusion>
+                    <groupId>postgresql</groupId>
+                    <artifactId>postgresql</artifactId>
+                </exclusion>
             </exclusions>
         </dependency>
-		<dependency>
-			<groupId>org.slf4j</groupId>
-			<artifactId>slf4j-api</artifactId>
-		</dependency>
-		<dependency>
-			<groupId>log4j</groupId>
-			<artifactId>log4j</artifactId>
-		</dependency>
-		<dependency>
-			<groupId>junit</groupId>
-			<artifactId>junit</artifactId>
-			<version>4.7</version>
-			<scope>test</scope>
-		</dependency>
-		<dependency>
-			<groupId>org.apache.derby</groupId>
-			<artifactId>derby</artifactId>
-			<version>${derby.version}</version>
-			<scope>test</scope>
-		</dependency>
-		<dependency>
-			<groupId>org.apache.derby</groupId>
-			<artifactId>derbyclient</artifactId>
-			<version>${derby.version}</version>
-			<scope>test</scope>
-		</dependency>
-		<dependency>
-			<groupId>org.apache.derby</groupId>
-			<artifactId>derbynet</artifactId>
-			<version>${derby.version}</version>
-			<scope>test</scope>
-		</dependency>
-		<dependency>
-			<groupId>org.apache.derby</groupId>
-			<artifactId>derbytools</artifactId>
-			<version>${derby.version}</version>
-			<scope>test</scope>
-		</dependency>
-		<dependency>
-			<groupId>commons-dbcp</groupId>
-			<artifactId>commons-dbcp</artifactId>
-			<version>1.4</version>
-		</dependency>
-		<dependency>
-			<groupId>org.apache.airavata</groupId>
-			<artifactId>airavata-common-utils</artifactId>
-			<version>${project.version}</version>
-		</dependency> 
-		<dependency>
-			<groupId>com.jcraft</groupId>
-			<artifactId>jsch</artifactId>
-			<version>0.1.50</version>
-		</dependency>
-		<dependency>
-			<groupId>javax.servlet</groupId>
-			<artifactId>servlet-api</artifactId>
-			<version>2.5</version>
-			<scope>provided</scope>
-		</dependency>
-		<dependency>
-			<groupId>org.apache.commons</groupId>
-			<artifactId>commons-email</artifactId>
-			<version>1.3.2</version>
-		</dependency>
-		<dependency>
-			<groupId>org.apache.commons</groupId>
-			<artifactId>commons-io</artifactId>
-			<version>1.3.2</version>
-		</dependency>
-	</dependencies>
-	<build>
-		<plugins>
-			<plugin>
-				<groupId>org.apache.maven.plugins</groupId>
-				<artifactId>maven-surefire-plugin</artifactId>
-				<version>${surefire.version}</version>
-				<inherited>true</inherited>
-				<configuration>
-					<systemPropertyVariables>
-						<credential.module.directory>${basedir}</credential.module.directory>
-					</systemPropertyVariables>
-					<excludes>
-						<exclude>**/DAOBaseTestCase.java</exclude>
-						<exclude>**/MappingDAOTest.java</exclude>
-					</excludes>
-					<testSourceDirectory>${basedir}\src\test\java\</testSourceDirectory>
-				</configuration>
-			</plugin>
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-api</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>log4j</groupId>
+            <artifactId>log4j</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <version>4.7</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.derby</groupId>
+            <artifactId>derby</artifactId>
+            <version>${derby.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.derby</groupId>
+            <artifactId>derbyclient</artifactId>
+            <version>${derby.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.derby</groupId>
+            <artifactId>derbynet</artifactId>
+            <version>${derby.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.derby</groupId>
+            <artifactId>derbytools</artifactId>
+            <version>${derby.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>commons-dbcp</groupId>
+            <artifactId>commons-dbcp</artifactId>
+            <version>1.4</version>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.airavata</groupId>
+            <artifactId>airavata-common-utils</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>com.jcraft</groupId>
+            <artifactId>jsch</artifactId>
+            <version>0.1.50</version>
+        </dependency>
+        <dependency>
+            <groupId>javax.servlet</groupId>
+            <artifactId>servlet-api</artifactId>
+            <version>2.5</version>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.commons</groupId>
+            <artifactId>commons-email</artifactId>
+            <version>1.3.2</version>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.commons</groupId>
+            <artifactId>commons-io</artifactId>
+            <version>1.3.2</version>
+        </dependency>
+    </dependencies>
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-surefire-plugin</artifactId>
+                <version>${surefire.version}</version>
+                <inherited>true</inherited>
+                <configuration>
+                    <systemPropertyVariables>
+                        <credential.module.directory>${basedir}</credential.module.directory>
+                    </systemPropertyVariables>
+                    <excludes>
+                        <exclude>**/DAOBaseTestCase.java</exclude>
+                        <exclude>**/MappingDAOTest.java</exclude>
+                    </excludes>
+                    <testSourceDirectory>${basedir}\src\test\java\</testSourceDirectory>
+                </configuration>
+            </plugin>
 
-		</plugins>
-		<testSourceDirectory>${project.basedir}/src/test/java</testSourceDirectory>
-		<testOutputDirectory>${project.build.directory}/test-classes</testOutputDirectory>
-		<testResources>
-			<testResource>
-				<directory>${project.basedir}/src/test/resources</directory>
-			</testResource>
-		</testResources>
-	</build>
+        </plugins>
+        <testSourceDirectory>${project.basedir}/src/test/java</testSourceDirectory>
+        <testOutputDirectory>${project.build.directory}/test-classes</testOutputDirectory>
+        <testResources>
+            <testResource>
+                <directory>${project.basedir}/src/test/resources</directory>
+            </testResource>
+        </testResources>
+    </build>
 </project>

http://git-wip-us.apache.org/repos/asf/airavata/blob/b25e0a5d/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/client/TestSSLClient.java
----------------------------------------------------------------------
diff --git a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/client/TestSSLClient.java b/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/client/TestSSLClient.java
index 12105e2..cc5ebb6 100644
--- a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/client/TestSSLClient.java
+++ b/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/client/TestSSLClient.java
@@ -56,8 +56,8 @@ public class TestSSLClient {
             String keystorePath = ServerSettings.getCredentialStoreThriftServerKeyStorePath();
             String keystorePWD = ServerSettings.getCredentialStoreThriftServerKeyStorePassword();
             params.setTrustStore(keystorePath, keystorePWD);
-            final int serverPort = Integer.parseInt(ServerSettings.getSetting(Constants.CREDNETIAL_SERVER_PORT, "8960"));
-            final String serverHost = ServerSettings.getSetting(Constants.CREDNETIAL_SERVER_HOST, null);
+            final int serverPort = Integer.parseInt(ServerSettings.getSetting(Constants.CREDENTIAL_SERVER_PORT, "8960"));
+            final String serverHost = ServerSettings.getSetting(Constants.CREDENTIAL_SERVER_HOST, null);
 
             transport = TSSLTransportFactory.getClientSocket(serverHost, serverPort, 10000, params);
             TProtocol protocol = new TBinaryProtocol(transport);
@@ -98,7 +98,7 @@ public class TestSSLClient {
             certificateCredential.setCommunityUser(communityUser);
             X509Certificate[] x509Certificates = new X509Certificate[1];
             KeyStore ks = KeyStore.getInstance("JKS");
-            File keyStoreFile = new File("/Users/chathuri/dev/airavata/credential-store/oa4mp/airavata.jks");
+            File keyStoreFile = new File("/Users/smarru/code/airavata-master/modules/configuration/server/src/main/resources/airavata.jks");
             FileInputStream fis = new FileInputStream(keyStoreFile);
             char[] password = "airavata".toCharArray();
             ks.load(fis,password);
@@ -114,7 +114,7 @@ public class TestSSLClient {
             System.out.println("Certificate Token :" + token);
             CertificateCredential credential = client.getCertificateCredential(token, "testGateway");
             System.out.println("certificate : " + credential.getX509Cert());
-            System.out.println("gateway name  : " + credential.getCommunityUser().getGatewayNmae());
+            System.out.println("gateway name  : " + credential.getCommunityUser().getGatewayName());
         }catch (TTransportException e) {
             e.printStackTrace();
         } catch (TException e) {


[2/4] airavata git commit: Reorganizing duplicate generated classed and instead using the stubs artifact - AIRAVATA-1621

Posted by sm...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/b25e0a5d/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/cpi/cs_cpi_serviceConstants.java
----------------------------------------------------------------------
diff --git a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/cpi/cs_cpi_serviceConstants.java b/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/cpi/cs_cpi_serviceConstants.java
deleted file mode 100644
index 2b8858e..0000000
--- a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/cpi/cs_cpi_serviceConstants.java
+++ /dev/null
@@ -1,55 +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.
-     */
-/**
- * Autogenerated by Thrift Compiler (0.9.1)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- *  @generated
- */
-package org.apache.airavata.credential.store.cpi;
-
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-import org.apache.thrift.protocol.TTupleProtocol;
-import org.apache.thrift.protocol.TProtocolException;
-import org.apache.thrift.EncodingUtils;
-import org.apache.thrift.TException;
-import org.apache.thrift.async.AsyncMethodCallback;
-import org.apache.thrift.server.AbstractNonblockingServer.*;
-import java.util.List;
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-import java.util.Collections;
-import java.util.BitSet;
-import java.nio.ByteBuffer;
-import java.util.Arrays;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings("all") public class cs_cpi_serviceConstants {
-
-  public static final String CS_CPI_VERSION = "0.15.0";
-
-}

http://git-wip-us.apache.org/repos/asf/airavata/blob/b25e0a5d/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/CertificateCredential.java
----------------------------------------------------------------------
diff --git a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/CertificateCredential.java b/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/CertificateCredential.java
deleted file mode 100644
index ae37b1d..0000000
--- a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/CertificateCredential.java
+++ /dev/null
@@ -1,1104 +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.
-     */
-/**
- * Autogenerated by Thrift Compiler (0.9.1)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- *  @generated
- */
-package org.apache.airavata.credential.store.datamodel;
-
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-import org.apache.thrift.protocol.TTupleProtocol;
-import org.apache.thrift.protocol.TProtocolException;
-import org.apache.thrift.EncodingUtils;
-import org.apache.thrift.TException;
-import org.apache.thrift.async.AsyncMethodCallback;
-import org.apache.thrift.server.AbstractNonblockingServer.*;
-import java.util.List;
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-import java.util.Collections;
-import java.util.BitSet;
-import java.nio.ByteBuffer;
-import java.util.Arrays;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings("all") public class CertificateCredential implements org.apache.thrift.TBase<CertificateCredential, CertificateCredential._Fields>, java.io.Serializable, Cloneable, Comparable<CertificateCredential> {
-  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("CertificateCredential");
-
-  private static final org.apache.thrift.protocol.TField COMMUNITY_USER_FIELD_DESC = new org.apache.thrift.protocol.TField("communityUser", org.apache.thrift.protocol.TType.STRUCT, (short)1);
-  private static final org.apache.thrift.protocol.TField X509_CERT_FIELD_DESC = new org.apache.thrift.protocol.TField("x509Cert", org.apache.thrift.protocol.TType.STRING, (short)2);
-  private static final org.apache.thrift.protocol.TField NOT_AFTER_FIELD_DESC = new org.apache.thrift.protocol.TField("notAfter", org.apache.thrift.protocol.TType.STRING, (short)3);
-  private static final org.apache.thrift.protocol.TField PRIVATE_KEY_FIELD_DESC = new org.apache.thrift.protocol.TField("privateKey", org.apache.thrift.protocol.TType.STRING, (short)4);
-  private static final org.apache.thrift.protocol.TField LIFE_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("lifeTime", org.apache.thrift.protocol.TType.I64, (short)5);
-  private static final org.apache.thrift.protocol.TField NOT_BEFORE_FIELD_DESC = new org.apache.thrift.protocol.TField("notBefore", org.apache.thrift.protocol.TType.STRING, (short)6);
-  private static final org.apache.thrift.protocol.TField PERSISTED_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("persistedTime", org.apache.thrift.protocol.TType.I64, (short)7);
-  private static final org.apache.thrift.protocol.TField TOKEN_FIELD_DESC = new org.apache.thrift.protocol.TField("token", org.apache.thrift.protocol.TType.STRING, (short)8);
-
-  private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
-  static {
-    schemes.put(StandardScheme.class, new CertificateCredentialStandardSchemeFactory());
-    schemes.put(TupleScheme.class, new CertificateCredentialTupleSchemeFactory());
-  }
-
-  public CommunityUser communityUser; // required
-  public String x509Cert; // required
-  public String notAfter; // optional
-  public String privateKey; // optional
-  public long lifeTime; // optional
-  public String notBefore; // optional
-  public long persistedTime; // optional
-  public String token; // optional
-
-  /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-  @SuppressWarnings("all") public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-    COMMUNITY_USER((short)1, "communityUser"),
-    X509_CERT((short)2, "x509Cert"),
-    NOT_AFTER((short)3, "notAfter"),
-    PRIVATE_KEY((short)4, "privateKey"),
-    LIFE_TIME((short)5, "lifeTime"),
-    NOT_BEFORE((short)6, "notBefore"),
-    PERSISTED_TIME((short)7, "persistedTime"),
-    TOKEN((short)8, "token");
-
-    private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
-    static {
-      for (_Fields field : EnumSet.allOf(_Fields.class)) {
-        byName.put(field.getFieldName(), field);
-      }
-    }
-
-    /**
-     * Find the _Fields constant that matches fieldId, or null if its not found.
-     */
-    public static _Fields findByThriftId(int fieldId) {
-      switch(fieldId) {
-        case 1: // COMMUNITY_USER
-          return COMMUNITY_USER;
-        case 2: // X509_CERT
-          return X509_CERT;
-        case 3: // NOT_AFTER
-          return NOT_AFTER;
-        case 4: // PRIVATE_KEY
-          return PRIVATE_KEY;
-        case 5: // LIFE_TIME
-          return LIFE_TIME;
-        case 6: // NOT_BEFORE
-          return NOT_BEFORE;
-        case 7: // PERSISTED_TIME
-          return PERSISTED_TIME;
-        case 8: // TOKEN
-          return TOKEN;
-        default:
-          return null;
-      }
-    }
-
-    /**
-     * Find the _Fields constant that matches fieldId, throwing an exception
-     * if it is not found.
-     */
-    public static _Fields findByThriftIdOrThrow(int fieldId) {
-      _Fields fields = findByThriftId(fieldId);
-      if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-      return fields;
-    }
-
-    /**
-     * Find the _Fields constant that matches name, or null if its not found.
-     */
-    public static _Fields findByName(String name) {
-      return byName.get(name);
-    }
-
-    private final short _thriftId;
-    private final String _fieldName;
-
-    _Fields(short thriftId, String fieldName) {
-      _thriftId = thriftId;
-      _fieldName = fieldName;
-    }
-
-    public short getThriftFieldId() {
-      return _thriftId;
-    }
-
-    public String getFieldName() {
-      return _fieldName;
-    }
-  }
-
-  // isset id assignments
-  private static final int __LIFETIME_ISSET_ID = 0;
-  private static final int __PERSISTEDTIME_ISSET_ID = 1;
-  private byte __isset_bitfield = 0;
-  private _Fields optionals[] = {_Fields.NOT_AFTER,_Fields.PRIVATE_KEY,_Fields.LIFE_TIME,_Fields.NOT_BEFORE,_Fields.PERSISTED_TIME,_Fields.TOKEN};
-  public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-  static {
-    Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-    tmpMap.put(_Fields.COMMUNITY_USER, new org.apache.thrift.meta_data.FieldMetaData("communityUser", org.apache.thrift.TFieldRequirementType.REQUIRED, 
-        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, CommunityUser.class)));
-    tmpMap.put(_Fields.X509_CERT, new org.apache.thrift.meta_data.FieldMetaData("x509Cert", org.apache.thrift.TFieldRequirementType.REQUIRED, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    tmpMap.put(_Fields.NOT_AFTER, new org.apache.thrift.meta_data.FieldMetaData("notAfter", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    tmpMap.put(_Fields.PRIVATE_KEY, new org.apache.thrift.meta_data.FieldMetaData("privateKey", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    tmpMap.put(_Fields.LIFE_TIME, new org.apache.thrift.meta_data.FieldMetaData("lifeTime", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-    tmpMap.put(_Fields.NOT_BEFORE, new org.apache.thrift.meta_data.FieldMetaData("notBefore", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    tmpMap.put(_Fields.PERSISTED_TIME, new org.apache.thrift.meta_data.FieldMetaData("persistedTime", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-    tmpMap.put(_Fields.TOKEN, new org.apache.thrift.meta_data.FieldMetaData("token", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    metaDataMap = Collections.unmodifiableMap(tmpMap);
-    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(CertificateCredential.class, metaDataMap);
-  }
-
-  public CertificateCredential() {
-  }
-
-  public CertificateCredential(
-    CommunityUser communityUser,
-    String x509Cert)
-  {
-    this();
-    this.communityUser = communityUser;
-    this.x509Cert = x509Cert;
-  }
-
-  /**
-   * Performs a deep copy on <i>other</i>.
-   */
-  public CertificateCredential(CertificateCredential other) {
-    __isset_bitfield = other.__isset_bitfield;
-    if (other.isSetCommunityUser()) {
-      this.communityUser = new CommunityUser(other.communityUser);
-    }
-    if (other.isSetX509Cert()) {
-      this.x509Cert = other.x509Cert;
-    }
-    if (other.isSetNotAfter()) {
-      this.notAfter = other.notAfter;
-    }
-    if (other.isSetPrivateKey()) {
-      this.privateKey = other.privateKey;
-    }
-    this.lifeTime = other.lifeTime;
-    if (other.isSetNotBefore()) {
-      this.notBefore = other.notBefore;
-    }
-    this.persistedTime = other.persistedTime;
-    if (other.isSetToken()) {
-      this.token = other.token;
-    }
-  }
-
-  public CertificateCredential deepCopy() {
-    return new CertificateCredential(this);
-  }
-
-  @Override
-  public void clear() {
-    this.communityUser = null;
-    this.x509Cert = null;
-    this.notAfter = null;
-    this.privateKey = null;
-    setLifeTimeIsSet(false);
-    this.lifeTime = 0;
-    this.notBefore = null;
-    setPersistedTimeIsSet(false);
-    this.persistedTime = 0;
-    this.token = null;
-  }
-
-  public CommunityUser getCommunityUser() {
-    return this.communityUser;
-  }
-
-  public CertificateCredential setCommunityUser(CommunityUser communityUser) {
-    this.communityUser = communityUser;
-    return this;
-  }
-
-  public void unsetCommunityUser() {
-    this.communityUser = null;
-  }
-
-  /** Returns true if field communityUser is set (has been assigned a value) and false otherwise */
-  public boolean isSetCommunityUser() {
-    return this.communityUser != null;
-  }
-
-  public void setCommunityUserIsSet(boolean value) {
-    if (!value) {
-      this.communityUser = null;
-    }
-  }
-
-  public String getX509Cert() {
-    return this.x509Cert;
-  }
-
-  public CertificateCredential setX509Cert(String x509Cert) {
-    this.x509Cert = x509Cert;
-    return this;
-  }
-
-  public void unsetX509Cert() {
-    this.x509Cert = null;
-  }
-
-  /** Returns true if field x509Cert is set (has been assigned a value) and false otherwise */
-  public boolean isSetX509Cert() {
-    return this.x509Cert != null;
-  }
-
-  public void setX509CertIsSet(boolean value) {
-    if (!value) {
-      this.x509Cert = null;
-    }
-  }
-
-  public String getNotAfter() {
-    return this.notAfter;
-  }
-
-  public CertificateCredential setNotAfter(String notAfter) {
-    this.notAfter = notAfter;
-    return this;
-  }
-
-  public void unsetNotAfter() {
-    this.notAfter = null;
-  }
-
-  /** Returns true if field notAfter is set (has been assigned a value) and false otherwise */
-  public boolean isSetNotAfter() {
-    return this.notAfter != null;
-  }
-
-  public void setNotAfterIsSet(boolean value) {
-    if (!value) {
-      this.notAfter = null;
-    }
-  }
-
-  public String getPrivateKey() {
-    return this.privateKey;
-  }
-
-  public CertificateCredential setPrivateKey(String privateKey) {
-    this.privateKey = privateKey;
-    return this;
-  }
-
-  public void unsetPrivateKey() {
-    this.privateKey = null;
-  }
-
-  /** Returns true if field privateKey is set (has been assigned a value) and false otherwise */
-  public boolean isSetPrivateKey() {
-    return this.privateKey != null;
-  }
-
-  public void setPrivateKeyIsSet(boolean value) {
-    if (!value) {
-      this.privateKey = null;
-    }
-  }
-
-  public long getLifeTime() {
-    return this.lifeTime;
-  }
-
-  public CertificateCredential setLifeTime(long lifeTime) {
-    this.lifeTime = lifeTime;
-    setLifeTimeIsSet(true);
-    return this;
-  }
-
-  public void unsetLifeTime() {
-    __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __LIFETIME_ISSET_ID);
-  }
-
-  /** Returns true if field lifeTime is set (has been assigned a value) and false otherwise */
-  public boolean isSetLifeTime() {
-    return EncodingUtils.testBit(__isset_bitfield, __LIFETIME_ISSET_ID);
-  }
-
-  public void setLifeTimeIsSet(boolean value) {
-    __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __LIFETIME_ISSET_ID, value);
-  }
-
-  public String getNotBefore() {
-    return this.notBefore;
-  }
-
-  public CertificateCredential setNotBefore(String notBefore) {
-    this.notBefore = notBefore;
-    return this;
-  }
-
-  public void unsetNotBefore() {
-    this.notBefore = null;
-  }
-
-  /** Returns true if field notBefore is set (has been assigned a value) and false otherwise */
-  public boolean isSetNotBefore() {
-    return this.notBefore != null;
-  }
-
-  public void setNotBeforeIsSet(boolean value) {
-    if (!value) {
-      this.notBefore = null;
-    }
-  }
-
-  public long getPersistedTime() {
-    return this.persistedTime;
-  }
-
-  public CertificateCredential setPersistedTime(long persistedTime) {
-    this.persistedTime = persistedTime;
-    setPersistedTimeIsSet(true);
-    return this;
-  }
-
-  public void unsetPersistedTime() {
-    __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID);
-  }
-
-  /** Returns true if field persistedTime is set (has been assigned a value) and false otherwise */
-  public boolean isSetPersistedTime() {
-    return EncodingUtils.testBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID);
-  }
-
-  public void setPersistedTimeIsSet(boolean value) {
-    __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID, value);
-  }
-
-  public String getToken() {
-    return this.token;
-  }
-
-  public CertificateCredential setToken(String token) {
-    this.token = token;
-    return this;
-  }
-
-  public void unsetToken() {
-    this.token = null;
-  }
-
-  /** Returns true if field token is set (has been assigned a value) and false otherwise */
-  public boolean isSetToken() {
-    return this.token != null;
-  }
-
-  public void setTokenIsSet(boolean value) {
-    if (!value) {
-      this.token = null;
-    }
-  }
-
-  public void setFieldValue(_Fields field, Object value) {
-    switch (field) {
-    case COMMUNITY_USER:
-      if (value == null) {
-        unsetCommunityUser();
-      } else {
-        setCommunityUser((CommunityUser)value);
-      }
-      break;
-
-    case X509_CERT:
-      if (value == null) {
-        unsetX509Cert();
-      } else {
-        setX509Cert((String)value);
-      }
-      break;
-
-    case NOT_AFTER:
-      if (value == null) {
-        unsetNotAfter();
-      } else {
-        setNotAfter((String)value);
-      }
-      break;
-
-    case PRIVATE_KEY:
-      if (value == null) {
-        unsetPrivateKey();
-      } else {
-        setPrivateKey((String)value);
-      }
-      break;
-
-    case LIFE_TIME:
-      if (value == null) {
-        unsetLifeTime();
-      } else {
-        setLifeTime((Long)value);
-      }
-      break;
-
-    case NOT_BEFORE:
-      if (value == null) {
-        unsetNotBefore();
-      } else {
-        setNotBefore((String)value);
-      }
-      break;
-
-    case PERSISTED_TIME:
-      if (value == null) {
-        unsetPersistedTime();
-      } else {
-        setPersistedTime((Long)value);
-      }
-      break;
-
-    case TOKEN:
-      if (value == null) {
-        unsetToken();
-      } else {
-        setToken((String)value);
-      }
-      break;
-
-    }
-  }
-
-  public Object getFieldValue(_Fields field) {
-    switch (field) {
-    case COMMUNITY_USER:
-      return getCommunityUser();
-
-    case X509_CERT:
-      return getX509Cert();
-
-    case NOT_AFTER:
-      return getNotAfter();
-
-    case PRIVATE_KEY:
-      return getPrivateKey();
-
-    case LIFE_TIME:
-      return Long.valueOf(getLifeTime());
-
-    case NOT_BEFORE:
-      return getNotBefore();
-
-    case PERSISTED_TIME:
-      return Long.valueOf(getPersistedTime());
-
-    case TOKEN:
-      return getToken();
-
-    }
-    throw new IllegalStateException();
-  }
-
-  /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-  public boolean isSet(_Fields field) {
-    if (field == null) {
-      throw new IllegalArgumentException();
-    }
-
-    switch (field) {
-    case COMMUNITY_USER:
-      return isSetCommunityUser();
-    case X509_CERT:
-      return isSetX509Cert();
-    case NOT_AFTER:
-      return isSetNotAfter();
-    case PRIVATE_KEY:
-      return isSetPrivateKey();
-    case LIFE_TIME:
-      return isSetLifeTime();
-    case NOT_BEFORE:
-      return isSetNotBefore();
-    case PERSISTED_TIME:
-      return isSetPersistedTime();
-    case TOKEN:
-      return isSetToken();
-    }
-    throw new IllegalStateException();
-  }
-
-  @Override
-  public boolean equals(Object that) {
-    if (that == null)
-      return false;
-    if (that instanceof CertificateCredential)
-      return this.equals((CertificateCredential)that);
-    return false;
-  }
-
-  public boolean equals(CertificateCredential that) {
-    if (that == null)
-      return false;
-
-    boolean this_present_communityUser = true && this.isSetCommunityUser();
-    boolean that_present_communityUser = true && that.isSetCommunityUser();
-    if (this_present_communityUser || that_present_communityUser) {
-      if (!(this_present_communityUser && that_present_communityUser))
-        return false;
-      if (!this.communityUser.equals(that.communityUser))
-        return false;
-    }
-
-    boolean this_present_x509Cert = true && this.isSetX509Cert();
-    boolean that_present_x509Cert = true && that.isSetX509Cert();
-    if (this_present_x509Cert || that_present_x509Cert) {
-      if (!(this_present_x509Cert && that_present_x509Cert))
-        return false;
-      if (!this.x509Cert.equals(that.x509Cert))
-        return false;
-    }
-
-    boolean this_present_notAfter = true && this.isSetNotAfter();
-    boolean that_present_notAfter = true && that.isSetNotAfter();
-    if (this_present_notAfter || that_present_notAfter) {
-      if (!(this_present_notAfter && that_present_notAfter))
-        return false;
-      if (!this.notAfter.equals(that.notAfter))
-        return false;
-    }
-
-    boolean this_present_privateKey = true && this.isSetPrivateKey();
-    boolean that_present_privateKey = true && that.isSetPrivateKey();
-    if (this_present_privateKey || that_present_privateKey) {
-      if (!(this_present_privateKey && that_present_privateKey))
-        return false;
-      if (!this.privateKey.equals(that.privateKey))
-        return false;
-    }
-
-    boolean this_present_lifeTime = true && this.isSetLifeTime();
-    boolean that_present_lifeTime = true && that.isSetLifeTime();
-    if (this_present_lifeTime || that_present_lifeTime) {
-      if (!(this_present_lifeTime && that_present_lifeTime))
-        return false;
-      if (this.lifeTime != that.lifeTime)
-        return false;
-    }
-
-    boolean this_present_notBefore = true && this.isSetNotBefore();
-    boolean that_present_notBefore = true && that.isSetNotBefore();
-    if (this_present_notBefore || that_present_notBefore) {
-      if (!(this_present_notBefore && that_present_notBefore))
-        return false;
-      if (!this.notBefore.equals(that.notBefore))
-        return false;
-    }
-
-    boolean this_present_persistedTime = true && this.isSetPersistedTime();
-    boolean that_present_persistedTime = true && that.isSetPersistedTime();
-    if (this_present_persistedTime || that_present_persistedTime) {
-      if (!(this_present_persistedTime && that_present_persistedTime))
-        return false;
-      if (this.persistedTime != that.persistedTime)
-        return false;
-    }
-
-    boolean this_present_token = true && this.isSetToken();
-    boolean that_present_token = true && that.isSetToken();
-    if (this_present_token || that_present_token) {
-      if (!(this_present_token && that_present_token))
-        return false;
-      if (!this.token.equals(that.token))
-        return false;
-    }
-
-    return true;
-  }
-
-  @Override
-  public int hashCode() {
-    return 0;
-  }
-
-  @Override
-  public int compareTo(CertificateCredential other) {
-    if (!getClass().equals(other.getClass())) {
-      return getClass().getName().compareTo(other.getClass().getName());
-    }
-
-    int lastComparison = 0;
-
-    lastComparison = Boolean.valueOf(isSetCommunityUser()).compareTo(other.isSetCommunityUser());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetCommunityUser()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.communityUser, other.communityUser);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetX509Cert()).compareTo(other.isSetX509Cert());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetX509Cert()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.x509Cert, other.x509Cert);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetNotAfter()).compareTo(other.isSetNotAfter());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetNotAfter()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.notAfter, other.notAfter);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetPrivateKey()).compareTo(other.isSetPrivateKey());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetPrivateKey()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.privateKey, other.privateKey);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetLifeTime()).compareTo(other.isSetLifeTime());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetLifeTime()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.lifeTime, other.lifeTime);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetNotBefore()).compareTo(other.isSetNotBefore());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetNotBefore()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.notBefore, other.notBefore);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetPersistedTime()).compareTo(other.isSetPersistedTime());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetPersistedTime()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.persistedTime, other.persistedTime);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetToken()).compareTo(other.isSetToken());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetToken()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.token, other.token);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    return 0;
-  }
-
-  public _Fields fieldForId(int fieldId) {
-    return _Fields.findByThriftId(fieldId);
-  }
-
-  public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-    schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
-  }
-
-  public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-    schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
-  }
-
-  @Override
-  public String toString() {
-    StringBuilder sb = new StringBuilder("CertificateCredential(");
-    boolean first = true;
-
-    sb.append("communityUser:");
-    if (this.communityUser == null) {
-      sb.append("null");
-    } else {
-      sb.append(this.communityUser);
-    }
-    first = false;
-    if (!first) sb.append(", ");
-    sb.append("x509Cert:");
-    if (this.x509Cert == null) {
-      sb.append("null");
-    } else {
-      sb.append(this.x509Cert);
-    }
-    first = false;
-    if (isSetNotAfter()) {
-      if (!first) sb.append(", ");
-      sb.append("notAfter:");
-      if (this.notAfter == null) {
-        sb.append("null");
-      } else {
-        sb.append(this.notAfter);
-      }
-      first = false;
-    }
-    if (isSetPrivateKey()) {
-      if (!first) sb.append(", ");
-      sb.append("privateKey:");
-      if (this.privateKey == null) {
-        sb.append("null");
-      } else {
-        sb.append(this.privateKey);
-      }
-      first = false;
-    }
-    if (isSetLifeTime()) {
-      if (!first) sb.append(", ");
-      sb.append("lifeTime:");
-      sb.append(this.lifeTime);
-      first = false;
-    }
-    if (isSetNotBefore()) {
-      if (!first) sb.append(", ");
-      sb.append("notBefore:");
-      if (this.notBefore == null) {
-        sb.append("null");
-      } else {
-        sb.append(this.notBefore);
-      }
-      first = false;
-    }
-    if (isSetPersistedTime()) {
-      if (!first) sb.append(", ");
-      sb.append("persistedTime:");
-      sb.append(this.persistedTime);
-      first = false;
-    }
-    if (isSetToken()) {
-      if (!first) sb.append(", ");
-      sb.append("token:");
-      if (this.token == null) {
-        sb.append("null");
-      } else {
-        sb.append(this.token);
-      }
-      first = false;
-    }
-    sb.append(")");
-    return sb.toString();
-  }
-
-  public void validate() throws org.apache.thrift.TException {
-    // check for required fields
-    if (communityUser == null) {
-      throw new org.apache.thrift.protocol.TProtocolException("Required field 'communityUser' was not present! Struct: " + toString());
-    }
-    if (x509Cert == null) {
-      throw new org.apache.thrift.protocol.TProtocolException("Required field 'x509Cert' was not present! Struct: " + toString());
-    }
-    // check for sub-struct validity
-    if (communityUser != null) {
-      communityUser.validate();
-    }
-  }
-
-  private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-    try {
-      write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-    } catch (org.apache.thrift.TException te) {
-      throw new java.io.IOException(te);
-    }
-  }
-
-  private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-    try {
-      // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
-      __isset_bitfield = 0;
-      read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-    } catch (org.apache.thrift.TException te) {
-      throw new java.io.IOException(te);
-    }
-  }
-
-  private static class CertificateCredentialStandardSchemeFactory implements SchemeFactory {
-    public CertificateCredentialStandardScheme getScheme() {
-      return new CertificateCredentialStandardScheme();
-    }
-  }
-
-  private static class CertificateCredentialStandardScheme extends StandardScheme<CertificateCredential> {
-
-    public void read(org.apache.thrift.protocol.TProtocol iprot, CertificateCredential struct) throws org.apache.thrift.TException {
-      org.apache.thrift.protocol.TField schemeField;
-      iprot.readStructBegin();
-      while (true)
-      {
-        schemeField = iprot.readFieldBegin();
-        if (schemeField.type == org.apache.thrift.protocol.TType.STOP) { 
-          break;
-        }
-        switch (schemeField.id) {
-          case 1: // COMMUNITY_USER
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
-              struct.communityUser = new CommunityUser();
-              struct.communityUser.read(iprot);
-              struct.setCommunityUserIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 2: // X509_CERT
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.x509Cert = iprot.readString();
-              struct.setX509CertIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 3: // NOT_AFTER
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.notAfter = iprot.readString();
-              struct.setNotAfterIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 4: // PRIVATE_KEY
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.privateKey = iprot.readString();
-              struct.setPrivateKeyIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 5: // LIFE_TIME
-            if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
-              struct.lifeTime = iprot.readI64();
-              struct.setLifeTimeIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 6: // NOT_BEFORE
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.notBefore = iprot.readString();
-              struct.setNotBeforeIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 7: // PERSISTED_TIME
-            if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
-              struct.persistedTime = iprot.readI64();
-              struct.setPersistedTimeIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 8: // TOKEN
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.token = iprot.readString();
-              struct.setTokenIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          default:
-            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-        }
-        iprot.readFieldEnd();
-      }
-      iprot.readStructEnd();
-
-      // check for required fields of primitive type, which can't be checked in the validate method
-      struct.validate();
-    }
-
-    public void write(org.apache.thrift.protocol.TProtocol oprot, CertificateCredential struct) throws org.apache.thrift.TException {
-      struct.validate();
-
-      oprot.writeStructBegin(STRUCT_DESC);
-      if (struct.communityUser != null) {
-        oprot.writeFieldBegin(COMMUNITY_USER_FIELD_DESC);
-        struct.communityUser.write(oprot);
-        oprot.writeFieldEnd();
-      }
-      if (struct.x509Cert != null) {
-        oprot.writeFieldBegin(X509_CERT_FIELD_DESC);
-        oprot.writeString(struct.x509Cert);
-        oprot.writeFieldEnd();
-      }
-      if (struct.notAfter != null) {
-        if (struct.isSetNotAfter()) {
-          oprot.writeFieldBegin(NOT_AFTER_FIELD_DESC);
-          oprot.writeString(struct.notAfter);
-          oprot.writeFieldEnd();
-        }
-      }
-      if (struct.privateKey != null) {
-        if (struct.isSetPrivateKey()) {
-          oprot.writeFieldBegin(PRIVATE_KEY_FIELD_DESC);
-          oprot.writeString(struct.privateKey);
-          oprot.writeFieldEnd();
-        }
-      }
-      if (struct.isSetLifeTime()) {
-        oprot.writeFieldBegin(LIFE_TIME_FIELD_DESC);
-        oprot.writeI64(struct.lifeTime);
-        oprot.writeFieldEnd();
-      }
-      if (struct.notBefore != null) {
-        if (struct.isSetNotBefore()) {
-          oprot.writeFieldBegin(NOT_BEFORE_FIELD_DESC);
-          oprot.writeString(struct.notBefore);
-          oprot.writeFieldEnd();
-        }
-      }
-      if (struct.isSetPersistedTime()) {
-        oprot.writeFieldBegin(PERSISTED_TIME_FIELD_DESC);
-        oprot.writeI64(struct.persistedTime);
-        oprot.writeFieldEnd();
-      }
-      if (struct.token != null) {
-        if (struct.isSetToken()) {
-          oprot.writeFieldBegin(TOKEN_FIELD_DESC);
-          oprot.writeString(struct.token);
-          oprot.writeFieldEnd();
-        }
-      }
-      oprot.writeFieldStop();
-      oprot.writeStructEnd();
-    }
-
-  }
-
-  private static class CertificateCredentialTupleSchemeFactory implements SchemeFactory {
-    public CertificateCredentialTupleScheme getScheme() {
-      return new CertificateCredentialTupleScheme();
-    }
-  }
-
-  private static class CertificateCredentialTupleScheme extends TupleScheme<CertificateCredential> {
-
-    @Override
-    public void write(org.apache.thrift.protocol.TProtocol prot, CertificateCredential struct) throws org.apache.thrift.TException {
-      TTupleProtocol oprot = (TTupleProtocol) prot;
-      struct.communityUser.write(oprot);
-      oprot.writeString(struct.x509Cert);
-      BitSet optionals = new BitSet();
-      if (struct.isSetNotAfter()) {
-        optionals.set(0);
-      }
-      if (struct.isSetPrivateKey()) {
-        optionals.set(1);
-      }
-      if (struct.isSetLifeTime()) {
-        optionals.set(2);
-      }
-      if (struct.isSetNotBefore()) {
-        optionals.set(3);
-      }
-      if (struct.isSetPersistedTime()) {
-        optionals.set(4);
-      }
-      if (struct.isSetToken()) {
-        optionals.set(5);
-      }
-      oprot.writeBitSet(optionals, 6);
-      if (struct.isSetNotAfter()) {
-        oprot.writeString(struct.notAfter);
-      }
-      if (struct.isSetPrivateKey()) {
-        oprot.writeString(struct.privateKey);
-      }
-      if (struct.isSetLifeTime()) {
-        oprot.writeI64(struct.lifeTime);
-      }
-      if (struct.isSetNotBefore()) {
-        oprot.writeString(struct.notBefore);
-      }
-      if (struct.isSetPersistedTime()) {
-        oprot.writeI64(struct.persistedTime);
-      }
-      if (struct.isSetToken()) {
-        oprot.writeString(struct.token);
-      }
-    }
-
-    @Override
-    public void read(org.apache.thrift.protocol.TProtocol prot, CertificateCredential struct) throws org.apache.thrift.TException {
-      TTupleProtocol iprot = (TTupleProtocol) prot;
-      struct.communityUser = new CommunityUser();
-      struct.communityUser.read(iprot);
-      struct.setCommunityUserIsSet(true);
-      struct.x509Cert = iprot.readString();
-      struct.setX509CertIsSet(true);
-      BitSet incoming = iprot.readBitSet(6);
-      if (incoming.get(0)) {
-        struct.notAfter = iprot.readString();
-        struct.setNotAfterIsSet(true);
-      }
-      if (incoming.get(1)) {
-        struct.privateKey = iprot.readString();
-        struct.setPrivateKeyIsSet(true);
-      }
-      if (incoming.get(2)) {
-        struct.lifeTime = iprot.readI64();
-        struct.setLifeTimeIsSet(true);
-      }
-      if (incoming.get(3)) {
-        struct.notBefore = iprot.readString();
-        struct.setNotBeforeIsSet(true);
-      }
-      if (incoming.get(4)) {
-        struct.persistedTime = iprot.readI64();
-        struct.setPersistedTimeIsSet(true);
-      }
-      if (incoming.get(5)) {
-        struct.token = iprot.readString();
-        struct.setTokenIsSet(true);
-      }
-    }
-  }
-
-}
-

http://git-wip-us.apache.org/repos/asf/airavata/blob/b25e0a5d/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/CommunityUser.java
----------------------------------------------------------------------
diff --git a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/CommunityUser.java b/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/CommunityUser.java
deleted file mode 100644
index 9b62310..0000000
--- a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/CommunityUser.java
+++ /dev/null
@@ -1,589 +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.
-     */
-/**
- * Autogenerated by Thrift Compiler (0.9.1)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- *  @generated
- */
-package org.apache.airavata.credential.store.datamodel;
-
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-import org.apache.thrift.protocol.TTupleProtocol;
-import org.apache.thrift.protocol.TProtocolException;
-import org.apache.thrift.EncodingUtils;
-import org.apache.thrift.TException;
-import org.apache.thrift.async.AsyncMethodCallback;
-import org.apache.thrift.server.AbstractNonblockingServer.*;
-import java.util.List;
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-import java.util.Collections;
-import java.util.BitSet;
-import java.nio.ByteBuffer;
-import java.util.Arrays;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings("all") public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, CommunityUser._Fields>, java.io.Serializable, Cloneable, Comparable<CommunityUser> {
-  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("CommunityUser");
-
-  private static final org.apache.thrift.protocol.TField GATEWAY_NMAE_FIELD_DESC = new org.apache.thrift.protocol.TField("gatewayNmae", org.apache.thrift.protocol.TType.STRING, (short)1);
-  private static final org.apache.thrift.protocol.TField USERNAME_FIELD_DESC = new org.apache.thrift.protocol.TField("username", org.apache.thrift.protocol.TType.STRING, (short)2);
-  private static final org.apache.thrift.protocol.TField USER_EMAIL_FIELD_DESC = new org.apache.thrift.protocol.TField("userEmail", org.apache.thrift.protocol.TType.STRING, (short)3);
-
-  private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
-  static {
-    schemes.put(StandardScheme.class, new CommunityUserStandardSchemeFactory());
-    schemes.put(TupleScheme.class, new CommunityUserTupleSchemeFactory());
-  }
-
-  public String gatewayNmae; // required
-  public String username; // required
-  public String userEmail; // required
-
-  /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-  @SuppressWarnings("all") public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-    GATEWAY_NMAE((short)1, "gatewayNmae"),
-    USERNAME((short)2, "username"),
-    USER_EMAIL((short)3, "userEmail");
-
-    private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
-    static {
-      for (_Fields field : EnumSet.allOf(_Fields.class)) {
-        byName.put(field.getFieldName(), field);
-      }
-    }
-
-    /**
-     * Find the _Fields constant that matches fieldId, or null if its not found.
-     */
-    public static _Fields findByThriftId(int fieldId) {
-      switch(fieldId) {
-        case 1: // GATEWAY_NMAE
-          return GATEWAY_NMAE;
-        case 2: // USERNAME
-          return USERNAME;
-        case 3: // USER_EMAIL
-          return USER_EMAIL;
-        default:
-          return null;
-      }
-    }
-
-    /**
-     * Find the _Fields constant that matches fieldId, throwing an exception
-     * if it is not found.
-     */
-    public static _Fields findByThriftIdOrThrow(int fieldId) {
-      _Fields fields = findByThriftId(fieldId);
-      if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-      return fields;
-    }
-
-    /**
-     * Find the _Fields constant that matches name, or null if its not found.
-     */
-    public static _Fields findByName(String name) {
-      return byName.get(name);
-    }
-
-    private final short _thriftId;
-    private final String _fieldName;
-
-    _Fields(short thriftId, String fieldName) {
-      _thriftId = thriftId;
-      _fieldName = fieldName;
-    }
-
-    public short getThriftFieldId() {
-      return _thriftId;
-    }
-
-    public String getFieldName() {
-      return _fieldName;
-    }
-  }
-
-  // isset id assignments
-  public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-  static {
-    Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-    tmpMap.put(_Fields.GATEWAY_NMAE, new org.apache.thrift.meta_data.FieldMetaData("gatewayNmae", org.apache.thrift.TFieldRequirementType.REQUIRED, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    tmpMap.put(_Fields.USERNAME, new org.apache.thrift.meta_data.FieldMetaData("username", org.apache.thrift.TFieldRequirementType.REQUIRED, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    tmpMap.put(_Fields.USER_EMAIL, new org.apache.thrift.meta_data.FieldMetaData("userEmail", org.apache.thrift.TFieldRequirementType.REQUIRED, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    metaDataMap = Collections.unmodifiableMap(tmpMap);
-    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(CommunityUser.class, metaDataMap);
-  }
-
-  public CommunityUser() {
-  }
-
-  public CommunityUser(
-    String gatewayNmae,
-    String username,
-    String userEmail)
-  {
-    this();
-    this.gatewayNmae = gatewayNmae;
-    this.username = username;
-    this.userEmail = userEmail;
-  }
-
-  /**
-   * Performs a deep copy on <i>other</i>.
-   */
-  public CommunityUser(CommunityUser other) {
-    if (other.isSetGatewayNmae()) {
-      this.gatewayNmae = other.gatewayNmae;
-    }
-    if (other.isSetUsername()) {
-      this.username = other.username;
-    }
-    if (other.isSetUserEmail()) {
-      this.userEmail = other.userEmail;
-    }
-  }
-
-  public CommunityUser deepCopy() {
-    return new CommunityUser(this);
-  }
-
-  @Override
-  public void clear() {
-    this.gatewayNmae = null;
-    this.username = null;
-    this.userEmail = null;
-  }
-
-  public String getGatewayNmae() {
-    return this.gatewayNmae;
-  }
-
-  public CommunityUser setGatewayNmae(String gatewayNmae) {
-    this.gatewayNmae = gatewayNmae;
-    return this;
-  }
-
-  public void unsetGatewayNmae() {
-    this.gatewayNmae = null;
-  }
-
-  /** Returns true if field gatewayNmae is set (has been assigned a value) and false otherwise */
-  public boolean isSetGatewayNmae() {
-    return this.gatewayNmae != null;
-  }
-
-  public void setGatewayNmaeIsSet(boolean value) {
-    if (!value) {
-      this.gatewayNmae = null;
-    }
-  }
-
-  public String getUsername() {
-    return this.username;
-  }
-
-  public CommunityUser setUsername(String username) {
-    this.username = username;
-    return this;
-  }
-
-  public void unsetUsername() {
-    this.username = null;
-  }
-
-  /** Returns true if field username is set (has been assigned a value) and false otherwise */
-  public boolean isSetUsername() {
-    return this.username != null;
-  }
-
-  public void setUsernameIsSet(boolean value) {
-    if (!value) {
-      this.username = null;
-    }
-  }
-
-  public String getUserEmail() {
-    return this.userEmail;
-  }
-
-  public CommunityUser setUserEmail(String userEmail) {
-    this.userEmail = userEmail;
-    return this;
-  }
-
-  public void unsetUserEmail() {
-    this.userEmail = null;
-  }
-
-  /** Returns true if field userEmail is set (has been assigned a value) and false otherwise */
-  public boolean isSetUserEmail() {
-    return this.userEmail != null;
-  }
-
-  public void setUserEmailIsSet(boolean value) {
-    if (!value) {
-      this.userEmail = null;
-    }
-  }
-
-  public void setFieldValue(_Fields field, Object value) {
-    switch (field) {
-    case GATEWAY_NMAE:
-      if (value == null) {
-        unsetGatewayNmae();
-      } else {
-        setGatewayNmae((String)value);
-      }
-      break;
-
-    case USERNAME:
-      if (value == null) {
-        unsetUsername();
-      } else {
-        setUsername((String)value);
-      }
-      break;
-
-    case USER_EMAIL:
-      if (value == null) {
-        unsetUserEmail();
-      } else {
-        setUserEmail((String)value);
-      }
-      break;
-
-    }
-  }
-
-  public Object getFieldValue(_Fields field) {
-    switch (field) {
-    case GATEWAY_NMAE:
-      return getGatewayNmae();
-
-    case USERNAME:
-      return getUsername();
-
-    case USER_EMAIL:
-      return getUserEmail();
-
-    }
-    throw new IllegalStateException();
-  }
-
-  /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-  public boolean isSet(_Fields field) {
-    if (field == null) {
-      throw new IllegalArgumentException();
-    }
-
-    switch (field) {
-    case GATEWAY_NMAE:
-      return isSetGatewayNmae();
-    case USERNAME:
-      return isSetUsername();
-    case USER_EMAIL:
-      return isSetUserEmail();
-    }
-    throw new IllegalStateException();
-  }
-
-  @Override
-  public boolean equals(Object that) {
-    if (that == null)
-      return false;
-    if (that instanceof CommunityUser)
-      return this.equals((CommunityUser)that);
-    return false;
-  }
-
-  public boolean equals(CommunityUser that) {
-    if (that == null)
-      return false;
-
-    boolean this_present_gatewayNmae = true && this.isSetGatewayNmae();
-    boolean that_present_gatewayNmae = true && that.isSetGatewayNmae();
-    if (this_present_gatewayNmae || that_present_gatewayNmae) {
-      if (!(this_present_gatewayNmae && that_present_gatewayNmae))
-        return false;
-      if (!this.gatewayNmae.equals(that.gatewayNmae))
-        return false;
-    }
-
-    boolean this_present_username = true && this.isSetUsername();
-    boolean that_present_username = true && that.isSetUsername();
-    if (this_present_username || that_present_username) {
-      if (!(this_present_username && that_present_username))
-        return false;
-      if (!this.username.equals(that.username))
-        return false;
-    }
-
-    boolean this_present_userEmail = true && this.isSetUserEmail();
-    boolean that_present_userEmail = true && that.isSetUserEmail();
-    if (this_present_userEmail || that_present_userEmail) {
-      if (!(this_present_userEmail && that_present_userEmail))
-        return false;
-      if (!this.userEmail.equals(that.userEmail))
-        return false;
-    }
-
-    return true;
-  }
-
-  @Override
-  public int hashCode() {
-    return 0;
-  }
-
-  @Override
-  public int compareTo(CommunityUser other) {
-    if (!getClass().equals(other.getClass())) {
-      return getClass().getName().compareTo(other.getClass().getName());
-    }
-
-    int lastComparison = 0;
-
-    lastComparison = Boolean.valueOf(isSetGatewayNmae()).compareTo(other.isSetGatewayNmae());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetGatewayNmae()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayNmae, other.gatewayNmae);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetUsername()).compareTo(other.isSetUsername());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetUsername()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.username, other.username);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetUserEmail()).compareTo(other.isSetUserEmail());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetUserEmail()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.userEmail, other.userEmail);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    return 0;
-  }
-
-  public _Fields fieldForId(int fieldId) {
-    return _Fields.findByThriftId(fieldId);
-  }
-
-  public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-    schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
-  }
-
-  public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-    schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
-  }
-
-  @Override
-  public String toString() {
-    StringBuilder sb = new StringBuilder("CommunityUser(");
-    boolean first = true;
-
-    sb.append("gatewayNmae:");
-    if (this.gatewayNmae == null) {
-      sb.append("null");
-    } else {
-      sb.append(this.gatewayNmae);
-    }
-    first = false;
-    if (!first) sb.append(", ");
-    sb.append("username:");
-    if (this.username == null) {
-      sb.append("null");
-    } else {
-      sb.append(this.username);
-    }
-    first = false;
-    if (!first) sb.append(", ");
-    sb.append("userEmail:");
-    if (this.userEmail == null) {
-      sb.append("null");
-    } else {
-      sb.append(this.userEmail);
-    }
-    first = false;
-    sb.append(")");
-    return sb.toString();
-  }
-
-  public void validate() throws org.apache.thrift.TException {
-    // check for required fields
-    if (gatewayNmae == null) {
-      throw new org.apache.thrift.protocol.TProtocolException("Required field 'gatewayNmae' was not present! Struct: " + toString());
-    }
-    if (username == null) {
-      throw new org.apache.thrift.protocol.TProtocolException("Required field 'username' was not present! Struct: " + toString());
-    }
-    if (userEmail == null) {
-      throw new org.apache.thrift.protocol.TProtocolException("Required field 'userEmail' was not present! Struct: " + toString());
-    }
-    // check for sub-struct validity
-  }
-
-  private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-    try {
-      write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-    } catch (org.apache.thrift.TException te) {
-      throw new java.io.IOException(te);
-    }
-  }
-
-  private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-    try {
-      read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-    } catch (org.apache.thrift.TException te) {
-      throw new java.io.IOException(te);
-    }
-  }
-
-  private static class CommunityUserStandardSchemeFactory implements SchemeFactory {
-    public CommunityUserStandardScheme getScheme() {
-      return new CommunityUserStandardScheme();
-    }
-  }
-
-  private static class CommunityUserStandardScheme extends StandardScheme<CommunityUser> {
-
-    public void read(org.apache.thrift.protocol.TProtocol iprot, CommunityUser struct) throws org.apache.thrift.TException {
-      org.apache.thrift.protocol.TField schemeField;
-      iprot.readStructBegin();
-      while (true)
-      {
-        schemeField = iprot.readFieldBegin();
-        if (schemeField.type == org.apache.thrift.protocol.TType.STOP) { 
-          break;
-        }
-        switch (schemeField.id) {
-          case 1: // GATEWAY_NMAE
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.gatewayNmae = iprot.readString();
-              struct.setGatewayNmaeIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 2: // USERNAME
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.username = iprot.readString();
-              struct.setUsernameIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 3: // USER_EMAIL
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.userEmail = iprot.readString();
-              struct.setUserEmailIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          default:
-            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-        }
-        iprot.readFieldEnd();
-      }
-      iprot.readStructEnd();
-
-      // check for required fields of primitive type, which can't be checked in the validate method
-      struct.validate();
-    }
-
-    public void write(org.apache.thrift.protocol.TProtocol oprot, CommunityUser struct) throws org.apache.thrift.TException {
-      struct.validate();
-
-      oprot.writeStructBegin(STRUCT_DESC);
-      if (struct.gatewayNmae != null) {
-        oprot.writeFieldBegin(GATEWAY_NMAE_FIELD_DESC);
-        oprot.writeString(struct.gatewayNmae);
-        oprot.writeFieldEnd();
-      }
-      if (struct.username != null) {
-        oprot.writeFieldBegin(USERNAME_FIELD_DESC);
-        oprot.writeString(struct.username);
-        oprot.writeFieldEnd();
-      }
-      if (struct.userEmail != null) {
-        oprot.writeFieldBegin(USER_EMAIL_FIELD_DESC);
-        oprot.writeString(struct.userEmail);
-        oprot.writeFieldEnd();
-      }
-      oprot.writeFieldStop();
-      oprot.writeStructEnd();
-    }
-
-  }
-
-  private static class CommunityUserTupleSchemeFactory implements SchemeFactory {
-    public CommunityUserTupleScheme getScheme() {
-      return new CommunityUserTupleScheme();
-    }
-  }
-
-  private static class CommunityUserTupleScheme extends TupleScheme<CommunityUser> {
-
-    @Override
-    public void write(org.apache.thrift.protocol.TProtocol prot, CommunityUser struct) throws org.apache.thrift.TException {
-      TTupleProtocol oprot = (TTupleProtocol) prot;
-      oprot.writeString(struct.gatewayNmae);
-      oprot.writeString(struct.username);
-      oprot.writeString(struct.userEmail);
-    }
-
-    @Override
-    public void read(org.apache.thrift.protocol.TProtocol prot, CommunityUser struct) throws org.apache.thrift.TException {
-      TTupleProtocol iprot = (TTupleProtocol) prot;
-      struct.gatewayNmae = iprot.readString();
-      struct.setGatewayNmaeIsSet(true);
-      struct.username = iprot.readString();
-      struct.setUsernameIsSet(true);
-      struct.userEmail = iprot.readString();
-      struct.setUserEmailIsSet(true);
-    }
-  }
-
-}
-

http://git-wip-us.apache.org/repos/asf/airavata/blob/b25e0a5d/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/PasswordCredential.java
----------------------------------------------------------------------
diff --git a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/PasswordCredential.java b/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/PasswordCredential.java
deleted file mode 100644
index f6b6837..0000000
--- a/modules/credential-store/credential-store-service/src/main/java/org/apache/airavata/credential/store/datamodel/PasswordCredential.java
+++ /dev/null
@@ -1,698 +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.
-     */
-/**
- * Autogenerated by Thrift Compiler (0.9.1)
- *
- * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
- *  @generated
- */
-package org.apache.airavata.credential.store.datamodel;
-
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-import org.apache.thrift.protocol.TTupleProtocol;
-import org.apache.thrift.protocol.TProtocolException;
-import org.apache.thrift.EncodingUtils;
-import org.apache.thrift.TException;
-import org.apache.thrift.async.AsyncMethodCallback;
-import org.apache.thrift.server.AbstractNonblockingServer.*;
-import java.util.List;
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-import java.util.Collections;
-import java.util.BitSet;
-import java.nio.ByteBuffer;
-import java.util.Arrays;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings("all") public class PasswordCredential implements org.apache.thrift.TBase<PasswordCredential, PasswordCredential._Fields>, java.io.Serializable, Cloneable, Comparable<PasswordCredential> {
-  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("PasswordCredential");
-
-  private static final org.apache.thrift.protocol.TField USERNAME_FIELD_DESC = new org.apache.thrift.protocol.TField("username", org.apache.thrift.protocol.TType.STRING, (short)1);
-  private static final org.apache.thrift.protocol.TField PASSWORD_FIELD_DESC = new org.apache.thrift.protocol.TField("password", org.apache.thrift.protocol.TType.STRING, (short)2);
-  private static final org.apache.thrift.protocol.TField PERSISTED_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("persistedTime", org.apache.thrift.protocol.TType.I64, (short)3);
-  private static final org.apache.thrift.protocol.TField TOKEN_FIELD_DESC = new org.apache.thrift.protocol.TField("token", org.apache.thrift.protocol.TType.STRING, (short)4);
-
-  private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
-  static {
-    schemes.put(StandardScheme.class, new PasswordCredentialStandardSchemeFactory());
-    schemes.put(TupleScheme.class, new PasswordCredentialTupleSchemeFactory());
-  }
-
-  public String username; // required
-  public String password; // required
-  public long persistedTime; // optional
-  public String token; // optional
-
-  /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-  @SuppressWarnings("all") public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-    USERNAME((short)1, "username"),
-    PASSWORD((short)2, "password"),
-    PERSISTED_TIME((short)3, "persistedTime"),
-    TOKEN((short)4, "token");
-
-    private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
-    static {
-      for (_Fields field : EnumSet.allOf(_Fields.class)) {
-        byName.put(field.getFieldName(), field);
-      }
-    }
-
-    /**
-     * Find the _Fields constant that matches fieldId, or null if its not found.
-     */
-    public static _Fields findByThriftId(int fieldId) {
-      switch(fieldId) {
-        case 1: // USERNAME
-          return USERNAME;
-        case 2: // PASSWORD
-          return PASSWORD;
-        case 3: // PERSISTED_TIME
-          return PERSISTED_TIME;
-        case 4: // TOKEN
-          return TOKEN;
-        default:
-          return null;
-      }
-    }
-
-    /**
-     * Find the _Fields constant that matches fieldId, throwing an exception
-     * if it is not found.
-     */
-    public static _Fields findByThriftIdOrThrow(int fieldId) {
-      _Fields fields = findByThriftId(fieldId);
-      if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-      return fields;
-    }
-
-    /**
-     * Find the _Fields constant that matches name, or null if its not found.
-     */
-    public static _Fields findByName(String name) {
-      return byName.get(name);
-    }
-
-    private final short _thriftId;
-    private final String _fieldName;
-
-    _Fields(short thriftId, String fieldName) {
-      _thriftId = thriftId;
-      _fieldName = fieldName;
-    }
-
-    public short getThriftFieldId() {
-      return _thriftId;
-    }
-
-    public String getFieldName() {
-      return _fieldName;
-    }
-  }
-
-  // isset id assignments
-  private static final int __PERSISTEDTIME_ISSET_ID = 0;
-  private byte __isset_bitfield = 0;
-  private _Fields optionals[] = {_Fields.PERSISTED_TIME,_Fields.TOKEN};
-  public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-  static {
-    Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-    tmpMap.put(_Fields.USERNAME, new org.apache.thrift.meta_data.FieldMetaData("username", org.apache.thrift.TFieldRequirementType.REQUIRED, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    tmpMap.put(_Fields.PASSWORD, new org.apache.thrift.meta_data.FieldMetaData("password", org.apache.thrift.TFieldRequirementType.REQUIRED, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    tmpMap.put(_Fields.PERSISTED_TIME, new org.apache.thrift.meta_data.FieldMetaData("persistedTime", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-    tmpMap.put(_Fields.TOKEN, new org.apache.thrift.meta_data.FieldMetaData("token", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
-        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
-    metaDataMap = Collections.unmodifiableMap(tmpMap);
-    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(PasswordCredential.class, metaDataMap);
-  }
-
-  public PasswordCredential() {
-  }
-
-  public PasswordCredential(
-    String username,
-    String password)
-  {
-    this();
-    this.username = username;
-    this.password = password;
-  }
-
-  /**
-   * Performs a deep copy on <i>other</i>.
-   */
-  public PasswordCredential(PasswordCredential other) {
-    __isset_bitfield = other.__isset_bitfield;
-    if (other.isSetUsername()) {
-      this.username = other.username;
-    }
-    if (other.isSetPassword()) {
-      this.password = other.password;
-    }
-    this.persistedTime = other.persistedTime;
-    if (other.isSetToken()) {
-      this.token = other.token;
-    }
-  }
-
-  public PasswordCredential deepCopy() {
-    return new PasswordCredential(this);
-  }
-
-  @Override
-  public void clear() {
-    this.username = null;
-    this.password = null;
-    setPersistedTimeIsSet(false);
-    this.persistedTime = 0;
-    this.token = null;
-  }
-
-  public String getUsername() {
-    return this.username;
-  }
-
-  public PasswordCredential setUsername(String username) {
-    this.username = username;
-    return this;
-  }
-
-  public void unsetUsername() {
-    this.username = null;
-  }
-
-  /** Returns true if field username is set (has been assigned a value) and false otherwise */
-  public boolean isSetUsername() {
-    return this.username != null;
-  }
-
-  public void setUsernameIsSet(boolean value) {
-    if (!value) {
-      this.username = null;
-    }
-  }
-
-  public String getPassword() {
-    return this.password;
-  }
-
-  public PasswordCredential setPassword(String password) {
-    this.password = password;
-    return this;
-  }
-
-  public void unsetPassword() {
-    this.password = null;
-  }
-
-  /** Returns true if field password is set (has been assigned a value) and false otherwise */
-  public boolean isSetPassword() {
-    return this.password != null;
-  }
-
-  public void setPasswordIsSet(boolean value) {
-    if (!value) {
-      this.password = null;
-    }
-  }
-
-  public long getPersistedTime() {
-    return this.persistedTime;
-  }
-
-  public PasswordCredential setPersistedTime(long persistedTime) {
-    this.persistedTime = persistedTime;
-    setPersistedTimeIsSet(true);
-    return this;
-  }
-
-  public void unsetPersistedTime() {
-    __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID);
-  }
-
-  /** Returns true if field persistedTime is set (has been assigned a value) and false otherwise */
-  public boolean isSetPersistedTime() {
-    return EncodingUtils.testBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID);
-  }
-
-  public void setPersistedTimeIsSet(boolean value) {
-    __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID, value);
-  }
-
-  public String getToken() {
-    return this.token;
-  }
-
-  public PasswordCredential setToken(String token) {
-    this.token = token;
-    return this;
-  }
-
-  public void unsetToken() {
-    this.token = null;
-  }
-
-  /** Returns true if field token is set (has been assigned a value) and false otherwise */
-  public boolean isSetToken() {
-    return this.token != null;
-  }
-
-  public void setTokenIsSet(boolean value) {
-    if (!value) {
-      this.token = null;
-    }
-  }
-
-  public void setFieldValue(_Fields field, Object value) {
-    switch (field) {
-    case USERNAME:
-      if (value == null) {
-        unsetUsername();
-      } else {
-        setUsername((String)value);
-      }
-      break;
-
-    case PASSWORD:
-      if (value == null) {
-        unsetPassword();
-      } else {
-        setPassword((String)value);
-      }
-      break;
-
-    case PERSISTED_TIME:
-      if (value == null) {
-        unsetPersistedTime();
-      } else {
-        setPersistedTime((Long)value);
-      }
-      break;
-
-    case TOKEN:
-      if (value == null) {
-        unsetToken();
-      } else {
-        setToken((String)value);
-      }
-      break;
-
-    }
-  }
-
-  public Object getFieldValue(_Fields field) {
-    switch (field) {
-    case USERNAME:
-      return getUsername();
-
-    case PASSWORD:
-      return getPassword();
-
-    case PERSISTED_TIME:
-      return Long.valueOf(getPersistedTime());
-
-    case TOKEN:
-      return getToken();
-
-    }
-    throw new IllegalStateException();
-  }
-
-  /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-  public boolean isSet(_Fields field) {
-    if (field == null) {
-      throw new IllegalArgumentException();
-    }
-
-    switch (field) {
-    case USERNAME:
-      return isSetUsername();
-    case PASSWORD:
-      return isSetPassword();
-    case PERSISTED_TIME:
-      return isSetPersistedTime();
-    case TOKEN:
-      return isSetToken();
-    }
-    throw new IllegalStateException();
-  }
-
-  @Override
-  public boolean equals(Object that) {
-    if (that == null)
-      return false;
-    if (that instanceof PasswordCredential)
-      return this.equals((PasswordCredential)that);
-    return false;
-  }
-
-  public boolean equals(PasswordCredential that) {
-    if (that == null)
-      return false;
-
-    boolean this_present_username = true && this.isSetUsername();
-    boolean that_present_username = true && that.isSetUsername();
-    if (this_present_username || that_present_username) {
-      if (!(this_present_username && that_present_username))
-        return false;
-      if (!this.username.equals(that.username))
-        return false;
-    }
-
-    boolean this_present_password = true && this.isSetPassword();
-    boolean that_present_password = true && that.isSetPassword();
-    if (this_present_password || that_present_password) {
-      if (!(this_present_password && that_present_password))
-        return false;
-      if (!this.password.equals(that.password))
-        return false;
-    }
-
-    boolean this_present_persistedTime = true && this.isSetPersistedTime();
-    boolean that_present_persistedTime = true && that.isSetPersistedTime();
-    if (this_present_persistedTime || that_present_persistedTime) {
-      if (!(this_present_persistedTime && that_present_persistedTime))
-        return false;
-      if (this.persistedTime != that.persistedTime)
-        return false;
-    }
-
-    boolean this_present_token = true && this.isSetToken();
-    boolean that_present_token = true && that.isSetToken();
-    if (this_present_token || that_present_token) {
-      if (!(this_present_token && that_present_token))
-        return false;
-      if (!this.token.equals(that.token))
-        return false;
-    }
-
-    return true;
-  }
-
-  @Override
-  public int hashCode() {
-    return 0;
-  }
-
-  @Override
-  public int compareTo(PasswordCredential other) {
-    if (!getClass().equals(other.getClass())) {
-      return getClass().getName().compareTo(other.getClass().getName());
-    }
-
-    int lastComparison = 0;
-
-    lastComparison = Boolean.valueOf(isSetUsername()).compareTo(other.isSetUsername());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetUsername()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.username, other.username);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetPassword()).compareTo(other.isSetPassword());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetPassword()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.password, other.password);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetPersistedTime()).compareTo(other.isSetPersistedTime());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetPersistedTime()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.persistedTime, other.persistedTime);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    lastComparison = Boolean.valueOf(isSetToken()).compareTo(other.isSetToken());
-    if (lastComparison != 0) {
-      return lastComparison;
-    }
-    if (isSetToken()) {
-      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.token, other.token);
-      if (lastComparison != 0) {
-        return lastComparison;
-      }
-    }
-    return 0;
-  }
-
-  public _Fields fieldForId(int fieldId) {
-    return _Fields.findByThriftId(fieldId);
-  }
-
-  public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-    schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
-  }
-
-  public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-    schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
-  }
-
-  @Override
-  public String toString() {
-    StringBuilder sb = new StringBuilder("PasswordCredential(");
-    boolean first = true;
-
-    sb.append("username:");
-    if (this.username == null) {
-      sb.append("null");
-    } else {
-      sb.append(this.username);
-    }
-    first = false;
-    if (!first) sb.append(", ");
-    sb.append("password:");
-    if (this.password == null) {
-      sb.append("null");
-    } else {
-      sb.append(this.password);
-    }
-    first = false;
-    if (isSetPersistedTime()) {
-      if (!first) sb.append(", ");
-      sb.append("persistedTime:");
-      sb.append(this.persistedTime);
-      first = false;
-    }
-    if (isSetToken()) {
-      if (!first) sb.append(", ");
-      sb.append("token:");
-      if (this.token == null) {
-        sb.append("null");
-      } else {
-        sb.append(this.token);
-      }
-      first = false;
-    }
-    sb.append(")");
-    return sb.toString();
-  }
-
-  public void validate() throws org.apache.thrift.TException {
-    // check for required fields
-    if (username == null) {
-      throw new org.apache.thrift.protocol.TProtocolException("Required field 'username' was not present! Struct: " + toString());
-    }
-    if (password == null) {
-      throw new org.apache.thrift.protocol.TProtocolException("Required field 'password' was not present! Struct: " + toString());
-    }
-    // check for sub-struct validity
-  }
-
-  private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-    try {
-      write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-    } catch (org.apache.thrift.TException te) {
-      throw new java.io.IOException(te);
-    }
-  }
-
-  private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-    try {
-      // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
-      __isset_bitfield = 0;
-      read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-    } catch (org.apache.thrift.TException te) {
-      throw new java.io.IOException(te);
-    }
-  }
-
-  private static class PasswordCredentialStandardSchemeFactory implements SchemeFactory {
-    public PasswordCredentialStandardScheme getScheme() {
-      return new PasswordCredentialStandardScheme();
-    }
-  }
-
-  private static class PasswordCredentialStandardScheme extends StandardScheme<PasswordCredential> {
-
-    public void read(org.apache.thrift.protocol.TProtocol iprot, PasswordCredential struct) throws org.apache.thrift.TException {
-      org.apache.thrift.protocol.TField schemeField;
-      iprot.readStructBegin();
-      while (true)
-      {
-        schemeField = iprot.readFieldBegin();
-        if (schemeField.type == org.apache.thrift.protocol.TType.STOP) { 
-          break;
-        }
-        switch (schemeField.id) {
-          case 1: // USERNAME
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.username = iprot.readString();
-              struct.setUsernameIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 2: // PASSWORD
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.password = iprot.readString();
-              struct.setPasswordIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 3: // PERSISTED_TIME
-            if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
-              struct.persistedTime = iprot.readI64();
-              struct.setPersistedTimeIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          case 4: // TOKEN
-            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
-              struct.token = iprot.readString();
-              struct.setTokenIsSet(true);
-            } else { 
-              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-            }
-            break;
-          default:
-            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
-        }
-        iprot.readFieldEnd();
-      }
-      iprot.readStructEnd();
-
-      // check for required fields of primitive type, which can't be checked in the validate method
-      struct.validate();
-    }
-
-    public void write(org.apache.thrift.protocol.TProtocol oprot, PasswordCredential struct) throws org.apache.thrift.TException {
-      struct.validate();
-
-      oprot.writeStructBegin(STRUCT_DESC);
-      if (struct.username != null) {
-        oprot.writeFieldBegin(USERNAME_FIELD_DESC);
-        oprot.writeString(struct.username);
-        oprot.writeFieldEnd();
-      }
-      if (struct.password != null) {
-        oprot.writeFieldBegin(PASSWORD_FIELD_DESC);
-        oprot.writeString(struct.password);
-        oprot.writeFieldEnd();
-      }
-      if (struct.isSetPersistedTime()) {
-        oprot.writeFieldBegin(PERSISTED_TIME_FIELD_DESC);
-        oprot.writeI64(struct.persistedTime);
-        oprot.writeFieldEnd();
-      }
-      if (struct.token != null) {
-        if (struct.isSetToken()) {
-          oprot.writeFieldBegin(TOKEN_FIELD_DESC);
-          oprot.writeString(struct.token);
-          oprot.writeFieldEnd();
-        }
-      }
-      oprot.writeFieldStop();
-      oprot.writeStructEnd();
-    }
-
-  }
-
-  private static class PasswordCredentialTupleSchemeFactory implements SchemeFactory {
-    public PasswordCredentialTupleScheme getScheme() {
-      return new PasswordCredentialTupleScheme();
-    }
-  }
-
-  private static class PasswordCredentialTupleScheme extends TupleScheme<PasswordCredential> {
-
-    @Override
-    public void write(org.apache.thrift.protocol.TProtocol prot, PasswordCredential struct) throws org.apache.thrift.TException {
-      TTupleProtocol oprot = (TTupleProtocol) prot;
-      oprot.writeString(struct.username);
-      oprot.writeString(struct.password);
-      BitSet optionals = new BitSet();
-      if (struct.isSetPersistedTime()) {
-        optionals.set(0);
-      }
-      if (struct.isSetToken()) {
-        optionals.set(1);
-      }
-      oprot.writeBitSet(optionals, 2);
-      if (struct.isSetPersistedTime()) {
-        oprot.writeI64(struct.persistedTime);
-      }
-      if (struct.isSetToken()) {
-        oprot.writeString(struct.token);
-      }
-    }
-
-    @Override
-    public void read(org.apache.thrift.protocol.TProtocol prot, PasswordCredential struct) throws org.apache.thrift.TException {
-      TTupleProtocol iprot = (TTupleProtocol) prot;
-      struct.username = iprot.readString();
-      struct.setUsernameIsSet(true);
-      struct.password = iprot.readString();
-      struct.setPasswordIsSet(true);
-      BitSet incoming = iprot.readBitSet(2);
-      if (incoming.get(0)) {
-        struct.persistedTime = iprot.readI64();
-        struct.setPersistedTimeIsSet(true);
-      }
-      if (incoming.get(1)) {
-        struct.token = iprot.readString();
-        struct.setTokenIsSet(true);
-      }
-    }
-  }
-
-}
-