You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airavata.apache.org by ma...@apache.org on 2017/08/04 20:10:18 UTC
[01/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Repository: airavata
Updated Branches:
refs/heads/thrift-0.10.0-upgrade [created] 9d165bd87
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/job/JobModel.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/job/JobModel.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/job/JobModel.java
index 9553b0c..508709a 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/job/JobModel.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/job/JobModel.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.job;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fields>, java.io.Serializable, Cloneable, Comparable<JobModel> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("JobModel");
@@ -68,23 +41,20 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
private static final org.apache.thrift.protocol.TField STD_ERR_FIELD_DESC = new org.apache.thrift.protocol.TField("stdErr", org.apache.thrift.protocol.TType.STRING, (short)11);
private static final org.apache.thrift.protocol.TField EXIT_CODE_FIELD_DESC = new org.apache.thrift.protocol.TField("exitCode", org.apache.thrift.protocol.TType.I32, (short)12);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new JobModelStandardSchemeFactory());
- schemes.put(TupleScheme.class, new JobModelTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new JobModelStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new JobModelTupleSchemeFactory();
- private String jobId; // required
- private String taskId; // required
- private String processId; // required
- private String jobDescription; // required
+ private java.lang.String jobId; // required
+ private java.lang.String taskId; // required
+ private java.lang.String processId; // required
+ private java.lang.String jobDescription; // required
private long creationTime; // optional
- private List<org.apache.airavata.model.status.JobStatus> jobStatuses; // optional
- private String computeResourceConsumed; // optional
- private String jobName; // optional
- private String workingDir; // optional
- private String stdOut; // optional
- private String stdErr; // optional
+ private java.util.List<org.apache.airavata.model.status.JobStatus> jobStatuses; // optional
+ private java.lang.String computeResourceConsumed; // optional
+ private java.lang.String jobName; // optional
+ private java.lang.String workingDir; // optional
+ private java.lang.String stdOut; // optional
+ private java.lang.String stdErr; // optional
private int exitCode; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
@@ -102,10 +72,10 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
STD_ERR((short)11, "stdErr"),
EXIT_CODE((short)12, "exitCode");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -150,21 +120,21 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -173,7 +143,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -183,9 +153,9 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
private static final int __EXITCODE_ISSET_ID = 1;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.CREATION_TIME,_Fields.JOB_STATUSES,_Fields.COMPUTE_RESOURCE_CONSUMED,_Fields.JOB_NAME,_Fields.WORKING_DIR,_Fields.STD_OUT,_Fields.STD_ERR,_Fields.EXIT_CODE};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.JOB_ID, new org.apache.thrift.meta_data.FieldMetaData("jobId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.TASK_ID, new org.apache.thrift.meta_data.FieldMetaData("taskId", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -211,7 +181,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.EXIT_CODE, new org.apache.thrift.meta_data.FieldMetaData("exitCode", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(JobModel.class, metaDataMap);
}
@@ -219,10 +189,10 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
}
public JobModel(
- String jobId,
- String taskId,
- String processId,
- String jobDescription)
+ java.lang.String jobId,
+ java.lang.String taskId,
+ java.lang.String processId,
+ java.lang.String jobDescription)
{
this();
this.jobId = jobId;
@@ -250,7 +220,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
}
this.creationTime = other.creationTime;
if (other.isSetJobStatuses()) {
- List<org.apache.airavata.model.status.JobStatus> __this__jobStatuses = new ArrayList<org.apache.airavata.model.status.JobStatus>(other.jobStatuses.size());
+ java.util.List<org.apache.airavata.model.status.JobStatus> __this__jobStatuses = new java.util.ArrayList<org.apache.airavata.model.status.JobStatus>(other.jobStatuses.size());
for (org.apache.airavata.model.status.JobStatus other_element : other.jobStatuses) {
__this__jobStatuses.add(new org.apache.airavata.model.status.JobStatus(other_element));
}
@@ -296,11 +266,11 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
this.exitCode = 0;
}
- public String getJobId() {
+ public java.lang.String getJobId() {
return this.jobId;
}
- public void setJobId(String jobId) {
+ public void setJobId(java.lang.String jobId) {
this.jobId = jobId;
}
@@ -319,11 +289,11 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
}
}
- public String getTaskId() {
+ public java.lang.String getTaskId() {
return this.taskId;
}
- public void setTaskId(String taskId) {
+ public void setTaskId(java.lang.String taskId) {
this.taskId = taskId;
}
@@ -342,11 +312,11 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
}
}
- public String getProcessId() {
+ public java.lang.String getProcessId() {
return this.processId;
}
- public void setProcessId(String processId) {
+ public void setProcessId(java.lang.String processId) {
this.processId = processId;
}
@@ -365,11 +335,11 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
}
}
- public String getJobDescription() {
+ public java.lang.String getJobDescription() {
return this.jobDescription;
}
- public void setJobDescription(String jobDescription) {
+ public void setJobDescription(java.lang.String jobDescription) {
this.jobDescription = jobDescription;
}
@@ -398,16 +368,16 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
}
public void unsetCreationTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
}
/** Returns true if field creationTime is set (has been assigned a value) and false otherwise */
public boolean isSetCreationTime() {
- return EncodingUtils.testBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
}
public void setCreationTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __CREATIONTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __CREATIONTIME_ISSET_ID, value);
}
public int getJobStatusesSize() {
@@ -420,16 +390,16 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
public void addToJobStatuses(org.apache.airavata.model.status.JobStatus elem) {
if (this.jobStatuses == null) {
- this.jobStatuses = new ArrayList<org.apache.airavata.model.status.JobStatus>();
+ this.jobStatuses = new java.util.ArrayList<org.apache.airavata.model.status.JobStatus>();
}
this.jobStatuses.add(elem);
}
- public List<org.apache.airavata.model.status.JobStatus> getJobStatuses() {
+ public java.util.List<org.apache.airavata.model.status.JobStatus> getJobStatuses() {
return this.jobStatuses;
}
- public void setJobStatuses(List<org.apache.airavata.model.status.JobStatus> jobStatuses) {
+ public void setJobStatuses(java.util.List<org.apache.airavata.model.status.JobStatus> jobStatuses) {
this.jobStatuses = jobStatuses;
}
@@ -448,11 +418,11 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
}
}
- public String getComputeResourceConsumed() {
+ public java.lang.String getComputeResourceConsumed() {
return this.computeResourceConsumed;
}
- public void setComputeResourceConsumed(String computeResourceConsumed) {
+ public void setComputeResourceConsumed(java.lang.String computeResourceConsumed) {
this.computeResourceConsumed = computeResourceConsumed;
}
@@ -471,11 +441,11 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
}
}
- public String getJobName() {
+ public java.lang.String getJobName() {
return this.jobName;
}
- public void setJobName(String jobName) {
+ public void setJobName(java.lang.String jobName) {
this.jobName = jobName;
}
@@ -494,11 +464,11 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
}
}
- public String getWorkingDir() {
+ public java.lang.String getWorkingDir() {
return this.workingDir;
}
- public void setWorkingDir(String workingDir) {
+ public void setWorkingDir(java.lang.String workingDir) {
this.workingDir = workingDir;
}
@@ -517,11 +487,11 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
}
}
- public String getStdOut() {
+ public java.lang.String getStdOut() {
return this.stdOut;
}
- public void setStdOut(String stdOut) {
+ public void setStdOut(java.lang.String stdOut) {
this.stdOut = stdOut;
}
@@ -540,11 +510,11 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
}
}
- public String getStdErr() {
+ public java.lang.String getStdErr() {
return this.stdErr;
}
- public void setStdErr(String stdErr) {
+ public void setStdErr(java.lang.String stdErr) {
this.stdErr = stdErr;
}
@@ -573,25 +543,25 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
}
public void unsetExitCode() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __EXITCODE_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __EXITCODE_ISSET_ID);
}
/** Returns true if field exitCode is set (has been assigned a value) and false otherwise */
public boolean isSetExitCode() {
- return EncodingUtils.testBit(__isset_bitfield, __EXITCODE_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __EXITCODE_ISSET_ID);
}
public void setExitCodeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __EXITCODE_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __EXITCODE_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case JOB_ID:
if (value == null) {
unsetJobId();
} else {
- setJobId((String)value);
+ setJobId((java.lang.String)value);
}
break;
@@ -599,7 +569,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
if (value == null) {
unsetTaskId();
} else {
- setTaskId((String)value);
+ setTaskId((java.lang.String)value);
}
break;
@@ -607,7 +577,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
if (value == null) {
unsetProcessId();
} else {
- setProcessId((String)value);
+ setProcessId((java.lang.String)value);
}
break;
@@ -615,7 +585,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
if (value == null) {
unsetJobDescription();
} else {
- setJobDescription((String)value);
+ setJobDescription((java.lang.String)value);
}
break;
@@ -623,7 +593,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
if (value == null) {
unsetCreationTime();
} else {
- setCreationTime((Long)value);
+ setCreationTime((java.lang.Long)value);
}
break;
@@ -631,7 +601,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
if (value == null) {
unsetJobStatuses();
} else {
- setJobStatuses((List<org.apache.airavata.model.status.JobStatus>)value);
+ setJobStatuses((java.util.List<org.apache.airavata.model.status.JobStatus>)value);
}
break;
@@ -639,7 +609,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
if (value == null) {
unsetComputeResourceConsumed();
} else {
- setComputeResourceConsumed((String)value);
+ setComputeResourceConsumed((java.lang.String)value);
}
break;
@@ -647,7 +617,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
if (value == null) {
unsetJobName();
} else {
- setJobName((String)value);
+ setJobName((java.lang.String)value);
}
break;
@@ -655,7 +625,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
if (value == null) {
unsetWorkingDir();
} else {
- setWorkingDir((String)value);
+ setWorkingDir((java.lang.String)value);
}
break;
@@ -663,7 +633,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
if (value == null) {
unsetStdOut();
} else {
- setStdOut((String)value);
+ setStdOut((java.lang.String)value);
}
break;
@@ -671,7 +641,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
if (value == null) {
unsetStdErr();
} else {
- setStdErr((String)value);
+ setStdErr((java.lang.String)value);
}
break;
@@ -679,14 +649,14 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
if (value == null) {
unsetExitCode();
} else {
- setExitCode((Integer)value);
+ setExitCode((java.lang.Integer)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case JOB_ID:
return getJobId();
@@ -725,13 +695,13 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
return getExitCode();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -760,11 +730,11 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
case EXIT_CODE:
return isSetExitCode();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof JobModel)
@@ -775,6 +745,8 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
public boolean equals(JobModel that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_jobId = true && this.isSetJobId();
boolean that_present_jobId = true && that.isSetJobId();
@@ -889,69 +861,57 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_jobId = true && (isSetJobId());
- list.add(present_jobId);
- if (present_jobId)
- list.add(jobId);
-
- boolean present_taskId = true && (isSetTaskId());
- list.add(present_taskId);
- if (present_taskId)
- list.add(taskId);
-
- boolean present_processId = true && (isSetProcessId());
- list.add(present_processId);
- if (present_processId)
- list.add(processId);
-
- boolean present_jobDescription = true && (isSetJobDescription());
- list.add(present_jobDescription);
- if (present_jobDescription)
- list.add(jobDescription);
-
- boolean present_creationTime = true && (isSetCreationTime());
- list.add(present_creationTime);
- if (present_creationTime)
- list.add(creationTime);
-
- boolean present_jobStatuses = true && (isSetJobStatuses());
- list.add(present_jobStatuses);
- if (present_jobStatuses)
- list.add(jobStatuses);
-
- boolean present_computeResourceConsumed = true && (isSetComputeResourceConsumed());
- list.add(present_computeResourceConsumed);
- if (present_computeResourceConsumed)
- list.add(computeResourceConsumed);
-
- boolean present_jobName = true && (isSetJobName());
- list.add(present_jobName);
- if (present_jobName)
- list.add(jobName);
-
- boolean present_workingDir = true && (isSetWorkingDir());
- list.add(present_workingDir);
- if (present_workingDir)
- list.add(workingDir);
-
- boolean present_stdOut = true && (isSetStdOut());
- list.add(present_stdOut);
- if (present_stdOut)
- list.add(stdOut);
-
- boolean present_stdErr = true && (isSetStdErr());
- list.add(present_stdErr);
- if (present_stdErr)
- list.add(stdErr);
-
- boolean present_exitCode = true && (isSetExitCode());
- list.add(present_exitCode);
- if (present_exitCode)
- list.add(exitCode);
-
- return list.hashCode();
+ int hashCode = 1;
+
+ hashCode = hashCode * 8191 + ((isSetJobId()) ? 131071 : 524287);
+ if (isSetJobId())
+ hashCode = hashCode * 8191 + jobId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetTaskId()) ? 131071 : 524287);
+ if (isSetTaskId())
+ hashCode = hashCode * 8191 + taskId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetProcessId()) ? 131071 : 524287);
+ if (isSetProcessId())
+ hashCode = hashCode * 8191 + processId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetJobDescription()) ? 131071 : 524287);
+ if (isSetJobDescription())
+ hashCode = hashCode * 8191 + jobDescription.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetCreationTime()) ? 131071 : 524287);
+ if (isSetCreationTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(creationTime);
+
+ hashCode = hashCode * 8191 + ((isSetJobStatuses()) ? 131071 : 524287);
+ if (isSetJobStatuses())
+ hashCode = hashCode * 8191 + jobStatuses.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetComputeResourceConsumed()) ? 131071 : 524287);
+ if (isSetComputeResourceConsumed())
+ hashCode = hashCode * 8191 + computeResourceConsumed.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetJobName()) ? 131071 : 524287);
+ if (isSetJobName())
+ hashCode = hashCode * 8191 + jobName.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetWorkingDir()) ? 131071 : 524287);
+ if (isSetWorkingDir())
+ hashCode = hashCode * 8191 + workingDir.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetStdOut()) ? 131071 : 524287);
+ if (isSetStdOut())
+ hashCode = hashCode * 8191 + stdOut.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetStdErr()) ? 131071 : 524287);
+ if (isSetStdErr())
+ hashCode = hashCode * 8191 + stdErr.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetExitCode()) ? 131071 : 524287);
+ if (isSetExitCode())
+ hashCode = hashCode * 8191 + exitCode;
+
+ return hashCode;
}
@Override
@@ -962,7 +922,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetJobId()).compareTo(other.isSetJobId());
+ lastComparison = java.lang.Boolean.valueOf(isSetJobId()).compareTo(other.isSetJobId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -972,7 +932,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetTaskId()).compareTo(other.isSetTaskId());
+ lastComparison = java.lang.Boolean.valueOf(isSetTaskId()).compareTo(other.isSetTaskId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -982,7 +942,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetProcessId()).compareTo(other.isSetProcessId());
+ lastComparison = java.lang.Boolean.valueOf(isSetProcessId()).compareTo(other.isSetProcessId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -992,7 +952,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetJobDescription()).compareTo(other.isSetJobDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetJobDescription()).compareTo(other.isSetJobDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1002,7 +962,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCreationTime()).compareTo(other.isSetCreationTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetCreationTime()).compareTo(other.isSetCreationTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1012,7 +972,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetJobStatuses()).compareTo(other.isSetJobStatuses());
+ lastComparison = java.lang.Boolean.valueOf(isSetJobStatuses()).compareTo(other.isSetJobStatuses());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1022,7 +982,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetComputeResourceConsumed()).compareTo(other.isSetComputeResourceConsumed());
+ lastComparison = java.lang.Boolean.valueOf(isSetComputeResourceConsumed()).compareTo(other.isSetComputeResourceConsumed());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1032,7 +992,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetJobName()).compareTo(other.isSetJobName());
+ lastComparison = java.lang.Boolean.valueOf(isSetJobName()).compareTo(other.isSetJobName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1042,7 +1002,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetWorkingDir()).compareTo(other.isSetWorkingDir());
+ lastComparison = java.lang.Boolean.valueOf(isSetWorkingDir()).compareTo(other.isSetWorkingDir());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1052,7 +1012,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetStdOut()).compareTo(other.isSetStdOut());
+ lastComparison = java.lang.Boolean.valueOf(isSetStdOut()).compareTo(other.isSetStdOut());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1062,7 +1022,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetStdErr()).compareTo(other.isSetStdErr());
+ lastComparison = java.lang.Boolean.valueOf(isSetStdErr()).compareTo(other.isSetStdErr());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1072,7 +1032,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetExitCode()).compareTo(other.isSetExitCode());
+ lastComparison = java.lang.Boolean.valueOf(isSetExitCode()).compareTo(other.isSetExitCode());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1090,16 +1050,16 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("JobModel(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("JobModel(");
boolean first = true;
sb.append("jobId:");
@@ -1238,7 +1198,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -1248,13 +1208,13 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
}
}
- private static class JobModelStandardSchemeFactory implements SchemeFactory {
+ private static class JobModelStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public JobModelStandardScheme getScheme() {
return new JobModelStandardScheme();
}
}
- private static class JobModelStandardScheme extends StandardScheme<JobModel> {
+ private static class JobModelStandardScheme extends org.apache.thrift.scheme.StandardScheme<JobModel> {
public void read(org.apache.thrift.protocol.TProtocol iprot, JobModel struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1310,7 +1270,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list0 = iprot.readListBegin();
- struct.jobStatuses = new ArrayList<org.apache.airavata.model.status.JobStatus>(_list0.size);
+ struct.jobStatuses = new java.util.ArrayList<org.apache.airavata.model.status.JobStatus>(_list0.size);
org.apache.airavata.model.status.JobStatus _elem1;
for (int _i2 = 0; _i2 < _list0.size; ++_i2)
{
@@ -1471,22 +1431,22 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
}
- private static class JobModelTupleSchemeFactory implements SchemeFactory {
+ private static class JobModelTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public JobModelTupleScheme getScheme() {
return new JobModelTupleScheme();
}
}
- private static class JobModelTupleScheme extends TupleScheme<JobModel> {
+ private static class JobModelTupleScheme extends org.apache.thrift.scheme.TupleScheme<JobModel> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, JobModel struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.jobId);
oprot.writeString(struct.taskId);
oprot.writeString(struct.processId);
oprot.writeString(struct.jobDescription);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetCreationTime()) {
optionals.set(0);
}
@@ -1546,7 +1506,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, JobModel struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.jobId = iprot.readString();
struct.setJobIdIsSet(true);
struct.taskId = iprot.readString();
@@ -1555,7 +1515,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
struct.setProcessIdIsSet(true);
struct.jobDescription = iprot.readString();
struct.setJobDescriptionIsSet(true);
- BitSet incoming = iprot.readBitSet(8);
+ java.util.BitSet incoming = iprot.readBitSet(8);
if (incoming.get(0)) {
struct.creationTime = iprot.readI64();
struct.setCreationTimeIsSet(true);
@@ -1563,7 +1523,7 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
if (incoming.get(1)) {
{
org.apache.thrift.protocol.TList _list5 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.jobStatuses = new ArrayList<org.apache.airavata.model.status.JobStatus>(_list5.size);
+ struct.jobStatuses = new java.util.ArrayList<org.apache.airavata.model.status.JobStatus>(_list5.size);
org.apache.airavata.model.status.JobStatus _elem6;
for (int _i7 = 0; _i7 < _list5.size; ++_i7)
{
@@ -1601,5 +1561,8 @@ public class JobModel implements org.apache.thrift.TBase<JobModel, JobModel._Fie
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
[45/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/SharingRegistryService-remote
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/SharingRegistryService-remote b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/SharingRegistryService-remote
index 9ec9a1c..dacc90a 100755
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/SharingRegistryService-remote
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/SharingRegistryService-remote
@@ -1,6 +1,6 @@
#!/usr/bin/env python
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
@@ -9,429 +9,452 @@
import sys
import pprint
-from urlparse import urlparse
-from thrift.transport import TTransport
-from thrift.transport import TSocket
-from thrift.transport import TSSLSocket
-from thrift.transport import THttpClient
-from thrift.protocol import TBinaryProtocol
+if sys.version_info[0] > 2:
+ from urllib.parse import urlparse
+else:
+ from urlparse import urlparse
+from thrift.transport import TTransport, TSocket, TSSLSocket, THttpClient
+from thrift.protocol.TBinaryProtocol import TBinaryProtocol
from apache.airavata.api.sharing import SharingRegistryService
from apache.airavata.api.sharing.ttypes import *
if len(sys.argv) <= 1 or sys.argv[1] == '--help':
- print('')
- print('Usage: ' + sys.argv[0] + ' [-h host[:port]] [-u url] [-f[ramed]] [-s[sl]] function [arg1 [arg2...]]')
- print('')
- print('Functions:')
- print(' string createDomain(Domain domain)')
- print(' bool updateDomain(Domain domain)')
- print(' bool isDomainExists(string domainId)')
- print(' bool deleteDomain(string domainId)')
- print(' Domain getDomain(string domainId)')
- print(' getDomains(i32 offset, i32 limit)')
- print(' string createUser(User user)')
- print(' bool updatedUser(User user)')
- print(' bool isUserExists(string domainId, string userId)')
- print(' bool deleteUser(string domainId, string userId)')
- print(' User getUser(string domainId, string userId)')
- print(' getUsers(string domainId, i32 offset, i32 limit)')
- print(' string createGroup(UserGroup group)')
- print(' bool updateGroup(UserGroup group)')
- print(' bool isGroupExists(string domainId, string groupId)')
- print(' bool deleteGroup(string domainId, string groupId)')
- print(' UserGroup getGroup(string domainId, string groupId)')
- print(' getGroups(string domainId, i32 offset, i32 limit)')
- print(' bool addUsersToGroup(string domainId, userIds, string groupId)')
- print(' bool removeUsersFromGroup(string domainId, userIds, string groupId)')
- print(' getGroupMembersOfTypeUser(string domainId, string groupId, i32 offset, i32 limit)')
- print(' getGroupMembersOfTypeGroup(string domainId, string groupId, i32 offset, i32 limit)')
- print(' bool addChildGroupsToParentGroup(string domainId, childIds, string groupId)')
- print(' bool removeChildGroupFromParentGroup(string domainId, string childId, string groupId)')
- print(' getAllMemberGroupsForUser(string domainId, string userId)')
- print(' string createEntityType(EntityType entityType)')
- print(' bool updateEntityType(EntityType entityType)')
- print(' bool isEntityTypeExists(string domainId, string entityTypeId)')
- print(' bool deleteEntityType(string domainId, string entityTypeId)')
- print(' EntityType getEntityType(string domainId, string entityTypeId)')
- print(' getEntityTypes(string domainId, i32 offset, i32 limit)')
- print(' string createEntity(Entity entity)')
- print(' bool updateEntity(Entity entity)')
- print(' bool isEntityExists(string domainId, string entityId)')
- print(' bool deleteEntity(string domainId, string entityId)')
- print(' Entity getEntity(string domainId, string entityId)')
- print(' searchEntities(string domainId, string userId, filters, i32 offset, i32 limit)')
- print(' getListOfSharedUsers(string domainId, string entityId, string permissionTypeId)')
- print(' getListOfSharedGroups(string domainId, string entityId, string permissionTypeId)')
- print(' string createPermissionType(PermissionType permissionType)')
- print(' bool updatePermissionType(PermissionType permissionType)')
- print(' bool isPermissionExists(string dimainId, string permissionId)')
- print(' bool deletePermissionType(string domainId, string permissionTypeId)')
- print(' PermissionType getPermissionType(string domainId, string permissionTypeId)')
- print(' getPermissionTypes(string domainId, i32 offset, i32 limit)')
- print(' bool shareEntityWithUsers(string domainId, string entityId, userList, string perssionTypeId, bool cascadePermission)')
- print(' bool revokeEntitySharingFromUsers(string domainId, string entityId, userList, string perssionTypeId)')
- print(' bool shareEntityWithGroups(string domainId, string entityId, groupList, string perssionTypeId, bool cascadePermission)')
- print(' bool revokeEntitySharingFromGroups(string domainId, string entityId, groupList, string perssionTypeId)')
- print(' bool userHasAccess(string domainId, string userId, string entityId, string permissionTypeId)')
- print('')
- sys.exit(0)
-
-pp = pprint.PrettyPrinter(indent = 2)
+ print('')
+ print('Usage: ' + sys.argv[0] + ' [-h host[:port]] [-u url] [-f[ramed]] [-s[sl]] [-novalidate] [-ca_certs certs] [-keyfile keyfile] [-certfile certfile] function [arg1 [arg2...]]')
+ print('')
+ print('Functions:')
+ print(' string createDomain(Domain domain)')
+ print(' bool updateDomain(Domain domain)')
+ print(' bool isDomainExists(string domainId)')
+ print(' bool deleteDomain(string domainId)')
+ print(' Domain getDomain(string domainId)')
+ print(' getDomains(i32 offset, i32 limit)')
+ print(' string createUser(User user)')
+ print(' bool updatedUser(User user)')
+ print(' bool isUserExists(string domainId, string userId)')
+ print(' bool deleteUser(string domainId, string userId)')
+ print(' User getUser(string domainId, string userId)')
+ print(' getUsers(string domainId, i32 offset, i32 limit)')
+ print(' string createGroup(UserGroup group)')
+ print(' bool updateGroup(UserGroup group)')
+ print(' bool isGroupExists(string domainId, string groupId)')
+ print(' bool deleteGroup(string domainId, string groupId)')
+ print(' UserGroup getGroup(string domainId, string groupId)')
+ print(' getGroups(string domainId, i32 offset, i32 limit)')
+ print(' bool addUsersToGroup(string domainId, userIds, string groupId)')
+ print(' bool removeUsersFromGroup(string domainId, userIds, string groupId)')
+ print(' getGroupMembersOfTypeUser(string domainId, string groupId, i32 offset, i32 limit)')
+ print(' getGroupMembersOfTypeGroup(string domainId, string groupId, i32 offset, i32 limit)')
+ print(' bool addChildGroupsToParentGroup(string domainId, childIds, string groupId)')
+ print(' bool removeChildGroupFromParentGroup(string domainId, string childId, string groupId)')
+ print(' getAllMemberGroupsForUser(string domainId, string userId)')
+ print(' string createEntityType(EntityType entityType)')
+ print(' bool updateEntityType(EntityType entityType)')
+ print(' bool isEntityTypeExists(string domainId, string entityTypeId)')
+ print(' bool deleteEntityType(string domainId, string entityTypeId)')
+ print(' EntityType getEntityType(string domainId, string entityTypeId)')
+ print(' getEntityTypes(string domainId, i32 offset, i32 limit)')
+ print(' string createEntity(Entity entity)')
+ print(' bool updateEntity(Entity entity)')
+ print(' bool isEntityExists(string domainId, string entityId)')
+ print(' bool deleteEntity(string domainId, string entityId)')
+ print(' Entity getEntity(string domainId, string entityId)')
+ print(' searchEntities(string domainId, string userId, filters, i32 offset, i32 limit)')
+ print(' getListOfSharedUsers(string domainId, string entityId, string permissionTypeId)')
+ print(' getListOfSharedGroups(string domainId, string entityId, string permissionTypeId)')
+ print(' string createPermissionType(PermissionType permissionType)')
+ print(' bool updatePermissionType(PermissionType permissionType)')
+ print(' bool isPermissionExists(string dimainId, string permissionId)')
+ print(' bool deletePermissionType(string domainId, string permissionTypeId)')
+ print(' PermissionType getPermissionType(string domainId, string permissionTypeId)')
+ print(' getPermissionTypes(string domainId, i32 offset, i32 limit)')
+ print(' bool shareEntityWithUsers(string domainId, string entityId, userList, string perssionTypeId, bool cascadePermission)')
+ print(' bool revokeEntitySharingFromUsers(string domainId, string entityId, userList, string perssionTypeId)')
+ print(' bool shareEntityWithGroups(string domainId, string entityId, groupList, string perssionTypeId, bool cascadePermission)')
+ print(' bool revokeEntitySharingFromGroups(string domainId, string entityId, groupList, string perssionTypeId)')
+ print(' bool userHasAccess(string domainId, string userId, string entityId, string permissionTypeId)')
+ print('')
+ sys.exit(0)
+
+pp = pprint.PrettyPrinter(indent=2)
host = 'localhost'
port = 9090
uri = ''
framed = False
ssl = False
+validate = True
+ca_certs = None
+keyfile = None
+certfile = None
http = False
argi = 1
if sys.argv[argi] == '-h':
- parts = sys.argv[argi+1].split(':')
- host = parts[0]
- if len(parts) > 1:
- port = int(parts[1])
- argi += 2
+ parts = sys.argv[argi + 1].split(':')
+ host = parts[0]
+ if len(parts) > 1:
+ port = int(parts[1])
+ argi += 2
if sys.argv[argi] == '-u':
- url = urlparse(sys.argv[argi+1])
- parts = url[1].split(':')
- host = parts[0]
- if len(parts) > 1:
- port = int(parts[1])
- else:
- port = 80
- uri = url[2]
- if url[4]:
- uri += '?%s' % url[4]
- http = True
- argi += 2
+ url = urlparse(sys.argv[argi + 1])
+ parts = url[1].split(':')
+ host = parts[0]
+ if len(parts) > 1:
+ port = int(parts[1])
+ else:
+ port = 80
+ uri = url[2]
+ if url[4]:
+ uri += '?%s' % url[4]
+ http = True
+ argi += 2
if sys.argv[argi] == '-f' or sys.argv[argi] == '-framed':
- framed = True
- argi += 1
+ framed = True
+ argi += 1
if sys.argv[argi] == '-s' or sys.argv[argi] == '-ssl':
- ssl = True
- argi += 1
+ ssl = True
+ argi += 1
+
+if sys.argv[argi] == '-novalidate':
+ validate = False
+ argi += 1
+
+if sys.argv[argi] == '-ca_certs':
+ ca_certs = sys.argv[argi+1]
+ argi += 2
+
+if sys.argv[argi] == '-keyfile':
+ keyfile = sys.argv[argi+1]
+ argi += 2
+
+if sys.argv[argi] == '-certfile':
+ certfile = sys.argv[argi+1]
+ argi += 2
cmd = sys.argv[argi]
-args = sys.argv[argi+1:]
+args = sys.argv[argi + 1:]
if http:
- transport = THttpClient.THttpClient(host, port, uri)
+ transport = THttpClient.THttpClient(host, port, uri)
else:
- socket = TSSLSocket.TSSLSocket(host, port, validate=False) if ssl else TSocket.TSocket(host, port)
- if framed:
- transport = TTransport.TFramedTransport(socket)
- else:
- transport = TTransport.TBufferedTransport(socket)
-protocol = TBinaryProtocol.TBinaryProtocol(transport)
+ if ssl:
+ socket = TSSLSocket.TSSLSocket(host, port, validate=validate, ca_certs=ca_certs, keyfile=keyfile, certfile=certfile)
+ else:
+ socket = TSocket.TSocket(host, port)
+ if framed:
+ transport = TTransport.TFramedTransport(socket)
+ else:
+ transport = TTransport.TBufferedTransport(socket)
+protocol = TBinaryProtocol(transport)
client = SharingRegistryService.Client(protocol)
transport.open()
if cmd == 'createDomain':
- if len(args) != 1:
- print('createDomain requires 1 args')
- sys.exit(1)
- pp.pprint(client.createDomain(eval(args[0]),))
+ if len(args) != 1:
+ print('createDomain requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.createDomain(eval(args[0]),))
elif cmd == 'updateDomain':
- if len(args) != 1:
- print('updateDomain requires 1 args')
- sys.exit(1)
- pp.pprint(client.updateDomain(eval(args[0]),))
+ if len(args) != 1:
+ print('updateDomain requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.updateDomain(eval(args[0]),))
elif cmd == 'isDomainExists':
- if len(args) != 1:
- print('isDomainExists requires 1 args')
- sys.exit(1)
- pp.pprint(client.isDomainExists(args[0],))
+ if len(args) != 1:
+ print('isDomainExists requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.isDomainExists(args[0],))
elif cmd == 'deleteDomain':
- if len(args) != 1:
- print('deleteDomain requires 1 args')
- sys.exit(1)
- pp.pprint(client.deleteDomain(args[0],))
+ if len(args) != 1:
+ print('deleteDomain requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.deleteDomain(args[0],))
elif cmd == 'getDomain':
- if len(args) != 1:
- print('getDomain requires 1 args')
- sys.exit(1)
- pp.pprint(client.getDomain(args[0],))
+ if len(args) != 1:
+ print('getDomain requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.getDomain(args[0],))
elif cmd == 'getDomains':
- if len(args) != 2:
- print('getDomains requires 2 args')
- sys.exit(1)
- pp.pprint(client.getDomains(eval(args[0]),eval(args[1]),))
+ if len(args) != 2:
+ print('getDomains requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getDomains(eval(args[0]), eval(args[1]),))
elif cmd == 'createUser':
- if len(args) != 1:
- print('createUser requires 1 args')
- sys.exit(1)
- pp.pprint(client.createUser(eval(args[0]),))
+ if len(args) != 1:
+ print('createUser requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.createUser(eval(args[0]),))
elif cmd == 'updatedUser':
- if len(args) != 1:
- print('updatedUser requires 1 args')
- sys.exit(1)
- pp.pprint(client.updatedUser(eval(args[0]),))
+ if len(args) != 1:
+ print('updatedUser requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.updatedUser(eval(args[0]),))
elif cmd == 'isUserExists':
- if len(args) != 2:
- print('isUserExists requires 2 args')
- sys.exit(1)
- pp.pprint(client.isUserExists(args[0],args[1],))
+ if len(args) != 2:
+ print('isUserExists requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.isUserExists(args[0], args[1],))
elif cmd == 'deleteUser':
- if len(args) != 2:
- print('deleteUser requires 2 args')
- sys.exit(1)
- pp.pprint(client.deleteUser(args[0],args[1],))
+ if len(args) != 2:
+ print('deleteUser requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.deleteUser(args[0], args[1],))
elif cmd == 'getUser':
- if len(args) != 2:
- print('getUser requires 2 args')
- sys.exit(1)
- pp.pprint(client.getUser(args[0],args[1],))
+ if len(args) != 2:
+ print('getUser requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getUser(args[0], args[1],))
elif cmd == 'getUsers':
- if len(args) != 3:
- print('getUsers requires 3 args')
- sys.exit(1)
- pp.pprint(client.getUsers(args[0],eval(args[1]),eval(args[2]),))
+ if len(args) != 3:
+ print('getUsers requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.getUsers(args[0], eval(args[1]), eval(args[2]),))
elif cmd == 'createGroup':
- if len(args) != 1:
- print('createGroup requires 1 args')
- sys.exit(1)
- pp.pprint(client.createGroup(eval(args[0]),))
+ if len(args) != 1:
+ print('createGroup requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.createGroup(eval(args[0]),))
elif cmd == 'updateGroup':
- if len(args) != 1:
- print('updateGroup requires 1 args')
- sys.exit(1)
- pp.pprint(client.updateGroup(eval(args[0]),))
+ if len(args) != 1:
+ print('updateGroup requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.updateGroup(eval(args[0]),))
elif cmd == 'isGroupExists':
- if len(args) != 2:
- print('isGroupExists requires 2 args')
- sys.exit(1)
- pp.pprint(client.isGroupExists(args[0],args[1],))
+ if len(args) != 2:
+ print('isGroupExists requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.isGroupExists(args[0], args[1],))
elif cmd == 'deleteGroup':
- if len(args) != 2:
- print('deleteGroup requires 2 args')
- sys.exit(1)
- pp.pprint(client.deleteGroup(args[0],args[1],))
+ if len(args) != 2:
+ print('deleteGroup requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.deleteGroup(args[0], args[1],))
elif cmd == 'getGroup':
- if len(args) != 2:
- print('getGroup requires 2 args')
- sys.exit(1)
- pp.pprint(client.getGroup(args[0],args[1],))
+ if len(args) != 2:
+ print('getGroup requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getGroup(args[0], args[1],))
elif cmd == 'getGroups':
- if len(args) != 3:
- print('getGroups requires 3 args')
- sys.exit(1)
- pp.pprint(client.getGroups(args[0],eval(args[1]),eval(args[2]),))
+ if len(args) != 3:
+ print('getGroups requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.getGroups(args[0], eval(args[1]), eval(args[2]),))
elif cmd == 'addUsersToGroup':
- if len(args) != 3:
- print('addUsersToGroup requires 3 args')
- sys.exit(1)
- pp.pprint(client.addUsersToGroup(args[0],eval(args[1]),args[2],))
+ if len(args) != 3:
+ print('addUsersToGroup requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.addUsersToGroup(args[0], eval(args[1]), args[2],))
elif cmd == 'removeUsersFromGroup':
- if len(args) != 3:
- print('removeUsersFromGroup requires 3 args')
- sys.exit(1)
- pp.pprint(client.removeUsersFromGroup(args[0],eval(args[1]),args[2],))
+ if len(args) != 3:
+ print('removeUsersFromGroup requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.removeUsersFromGroup(args[0], eval(args[1]), args[2],))
elif cmd == 'getGroupMembersOfTypeUser':
- if len(args) != 4:
- print('getGroupMembersOfTypeUser requires 4 args')
- sys.exit(1)
- pp.pprint(client.getGroupMembersOfTypeUser(args[0],args[1],eval(args[2]),eval(args[3]),))
+ if len(args) != 4:
+ print('getGroupMembersOfTypeUser requires 4 args')
+ sys.exit(1)
+ pp.pprint(client.getGroupMembersOfTypeUser(args[0], args[1], eval(args[2]), eval(args[3]),))
elif cmd == 'getGroupMembersOfTypeGroup':
- if len(args) != 4:
- print('getGroupMembersOfTypeGroup requires 4 args')
- sys.exit(1)
- pp.pprint(client.getGroupMembersOfTypeGroup(args[0],args[1],eval(args[2]),eval(args[3]),))
+ if len(args) != 4:
+ print('getGroupMembersOfTypeGroup requires 4 args')
+ sys.exit(1)
+ pp.pprint(client.getGroupMembersOfTypeGroup(args[0], args[1], eval(args[2]), eval(args[3]),))
elif cmd == 'addChildGroupsToParentGroup':
- if len(args) != 3:
- print('addChildGroupsToParentGroup requires 3 args')
- sys.exit(1)
- pp.pprint(client.addChildGroupsToParentGroup(args[0],eval(args[1]),args[2],))
+ if len(args) != 3:
+ print('addChildGroupsToParentGroup requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.addChildGroupsToParentGroup(args[0], eval(args[1]), args[2],))
elif cmd == 'removeChildGroupFromParentGroup':
- if len(args) != 3:
- print('removeChildGroupFromParentGroup requires 3 args')
- sys.exit(1)
- pp.pprint(client.removeChildGroupFromParentGroup(args[0],args[1],args[2],))
+ if len(args) != 3:
+ print('removeChildGroupFromParentGroup requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.removeChildGroupFromParentGroup(args[0], args[1], args[2],))
elif cmd == 'getAllMemberGroupsForUser':
- if len(args) != 2:
- print('getAllMemberGroupsForUser requires 2 args')
- sys.exit(1)
- pp.pprint(client.getAllMemberGroupsForUser(args[0],args[1],))
+ if len(args) != 2:
+ print('getAllMemberGroupsForUser requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getAllMemberGroupsForUser(args[0], args[1],))
elif cmd == 'createEntityType':
- if len(args) != 1:
- print('createEntityType requires 1 args')
- sys.exit(1)
- pp.pprint(client.createEntityType(eval(args[0]),))
+ if len(args) != 1:
+ print('createEntityType requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.createEntityType(eval(args[0]),))
elif cmd == 'updateEntityType':
- if len(args) != 1:
- print('updateEntityType requires 1 args')
- sys.exit(1)
- pp.pprint(client.updateEntityType(eval(args[0]),))
+ if len(args) != 1:
+ print('updateEntityType requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.updateEntityType(eval(args[0]),))
elif cmd == 'isEntityTypeExists':
- if len(args) != 2:
- print('isEntityTypeExists requires 2 args')
- sys.exit(1)
- pp.pprint(client.isEntityTypeExists(args[0],args[1],))
+ if len(args) != 2:
+ print('isEntityTypeExists requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.isEntityTypeExists(args[0], args[1],))
elif cmd == 'deleteEntityType':
- if len(args) != 2:
- print('deleteEntityType requires 2 args')
- sys.exit(1)
- pp.pprint(client.deleteEntityType(args[0],args[1],))
+ if len(args) != 2:
+ print('deleteEntityType requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.deleteEntityType(args[0], args[1],))
elif cmd == 'getEntityType':
- if len(args) != 2:
- print('getEntityType requires 2 args')
- sys.exit(1)
- pp.pprint(client.getEntityType(args[0],args[1],))
+ if len(args) != 2:
+ print('getEntityType requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getEntityType(args[0], args[1],))
elif cmd == 'getEntityTypes':
- if len(args) != 3:
- print('getEntityTypes requires 3 args')
- sys.exit(1)
- pp.pprint(client.getEntityTypes(args[0],eval(args[1]),eval(args[2]),))
+ if len(args) != 3:
+ print('getEntityTypes requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.getEntityTypes(args[0], eval(args[1]), eval(args[2]),))
elif cmd == 'createEntity':
- if len(args) != 1:
- print('createEntity requires 1 args')
- sys.exit(1)
- pp.pprint(client.createEntity(eval(args[0]),))
+ if len(args) != 1:
+ print('createEntity requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.createEntity(eval(args[0]),))
elif cmd == 'updateEntity':
- if len(args) != 1:
- print('updateEntity requires 1 args')
- sys.exit(1)
- pp.pprint(client.updateEntity(eval(args[0]),))
+ if len(args) != 1:
+ print('updateEntity requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.updateEntity(eval(args[0]),))
elif cmd == 'isEntityExists':
- if len(args) != 2:
- print('isEntityExists requires 2 args')
- sys.exit(1)
- pp.pprint(client.isEntityExists(args[0],args[1],))
+ if len(args) != 2:
+ print('isEntityExists requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.isEntityExists(args[0], args[1],))
elif cmd == 'deleteEntity':
- if len(args) != 2:
- print('deleteEntity requires 2 args')
- sys.exit(1)
- pp.pprint(client.deleteEntity(args[0],args[1],))
+ if len(args) != 2:
+ print('deleteEntity requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.deleteEntity(args[0], args[1],))
elif cmd == 'getEntity':
- if len(args) != 2:
- print('getEntity requires 2 args')
- sys.exit(1)
- pp.pprint(client.getEntity(args[0],args[1],))
+ if len(args) != 2:
+ print('getEntity requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getEntity(args[0], args[1],))
elif cmd == 'searchEntities':
- if len(args) != 5:
- print('searchEntities requires 5 args')
- sys.exit(1)
- pp.pprint(client.searchEntities(args[0],args[1],eval(args[2]),eval(args[3]),eval(args[4]),))
+ if len(args) != 5:
+ print('searchEntities requires 5 args')
+ sys.exit(1)
+ pp.pprint(client.searchEntities(args[0], args[1], eval(args[2]), eval(args[3]), eval(args[4]),))
elif cmd == 'getListOfSharedUsers':
- if len(args) != 3:
- print('getListOfSharedUsers requires 3 args')
- sys.exit(1)
- pp.pprint(client.getListOfSharedUsers(args[0],args[1],args[2],))
+ if len(args) != 3:
+ print('getListOfSharedUsers requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.getListOfSharedUsers(args[0], args[1], args[2],))
elif cmd == 'getListOfSharedGroups':
- if len(args) != 3:
- print('getListOfSharedGroups requires 3 args')
- sys.exit(1)
- pp.pprint(client.getListOfSharedGroups(args[0],args[1],args[2],))
+ if len(args) != 3:
+ print('getListOfSharedGroups requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.getListOfSharedGroups(args[0], args[1], args[2],))
elif cmd == 'createPermissionType':
- if len(args) != 1:
- print('createPermissionType requires 1 args')
- sys.exit(1)
- pp.pprint(client.createPermissionType(eval(args[0]),))
+ if len(args) != 1:
+ print('createPermissionType requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.createPermissionType(eval(args[0]),))
elif cmd == 'updatePermissionType':
- if len(args) != 1:
- print('updatePermissionType requires 1 args')
- sys.exit(1)
- pp.pprint(client.updatePermissionType(eval(args[0]),))
+ if len(args) != 1:
+ print('updatePermissionType requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.updatePermissionType(eval(args[0]),))
elif cmd == 'isPermissionExists':
- if len(args) != 2:
- print('isPermissionExists requires 2 args')
- sys.exit(1)
- pp.pprint(client.isPermissionExists(args[0],args[1],))
+ if len(args) != 2:
+ print('isPermissionExists requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.isPermissionExists(args[0], args[1],))
elif cmd == 'deletePermissionType':
- if len(args) != 2:
- print('deletePermissionType requires 2 args')
- sys.exit(1)
- pp.pprint(client.deletePermissionType(args[0],args[1],))
+ if len(args) != 2:
+ print('deletePermissionType requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.deletePermissionType(args[0], args[1],))
elif cmd == 'getPermissionType':
- if len(args) != 2:
- print('getPermissionType requires 2 args')
- sys.exit(1)
- pp.pprint(client.getPermissionType(args[0],args[1],))
+ if len(args) != 2:
+ print('getPermissionType requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getPermissionType(args[0], args[1],))
elif cmd == 'getPermissionTypes':
- if len(args) != 3:
- print('getPermissionTypes requires 3 args')
- sys.exit(1)
- pp.pprint(client.getPermissionTypes(args[0],eval(args[1]),eval(args[2]),))
+ if len(args) != 3:
+ print('getPermissionTypes requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.getPermissionTypes(args[0], eval(args[1]), eval(args[2]),))
elif cmd == 'shareEntityWithUsers':
- if len(args) != 5:
- print('shareEntityWithUsers requires 5 args')
- sys.exit(1)
- pp.pprint(client.shareEntityWithUsers(args[0],args[1],eval(args[2]),args[3],eval(args[4]),))
+ if len(args) != 5:
+ print('shareEntityWithUsers requires 5 args')
+ sys.exit(1)
+ pp.pprint(client.shareEntityWithUsers(args[0], args[1], eval(args[2]), args[3], eval(args[4]),))
elif cmd == 'revokeEntitySharingFromUsers':
- if len(args) != 4:
- print('revokeEntitySharingFromUsers requires 4 args')
- sys.exit(1)
- pp.pprint(client.revokeEntitySharingFromUsers(args[0],args[1],eval(args[2]),args[3],))
+ if len(args) != 4:
+ print('revokeEntitySharingFromUsers requires 4 args')
+ sys.exit(1)
+ pp.pprint(client.revokeEntitySharingFromUsers(args[0], args[1], eval(args[2]), args[3],))
elif cmd == 'shareEntityWithGroups':
- if len(args) != 5:
- print('shareEntityWithGroups requires 5 args')
- sys.exit(1)
- pp.pprint(client.shareEntityWithGroups(args[0],args[1],eval(args[2]),args[3],eval(args[4]),))
+ if len(args) != 5:
+ print('shareEntityWithGroups requires 5 args')
+ sys.exit(1)
+ pp.pprint(client.shareEntityWithGroups(args[0], args[1], eval(args[2]), args[3], eval(args[4]),))
elif cmd == 'revokeEntitySharingFromGroups':
- if len(args) != 4:
- print('revokeEntitySharingFromGroups requires 4 args')
- sys.exit(1)
- pp.pprint(client.revokeEntitySharingFromGroups(args[0],args[1],eval(args[2]),args[3],))
+ if len(args) != 4:
+ print('revokeEntitySharingFromGroups requires 4 args')
+ sys.exit(1)
+ pp.pprint(client.revokeEntitySharingFromGroups(args[0], args[1], eval(args[2]), args[3],))
elif cmd == 'userHasAccess':
- if len(args) != 4:
- print('userHasAccess requires 4 args')
- sys.exit(1)
- pp.pprint(client.userHasAccess(args[0],args[1],args[2],args[3],))
+ if len(args) != 4:
+ print('userHasAccess requires 4 args')
+ sys.exit(1)
+ pp.pprint(client.userHasAccess(args[0], args[1], args[2], args[3],))
else:
- print('Unrecognized method %s' % cmd)
- sys.exit(1)
+ print('Unrecognized method %s' % cmd)
+ sys.exit(1)
transport.close()
[22/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/CommandObject.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/CommandObject.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/CommandObject.java
index 45df73d..86e849f 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/CommandObject.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/CommandObject.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.appdeployment;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Job commands to be used in Pre Job, Post Job and Module Load Commands
*
@@ -60,20 +33,17 @@ import org.slf4j.LoggerFactory;
* commandOrder:
* Order of the command in the multiple command situation
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class CommandObject implements org.apache.thrift.TBase<CommandObject, CommandObject._Fields>, java.io.Serializable, Cloneable, Comparable<CommandObject> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("CommandObject");
private static final org.apache.thrift.protocol.TField COMMAND_FIELD_DESC = new org.apache.thrift.protocol.TField("command", org.apache.thrift.protocol.TType.STRING, (short)1);
private static final org.apache.thrift.protocol.TField COMMAND_ORDER_FIELD_DESC = new org.apache.thrift.protocol.TField("commandOrder", org.apache.thrift.protocol.TType.I32, (short)2);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new CommandObjectStandardSchemeFactory());
- schemes.put(TupleScheme.class, new CommandObjectTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new CommandObjectStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new CommandObjectTupleSchemeFactory();
- private String command; // required
+ private java.lang.String command; // required
private int commandOrder; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
@@ -81,10 +51,10 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
COMMAND((short)1, "command"),
COMMAND_ORDER((short)2, "commandOrder");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -109,21 +79,21 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -132,7 +102,7 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -141,14 +111,14 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
private static final int __COMMANDORDER_ISSET_ID = 0;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.COMMAND_ORDER};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.COMMAND, new org.apache.thrift.meta_data.FieldMetaData("command", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.COMMAND_ORDER, new org.apache.thrift.meta_data.FieldMetaData("commandOrder", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(CommandObject.class, metaDataMap);
}
@@ -156,7 +126,7 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
}
public CommandObject(
- String command)
+ java.lang.String command)
{
this();
this.command = command;
@@ -184,11 +154,11 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
this.commandOrder = 0;
}
- public String getCommand() {
+ public java.lang.String getCommand() {
return this.command;
}
- public void setCommand(String command) {
+ public void setCommand(java.lang.String command) {
this.command = command;
}
@@ -217,25 +187,25 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
}
public void unsetCommandOrder() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __COMMANDORDER_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __COMMANDORDER_ISSET_ID);
}
/** Returns true if field commandOrder is set (has been assigned a value) and false otherwise */
public boolean isSetCommandOrder() {
- return EncodingUtils.testBit(__isset_bitfield, __COMMANDORDER_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __COMMANDORDER_ISSET_ID);
}
public void setCommandOrderIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __COMMANDORDER_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __COMMANDORDER_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case COMMAND:
if (value == null) {
unsetCommand();
} else {
- setCommand((String)value);
+ setCommand((java.lang.String)value);
}
break;
@@ -243,14 +213,14 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
if (value == null) {
unsetCommandOrder();
} else {
- setCommandOrder((Integer)value);
+ setCommandOrder((java.lang.Integer)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case COMMAND:
return getCommand();
@@ -259,13 +229,13 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
return getCommandOrder();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -274,11 +244,11 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
case COMMAND_ORDER:
return isSetCommandOrder();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof CommandObject)
@@ -289,6 +259,8 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
public boolean equals(CommandObject that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_command = true && this.isSetCommand();
boolean that_present_command = true && that.isSetCommand();
@@ -313,19 +285,17 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_command = true && (isSetCommand());
- list.add(present_command);
- if (present_command)
- list.add(command);
+ hashCode = hashCode * 8191 + ((isSetCommand()) ? 131071 : 524287);
+ if (isSetCommand())
+ hashCode = hashCode * 8191 + command.hashCode();
- boolean present_commandOrder = true && (isSetCommandOrder());
- list.add(present_commandOrder);
- if (present_commandOrder)
- list.add(commandOrder);
+ hashCode = hashCode * 8191 + ((isSetCommandOrder()) ? 131071 : 524287);
+ if (isSetCommandOrder())
+ hashCode = hashCode * 8191 + commandOrder;
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -336,7 +306,7 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetCommand()).compareTo(other.isSetCommand());
+ lastComparison = java.lang.Boolean.valueOf(isSetCommand()).compareTo(other.isSetCommand());
if (lastComparison != 0) {
return lastComparison;
}
@@ -346,7 +316,7 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCommandOrder()).compareTo(other.isSetCommandOrder());
+ lastComparison = java.lang.Boolean.valueOf(isSetCommandOrder()).compareTo(other.isSetCommandOrder());
if (lastComparison != 0) {
return lastComparison;
}
@@ -364,16 +334,16 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("CommandObject(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("CommandObject(");
boolean first = true;
sb.append("command:");
@@ -410,7 +380,7 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -420,13 +390,13 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
}
}
- private static class CommandObjectStandardSchemeFactory implements SchemeFactory {
+ private static class CommandObjectStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public CommandObjectStandardScheme getScheme() {
return new CommandObjectStandardScheme();
}
}
- private static class CommandObjectStandardScheme extends StandardScheme<CommandObject> {
+ private static class CommandObjectStandardScheme extends org.apache.thrift.scheme.StandardScheme<CommandObject> {
public void read(org.apache.thrift.protocol.TProtocol iprot, CommandObject struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -483,19 +453,19 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
}
- private static class CommandObjectTupleSchemeFactory implements SchemeFactory {
+ private static class CommandObjectTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public CommandObjectTupleScheme getScheme() {
return new CommandObjectTupleScheme();
}
}
- private static class CommandObjectTupleScheme extends TupleScheme<CommandObject> {
+ private static class CommandObjectTupleScheme extends org.apache.thrift.scheme.TupleScheme<CommandObject> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, CommandObject struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.command);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetCommandOrder()) {
optionals.set(0);
}
@@ -507,10 +477,10 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, CommandObject struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.command = iprot.readString();
struct.setCommandIsSet(true);
- BitSet incoming = iprot.readBitSet(1);
+ java.util.BitSet incoming = iprot.readBitSet(1);
if (incoming.get(0)) {
struct.commandOrder = iprot.readI32();
struct.setCommandOrderIsSet(true);
@@ -518,5 +488,8 @@ public class CommandObject implements org.apache.thrift.TBase<CommandObject, Com
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/SetEnvPaths.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/SetEnvPaths.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/SetEnvPaths.java
index 392cc9e..91e3cc1 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/SetEnvPaths.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/SetEnvPaths.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.appdeployment;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Key Value pairs to be used to set environments
*
@@ -63,7 +36,7 @@ import org.slf4j.LoggerFactory;
* envPathOrder:
* The order of the setting of the env variables when there are multiple env variables
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvPaths._Fields>, java.io.Serializable, Cloneable, Comparable<SetEnvPaths> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("SetEnvPaths");
@@ -71,14 +44,11 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
private static final org.apache.thrift.protocol.TField VALUE_FIELD_DESC = new org.apache.thrift.protocol.TField("value", org.apache.thrift.protocol.TType.STRING, (short)2);
private static final org.apache.thrift.protocol.TField ENV_PATH_ORDER_FIELD_DESC = new org.apache.thrift.protocol.TField("envPathOrder", org.apache.thrift.protocol.TType.I32, (short)3);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new SetEnvPathsStandardSchemeFactory());
- schemes.put(TupleScheme.class, new SetEnvPathsTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new SetEnvPathsStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new SetEnvPathsTupleSchemeFactory();
- private String name; // required
- private String value; // required
+ private java.lang.String name; // required
+ private java.lang.String value; // required
private int envPathOrder; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
@@ -87,10 +57,10 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
VALUE((short)2, "value"),
ENV_PATH_ORDER((short)3, "envPathOrder");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -117,21 +87,21 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -140,7 +110,7 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -149,16 +119,16 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
private static final int __ENVPATHORDER_ISSET_ID = 0;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.ENV_PATH_ORDER};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.NAME, new org.apache.thrift.meta_data.FieldMetaData("name", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.VALUE, new org.apache.thrift.meta_data.FieldMetaData("value", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.ENV_PATH_ORDER, new org.apache.thrift.meta_data.FieldMetaData("envPathOrder", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(SetEnvPaths.class, metaDataMap);
}
@@ -166,8 +136,8 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
}
public SetEnvPaths(
- String name,
- String value)
+ java.lang.String name,
+ java.lang.String value)
{
this();
this.name = name;
@@ -200,11 +170,11 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
this.envPathOrder = 0;
}
- public String getName() {
+ public java.lang.String getName() {
return this.name;
}
- public void setName(String name) {
+ public void setName(java.lang.String name) {
this.name = name;
}
@@ -223,11 +193,11 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
}
}
- public String getValue() {
+ public java.lang.String getValue() {
return this.value;
}
- public void setValue(String value) {
+ public void setValue(java.lang.String value) {
this.value = value;
}
@@ -256,25 +226,25 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
}
public void unsetEnvPathOrder() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ENVPATHORDER_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ENVPATHORDER_ISSET_ID);
}
/** Returns true if field envPathOrder is set (has been assigned a value) and false otherwise */
public boolean isSetEnvPathOrder() {
- return EncodingUtils.testBit(__isset_bitfield, __ENVPATHORDER_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ENVPATHORDER_ISSET_ID);
}
public void setEnvPathOrderIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ENVPATHORDER_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ENVPATHORDER_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case NAME:
if (value == null) {
unsetName();
} else {
- setName((String)value);
+ setName((java.lang.String)value);
}
break;
@@ -282,7 +252,7 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
if (value == null) {
unsetValue();
} else {
- setValue((String)value);
+ setValue((java.lang.String)value);
}
break;
@@ -290,14 +260,14 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
if (value == null) {
unsetEnvPathOrder();
} else {
- setEnvPathOrder((Integer)value);
+ setEnvPathOrder((java.lang.Integer)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case NAME:
return getName();
@@ -309,13 +279,13 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
return getEnvPathOrder();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -326,11 +296,11 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
case ENV_PATH_ORDER:
return isSetEnvPathOrder();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof SetEnvPaths)
@@ -341,6 +311,8 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
public boolean equals(SetEnvPaths that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_name = true && this.isSetName();
boolean that_present_name = true && that.isSetName();
@@ -374,24 +346,21 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_name = true && (isSetName());
- list.add(present_name);
- if (present_name)
- list.add(name);
+ hashCode = hashCode * 8191 + ((isSetName()) ? 131071 : 524287);
+ if (isSetName())
+ hashCode = hashCode * 8191 + name.hashCode();
- boolean present_value = true && (isSetValue());
- list.add(present_value);
- if (present_value)
- list.add(value);
+ hashCode = hashCode * 8191 + ((isSetValue()) ? 131071 : 524287);
+ if (isSetValue())
+ hashCode = hashCode * 8191 + value.hashCode();
- boolean present_envPathOrder = true && (isSetEnvPathOrder());
- list.add(present_envPathOrder);
- if (present_envPathOrder)
- list.add(envPathOrder);
+ hashCode = hashCode * 8191 + ((isSetEnvPathOrder()) ? 131071 : 524287);
+ if (isSetEnvPathOrder())
+ hashCode = hashCode * 8191 + envPathOrder;
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -402,7 +371,7 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetName()).compareTo(other.isSetName());
+ lastComparison = java.lang.Boolean.valueOf(isSetName()).compareTo(other.isSetName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -412,7 +381,7 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetValue()).compareTo(other.isSetValue());
+ lastComparison = java.lang.Boolean.valueOf(isSetValue()).compareTo(other.isSetValue());
if (lastComparison != 0) {
return lastComparison;
}
@@ -422,7 +391,7 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetEnvPathOrder()).compareTo(other.isSetEnvPathOrder());
+ lastComparison = java.lang.Boolean.valueOf(isSetEnvPathOrder()).compareTo(other.isSetEnvPathOrder());
if (lastComparison != 0) {
return lastComparison;
}
@@ -440,16 +409,16 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("SetEnvPaths(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("SetEnvPaths(");
boolean first = true;
sb.append("name:");
@@ -498,7 +467,7 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -508,13 +477,13 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
}
}
- private static class SetEnvPathsStandardSchemeFactory implements SchemeFactory {
+ private static class SetEnvPathsStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public SetEnvPathsStandardScheme getScheme() {
return new SetEnvPathsStandardScheme();
}
}
- private static class SetEnvPathsStandardScheme extends StandardScheme<SetEnvPaths> {
+ private static class SetEnvPathsStandardScheme extends org.apache.thrift.scheme.StandardScheme<SetEnvPaths> {
public void read(org.apache.thrift.protocol.TProtocol iprot, SetEnvPaths struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -584,20 +553,20 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
}
- private static class SetEnvPathsTupleSchemeFactory implements SchemeFactory {
+ private static class SetEnvPathsTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public SetEnvPathsTupleScheme getScheme() {
return new SetEnvPathsTupleScheme();
}
}
- private static class SetEnvPathsTupleScheme extends TupleScheme<SetEnvPaths> {
+ private static class SetEnvPathsTupleScheme extends org.apache.thrift.scheme.TupleScheme<SetEnvPaths> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, SetEnvPaths struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.name);
oprot.writeString(struct.value);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetEnvPathOrder()) {
optionals.set(0);
}
@@ -609,12 +578,12 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, SetEnvPaths struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.name = iprot.readString();
struct.setNameIsSet(true);
struct.value = iprot.readString();
struct.setValueIsSet(true);
- BitSet incoming = iprot.readBitSet(1);
+ java.util.BitSet incoming = iprot.readBitSet(1);
if (incoming.get(0)) {
struct.envPathOrder = iprot.readI32();
struct.setEnvPathOrderIsSet(true);
@@ -622,5 +591,8 @@ public class SetEnvPaths implements org.apache.thrift.TBase<SetEnvPaths, SetEnvP
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appinterface/ApplicationInterfaceDescription.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appinterface/ApplicationInterfaceDescription.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appinterface/ApplicationInterfaceDescription.java
index e832256..061da15 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appinterface/ApplicationInterfaceDescription.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appinterface/ApplicationInterfaceDescription.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.appinterface;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Application Interface Description
*
@@ -64,7 +37,7 @@ import org.slf4j.LoggerFactory;
* Outputs generated from the application
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<ApplicationInterfaceDescription, ApplicationInterfaceDescription._Fields>, java.io.Serializable, Cloneable, Comparable<ApplicationInterfaceDescription> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ApplicationInterfaceDescription");
@@ -77,18 +50,15 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
private static final org.apache.thrift.protocol.TField ARCHIVE_WORKING_DIRECTORY_FIELD_DESC = new org.apache.thrift.protocol.TField("archiveWorkingDirectory", org.apache.thrift.protocol.TType.BOOL, (short)7);
private static final org.apache.thrift.protocol.TField HAS_OPTIONAL_FILE_INPUTS_FIELD_DESC = new org.apache.thrift.protocol.TField("hasOptionalFileInputs", org.apache.thrift.protocol.TType.BOOL, (short)8);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new ApplicationInterfaceDescriptionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ApplicationInterfaceDescriptionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ApplicationInterfaceDescriptionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ApplicationInterfaceDescriptionTupleSchemeFactory();
- private String applicationInterfaceId; // required
- private String applicationName; // required
- private String applicationDescription; // optional
- private List<String> applicationModules; // optional
- private List<org.apache.airavata.model.application.io.InputDataObjectType> applicationInputs; // optional
- private List<org.apache.airavata.model.application.io.OutputDataObjectType> applicationOutputs; // optional
+ private java.lang.String applicationInterfaceId; // required
+ private java.lang.String applicationName; // required
+ private java.lang.String applicationDescription; // optional
+ private java.util.List<java.lang.String> applicationModules; // optional
+ private java.util.List<org.apache.airavata.model.application.io.InputDataObjectType> applicationInputs; // optional
+ private java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType> applicationOutputs; // optional
private boolean archiveWorkingDirectory; // optional
private boolean hasOptionalFileInputs; // optional
@@ -103,10 +73,10 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
ARCHIVE_WORKING_DIRECTORY((short)7, "archiveWorkingDirectory"),
HAS_OPTIONAL_FILE_INPUTS((short)8, "hasOptionalFileInputs");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -143,21 +113,21 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -166,7 +136,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -176,9 +146,9 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
private static final int __HASOPTIONALFILEINPUTS_ISSET_ID = 1;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.APPLICATION_DESCRIPTION,_Fields.APPLICATION_MODULES,_Fields.APPLICATION_INPUTS,_Fields.APPLICATION_OUTPUTS,_Fields.ARCHIVE_WORKING_DIRECTORY,_Fields.HAS_OPTIONAL_FILE_INPUTS};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.APPLICATION_INTERFACE_ID, new org.apache.thrift.meta_data.FieldMetaData("applicationInterfaceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.APPLICATION_NAME, new org.apache.thrift.meta_data.FieldMetaData("applicationName", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -198,7 +168,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
tmpMap.put(_Fields.HAS_OPTIONAL_FILE_INPUTS, new org.apache.thrift.meta_data.FieldMetaData("hasOptionalFileInputs", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ApplicationInterfaceDescription.class, metaDataMap);
}
@@ -210,8 +180,8 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
}
public ApplicationInterfaceDescription(
- String applicationInterfaceId,
- String applicationName)
+ java.lang.String applicationInterfaceId,
+ java.lang.String applicationName)
{
this();
this.applicationInterfaceId = applicationInterfaceId;
@@ -233,18 +203,18 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
this.applicationDescription = other.applicationDescription;
}
if (other.isSetApplicationModules()) {
- List<String> __this__applicationModules = new ArrayList<String>(other.applicationModules);
+ java.util.List<java.lang.String> __this__applicationModules = new java.util.ArrayList<java.lang.String>(other.applicationModules);
this.applicationModules = __this__applicationModules;
}
if (other.isSetApplicationInputs()) {
- List<org.apache.airavata.model.application.io.InputDataObjectType> __this__applicationInputs = new ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(other.applicationInputs.size());
+ java.util.List<org.apache.airavata.model.application.io.InputDataObjectType> __this__applicationInputs = new java.util.ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(other.applicationInputs.size());
for (org.apache.airavata.model.application.io.InputDataObjectType other_element : other.applicationInputs) {
__this__applicationInputs.add(new org.apache.airavata.model.application.io.InputDataObjectType(other_element));
}
this.applicationInputs = __this__applicationInputs;
}
if (other.isSetApplicationOutputs()) {
- List<org.apache.airavata.model.application.io.OutputDataObjectType> __this__applicationOutputs = new ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(other.applicationOutputs.size());
+ java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType> __this__applicationOutputs = new java.util.ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(other.applicationOutputs.size());
for (org.apache.airavata.model.application.io.OutputDataObjectType other_element : other.applicationOutputs) {
__this__applicationOutputs.add(new org.apache.airavata.model.application.io.OutputDataObjectType(other_element));
}
@@ -273,11 +243,11 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
this.hasOptionalFileInputs = false;
}
- public String getApplicationInterfaceId() {
+ public java.lang.String getApplicationInterfaceId() {
return this.applicationInterfaceId;
}
- public void setApplicationInterfaceId(String applicationInterfaceId) {
+ public void setApplicationInterfaceId(java.lang.String applicationInterfaceId) {
this.applicationInterfaceId = applicationInterfaceId;
}
@@ -296,11 +266,11 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
}
}
- public String getApplicationName() {
+ public java.lang.String getApplicationName() {
return this.applicationName;
}
- public void setApplicationName(String applicationName) {
+ public void setApplicationName(java.lang.String applicationName) {
this.applicationName = applicationName;
}
@@ -319,11 +289,11 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
}
}
- public String getApplicationDescription() {
+ public java.lang.String getApplicationDescription() {
return this.applicationDescription;
}
- public void setApplicationDescription(String applicationDescription) {
+ public void setApplicationDescription(java.lang.String applicationDescription) {
this.applicationDescription = applicationDescription;
}
@@ -346,22 +316,22 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
return (this.applicationModules == null) ? 0 : this.applicationModules.size();
}
- public java.util.Iterator<String> getApplicationModulesIterator() {
+ public java.util.Iterator<java.lang.String> getApplicationModulesIterator() {
return (this.applicationModules == null) ? null : this.applicationModules.iterator();
}
- public void addToApplicationModules(String elem) {
+ public void addToApplicationModules(java.lang.String elem) {
if (this.applicationModules == null) {
- this.applicationModules = new ArrayList<String>();
+ this.applicationModules = new java.util.ArrayList<java.lang.String>();
}
this.applicationModules.add(elem);
}
- public List<String> getApplicationModules() {
+ public java.util.List<java.lang.String> getApplicationModules() {
return this.applicationModules;
}
- public void setApplicationModules(List<String> applicationModules) {
+ public void setApplicationModules(java.util.List<java.lang.String> applicationModules) {
this.applicationModules = applicationModules;
}
@@ -390,16 +360,16 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
public void addToApplicationInputs(org.apache.airavata.model.application.io.InputDataObjectType elem) {
if (this.applicationInputs == null) {
- this.applicationInputs = new ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>();
+ this.applicationInputs = new java.util.ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>();
}
this.applicationInputs.add(elem);
}
- public List<org.apache.airavata.model.application.io.InputDataObjectType> getApplicationInputs() {
+ public java.util.List<org.apache.airavata.model.application.io.InputDataObjectType> getApplicationInputs() {
return this.applicationInputs;
}
- public void setApplicationInputs(List<org.apache.airavata.model.application.io.InputDataObjectType> applicationInputs) {
+ public void setApplicationInputs(java.util.List<org.apache.airavata.model.application.io.InputDataObjectType> applicationInputs) {
this.applicationInputs = applicationInputs;
}
@@ -428,16 +398,16 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
public void addToApplicationOutputs(org.apache.airavata.model.application.io.OutputDataObjectType elem) {
if (this.applicationOutputs == null) {
- this.applicationOutputs = new ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>();
+ this.applicationOutputs = new java.util.ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>();
}
this.applicationOutputs.add(elem);
}
- public List<org.apache.airavata.model.application.io.OutputDataObjectType> getApplicationOutputs() {
+ public java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType> getApplicationOutputs() {
return this.applicationOutputs;
}
- public void setApplicationOutputs(List<org.apache.airavata.model.application.io.OutputDataObjectType> applicationOutputs) {
+ public void setApplicationOutputs(java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType> applicationOutputs) {
this.applicationOutputs = applicationOutputs;
}
@@ -466,16 +436,16 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
}
public void unsetArchiveWorkingDirectory() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ARCHIVEWORKINGDIRECTORY_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ARCHIVEWORKINGDIRECTORY_ISSET_ID);
}
/** Returns true if field archiveWorkingDirectory is set (has been assigned a value) and false otherwise */
public boolean isSetArchiveWorkingDirectory() {
- return EncodingUtils.testBit(__isset_bitfield, __ARCHIVEWORKINGDIRECTORY_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ARCHIVEWORKINGDIRECTORY_ISSET_ID);
}
public void setArchiveWorkingDirectoryIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ARCHIVEWORKINGDIRECTORY_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ARCHIVEWORKINGDIRECTORY_ISSET_ID, value);
}
public boolean isHasOptionalFileInputs() {
@@ -488,25 +458,25 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
}
public void unsetHasOptionalFileInputs() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __HASOPTIONALFILEINPUTS_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __HASOPTIONALFILEINPUTS_ISSET_ID);
}
/** Returns true if field hasOptionalFileInputs is set (has been assigned a value) and false otherwise */
public boolean isSetHasOptionalFileInputs() {
- return EncodingUtils.testBit(__isset_bitfield, __HASOPTIONALFILEINPUTS_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __HASOPTIONALFILEINPUTS_ISSET_ID);
}
public void setHasOptionalFileInputsIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __HASOPTIONALFILEINPUTS_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __HASOPTIONALFILEINPUTS_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case APPLICATION_INTERFACE_ID:
if (value == null) {
unsetApplicationInterfaceId();
} else {
- setApplicationInterfaceId((String)value);
+ setApplicationInterfaceId((java.lang.String)value);
}
break;
@@ -514,7 +484,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
if (value == null) {
unsetApplicationName();
} else {
- setApplicationName((String)value);
+ setApplicationName((java.lang.String)value);
}
break;
@@ -522,7 +492,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
if (value == null) {
unsetApplicationDescription();
} else {
- setApplicationDescription((String)value);
+ setApplicationDescription((java.lang.String)value);
}
break;
@@ -530,7 +500,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
if (value == null) {
unsetApplicationModules();
} else {
- setApplicationModules((List<String>)value);
+ setApplicationModules((java.util.List<java.lang.String>)value);
}
break;
@@ -538,7 +508,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
if (value == null) {
unsetApplicationInputs();
} else {
- setApplicationInputs((List<org.apache.airavata.model.application.io.InputDataObjectType>)value);
+ setApplicationInputs((java.util.List<org.apache.airavata.model.application.io.InputDataObjectType>)value);
}
break;
@@ -546,7 +516,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
if (value == null) {
unsetApplicationOutputs();
} else {
- setApplicationOutputs((List<org.apache.airavata.model.application.io.OutputDataObjectType>)value);
+ setApplicationOutputs((java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType>)value);
}
break;
@@ -554,7 +524,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
if (value == null) {
unsetArchiveWorkingDirectory();
} else {
- setArchiveWorkingDirectory((Boolean)value);
+ setArchiveWorkingDirectory((java.lang.Boolean)value);
}
break;
@@ -562,14 +532,14 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
if (value == null) {
unsetHasOptionalFileInputs();
} else {
- setHasOptionalFileInputs((Boolean)value);
+ setHasOptionalFileInputs((java.lang.Boolean)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case APPLICATION_INTERFACE_ID:
return getApplicationInterfaceId();
@@ -596,13 +566,13 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
return isHasOptionalFileInputs();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -623,11 +593,11 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
case HAS_OPTIONAL_FILE_INPUTS:
return isSetHasOptionalFileInputs();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ApplicationInterfaceDescription)
@@ -638,6 +608,8 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
public boolean equals(ApplicationInterfaceDescription that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_applicationInterfaceId = true && this.isSetApplicationInterfaceId();
boolean that_present_applicationInterfaceId = true && that.isSetApplicationInterfaceId();
@@ -716,49 +688,41 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_applicationInterfaceId = true && (isSetApplicationInterfaceId());
- list.add(present_applicationInterfaceId);
- if (present_applicationInterfaceId)
- list.add(applicationInterfaceId);
+ hashCode = hashCode * 8191 + ((isSetApplicationInterfaceId()) ? 131071 : 524287);
+ if (isSetApplicationInterfaceId())
+ hashCode = hashCode * 8191 + applicationInterfaceId.hashCode();
- boolean present_applicationName = true && (isSetApplicationName());
- list.add(present_applicationName);
- if (present_applicationName)
- list.add(applicationName);
+ hashCode = hashCode * 8191 + ((isSetApplicationName()) ? 131071 : 524287);
+ if (isSetApplicationName())
+ hashCode = hashCode * 8191 + applicationName.hashCode();
- boolean present_applicationDescription = true && (isSetApplicationDescription());
- list.add(present_applicationDescription);
- if (present_applicationDescription)
- list.add(applicationDescription);
+ hashCode = hashCode * 8191 + ((isSetApplicationDescription()) ? 131071 : 524287);
+ if (isSetApplicationDescription())
+ hashCode = hashCode * 8191 + applicationDescription.hashCode();
- boolean present_applicationModules = true && (isSetApplicationModules());
- list.add(present_applicationModules);
- if (present_applicationModules)
- list.add(applicationModules);
+ hashCode = hashCode * 8191 + ((isSetApplicationModules()) ? 131071 : 524287);
+ if (isSetApplicationModules())
+ hashCode = hashCode * 8191 + applicationModules.hashCode();
- boolean present_applicationInputs = true && (isSetApplicationInputs());
- list.add(present_applicationInputs);
- if (present_applicationInputs)
- list.add(applicationInputs);
+ hashCode = hashCode * 8191 + ((isSetApplicationInputs()) ? 131071 : 524287);
+ if (isSetApplicationInputs())
+ hashCode = hashCode * 8191 + applicationInputs.hashCode();
- boolean present_applicationOutputs = true && (isSetApplicationOutputs());
- list.add(present_applicationOutputs);
- if (present_applicationOutputs)
- list.add(applicationOutputs);
+ hashCode = hashCode * 8191 + ((isSetApplicationOutputs()) ? 131071 : 524287);
+ if (isSetApplicationOutputs())
+ hashCode = hashCode * 8191 + applicationOutputs.hashCode();
- boolean present_archiveWorkingDirectory = true && (isSetArchiveWorkingDirectory());
- list.add(present_archiveWorkingDirectory);
- if (present_archiveWorkingDirectory)
- list.add(archiveWorkingDirectory);
+ hashCode = hashCode * 8191 + ((isSetArchiveWorkingDirectory()) ? 131071 : 524287);
+ if (isSetArchiveWorkingDirectory())
+ hashCode = hashCode * 8191 + ((archiveWorkingDirectory) ? 131071 : 524287);
- boolean present_hasOptionalFileInputs = true && (isSetHasOptionalFileInputs());
- list.add(present_hasOptionalFileInputs);
- if (present_hasOptionalFileInputs)
- list.add(hasOptionalFileInputs);
+ hashCode = hashCode * 8191 + ((isSetHasOptionalFileInputs()) ? 131071 : 524287);
+ if (isSetHasOptionalFileInputs())
+ hashCode = hashCode * 8191 + ((hasOptionalFileInputs) ? 131071 : 524287);
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -769,7 +733,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetApplicationInterfaceId()).compareTo(other.isSetApplicationInterfaceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetApplicationInterfaceId()).compareTo(other.isSetApplicationInterfaceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -779,7 +743,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetApplicationName()).compareTo(other.isSetApplicationName());
+ lastComparison = java.lang.Boolean.valueOf(isSetApplicationName()).compareTo(other.isSetApplicationName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -789,7 +753,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetApplicationDescription()).compareTo(other.isSetApplicationDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetApplicationDescription()).compareTo(other.isSetApplicationDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -799,7 +763,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetApplicationModules()).compareTo(other.isSetApplicationModules());
+ lastComparison = java.lang.Boolean.valueOf(isSetApplicationModules()).compareTo(other.isSetApplicationModules());
if (lastComparison != 0) {
return lastComparison;
}
@@ -809,7 +773,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetApplicationInputs()).compareTo(other.isSetApplicationInputs());
+ lastComparison = java.lang.Boolean.valueOf(isSetApplicationInputs()).compareTo(other.isSetApplicationInputs());
if (lastComparison != 0) {
return lastComparison;
}
@@ -819,7 +783,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetApplicationOutputs()).compareTo(other.isSetApplicationOutputs());
+ lastComparison = java.lang.Boolean.valueOf(isSetApplicationOutputs()).compareTo(other.isSetApplicationOutputs());
if (lastComparison != 0) {
return lastComparison;
}
@@ -829,7 +793,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetArchiveWorkingDirectory()).compareTo(other.isSetArchiveWorkingDirectory());
+ lastComparison = java.lang.Boolean.valueOf(isSetArchiveWorkingDirectory()).compareTo(other.isSetArchiveWorkingDirectory());
if (lastComparison != 0) {
return lastComparison;
}
@@ -839,7 +803,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetHasOptionalFileInputs()).compareTo(other.isSetHasOptionalFileInputs());
+ lastComparison = java.lang.Boolean.valueOf(isSetHasOptionalFileInputs()).compareTo(other.isSetHasOptionalFileInputs());
if (lastComparison != 0) {
return lastComparison;
}
@@ -857,16 +821,16 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ApplicationInterfaceDescription(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ApplicationInterfaceDescription(");
boolean first = true;
sb.append("applicationInterfaceId:");
@@ -961,7 +925,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -971,13 +935,13 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
}
}
- private static class ApplicationInterfaceDescriptionStandardSchemeFactory implements SchemeFactory {
+ private static class ApplicationInterfaceDescriptionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ApplicationInterfaceDescriptionStandardScheme getScheme() {
return new ApplicationInterfaceDescriptionStandardScheme();
}
}
- private static class ApplicationInterfaceDescriptionStandardScheme extends StandardScheme<ApplicationInterfaceDescription> {
+ private static class ApplicationInterfaceDescriptionStandardScheme extends org.apache.thrift.scheme.StandardScheme<ApplicationInterfaceDescription> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ApplicationInterfaceDescription struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1017,8 +981,8 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list0 = iprot.readListBegin();
- struct.applicationModules = new ArrayList<String>(_list0.size);
- String _elem1;
+ struct.applicationModules = new java.util.ArrayList<java.lang.String>(_list0.size);
+ java.lang.String _elem1;
for (int _i2 = 0; _i2 < _list0.size; ++_i2)
{
_elem1 = iprot.readString();
@@ -1035,7 +999,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list3 = iprot.readListBegin();
- struct.applicationInputs = new ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(_list3.size);
+ struct.applicationInputs = new java.util.ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(_list3.size);
org.apache.airavata.model.application.io.InputDataObjectType _elem4;
for (int _i5 = 0; _i5 < _list3.size; ++_i5)
{
@@ -1054,7 +1018,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list6 = iprot.readListBegin();
- struct.applicationOutputs = new ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(_list6.size);
+ struct.applicationOutputs = new java.util.ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(_list6.size);
org.apache.airavata.model.application.io.OutputDataObjectType _elem7;
for (int _i8 = 0; _i8 < _list6.size; ++_i8)
{
@@ -1120,7 +1084,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
oprot.writeFieldBegin(APPLICATION_MODULES_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.applicationModules.size()));
- for (String _iter9 : struct.applicationModules)
+ for (java.lang.String _iter9 : struct.applicationModules)
{
oprot.writeString(_iter9);
}
@@ -1173,20 +1137,20 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
}
- private static class ApplicationInterfaceDescriptionTupleSchemeFactory implements SchemeFactory {
+ private static class ApplicationInterfaceDescriptionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ApplicationInterfaceDescriptionTupleScheme getScheme() {
return new ApplicationInterfaceDescriptionTupleScheme();
}
}
- private static class ApplicationInterfaceDescriptionTupleScheme extends TupleScheme<ApplicationInterfaceDescription> {
+ private static class ApplicationInterfaceDescriptionTupleScheme extends org.apache.thrift.scheme.TupleScheme<ApplicationInterfaceDescription> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ApplicationInterfaceDescription struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.applicationInterfaceId);
oprot.writeString(struct.applicationName);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetApplicationDescription()) {
optionals.set(0);
}
@@ -1212,7 +1176,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
if (struct.isSetApplicationModules()) {
{
oprot.writeI32(struct.applicationModules.size());
- for (String _iter12 : struct.applicationModules)
+ for (java.lang.String _iter12 : struct.applicationModules)
{
oprot.writeString(_iter12);
}
@@ -1246,12 +1210,12 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ApplicationInterfaceDescription struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.applicationInterfaceId = iprot.readString();
struct.setApplicationInterfaceIdIsSet(true);
struct.applicationName = iprot.readString();
struct.setApplicationNameIsSet(true);
- BitSet incoming = iprot.readBitSet(6);
+ java.util.BitSet incoming = iprot.readBitSet(6);
if (incoming.get(0)) {
struct.applicationDescription = iprot.readString();
struct.setApplicationDescriptionIsSet(true);
@@ -1259,8 +1223,8 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
if (incoming.get(1)) {
{
org.apache.thrift.protocol.TList _list15 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.applicationModules = new ArrayList<String>(_list15.size);
- String _elem16;
+ struct.applicationModules = new java.util.ArrayList<java.lang.String>(_list15.size);
+ java.lang.String _elem16;
for (int _i17 = 0; _i17 < _list15.size; ++_i17)
{
_elem16 = iprot.readString();
@@ -1272,7 +1236,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
if (incoming.get(2)) {
{
org.apache.thrift.protocol.TList _list18 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.applicationInputs = new ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(_list18.size);
+ struct.applicationInputs = new java.util.ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(_list18.size);
org.apache.airavata.model.application.io.InputDataObjectType _elem19;
for (int _i20 = 0; _i20 < _list18.size; ++_i20)
{
@@ -1286,7 +1250,7 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
if (incoming.get(3)) {
{
org.apache.thrift.protocol.TList _list21 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.applicationOutputs = new ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(_list21.size);
+ struct.applicationOutputs = new java.util.ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(_list21.size);
org.apache.airavata.model.application.io.OutputDataObjectType _elem22;
for (int _i23 = 0; _i23 < _list21.size; ++_i23)
{
@@ -1308,5 +1272,8 @@ public class ApplicationInterfaceDescription implements org.apache.thrift.TBase<
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
[19/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/GlobusJobSubmission.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/GlobusJobSubmission.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/GlobusJobSubmission.java
index 70b7644..331935a 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/GlobusJobSubmission.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/GlobusJobSubmission.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.computeresource;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSubmission, GlobusJobSubmission._Fields>, java.io.Serializable, Cloneable, Comparable<GlobusJobSubmission> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("GlobusJobSubmission");
@@ -59,15 +32,12 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
private static final org.apache.thrift.protocol.TField SECURITY_PROTOCOL_FIELD_DESC = new org.apache.thrift.protocol.TField("securityProtocol", org.apache.thrift.protocol.TType.I32, (short)2);
private static final org.apache.thrift.protocol.TField GLOBUS_GATE_KEEPER_END_POINT_FIELD_DESC = new org.apache.thrift.protocol.TField("globusGateKeeperEndPoint", org.apache.thrift.protocol.TType.LIST, (short)3);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new GlobusJobSubmissionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new GlobusJobSubmissionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new GlobusJobSubmissionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new GlobusJobSubmissionTupleSchemeFactory();
- private String jobSubmissionInterfaceId; // required
+ private java.lang.String jobSubmissionInterfaceId; // required
private org.apache.airavata.model.data.movement.SecurityProtocol securityProtocol; // required
- private List<String> globusGateKeeperEndPoint; // optional
+ private java.util.List<java.lang.String> globusGateKeeperEndPoint; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -79,10 +49,10 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
SECURITY_PROTOCOL((short)2, "securityProtocol"),
GLOBUS_GATE_KEEPER_END_POINT((short)3, "globusGateKeeperEndPoint");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -109,21 +79,21 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -132,16 +102,16 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
private static final _Fields optionals[] = {_Fields.GLOBUS_GATE_KEEPER_END_POINT};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.JOB_SUBMISSION_INTERFACE_ID, new org.apache.thrift.meta_data.FieldMetaData("jobSubmissionInterfaceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.SECURITY_PROTOCOL, new org.apache.thrift.meta_data.FieldMetaData("securityProtocol", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -149,7 +119,7 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
tmpMap.put(_Fields.GLOBUS_GATE_KEEPER_END_POINT, new org.apache.thrift.meta_data.FieldMetaData("globusGateKeeperEndPoint", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(GlobusJobSubmission.class, metaDataMap);
}
@@ -159,7 +129,7 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
}
public GlobusJobSubmission(
- String jobSubmissionInterfaceId,
+ java.lang.String jobSubmissionInterfaceId,
org.apache.airavata.model.data.movement.SecurityProtocol securityProtocol)
{
this();
@@ -178,7 +148,7 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
this.securityProtocol = other.securityProtocol;
}
if (other.isSetGlobusGateKeeperEndPoint()) {
- List<String> __this__globusGateKeeperEndPoint = new ArrayList<String>(other.globusGateKeeperEndPoint);
+ java.util.List<java.lang.String> __this__globusGateKeeperEndPoint = new java.util.ArrayList<java.lang.String>(other.globusGateKeeperEndPoint);
this.globusGateKeeperEndPoint = __this__globusGateKeeperEndPoint;
}
}
@@ -195,11 +165,11 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
this.globusGateKeeperEndPoint = null;
}
- public String getJobSubmissionInterfaceId() {
+ public java.lang.String getJobSubmissionInterfaceId() {
return this.jobSubmissionInterfaceId;
}
- public void setJobSubmissionInterfaceId(String jobSubmissionInterfaceId) {
+ public void setJobSubmissionInterfaceId(java.lang.String jobSubmissionInterfaceId) {
this.jobSubmissionInterfaceId = jobSubmissionInterfaceId;
}
@@ -253,22 +223,22 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
return (this.globusGateKeeperEndPoint == null) ? 0 : this.globusGateKeeperEndPoint.size();
}
- public java.util.Iterator<String> getGlobusGateKeeperEndPointIterator() {
+ public java.util.Iterator<java.lang.String> getGlobusGateKeeperEndPointIterator() {
return (this.globusGateKeeperEndPoint == null) ? null : this.globusGateKeeperEndPoint.iterator();
}
- public void addToGlobusGateKeeperEndPoint(String elem) {
+ public void addToGlobusGateKeeperEndPoint(java.lang.String elem) {
if (this.globusGateKeeperEndPoint == null) {
- this.globusGateKeeperEndPoint = new ArrayList<String>();
+ this.globusGateKeeperEndPoint = new java.util.ArrayList<java.lang.String>();
}
this.globusGateKeeperEndPoint.add(elem);
}
- public List<String> getGlobusGateKeeperEndPoint() {
+ public java.util.List<java.lang.String> getGlobusGateKeeperEndPoint() {
return this.globusGateKeeperEndPoint;
}
- public void setGlobusGateKeeperEndPoint(List<String> globusGateKeeperEndPoint) {
+ public void setGlobusGateKeeperEndPoint(java.util.List<java.lang.String> globusGateKeeperEndPoint) {
this.globusGateKeeperEndPoint = globusGateKeeperEndPoint;
}
@@ -287,13 +257,13 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case JOB_SUBMISSION_INTERFACE_ID:
if (value == null) {
unsetJobSubmissionInterfaceId();
} else {
- setJobSubmissionInterfaceId((String)value);
+ setJobSubmissionInterfaceId((java.lang.String)value);
}
break;
@@ -309,14 +279,14 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
if (value == null) {
unsetGlobusGateKeeperEndPoint();
} else {
- setGlobusGateKeeperEndPoint((List<String>)value);
+ setGlobusGateKeeperEndPoint((java.util.List<java.lang.String>)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case JOB_SUBMISSION_INTERFACE_ID:
return getJobSubmissionInterfaceId();
@@ -328,13 +298,13 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
return getGlobusGateKeeperEndPoint();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -345,11 +315,11 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
case GLOBUS_GATE_KEEPER_END_POINT:
return isSetGlobusGateKeeperEndPoint();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof GlobusJobSubmission)
@@ -360,6 +330,8 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
public boolean equals(GlobusJobSubmission that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_jobSubmissionInterfaceId = true && this.isSetJobSubmissionInterfaceId();
boolean that_present_jobSubmissionInterfaceId = true && that.isSetJobSubmissionInterfaceId();
@@ -393,24 +365,21 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_jobSubmissionInterfaceId = true && (isSetJobSubmissionInterfaceId());
- list.add(present_jobSubmissionInterfaceId);
- if (present_jobSubmissionInterfaceId)
- list.add(jobSubmissionInterfaceId);
+ hashCode = hashCode * 8191 + ((isSetJobSubmissionInterfaceId()) ? 131071 : 524287);
+ if (isSetJobSubmissionInterfaceId())
+ hashCode = hashCode * 8191 + jobSubmissionInterfaceId.hashCode();
- boolean present_securityProtocol = true && (isSetSecurityProtocol());
- list.add(present_securityProtocol);
- if (present_securityProtocol)
- list.add(securityProtocol.getValue());
+ hashCode = hashCode * 8191 + ((isSetSecurityProtocol()) ? 131071 : 524287);
+ if (isSetSecurityProtocol())
+ hashCode = hashCode * 8191 + securityProtocol.getValue();
- boolean present_globusGateKeeperEndPoint = true && (isSetGlobusGateKeeperEndPoint());
- list.add(present_globusGateKeeperEndPoint);
- if (present_globusGateKeeperEndPoint)
- list.add(globusGateKeeperEndPoint);
+ hashCode = hashCode * 8191 + ((isSetGlobusGateKeeperEndPoint()) ? 131071 : 524287);
+ if (isSetGlobusGateKeeperEndPoint())
+ hashCode = hashCode * 8191 + globusGateKeeperEndPoint.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -421,7 +390,7 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetJobSubmissionInterfaceId()).compareTo(other.isSetJobSubmissionInterfaceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetJobSubmissionInterfaceId()).compareTo(other.isSetJobSubmissionInterfaceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -431,7 +400,7 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetSecurityProtocol()).compareTo(other.isSetSecurityProtocol());
+ lastComparison = java.lang.Boolean.valueOf(isSetSecurityProtocol()).compareTo(other.isSetSecurityProtocol());
if (lastComparison != 0) {
return lastComparison;
}
@@ -441,7 +410,7 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetGlobusGateKeeperEndPoint()).compareTo(other.isSetGlobusGateKeeperEndPoint());
+ lastComparison = java.lang.Boolean.valueOf(isSetGlobusGateKeeperEndPoint()).compareTo(other.isSetGlobusGateKeeperEndPoint());
if (lastComparison != 0) {
return lastComparison;
}
@@ -459,16 +428,16 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("GlobusJobSubmission(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("GlobusJobSubmission(");
boolean first = true;
sb.append("jobSubmissionInterfaceId:");
@@ -521,7 +490,7 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -529,13 +498,13 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
}
}
- private static class GlobusJobSubmissionStandardSchemeFactory implements SchemeFactory {
+ private static class GlobusJobSubmissionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public GlobusJobSubmissionStandardScheme getScheme() {
return new GlobusJobSubmissionStandardScheme();
}
}
- private static class GlobusJobSubmissionStandardScheme extends StandardScheme<GlobusJobSubmission> {
+ private static class GlobusJobSubmissionStandardScheme extends org.apache.thrift.scheme.StandardScheme<GlobusJobSubmission> {
public void read(org.apache.thrift.protocol.TProtocol iprot, GlobusJobSubmission struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -567,8 +536,8 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list28 = iprot.readListBegin();
- struct.globusGateKeeperEndPoint = new ArrayList<String>(_list28.size);
- String _elem29;
+ struct.globusGateKeeperEndPoint = new java.util.ArrayList<java.lang.String>(_list28.size);
+ java.lang.String _elem29;
for (int _i30 = 0; _i30 < _list28.size; ++_i30)
{
_elem29 = iprot.readString();
@@ -609,7 +578,7 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
oprot.writeFieldBegin(GLOBUS_GATE_KEEPER_END_POINT_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.globusGateKeeperEndPoint.size()));
- for (String _iter31 : struct.globusGateKeeperEndPoint)
+ for (java.lang.String _iter31 : struct.globusGateKeeperEndPoint)
{
oprot.writeString(_iter31);
}
@@ -624,20 +593,20 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
}
- private static class GlobusJobSubmissionTupleSchemeFactory implements SchemeFactory {
+ private static class GlobusJobSubmissionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public GlobusJobSubmissionTupleScheme getScheme() {
return new GlobusJobSubmissionTupleScheme();
}
}
- private static class GlobusJobSubmissionTupleScheme extends TupleScheme<GlobusJobSubmission> {
+ private static class GlobusJobSubmissionTupleScheme extends org.apache.thrift.scheme.TupleScheme<GlobusJobSubmission> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, GlobusJobSubmission struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.jobSubmissionInterfaceId);
oprot.writeI32(struct.securityProtocol.getValue());
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetGlobusGateKeeperEndPoint()) {
optionals.set(0);
}
@@ -645,7 +614,7 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
if (struct.isSetGlobusGateKeeperEndPoint()) {
{
oprot.writeI32(struct.globusGateKeeperEndPoint.size());
- for (String _iter32 : struct.globusGateKeeperEndPoint)
+ for (java.lang.String _iter32 : struct.globusGateKeeperEndPoint)
{
oprot.writeString(_iter32);
}
@@ -655,17 +624,17 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, GlobusJobSubmission struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.jobSubmissionInterfaceId = iprot.readString();
struct.setJobSubmissionInterfaceIdIsSet(true);
struct.securityProtocol = org.apache.airavata.model.data.movement.SecurityProtocol.findByValue(iprot.readI32());
struct.setSecurityProtocolIsSet(true);
- BitSet incoming = iprot.readBitSet(1);
+ java.util.BitSet incoming = iprot.readBitSet(1);
if (incoming.get(0)) {
{
org.apache.thrift.protocol.TList _list33 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.globusGateKeeperEndPoint = new ArrayList<String>(_list33.size);
- String _elem34;
+ struct.globusGateKeeperEndPoint = new java.util.ArrayList<java.lang.String>(_list33.size);
+ java.lang.String _elem34;
for (int _i35 = 0; _i35 < _list33.size; ++_i35)
{
_elem34 = iprot.readString();
@@ -677,5 +646,8 @@ public class GlobusJobSubmission implements org.apache.thrift.TBase<GlobusJobSub
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/JobManagerCommand.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/JobManagerCommand.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/JobManagerCommand.java
index 673da16..ccb208a 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/JobManagerCommand.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/JobManagerCommand.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/JobSubmissionInterface.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/JobSubmissionInterface.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/JobSubmissionInterface.java
index b83cc4e..30c6183 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/JobSubmissionInterface.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/JobSubmissionInterface.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.computeresource;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Job Submission Interfaces
*
@@ -61,7 +34,7 @@ import org.slf4j.LoggerFactory;
* Lower the numerical number, higher the priority
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmissionInterface, JobSubmissionInterface._Fields>, java.io.Serializable, Cloneable, Comparable<JobSubmissionInterface> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("JobSubmissionInterface");
@@ -69,13 +42,10 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
private static final org.apache.thrift.protocol.TField JOB_SUBMISSION_PROTOCOL_FIELD_DESC = new org.apache.thrift.protocol.TField("jobSubmissionProtocol", org.apache.thrift.protocol.TType.I32, (short)2);
private static final org.apache.thrift.protocol.TField PRIORITY_ORDER_FIELD_DESC = new org.apache.thrift.protocol.TField("priorityOrder", org.apache.thrift.protocol.TType.I32, (short)3);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new JobSubmissionInterfaceStandardSchemeFactory());
- schemes.put(TupleScheme.class, new JobSubmissionInterfaceTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new JobSubmissionInterfaceStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new JobSubmissionInterfaceTupleSchemeFactory();
- private String jobSubmissionInterfaceId; // required
+ private java.lang.String jobSubmissionInterfaceId; // required
private JobSubmissionProtocol jobSubmissionProtocol; // required
private int priorityOrder; // required
@@ -89,10 +59,10 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
JOB_SUBMISSION_PROTOCOL((short)2, "jobSubmissionProtocol"),
PRIORITY_ORDER((short)3, "priorityOrder");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -119,21 +89,21 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -142,7 +112,7 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -150,16 +120,16 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
// isset id assignments
private static final int __PRIORITYORDER_ISSET_ID = 0;
private byte __isset_bitfield = 0;
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.JOB_SUBMISSION_INTERFACE_ID, new org.apache.thrift.meta_data.FieldMetaData("jobSubmissionInterfaceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.JOB_SUBMISSION_PROTOCOL, new org.apache.thrift.meta_data.FieldMetaData("jobSubmissionProtocol", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, JobSubmissionProtocol.class)));
tmpMap.put(_Fields.PRIORITY_ORDER, new org.apache.thrift.meta_data.FieldMetaData("priorityOrder", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(JobSubmissionInterface.class, metaDataMap);
}
@@ -169,7 +139,7 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
}
public JobSubmissionInterface(
- String jobSubmissionInterfaceId,
+ java.lang.String jobSubmissionInterfaceId,
JobSubmissionProtocol jobSubmissionProtocol,
int priorityOrder)
{
@@ -206,11 +176,11 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
}
- public String getJobSubmissionInterfaceId() {
+ public java.lang.String getJobSubmissionInterfaceId() {
return this.jobSubmissionInterfaceId;
}
- public void setJobSubmissionInterfaceId(String jobSubmissionInterfaceId) {
+ public void setJobSubmissionInterfaceId(java.lang.String jobSubmissionInterfaceId) {
this.jobSubmissionInterfaceId = jobSubmissionInterfaceId;
}
@@ -270,25 +240,25 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
}
public void unsetPriorityOrder() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PRIORITYORDER_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __PRIORITYORDER_ISSET_ID);
}
/** Returns true if field priorityOrder is set (has been assigned a value) and false otherwise */
public boolean isSetPriorityOrder() {
- return EncodingUtils.testBit(__isset_bitfield, __PRIORITYORDER_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __PRIORITYORDER_ISSET_ID);
}
public void setPriorityOrderIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PRIORITYORDER_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __PRIORITYORDER_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case JOB_SUBMISSION_INTERFACE_ID:
if (value == null) {
unsetJobSubmissionInterfaceId();
} else {
- setJobSubmissionInterfaceId((String)value);
+ setJobSubmissionInterfaceId((java.lang.String)value);
}
break;
@@ -304,14 +274,14 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
if (value == null) {
unsetPriorityOrder();
} else {
- setPriorityOrder((Integer)value);
+ setPriorityOrder((java.lang.Integer)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case JOB_SUBMISSION_INTERFACE_ID:
return getJobSubmissionInterfaceId();
@@ -323,13 +293,13 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
return getPriorityOrder();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -340,11 +310,11 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
case PRIORITY_ORDER:
return isSetPriorityOrder();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof JobSubmissionInterface)
@@ -355,6 +325,8 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
public boolean equals(JobSubmissionInterface that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_jobSubmissionInterfaceId = true && this.isSetJobSubmissionInterfaceId();
boolean that_present_jobSubmissionInterfaceId = true && that.isSetJobSubmissionInterfaceId();
@@ -388,24 +360,19 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_jobSubmissionInterfaceId = true && (isSetJobSubmissionInterfaceId());
- list.add(present_jobSubmissionInterfaceId);
- if (present_jobSubmissionInterfaceId)
- list.add(jobSubmissionInterfaceId);
+ hashCode = hashCode * 8191 + ((isSetJobSubmissionInterfaceId()) ? 131071 : 524287);
+ if (isSetJobSubmissionInterfaceId())
+ hashCode = hashCode * 8191 + jobSubmissionInterfaceId.hashCode();
- boolean present_jobSubmissionProtocol = true && (isSetJobSubmissionProtocol());
- list.add(present_jobSubmissionProtocol);
- if (present_jobSubmissionProtocol)
- list.add(jobSubmissionProtocol.getValue());
+ hashCode = hashCode * 8191 + ((isSetJobSubmissionProtocol()) ? 131071 : 524287);
+ if (isSetJobSubmissionProtocol())
+ hashCode = hashCode * 8191 + jobSubmissionProtocol.getValue();
- boolean present_priorityOrder = true;
- list.add(present_priorityOrder);
- if (present_priorityOrder)
- list.add(priorityOrder);
+ hashCode = hashCode * 8191 + priorityOrder;
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -416,7 +383,7 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetJobSubmissionInterfaceId()).compareTo(other.isSetJobSubmissionInterfaceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetJobSubmissionInterfaceId()).compareTo(other.isSetJobSubmissionInterfaceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -426,7 +393,7 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetJobSubmissionProtocol()).compareTo(other.isSetJobSubmissionProtocol());
+ lastComparison = java.lang.Boolean.valueOf(isSetJobSubmissionProtocol()).compareTo(other.isSetJobSubmissionProtocol());
if (lastComparison != 0) {
return lastComparison;
}
@@ -436,7 +403,7 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPriorityOrder()).compareTo(other.isSetPriorityOrder());
+ lastComparison = java.lang.Boolean.valueOf(isSetPriorityOrder()).compareTo(other.isSetPriorityOrder());
if (lastComparison != 0) {
return lastComparison;
}
@@ -454,16 +421,16 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("JobSubmissionInterface(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("JobSubmissionInterface(");
boolean first = true;
sb.append("jobSubmissionInterfaceId:");
@@ -514,7 +481,7 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -524,13 +491,13 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
}
}
- private static class JobSubmissionInterfaceStandardSchemeFactory implements SchemeFactory {
+ private static class JobSubmissionInterfaceStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public JobSubmissionInterfaceStandardScheme getScheme() {
return new JobSubmissionInterfaceStandardScheme();
}
}
- private static class JobSubmissionInterfaceStandardScheme extends StandardScheme<JobSubmissionInterface> {
+ private static class JobSubmissionInterfaceStandardScheme extends org.apache.thrift.scheme.StandardScheme<JobSubmissionInterface> {
public void read(org.apache.thrift.protocol.TProtocol iprot, JobSubmissionInterface struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -598,17 +565,17 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
}
- private static class JobSubmissionInterfaceTupleSchemeFactory implements SchemeFactory {
+ private static class JobSubmissionInterfaceTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public JobSubmissionInterfaceTupleScheme getScheme() {
return new JobSubmissionInterfaceTupleScheme();
}
}
- private static class JobSubmissionInterfaceTupleScheme extends TupleScheme<JobSubmissionInterface> {
+ private static class JobSubmissionInterfaceTupleScheme extends org.apache.thrift.scheme.TupleScheme<JobSubmissionInterface> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, JobSubmissionInterface struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.jobSubmissionInterfaceId);
oprot.writeI32(struct.jobSubmissionProtocol.getValue());
oprot.writeI32(struct.priorityOrder);
@@ -616,7 +583,7 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, JobSubmissionInterface struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.jobSubmissionInterfaceId = iprot.readString();
struct.setJobSubmissionInterfaceIdIsSet(true);
struct.jobSubmissionProtocol = org.apache.airavata.model.appcatalog.computeresource.JobSubmissionProtocol.findByValue(iprot.readI32());
@@ -626,5 +593,8 @@ public class JobSubmissionInterface implements org.apache.thrift.TBase<JobSubmis
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/JobSubmissionProtocol.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/JobSubmissionProtocol.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/JobSubmissionProtocol.java
index 7c2d3e2..73f0fd3 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/JobSubmissionProtocol.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/JobSubmissionProtocol.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/LOCALSubmission.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/LOCALSubmission.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/LOCALSubmission.java
index 907f427..fe95140 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/LOCALSubmission.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/LOCALSubmission.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.computeresource;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Locally Fork Jobs as OS processes
*
@@ -60,7 +33,7 @@ import org.slf4j.LoggerFactory;
* sshPort:
* If a non-default port needs to used, specify it.
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission, LOCALSubmission._Fields>, java.io.Serializable, Cloneable, Comparable<LOCALSubmission> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("LOCALSubmission");
@@ -68,13 +41,10 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
private static final org.apache.thrift.protocol.TField RESOURCE_JOB_MANAGER_FIELD_DESC = new org.apache.thrift.protocol.TField("resourceJobManager", org.apache.thrift.protocol.TType.STRUCT, (short)2);
private static final org.apache.thrift.protocol.TField SECURITY_PROTOCOL_FIELD_DESC = new org.apache.thrift.protocol.TField("securityProtocol", org.apache.thrift.protocol.TType.I32, (short)3);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new LOCALSubmissionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new LOCALSubmissionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new LOCALSubmissionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new LOCALSubmissionTupleSchemeFactory();
- private String jobSubmissionInterfaceId; // required
+ private java.lang.String jobSubmissionInterfaceId; // required
private ResourceJobManager resourceJobManager; // required
private org.apache.airavata.model.data.movement.SecurityProtocol securityProtocol; // required
@@ -88,10 +58,10 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
*/
SECURITY_PROTOCOL((short)3, "securityProtocol");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -118,21 +88,21 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -141,22 +111,22 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.JOB_SUBMISSION_INTERFACE_ID, new org.apache.thrift.meta_data.FieldMetaData("jobSubmissionInterfaceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.RESOURCE_JOB_MANAGER, new org.apache.thrift.meta_data.FieldMetaData("resourceJobManager", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ResourceJobManager.class)));
tmpMap.put(_Fields.SECURITY_PROTOCOL, new org.apache.thrift.meta_data.FieldMetaData("securityProtocol", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, org.apache.airavata.model.data.movement.SecurityProtocol.class)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(LOCALSubmission.class, metaDataMap);
}
@@ -166,7 +136,7 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
}
public LOCALSubmission(
- String jobSubmissionInterfaceId,
+ java.lang.String jobSubmissionInterfaceId,
ResourceJobManager resourceJobManager,
org.apache.airavata.model.data.movement.SecurityProtocol securityProtocol)
{
@@ -203,11 +173,11 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
this.securityProtocol = null;
}
- public String getJobSubmissionInterfaceId() {
+ public java.lang.String getJobSubmissionInterfaceId() {
return this.jobSubmissionInterfaceId;
}
- public void setJobSubmissionInterfaceId(String jobSubmissionInterfaceId) {
+ public void setJobSubmissionInterfaceId(java.lang.String jobSubmissionInterfaceId) {
this.jobSubmissionInterfaceId = jobSubmissionInterfaceId;
}
@@ -280,13 +250,13 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case JOB_SUBMISSION_INTERFACE_ID:
if (value == null) {
unsetJobSubmissionInterfaceId();
} else {
- setJobSubmissionInterfaceId((String)value);
+ setJobSubmissionInterfaceId((java.lang.String)value);
}
break;
@@ -309,7 +279,7 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case JOB_SUBMISSION_INTERFACE_ID:
return getJobSubmissionInterfaceId();
@@ -321,13 +291,13 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
return getSecurityProtocol();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -338,11 +308,11 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
case SECURITY_PROTOCOL:
return isSetSecurityProtocol();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof LOCALSubmission)
@@ -353,6 +323,8 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
public boolean equals(LOCALSubmission that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_jobSubmissionInterfaceId = true && this.isSetJobSubmissionInterfaceId();
boolean that_present_jobSubmissionInterfaceId = true && that.isSetJobSubmissionInterfaceId();
@@ -386,24 +358,21 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_jobSubmissionInterfaceId = true && (isSetJobSubmissionInterfaceId());
- list.add(present_jobSubmissionInterfaceId);
- if (present_jobSubmissionInterfaceId)
- list.add(jobSubmissionInterfaceId);
+ hashCode = hashCode * 8191 + ((isSetJobSubmissionInterfaceId()) ? 131071 : 524287);
+ if (isSetJobSubmissionInterfaceId())
+ hashCode = hashCode * 8191 + jobSubmissionInterfaceId.hashCode();
- boolean present_resourceJobManager = true && (isSetResourceJobManager());
- list.add(present_resourceJobManager);
- if (present_resourceJobManager)
- list.add(resourceJobManager);
+ hashCode = hashCode * 8191 + ((isSetResourceJobManager()) ? 131071 : 524287);
+ if (isSetResourceJobManager())
+ hashCode = hashCode * 8191 + resourceJobManager.hashCode();
- boolean present_securityProtocol = true && (isSetSecurityProtocol());
- list.add(present_securityProtocol);
- if (present_securityProtocol)
- list.add(securityProtocol.getValue());
+ hashCode = hashCode * 8191 + ((isSetSecurityProtocol()) ? 131071 : 524287);
+ if (isSetSecurityProtocol())
+ hashCode = hashCode * 8191 + securityProtocol.getValue();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -414,7 +383,7 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetJobSubmissionInterfaceId()).compareTo(other.isSetJobSubmissionInterfaceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetJobSubmissionInterfaceId()).compareTo(other.isSetJobSubmissionInterfaceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -424,7 +393,7 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetResourceJobManager()).compareTo(other.isSetResourceJobManager());
+ lastComparison = java.lang.Boolean.valueOf(isSetResourceJobManager()).compareTo(other.isSetResourceJobManager());
if (lastComparison != 0) {
return lastComparison;
}
@@ -434,7 +403,7 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetSecurityProtocol()).compareTo(other.isSetSecurityProtocol());
+ lastComparison = java.lang.Boolean.valueOf(isSetSecurityProtocol()).compareTo(other.isSetSecurityProtocol());
if (lastComparison != 0) {
return lastComparison;
}
@@ -452,16 +421,16 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("LOCALSubmission(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("LOCALSubmission(");
boolean first = true;
sb.append("jobSubmissionInterfaceId:");
@@ -519,7 +488,7 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -527,13 +496,13 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
}
}
- private static class LOCALSubmissionStandardSchemeFactory implements SchemeFactory {
+ private static class LOCALSubmissionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public LOCALSubmissionStandardScheme getScheme() {
return new LOCALSubmissionStandardScheme();
}
}
- private static class LOCALSubmissionStandardScheme extends StandardScheme<LOCALSubmission> {
+ private static class LOCALSubmissionStandardScheme extends org.apache.thrift.scheme.StandardScheme<LOCALSubmission> {
public void read(org.apache.thrift.protocol.TProtocol iprot, LOCALSubmission struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -604,17 +573,17 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
}
- private static class LOCALSubmissionTupleSchemeFactory implements SchemeFactory {
+ private static class LOCALSubmissionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public LOCALSubmissionTupleScheme getScheme() {
return new LOCALSubmissionTupleScheme();
}
}
- private static class LOCALSubmissionTupleScheme extends TupleScheme<LOCALSubmission> {
+ private static class LOCALSubmissionTupleScheme extends org.apache.thrift.scheme.TupleScheme<LOCALSubmission> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, LOCALSubmission struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.jobSubmissionInterfaceId);
struct.resourceJobManager.write(oprot);
oprot.writeI32(struct.securityProtocol.getValue());
@@ -622,7 +591,7 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, LOCALSubmission struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.jobSubmissionInterfaceId = iprot.readString();
struct.setJobSubmissionInterfaceIdIsSet(true);
struct.resourceJobManager = new ResourceJobManager();
@@ -633,5 +602,8 @@ public class LOCALSubmission implements org.apache.thrift.TBase<LOCALSubmission,
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/MonitorMode.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/MonitorMode.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/MonitorMode.java
index 8526dff..1a10508 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/MonitorMode.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/MonitorMode.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ProviderName.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ProviderName.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ProviderName.java
index 34b85a4..c6bc082 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ProviderName.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ProviderName.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
[06/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ExperimentNotFoundException.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ExperimentNotFoundException.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ExperimentNotFoundException.java
index 517ee3b..58e2102 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ExperimentNotFoundException.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ExperimentNotFoundException.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.error;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* This exception is thrown when a client asks to perform an operation on an experiment that does not exist.
*
@@ -58,28 +31,25 @@ import org.slf4j.LoggerFactory;
*
* key: The value passed from the client in the identifier, which was not found.
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
-public class ExperimentNotFoundException extends TException implements org.apache.thrift.TBase<ExperimentNotFoundException, ExperimentNotFoundException._Fields>, java.io.Serializable, Cloneable, Comparable<ExperimentNotFoundException> {
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
+public class ExperimentNotFoundException extends org.apache.thrift.TException implements org.apache.thrift.TBase<ExperimentNotFoundException, ExperimentNotFoundException._Fields>, java.io.Serializable, Cloneable, Comparable<ExperimentNotFoundException> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ExperimentNotFoundException");
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 ExperimentNotFoundExceptionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ExperimentNotFoundExceptionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ExperimentNotFoundExceptionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ExperimentNotFoundExceptionTupleSchemeFactory();
- private String message; // required
+ private java.lang.String message; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
MESSAGE((short)1, "message");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -102,21 +72,21 @@ public class ExperimentNotFoundException extends TException implements org.apach
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -125,18 +95,18 @@ public class ExperimentNotFoundException extends TException implements org.apach
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.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);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ExperimentNotFoundException.class, metaDataMap);
}
@@ -144,7 +114,7 @@ public class ExperimentNotFoundException extends TException implements org.apach
}
public ExperimentNotFoundException(
- String message)
+ java.lang.String message)
{
this();
this.message = message;
@@ -168,11 +138,11 @@ public class ExperimentNotFoundException extends TException implements org.apach
this.message = null;
}
- public String getMessage() {
+ public java.lang.String getMessage() {
return this.message;
}
- public void setMessage(String message) {
+ public void setMessage(java.lang.String message) {
this.message = message;
}
@@ -191,43 +161,43 @@ public class ExperimentNotFoundException extends TException implements org.apach
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case MESSAGE:
if (value == null) {
unsetMessage();
} else {
- setMessage((String)value);
+ setMessage((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case MESSAGE:
return getMessage();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
case MESSAGE:
return isSetMessage();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ExperimentNotFoundException)
@@ -238,6 +208,8 @@ public class ExperimentNotFoundException extends TException implements org.apach
public boolean equals(ExperimentNotFoundException that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_message = true && this.isSetMessage();
boolean that_present_message = true && that.isSetMessage();
@@ -253,14 +225,13 @@ public class ExperimentNotFoundException extends TException implements org.apach
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_message = true && (isSetMessage());
- list.add(present_message);
- if (present_message)
- list.add(message);
+ hashCode = hashCode * 8191 + ((isSetMessage()) ? 131071 : 524287);
+ if (isSetMessage())
+ hashCode = hashCode * 8191 + message.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -271,7 +242,7 @@ public class ExperimentNotFoundException extends TException implements org.apach
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetMessage()).compareTo(other.isSetMessage());
+ lastComparison = java.lang.Boolean.valueOf(isSetMessage()).compareTo(other.isSetMessage());
if (lastComparison != 0) {
return lastComparison;
}
@@ -289,16 +260,16 @@ public class ExperimentNotFoundException extends TException implements org.apach
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ExperimentNotFoundException(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ExperimentNotFoundException(");
boolean first = true;
sb.append("message:");
@@ -329,7 +300,7 @@ public class ExperimentNotFoundException extends TException implements org.apach
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -337,13 +308,13 @@ public class ExperimentNotFoundException extends TException implements org.apach
}
}
- private static class ExperimentNotFoundExceptionStandardSchemeFactory implements SchemeFactory {
+ private static class ExperimentNotFoundExceptionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ExperimentNotFoundExceptionStandardScheme getScheme() {
return new ExperimentNotFoundExceptionStandardScheme();
}
}
- private static class ExperimentNotFoundExceptionStandardScheme extends StandardScheme<ExperimentNotFoundException> {
+ private static class ExperimentNotFoundExceptionStandardScheme extends org.apache.thrift.scheme.StandardScheme<ExperimentNotFoundException> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ExperimentNotFoundException struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -387,27 +358,30 @@ public class ExperimentNotFoundException extends TException implements org.apach
}
- private static class ExperimentNotFoundExceptionTupleSchemeFactory implements SchemeFactory {
+ private static class ExperimentNotFoundExceptionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ExperimentNotFoundExceptionTupleScheme getScheme() {
return new ExperimentNotFoundExceptionTupleScheme();
}
}
- private static class ExperimentNotFoundExceptionTupleScheme extends TupleScheme<ExperimentNotFoundException> {
+ private static class ExperimentNotFoundExceptionTupleScheme extends org.apache.thrift.scheme.TupleScheme<ExperimentNotFoundException> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ExperimentNotFoundException struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.message);
}
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ExperimentNotFoundException struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.message = iprot.readString();
struct.setMessageIsSet(true);
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/InvalidRequestException.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/InvalidRequestException.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/InvalidRequestException.java
index f909497..1dcf19a 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/InvalidRequestException.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/InvalidRequestException.java
@@ -16,69 +16,39 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.error;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* This exception is thrown for invalid requests that occur from any reasons like required input parameters are missing,
* or a parameter is malformed.
*
* message: contains the associated error message.
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
-public class InvalidRequestException extends TException implements org.apache.thrift.TBase<InvalidRequestException, InvalidRequestException._Fields>, java.io.Serializable, Cloneable, Comparable<InvalidRequestException> {
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
+public class InvalidRequestException extends org.apache.thrift.TException implements org.apache.thrift.TBase<InvalidRequestException, InvalidRequestException._Fields>, java.io.Serializable, Cloneable, Comparable<InvalidRequestException> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("InvalidRequestException");
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 InvalidRequestExceptionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new InvalidRequestExceptionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new InvalidRequestExceptionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new InvalidRequestExceptionTupleSchemeFactory();
- private String message; // required
+ private java.lang.String message; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
MESSAGE((short)1, "message");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -101,21 +71,21 @@ public class InvalidRequestException extends TException implements org.apache.th
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -124,18 +94,18 @@ public class InvalidRequestException extends TException implements org.apache.th
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.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);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(InvalidRequestException.class, metaDataMap);
}
@@ -143,7 +113,7 @@ public class InvalidRequestException extends TException implements org.apache.th
}
public InvalidRequestException(
- String message)
+ java.lang.String message)
{
this();
this.message = message;
@@ -167,11 +137,11 @@ public class InvalidRequestException extends TException implements org.apache.th
this.message = null;
}
- public String getMessage() {
+ public java.lang.String getMessage() {
return this.message;
}
- public void setMessage(String message) {
+ public void setMessage(java.lang.String message) {
this.message = message;
}
@@ -190,43 +160,43 @@ public class InvalidRequestException extends TException implements org.apache.th
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case MESSAGE:
if (value == null) {
unsetMessage();
} else {
- setMessage((String)value);
+ setMessage((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case MESSAGE:
return getMessage();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
case MESSAGE:
return isSetMessage();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof InvalidRequestException)
@@ -237,6 +207,8 @@ public class InvalidRequestException extends TException implements org.apache.th
public boolean equals(InvalidRequestException that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_message = true && this.isSetMessage();
boolean that_present_message = true && that.isSetMessage();
@@ -252,14 +224,13 @@ public class InvalidRequestException extends TException implements org.apache.th
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_message = true && (isSetMessage());
- list.add(present_message);
- if (present_message)
- list.add(message);
+ hashCode = hashCode * 8191 + ((isSetMessage()) ? 131071 : 524287);
+ if (isSetMessage())
+ hashCode = hashCode * 8191 + message.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -270,7 +241,7 @@ public class InvalidRequestException extends TException implements org.apache.th
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetMessage()).compareTo(other.isSetMessage());
+ lastComparison = java.lang.Boolean.valueOf(isSetMessage()).compareTo(other.isSetMessage());
if (lastComparison != 0) {
return lastComparison;
}
@@ -288,16 +259,16 @@ public class InvalidRequestException extends TException implements org.apache.th
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("InvalidRequestException(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("InvalidRequestException(");
boolean first = true;
sb.append("message:");
@@ -328,7 +299,7 @@ public class InvalidRequestException extends TException implements org.apache.th
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -336,13 +307,13 @@ public class InvalidRequestException extends TException implements org.apache.th
}
}
- private static class InvalidRequestExceptionStandardSchemeFactory implements SchemeFactory {
+ private static class InvalidRequestExceptionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public InvalidRequestExceptionStandardScheme getScheme() {
return new InvalidRequestExceptionStandardScheme();
}
}
- private static class InvalidRequestExceptionStandardScheme extends StandardScheme<InvalidRequestException> {
+ private static class InvalidRequestExceptionStandardScheme extends org.apache.thrift.scheme.StandardScheme<InvalidRequestException> {
public void read(org.apache.thrift.protocol.TProtocol iprot, InvalidRequestException struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -386,27 +357,30 @@ public class InvalidRequestException extends TException implements org.apache.th
}
- private static class InvalidRequestExceptionTupleSchemeFactory implements SchemeFactory {
+ private static class InvalidRequestExceptionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public InvalidRequestExceptionTupleScheme getScheme() {
return new InvalidRequestExceptionTupleScheme();
}
}
- private static class InvalidRequestExceptionTupleScheme extends TupleScheme<InvalidRequestException> {
+ private static class InvalidRequestExceptionTupleScheme extends org.apache.thrift.scheme.TupleScheme<InvalidRequestException> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, InvalidRequestException struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.message);
}
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, InvalidRequestException struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.message = iprot.readString();
struct.setMessageIsSet(true);
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/LaunchValidationException.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/LaunchValidationException.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/LaunchValidationException.java
index f6a7019..ddb83ad 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/LaunchValidationException.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/LaunchValidationException.java
@@ -16,66 +16,36 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.error;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
-public class LaunchValidationException extends TException implements org.apache.thrift.TBase<LaunchValidationException, LaunchValidationException._Fields>, java.io.Serializable, Cloneable, Comparable<LaunchValidationException> {
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
+public class LaunchValidationException extends org.apache.thrift.TException implements org.apache.thrift.TBase<LaunchValidationException, LaunchValidationException._Fields>, java.io.Serializable, Cloneable, Comparable<LaunchValidationException> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("LaunchValidationException");
private static final org.apache.thrift.protocol.TField VALIDATION_RESULT_FIELD_DESC = new org.apache.thrift.protocol.TField("validationResult", org.apache.thrift.protocol.TType.STRUCT, (short)1);
private static final org.apache.thrift.protocol.TField ERROR_MESSAGE_FIELD_DESC = new org.apache.thrift.protocol.TField("errorMessage", org.apache.thrift.protocol.TType.STRING, (short)2);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new LaunchValidationExceptionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new LaunchValidationExceptionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new LaunchValidationExceptionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new LaunchValidationExceptionTupleSchemeFactory();
private ValidationResults validationResult; // required
- private String errorMessage; // optional
+ private java.lang.String errorMessage; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
VALIDATION_RESULT((short)1, "validationResult"),
ERROR_MESSAGE((short)2, "errorMessage");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -100,21 +70,21 @@ public class LaunchValidationException extends TException implements org.apache.
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -123,21 +93,21 @@ public class LaunchValidationException extends TException implements org.apache.
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
private static final _Fields optionals[] = {_Fields.ERROR_MESSAGE};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.VALIDATION_RESULT, new org.apache.thrift.meta_data.FieldMetaData("validationResult", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ValidationResults.class)));
tmpMap.put(_Fields.ERROR_MESSAGE, new org.apache.thrift.meta_data.FieldMetaData("errorMessage", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(LaunchValidationException.class, metaDataMap);
}
@@ -196,11 +166,11 @@ public class LaunchValidationException extends TException implements org.apache.
}
}
- public String getErrorMessage() {
+ public java.lang.String getErrorMessage() {
return this.errorMessage;
}
- public void setErrorMessage(String errorMessage) {
+ public void setErrorMessage(java.lang.String errorMessage) {
this.errorMessage = errorMessage;
}
@@ -219,7 +189,7 @@ public class LaunchValidationException extends TException implements org.apache.
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case VALIDATION_RESULT:
if (value == null) {
@@ -233,14 +203,14 @@ public class LaunchValidationException extends TException implements org.apache.
if (value == null) {
unsetErrorMessage();
} else {
- setErrorMessage((String)value);
+ setErrorMessage((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case VALIDATION_RESULT:
return getValidationResult();
@@ -249,13 +219,13 @@ public class LaunchValidationException extends TException implements org.apache.
return getErrorMessage();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -264,11 +234,11 @@ public class LaunchValidationException extends TException implements org.apache.
case ERROR_MESSAGE:
return isSetErrorMessage();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof LaunchValidationException)
@@ -279,6 +249,8 @@ public class LaunchValidationException extends TException implements org.apache.
public boolean equals(LaunchValidationException that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_validationResult = true && this.isSetValidationResult();
boolean that_present_validationResult = true && that.isSetValidationResult();
@@ -303,19 +275,17 @@ public class LaunchValidationException extends TException implements org.apache.
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_validationResult = true && (isSetValidationResult());
- list.add(present_validationResult);
- if (present_validationResult)
- list.add(validationResult);
+ hashCode = hashCode * 8191 + ((isSetValidationResult()) ? 131071 : 524287);
+ if (isSetValidationResult())
+ hashCode = hashCode * 8191 + validationResult.hashCode();
- boolean present_errorMessage = true && (isSetErrorMessage());
- list.add(present_errorMessage);
- if (present_errorMessage)
- list.add(errorMessage);
+ hashCode = hashCode * 8191 + ((isSetErrorMessage()) ? 131071 : 524287);
+ if (isSetErrorMessage())
+ hashCode = hashCode * 8191 + errorMessage.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -326,7 +296,7 @@ public class LaunchValidationException extends TException implements org.apache.
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetValidationResult()).compareTo(other.isSetValidationResult());
+ lastComparison = java.lang.Boolean.valueOf(isSetValidationResult()).compareTo(other.isSetValidationResult());
if (lastComparison != 0) {
return lastComparison;
}
@@ -336,7 +306,7 @@ public class LaunchValidationException extends TException implements org.apache.
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetErrorMessage()).compareTo(other.isSetErrorMessage());
+ lastComparison = java.lang.Boolean.valueOf(isSetErrorMessage()).compareTo(other.isSetErrorMessage());
if (lastComparison != 0) {
return lastComparison;
}
@@ -354,16 +324,16 @@ public class LaunchValidationException extends TException implements org.apache.
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("LaunchValidationException(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("LaunchValidationException(");
boolean first = true;
sb.append("validationResult:");
@@ -407,7 +377,7 @@ public class LaunchValidationException extends TException implements org.apache.
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -415,13 +385,13 @@ public class LaunchValidationException extends TException implements org.apache.
}
}
- private static class LaunchValidationExceptionStandardSchemeFactory implements SchemeFactory {
+ private static class LaunchValidationExceptionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public LaunchValidationExceptionStandardScheme getScheme() {
return new LaunchValidationExceptionStandardScheme();
}
}
- private static class LaunchValidationExceptionStandardScheme extends StandardScheme<LaunchValidationException> {
+ private static class LaunchValidationExceptionStandardScheme extends org.apache.thrift.scheme.StandardScheme<LaunchValidationException> {
public void read(org.apache.thrift.protocol.TProtocol iprot, LaunchValidationException struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -481,19 +451,19 @@ public class LaunchValidationException extends TException implements org.apache.
}
- private static class LaunchValidationExceptionTupleSchemeFactory implements SchemeFactory {
+ private static class LaunchValidationExceptionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public LaunchValidationExceptionTupleScheme getScheme() {
return new LaunchValidationExceptionTupleScheme();
}
}
- private static class LaunchValidationExceptionTupleScheme extends TupleScheme<LaunchValidationException> {
+ private static class LaunchValidationExceptionTupleScheme extends org.apache.thrift.scheme.TupleScheme<LaunchValidationException> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, LaunchValidationException struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.validationResult.write(oprot);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetErrorMessage()) {
optionals.set(0);
}
@@ -505,11 +475,11 @@ public class LaunchValidationException extends TException implements org.apache.
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, LaunchValidationException struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.validationResult = new ValidationResults();
struct.validationResult.read(iprot);
struct.setValidationResultIsSet(true);
- BitSet incoming = iprot.readBitSet(1);
+ java.util.BitSet incoming = iprot.readBitSet(1);
if (incoming.get(0)) {
struct.errorMessage = iprot.readString();
struct.setErrorMessageIsSet(true);
@@ -517,5 +487,8 @@ public class LaunchValidationException extends TException implements org.apache.
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ProjectNotFoundException.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ProjectNotFoundException.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ProjectNotFoundException.java
index a81da69..f0ca5d2 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ProjectNotFoundException.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ProjectNotFoundException.java
@@ -16,68 +16,38 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.error;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* 1: optional string identifier,
* 2: optional string key
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
-public class ProjectNotFoundException extends TException implements org.apache.thrift.TBase<ProjectNotFoundException, ProjectNotFoundException._Fields>, java.io.Serializable, Cloneable, Comparable<ProjectNotFoundException> {
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
+public class ProjectNotFoundException extends org.apache.thrift.TException implements org.apache.thrift.TBase<ProjectNotFoundException, ProjectNotFoundException._Fields>, java.io.Serializable, Cloneable, Comparable<ProjectNotFoundException> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ProjectNotFoundException");
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 ProjectNotFoundExceptionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ProjectNotFoundExceptionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ProjectNotFoundExceptionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ProjectNotFoundExceptionTupleSchemeFactory();
- private String message; // required
+ private java.lang.String message; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
MESSAGE((short)1, "message");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -100,21 +70,21 @@ public class ProjectNotFoundException extends TException implements org.apache.t
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -123,18 +93,18 @@ public class ProjectNotFoundException extends TException implements org.apache.t
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.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);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ProjectNotFoundException.class, metaDataMap);
}
@@ -142,7 +112,7 @@ public class ProjectNotFoundException extends TException implements org.apache.t
}
public ProjectNotFoundException(
- String message)
+ java.lang.String message)
{
this();
this.message = message;
@@ -166,11 +136,11 @@ public class ProjectNotFoundException extends TException implements org.apache.t
this.message = null;
}
- public String getMessage() {
+ public java.lang.String getMessage() {
return this.message;
}
- public void setMessage(String message) {
+ public void setMessage(java.lang.String message) {
this.message = message;
}
@@ -189,43 +159,43 @@ public class ProjectNotFoundException extends TException implements org.apache.t
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case MESSAGE:
if (value == null) {
unsetMessage();
} else {
- setMessage((String)value);
+ setMessage((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case MESSAGE:
return getMessage();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
case MESSAGE:
return isSetMessage();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ProjectNotFoundException)
@@ -236,6 +206,8 @@ public class ProjectNotFoundException extends TException implements org.apache.t
public boolean equals(ProjectNotFoundException that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_message = true && this.isSetMessage();
boolean that_present_message = true && that.isSetMessage();
@@ -251,14 +223,13 @@ public class ProjectNotFoundException extends TException implements org.apache.t
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_message = true && (isSetMessage());
- list.add(present_message);
- if (present_message)
- list.add(message);
+ hashCode = hashCode * 8191 + ((isSetMessage()) ? 131071 : 524287);
+ if (isSetMessage())
+ hashCode = hashCode * 8191 + message.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -269,7 +240,7 @@ public class ProjectNotFoundException extends TException implements org.apache.t
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetMessage()).compareTo(other.isSetMessage());
+ lastComparison = java.lang.Boolean.valueOf(isSetMessage()).compareTo(other.isSetMessage());
if (lastComparison != 0) {
return lastComparison;
}
@@ -287,16 +258,16 @@ public class ProjectNotFoundException extends TException implements org.apache.t
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ProjectNotFoundException(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ProjectNotFoundException(");
boolean first = true;
sb.append("message:");
@@ -327,7 +298,7 @@ public class ProjectNotFoundException extends TException implements org.apache.t
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -335,13 +306,13 @@ public class ProjectNotFoundException extends TException implements org.apache.t
}
}
- private static class ProjectNotFoundExceptionStandardSchemeFactory implements SchemeFactory {
+ private static class ProjectNotFoundExceptionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ProjectNotFoundExceptionStandardScheme getScheme() {
return new ProjectNotFoundExceptionStandardScheme();
}
}
- private static class ProjectNotFoundExceptionStandardScheme extends StandardScheme<ProjectNotFoundException> {
+ private static class ProjectNotFoundExceptionStandardScheme extends org.apache.thrift.scheme.StandardScheme<ProjectNotFoundException> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ProjectNotFoundException struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -385,27 +356,30 @@ public class ProjectNotFoundException extends TException implements org.apache.t
}
- private static class ProjectNotFoundExceptionTupleSchemeFactory implements SchemeFactory {
+ private static class ProjectNotFoundExceptionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ProjectNotFoundExceptionTupleScheme getScheme() {
return new ProjectNotFoundExceptionTupleScheme();
}
}
- private static class ProjectNotFoundExceptionTupleScheme extends TupleScheme<ProjectNotFoundException> {
+ private static class ProjectNotFoundExceptionTupleScheme extends org.apache.thrift.scheme.TupleScheme<ProjectNotFoundException> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ProjectNotFoundException struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.message);
}
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ProjectNotFoundException struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.message = iprot.readString();
struct.setMessageIsSet(true);
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/TimedOutException.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/TimedOutException.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/TimedOutException.java
index b192ab6..33d95a0 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/TimedOutException.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/TimedOutException.java
@@ -16,64 +16,34 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.error;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* This exception is thrown when RPC timeout gets exceeded.
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
-public class TimedOutException extends TException implements org.apache.thrift.TBase<TimedOutException, TimedOutException._Fields>, java.io.Serializable, Cloneable, Comparable<TimedOutException> {
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
+public class TimedOutException extends org.apache.thrift.TException implements org.apache.thrift.TBase<TimedOutException, TimedOutException._Fields>, java.io.Serializable, Cloneable, Comparable<TimedOutException> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TimedOutException");
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new TimedOutExceptionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new TimedOutExceptionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TimedOutExceptionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TimedOutExceptionTupleSchemeFactory();
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
;
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -94,21 +64,21 @@ public class TimedOutException extends TException implements org.apache.thrift.T
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -117,14 +87,14 @@ public class TimedOutException extends TException implements org.apache.thrift.T
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TimedOutException.class, metaDataMap);
}
@@ -145,30 +115,30 @@ public class TimedOutException extends TException implements org.apache.thrift.T
public void clear() {
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof TimedOutException)
@@ -179,15 +149,17 @@ public class TimedOutException extends TException implements org.apache.thrift.T
public boolean equals(TimedOutException that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
return true;
}
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -206,16 +178,16 @@ public class TimedOutException extends TException implements org.apache.thrift.T
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("TimedOutException(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("TimedOutException(");
boolean first = true;
sb.append(")");
@@ -235,7 +207,7 @@ public class TimedOutException extends TException implements org.apache.thrift.T
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -243,13 +215,13 @@ public class TimedOutException extends TException implements org.apache.thrift.T
}
}
- private static class TimedOutExceptionStandardSchemeFactory implements SchemeFactory {
+ private static class TimedOutExceptionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public TimedOutExceptionStandardScheme getScheme() {
return new TimedOutExceptionStandardScheme();
}
}
- private static class TimedOutExceptionStandardScheme extends StandardScheme<TimedOutException> {
+ private static class TimedOutExceptionStandardScheme extends org.apache.thrift.scheme.StandardScheme<TimedOutException> {
public void read(org.apache.thrift.protocol.TProtocol iprot, TimedOutException struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -280,24 +252,27 @@ public class TimedOutException extends TException implements org.apache.thrift.T
}
- private static class TimedOutExceptionTupleSchemeFactory implements SchemeFactory {
+ private static class TimedOutExceptionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public TimedOutExceptionTupleScheme getScheme() {
return new TimedOutExceptionTupleScheme();
}
}
- private static class TimedOutExceptionTupleScheme extends TupleScheme<TimedOutException> {
+ private static class TimedOutExceptionTupleScheme extends org.apache.thrift.scheme.TupleScheme<TimedOutException> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, TimedOutException struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
}
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, TimedOutException struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
[41/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/gatewayprofile/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/gatewayprofile/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/gatewayprofile/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/gatewayprofile/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/gatewayprofile/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/gatewayprofile/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/gatewayprofile/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/gatewayprofile/ttypes.py
index ecb93e8..7e7d4dc 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/gatewayprofile/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/gatewayprofile/ttypes.py
@@ -1,564 +1,522 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.appcatalog.computeresource.ttypes
import apache.airavata.model.data.movement.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-
-class ComputeResourcePreference:
- """
- Gateway specific preferences for a Computer Resource
-
- computeResourceId:
- Corelate the preference to a compute resource.
-
- overridebyAiravata:
- If turned true, Airavata will override the preferences of better alternatives exist.
-
- loginUserName:
- If turned true, Airavata will override the preferences of better alternatives exist.
-
- preferredJobSubmissionProtocol:
- For resources with multiple job submission protocols, the gateway can pick a preferred option.
-
- preferredDataMovementProtocol:
- For resources with multiple data movement protocols, the gateway can pick a preferred option.
-
- preferredBatchQueue:
- Gateways can choose a defualt batch queue based on average job dimention, reservations or other metrics.
-
- scratchLocation:
- Path to the local scratch space on a HPC cluster. Typically used to create working directory for job execution.
-
- allocationProjectNumber:
- Typically used on HPC machines to charge computing usage to a account number. For instance, on XSEDE once an
- allocation is approved, an allocation number is assigned. Before passing this number with job submittions, the
- account to be used has to be added to the allocation.
-
- resourceSpecificCredentialStoreToken:
- Resource specific credential store token. If this token is specified, then it is superceeded by the gateway's
- default credential store.
-
-
- Attributes:
- - computeResourceId
- - overridebyAiravata
- - loginUserName
- - preferredJobSubmissionProtocol
- - preferredDataMovementProtocol
- - preferredBatchQueue
- - scratchLocation
- - allocationProjectNumber
- - resourceSpecificCredentialStoreToken
- - usageReportingGatewayId
- - qualityOfService
- - reservation
- - reservationStartTime
- - reservationEndTime
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'computeResourceId', None, None, ), # 1
- (2, TType.BOOL, 'overridebyAiravata', None, True, ), # 2
- (3, TType.STRING, 'loginUserName', None, None, ), # 3
- (4, TType.I32, 'preferredJobSubmissionProtocol', None, None, ), # 4
- (5, TType.I32, 'preferredDataMovementProtocol', None, None, ), # 5
- (6, TType.STRING, 'preferredBatchQueue', None, None, ), # 6
- (7, TType.STRING, 'scratchLocation', None, None, ), # 7
- (8, TType.STRING, 'allocationProjectNumber', None, None, ), # 8
- (9, TType.STRING, 'resourceSpecificCredentialStoreToken', None, None, ), # 9
- (10, TType.STRING, 'usageReportingGatewayId', None, None, ), # 10
- (11, TType.STRING, 'qualityOfService', None, None, ), # 11
- (12, TType.STRING, 'reservation', None, None, ), # 12
- (13, TType.I64, 'reservationStartTime', None, None, ), # 13
- (14, TType.I64, 'reservationEndTime', None, None, ), # 14
- )
-
- def __init__(self, computeResourceId=None, overridebyAiravata=thrift_spec[2][4], loginUserName=None, preferredJobSubmissionProtocol=None, preferredDataMovementProtocol=None, preferredBatchQueue=None, scratchLocation=None, allocationProjectNumber=None, resourceSpecificCredentialStoreToken=None, usageReportingGatewayId=None, qualityOfService=None, reservation=None, reservationStartTime=None, reservationEndTime=None,):
- self.computeResourceId = computeResourceId
- self.overridebyAiravata = overridebyAiravata
- self.loginUserName = loginUserName
- self.preferredJobSubmissionProtocol = preferredJobSubmissionProtocol
- self.preferredDataMovementProtocol = preferredDataMovementProtocol
- self.preferredBatchQueue = preferredBatchQueue
- self.scratchLocation = scratchLocation
- self.allocationProjectNumber = allocationProjectNumber
- self.resourceSpecificCredentialStoreToken = resourceSpecificCredentialStoreToken
- self.usageReportingGatewayId = usageReportingGatewayId
- self.qualityOfService = qualityOfService
- self.reservation = reservation
- self.reservationStartTime = reservationStartTime
- self.reservationEndTime = reservationEndTime
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.computeResourceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.BOOL:
- self.overridebyAiravata = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.loginUserName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.I32:
- self.preferredJobSubmissionProtocol = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I32:
- self.preferredDataMovementProtocol = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.preferredBatchQueue = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.STRING:
- self.scratchLocation = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.STRING:
- self.allocationProjectNumber = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.STRING:
- self.resourceSpecificCredentialStoreToken = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.STRING:
- self.usageReportingGatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 11:
- if ftype == TType.STRING:
- self.qualityOfService = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 12:
- if ftype == TType.STRING:
- self.reservation = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 13:
- if ftype == TType.I64:
- self.reservationStartTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 14:
- if ftype == TType.I64:
- self.reservationEndTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ComputeResourcePreference')
- if self.computeResourceId is not None:
- oprot.writeFieldBegin('computeResourceId', TType.STRING, 1)
- oprot.writeString(self.computeResourceId)
- oprot.writeFieldEnd()
- if self.overridebyAiravata is not None:
- oprot.writeFieldBegin('overridebyAiravata', TType.BOOL, 2)
- oprot.writeBool(self.overridebyAiravata)
- oprot.writeFieldEnd()
- if self.loginUserName is not None:
- oprot.writeFieldBegin('loginUserName', TType.STRING, 3)
- oprot.writeString(self.loginUserName)
- oprot.writeFieldEnd()
- if self.preferredJobSubmissionProtocol is not None:
- oprot.writeFieldBegin('preferredJobSubmissionProtocol', TType.I32, 4)
- oprot.writeI32(self.preferredJobSubmissionProtocol)
- oprot.writeFieldEnd()
- if self.preferredDataMovementProtocol is not None:
- oprot.writeFieldBegin('preferredDataMovementProtocol', TType.I32, 5)
- oprot.writeI32(self.preferredDataMovementProtocol)
- oprot.writeFieldEnd()
- if self.preferredBatchQueue is not None:
- oprot.writeFieldBegin('preferredBatchQueue', TType.STRING, 6)
- oprot.writeString(self.preferredBatchQueue)
- oprot.writeFieldEnd()
- if self.scratchLocation is not None:
- oprot.writeFieldBegin('scratchLocation', TType.STRING, 7)
- oprot.writeString(self.scratchLocation)
- oprot.writeFieldEnd()
- if self.allocationProjectNumber is not None:
- oprot.writeFieldBegin('allocationProjectNumber', TType.STRING, 8)
- oprot.writeString(self.allocationProjectNumber)
- oprot.writeFieldEnd()
- if self.resourceSpecificCredentialStoreToken is not None:
- oprot.writeFieldBegin('resourceSpecificCredentialStoreToken', TType.STRING, 9)
- oprot.writeString(self.resourceSpecificCredentialStoreToken)
- oprot.writeFieldEnd()
- if self.usageReportingGatewayId is not None:
- oprot.writeFieldBegin('usageReportingGatewayId', TType.STRING, 10)
- oprot.writeString(self.usageReportingGatewayId)
- oprot.writeFieldEnd()
- if self.qualityOfService is not None:
- oprot.writeFieldBegin('qualityOfService', TType.STRING, 11)
- oprot.writeString(self.qualityOfService)
- oprot.writeFieldEnd()
- if self.reservation is not None:
- oprot.writeFieldBegin('reservation', TType.STRING, 12)
- oprot.writeString(self.reservation)
- oprot.writeFieldEnd()
- if self.reservationStartTime is not None:
- oprot.writeFieldBegin('reservationStartTime', TType.I64, 13)
- oprot.writeI64(self.reservationStartTime)
- oprot.writeFieldEnd()
- if self.reservationEndTime is not None:
- oprot.writeFieldBegin('reservationEndTime', TType.I64, 14)
- oprot.writeI64(self.reservationEndTime)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.computeResourceId is None:
- raise TProtocol.TProtocolException(message='Required field computeResourceId is unset!')
- if self.overridebyAiravata is None:
- raise TProtocol.TProtocolException(message='Required field overridebyAiravata is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.computeResourceId)
- value = (value * 31) ^ hash(self.overridebyAiravata)
- value = (value * 31) ^ hash(self.loginUserName)
- value = (value * 31) ^ hash(self.preferredJobSubmissionProtocol)
- value = (value * 31) ^ hash(self.preferredDataMovementProtocol)
- value = (value * 31) ^ hash(self.preferredBatchQueue)
- value = (value * 31) ^ hash(self.scratchLocation)
- value = (value * 31) ^ hash(self.allocationProjectNumber)
- value = (value * 31) ^ hash(self.resourceSpecificCredentialStoreToken)
- value = (value * 31) ^ hash(self.usageReportingGatewayId)
- value = (value * 31) ^ hash(self.qualityOfService)
- value = (value * 31) ^ hash(self.reservation)
- value = (value * 31) ^ hash(self.reservationStartTime)
- value = (value * 31) ^ hash(self.reservationEndTime)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class StoragePreference:
- """
- Attributes:
- - storageResourceId
- - loginUserName
- - fileSystemRootLocation
- - resourceSpecificCredentialStoreToken
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'storageResourceId', None, None, ), # 1
- (2, TType.STRING, 'loginUserName', None, None, ), # 2
- (3, TType.STRING, 'fileSystemRootLocation', None, None, ), # 3
- (4, TType.STRING, 'resourceSpecificCredentialStoreToken', None, None, ), # 4
- )
-
- def __init__(self, storageResourceId=None, loginUserName=None, fileSystemRootLocation=None, resourceSpecificCredentialStoreToken=None,):
- self.storageResourceId = storageResourceId
- self.loginUserName = loginUserName
- self.fileSystemRootLocation = fileSystemRootLocation
- self.resourceSpecificCredentialStoreToken = resourceSpecificCredentialStoreToken
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.storageResourceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.loginUserName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.fileSystemRootLocation = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.resourceSpecificCredentialStoreToken = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('StoragePreference')
- if self.storageResourceId is not None:
- oprot.writeFieldBegin('storageResourceId', TType.STRING, 1)
- oprot.writeString(self.storageResourceId)
- oprot.writeFieldEnd()
- if self.loginUserName is not None:
- oprot.writeFieldBegin('loginUserName', TType.STRING, 2)
- oprot.writeString(self.loginUserName)
- oprot.writeFieldEnd()
- if self.fileSystemRootLocation is not None:
- oprot.writeFieldBegin('fileSystemRootLocation', TType.STRING, 3)
- oprot.writeString(self.fileSystemRootLocation)
- oprot.writeFieldEnd()
- if self.resourceSpecificCredentialStoreToken is not None:
- oprot.writeFieldBegin('resourceSpecificCredentialStoreToken', TType.STRING, 4)
- oprot.writeString(self.resourceSpecificCredentialStoreToken)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.storageResourceId is None:
- raise TProtocol.TProtocolException(message='Required field storageResourceId is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.storageResourceId)
- value = (value * 31) ^ hash(self.loginUserName)
- value = (value * 31) ^ hash(self.fileSystemRootLocation)
- value = (value * 31) ^ hash(self.resourceSpecificCredentialStoreToken)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class GatewayResourceProfile:
- """
- Gateway Resource Profile
-
- gatewayID:
- Unique identifier for the gateway assigned by Airavata. Corelate this to Airavata Admin API Gateway Registration.
-
- credentialStoreToken:
- Gateway's defualt credential store token.
-
- computeResourcePreferences:
- List of resource preferences for each of the registered compute resources.
-
- identityServerTenant:
-
- identityServerPwdCredToken:
-
-
- Attributes:
- - gatewayID
- - credentialStoreToken
- - computeResourcePreferences
- - storagePreferences
- - identityServerTenant
- - identityServerPwdCredToken
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'gatewayID', None, None, ), # 1
- (2, TType.STRING, 'credentialStoreToken', None, None, ), # 2
- (3, TType.LIST, 'computeResourcePreferences', (TType.STRUCT,(ComputeResourcePreference, ComputeResourcePreference.thrift_spec)), None, ), # 3
- (4, TType.LIST, 'storagePreferences', (TType.STRUCT,(StoragePreference, StoragePreference.thrift_spec)), None, ), # 4
- (5, TType.STRING, 'identityServerTenant', None, None, ), # 5
- (6, TType.STRING, 'identityServerPwdCredToken', None, None, ), # 6
- )
-
- def __init__(self, gatewayID=None, credentialStoreToken=None, computeResourcePreferences=None, storagePreferences=None, identityServerTenant=None, identityServerPwdCredToken=None,):
- self.gatewayID = gatewayID
- self.credentialStoreToken = credentialStoreToken
- self.computeResourcePreferences = computeResourcePreferences
- self.storagePreferences = storagePreferences
- self.identityServerTenant = identityServerTenant
- self.identityServerPwdCredToken = identityServerPwdCredToken
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.gatewayID = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.credentialStoreToken = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.LIST:
- self.computeResourcePreferences = []
- (_etype3, _size0) = iprot.readListBegin()
- for _i4 in xrange(_size0):
- _elem5 = ComputeResourcePreference()
- _elem5.read(iprot)
- self.computeResourcePreferences.append(_elem5)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.LIST:
- self.storagePreferences = []
- (_etype9, _size6) = iprot.readListBegin()
- for _i10 in xrange(_size6):
- _elem11 = StoragePreference()
- _elem11.read(iprot)
- self.storagePreferences.append(_elem11)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.identityServerTenant = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.identityServerPwdCredToken = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('GatewayResourceProfile')
- if self.gatewayID is not None:
- oprot.writeFieldBegin('gatewayID', TType.STRING, 1)
- oprot.writeString(self.gatewayID)
- oprot.writeFieldEnd()
- if self.credentialStoreToken is not None:
- oprot.writeFieldBegin('credentialStoreToken', TType.STRING, 2)
- oprot.writeString(self.credentialStoreToken)
- oprot.writeFieldEnd()
- if self.computeResourcePreferences is not None:
- oprot.writeFieldBegin('computeResourcePreferences', TType.LIST, 3)
- oprot.writeListBegin(TType.STRUCT, len(self.computeResourcePreferences))
- for iter12 in self.computeResourcePreferences:
- iter12.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.storagePreferences is not None:
- oprot.writeFieldBegin('storagePreferences', TType.LIST, 4)
- oprot.writeListBegin(TType.STRUCT, len(self.storagePreferences))
- for iter13 in self.storagePreferences:
- iter13.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.identityServerTenant is not None:
- oprot.writeFieldBegin('identityServerTenant', TType.STRING, 5)
- oprot.writeString(self.identityServerTenant)
- oprot.writeFieldEnd()
- if self.identityServerPwdCredToken is not None:
- oprot.writeFieldBegin('identityServerPwdCredToken', TType.STRING, 6)
- oprot.writeString(self.identityServerPwdCredToken)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.gatewayID is None:
- raise TProtocol.TProtocolException(message='Required field gatewayID is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.gatewayID)
- value = (value * 31) ^ hash(self.credentialStoreToken)
- value = (value * 31) ^ hash(self.computeResourcePreferences)
- value = (value * 31) ^ hash(self.storagePreferences)
- value = (value * 31) ^ hash(self.identityServerTenant)
- value = (value * 31) ^ hash(self.identityServerPwdCredToken)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class ComputeResourcePreference(object):
+ """
+ Gateway specific preferences for a Computer Resource
+
+ computeResourceId:
+ Corelate the preference to a compute resource.
+
+ overridebyAiravata:
+ If turned true, Airavata will override the preferences of better alternatives exist.
+
+ loginUserName:
+ If turned true, Airavata will override the preferences of better alternatives exist.
+
+ preferredJobSubmissionProtocol:
+ For resources with multiple job submission protocols, the gateway can pick a preferred option.
+
+ preferredDataMovementProtocol:
+ For resources with multiple data movement protocols, the gateway can pick a preferred option.
+
+ preferredBatchQueue:
+ Gateways can choose a defualt batch queue based on average job dimention, reservations or other metrics.
+
+ scratchLocation:
+ Path to the local scratch space on a HPC cluster. Typically used to create working directory for job execution.
+
+ allocationProjectNumber:
+ Typically used on HPC machines to charge computing usage to a account number. For instance, on XSEDE once an
+ allocation is approved, an allocation number is assigned. Before passing this number with job submittions, the
+ account to be used has to be added to the allocation.
+
+ resourceSpecificCredentialStoreToken:
+ Resource specific credential store token. If this token is specified, then it is superceeded by the gateway's
+ default credential store.
+
+
+ Attributes:
+ - computeResourceId
+ - overridebyAiravata
+ - loginUserName
+ - preferredJobSubmissionProtocol
+ - preferredDataMovementProtocol
+ - preferredBatchQueue
+ - scratchLocation
+ - allocationProjectNumber
+ - resourceSpecificCredentialStoreToken
+ - usageReportingGatewayId
+ - qualityOfService
+ - reservation
+ - reservationStartTime
+ - reservationEndTime
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'computeResourceId', 'UTF8', None, ), # 1
+ (2, TType.BOOL, 'overridebyAiravata', None, True, ), # 2
+ (3, TType.STRING, 'loginUserName', 'UTF8', None, ), # 3
+ (4, TType.I32, 'preferredJobSubmissionProtocol', None, None, ), # 4
+ (5, TType.I32, 'preferredDataMovementProtocol', None, None, ), # 5
+ (6, TType.STRING, 'preferredBatchQueue', 'UTF8', None, ), # 6
+ (7, TType.STRING, 'scratchLocation', 'UTF8', None, ), # 7
+ (8, TType.STRING, 'allocationProjectNumber', 'UTF8', None, ), # 8
+ (9, TType.STRING, 'resourceSpecificCredentialStoreToken', 'UTF8', None, ), # 9
+ (10, TType.STRING, 'usageReportingGatewayId', 'UTF8', None, ), # 10
+ (11, TType.STRING, 'qualityOfService', 'UTF8', None, ), # 11
+ (12, TType.STRING, 'reservation', 'UTF8', None, ), # 12
+ (13, TType.I64, 'reservationStartTime', None, None, ), # 13
+ (14, TType.I64, 'reservationEndTime', None, None, ), # 14
+ )
+
+ def __init__(self, computeResourceId=None, overridebyAiravata=thrift_spec[2][4], loginUserName=None, preferredJobSubmissionProtocol=None, preferredDataMovementProtocol=None, preferredBatchQueue=None, scratchLocation=None, allocationProjectNumber=None, resourceSpecificCredentialStoreToken=None, usageReportingGatewayId=None, qualityOfService=None, reservation=None, reservationStartTime=None, reservationEndTime=None,):
+ self.computeResourceId = computeResourceId
+ self.overridebyAiravata = overridebyAiravata
+ self.loginUserName = loginUserName
+ self.preferredJobSubmissionProtocol = preferredJobSubmissionProtocol
+ self.preferredDataMovementProtocol = preferredDataMovementProtocol
+ self.preferredBatchQueue = preferredBatchQueue
+ self.scratchLocation = scratchLocation
+ self.allocationProjectNumber = allocationProjectNumber
+ self.resourceSpecificCredentialStoreToken = resourceSpecificCredentialStoreToken
+ self.usageReportingGatewayId = usageReportingGatewayId
+ self.qualityOfService = qualityOfService
+ self.reservation = reservation
+ self.reservationStartTime = reservationStartTime
+ self.reservationEndTime = reservationEndTime
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.computeResourceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.BOOL:
+ self.overridebyAiravata = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.loginUserName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.I32:
+ self.preferredJobSubmissionProtocol = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.I32:
+ self.preferredDataMovementProtocol = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.preferredBatchQueue = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.STRING:
+ self.scratchLocation = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.STRING:
+ self.allocationProjectNumber = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.STRING:
+ self.resourceSpecificCredentialStoreToken = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.STRING:
+ self.usageReportingGatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 11:
+ if ftype == TType.STRING:
+ self.qualityOfService = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 12:
+ if ftype == TType.STRING:
+ self.reservation = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 13:
+ if ftype == TType.I64:
+ self.reservationStartTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 14:
+ if ftype == TType.I64:
+ self.reservationEndTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ComputeResourcePreference')
+ if self.computeResourceId is not None:
+ oprot.writeFieldBegin('computeResourceId', TType.STRING, 1)
+ oprot.writeString(self.computeResourceId.encode('utf-8') if sys.version_info[0] == 2 else self.computeResourceId)
+ oprot.writeFieldEnd()
+ if self.overridebyAiravata is not None:
+ oprot.writeFieldBegin('overridebyAiravata', TType.BOOL, 2)
+ oprot.writeBool(self.overridebyAiravata)
+ oprot.writeFieldEnd()
+ if self.loginUserName is not None:
+ oprot.writeFieldBegin('loginUserName', TType.STRING, 3)
+ oprot.writeString(self.loginUserName.encode('utf-8') if sys.version_info[0] == 2 else self.loginUserName)
+ oprot.writeFieldEnd()
+ if self.preferredJobSubmissionProtocol is not None:
+ oprot.writeFieldBegin('preferredJobSubmissionProtocol', TType.I32, 4)
+ oprot.writeI32(self.preferredJobSubmissionProtocol)
+ oprot.writeFieldEnd()
+ if self.preferredDataMovementProtocol is not None:
+ oprot.writeFieldBegin('preferredDataMovementProtocol', TType.I32, 5)
+ oprot.writeI32(self.preferredDataMovementProtocol)
+ oprot.writeFieldEnd()
+ if self.preferredBatchQueue is not None:
+ oprot.writeFieldBegin('preferredBatchQueue', TType.STRING, 6)
+ oprot.writeString(self.preferredBatchQueue.encode('utf-8') if sys.version_info[0] == 2 else self.preferredBatchQueue)
+ oprot.writeFieldEnd()
+ if self.scratchLocation is not None:
+ oprot.writeFieldBegin('scratchLocation', TType.STRING, 7)
+ oprot.writeString(self.scratchLocation.encode('utf-8') if sys.version_info[0] == 2 else self.scratchLocation)
+ oprot.writeFieldEnd()
+ if self.allocationProjectNumber is not None:
+ oprot.writeFieldBegin('allocationProjectNumber', TType.STRING, 8)
+ oprot.writeString(self.allocationProjectNumber.encode('utf-8') if sys.version_info[0] == 2 else self.allocationProjectNumber)
+ oprot.writeFieldEnd()
+ if self.resourceSpecificCredentialStoreToken is not None:
+ oprot.writeFieldBegin('resourceSpecificCredentialStoreToken', TType.STRING, 9)
+ oprot.writeString(self.resourceSpecificCredentialStoreToken.encode('utf-8') if sys.version_info[0] == 2 else self.resourceSpecificCredentialStoreToken)
+ oprot.writeFieldEnd()
+ if self.usageReportingGatewayId is not None:
+ oprot.writeFieldBegin('usageReportingGatewayId', TType.STRING, 10)
+ oprot.writeString(self.usageReportingGatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.usageReportingGatewayId)
+ oprot.writeFieldEnd()
+ if self.qualityOfService is not None:
+ oprot.writeFieldBegin('qualityOfService', TType.STRING, 11)
+ oprot.writeString(self.qualityOfService.encode('utf-8') if sys.version_info[0] == 2 else self.qualityOfService)
+ oprot.writeFieldEnd()
+ if self.reservation is not None:
+ oprot.writeFieldBegin('reservation', TType.STRING, 12)
+ oprot.writeString(self.reservation.encode('utf-8') if sys.version_info[0] == 2 else self.reservation)
+ oprot.writeFieldEnd()
+ if self.reservationStartTime is not None:
+ oprot.writeFieldBegin('reservationStartTime', TType.I64, 13)
+ oprot.writeI64(self.reservationStartTime)
+ oprot.writeFieldEnd()
+ if self.reservationEndTime is not None:
+ oprot.writeFieldBegin('reservationEndTime', TType.I64, 14)
+ oprot.writeI64(self.reservationEndTime)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.computeResourceId is None:
+ raise TProtocolException(message='Required field computeResourceId is unset!')
+ if self.overridebyAiravata is None:
+ raise TProtocolException(message='Required field overridebyAiravata is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class StoragePreference(object):
+ """
+ Attributes:
+ - storageResourceId
+ - loginUserName
+ - fileSystemRootLocation
+ - resourceSpecificCredentialStoreToken
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'storageResourceId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'loginUserName', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'fileSystemRootLocation', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'resourceSpecificCredentialStoreToken', 'UTF8', None, ), # 4
+ )
+
+ def __init__(self, storageResourceId=None, loginUserName=None, fileSystemRootLocation=None, resourceSpecificCredentialStoreToken=None,):
+ self.storageResourceId = storageResourceId
+ self.loginUserName = loginUserName
+ self.fileSystemRootLocation = fileSystemRootLocation
+ self.resourceSpecificCredentialStoreToken = resourceSpecificCredentialStoreToken
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.storageResourceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.loginUserName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.fileSystemRootLocation = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.resourceSpecificCredentialStoreToken = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('StoragePreference')
+ if self.storageResourceId is not None:
+ oprot.writeFieldBegin('storageResourceId', TType.STRING, 1)
+ oprot.writeString(self.storageResourceId.encode('utf-8') if sys.version_info[0] == 2 else self.storageResourceId)
+ oprot.writeFieldEnd()
+ if self.loginUserName is not None:
+ oprot.writeFieldBegin('loginUserName', TType.STRING, 2)
+ oprot.writeString(self.loginUserName.encode('utf-8') if sys.version_info[0] == 2 else self.loginUserName)
+ oprot.writeFieldEnd()
+ if self.fileSystemRootLocation is not None:
+ oprot.writeFieldBegin('fileSystemRootLocation', TType.STRING, 3)
+ oprot.writeString(self.fileSystemRootLocation.encode('utf-8') if sys.version_info[0] == 2 else self.fileSystemRootLocation)
+ oprot.writeFieldEnd()
+ if self.resourceSpecificCredentialStoreToken is not None:
+ oprot.writeFieldBegin('resourceSpecificCredentialStoreToken', TType.STRING, 4)
+ oprot.writeString(self.resourceSpecificCredentialStoreToken.encode('utf-8') if sys.version_info[0] == 2 else self.resourceSpecificCredentialStoreToken)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.storageResourceId is None:
+ raise TProtocolException(message='Required field storageResourceId is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class GatewayResourceProfile(object):
+ """
+ Gateway Resource Profile
+
+ gatewayID:
+ Unique identifier for the gateway assigned by Airavata. Corelate this to Airavata Admin API Gateway Registration.
+
+ credentialStoreToken:
+ Gateway's defualt credential store token.
+
+ computeResourcePreferences:
+ List of resource preferences for each of the registered compute resources.
+
+ identityServerTenant:
+
+ identityServerPwdCredToken:
+
+
+ Attributes:
+ - gatewayID
+ - credentialStoreToken
+ - computeResourcePreferences
+ - storagePreferences
+ - identityServerTenant
+ - identityServerPwdCredToken
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'gatewayID', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'credentialStoreToken', 'UTF8', None, ), # 2
+ (3, TType.LIST, 'computeResourcePreferences', (TType.STRUCT, (ComputeResourcePreference, ComputeResourcePreference.thrift_spec), False), None, ), # 3
+ (4, TType.LIST, 'storagePreferences', (TType.STRUCT, (StoragePreference, StoragePreference.thrift_spec), False), None, ), # 4
+ (5, TType.STRING, 'identityServerTenant', 'UTF8', None, ), # 5
+ (6, TType.STRING, 'identityServerPwdCredToken', 'UTF8', None, ), # 6
+ )
+
+ def __init__(self, gatewayID=None, credentialStoreToken=None, computeResourcePreferences=None, storagePreferences=None, identityServerTenant=None, identityServerPwdCredToken=None,):
+ self.gatewayID = gatewayID
+ self.credentialStoreToken = credentialStoreToken
+ self.computeResourcePreferences = computeResourcePreferences
+ self.storagePreferences = storagePreferences
+ self.identityServerTenant = identityServerTenant
+ self.identityServerPwdCredToken = identityServerPwdCredToken
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.gatewayID = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.credentialStoreToken = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.LIST:
+ self.computeResourcePreferences = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in range(_size0):
+ _elem5 = ComputeResourcePreference()
+ _elem5.read(iprot)
+ self.computeResourcePreferences.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.LIST:
+ self.storagePreferences = []
+ (_etype9, _size6) = iprot.readListBegin()
+ for _i10 in range(_size6):
+ _elem11 = StoragePreference()
+ _elem11.read(iprot)
+ self.storagePreferences.append(_elem11)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRING:
+ self.identityServerTenant = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.identityServerPwdCredToken = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('GatewayResourceProfile')
+ if self.gatewayID is not None:
+ oprot.writeFieldBegin('gatewayID', TType.STRING, 1)
+ oprot.writeString(self.gatewayID.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayID)
+ oprot.writeFieldEnd()
+ if self.credentialStoreToken is not None:
+ oprot.writeFieldBegin('credentialStoreToken', TType.STRING, 2)
+ oprot.writeString(self.credentialStoreToken.encode('utf-8') if sys.version_info[0] == 2 else self.credentialStoreToken)
+ oprot.writeFieldEnd()
+ if self.computeResourcePreferences is not None:
+ oprot.writeFieldBegin('computeResourcePreferences', TType.LIST, 3)
+ oprot.writeListBegin(TType.STRUCT, len(self.computeResourcePreferences))
+ for iter12 in self.computeResourcePreferences:
+ iter12.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.storagePreferences is not None:
+ oprot.writeFieldBegin('storagePreferences', TType.LIST, 4)
+ oprot.writeListBegin(TType.STRUCT, len(self.storagePreferences))
+ for iter13 in self.storagePreferences:
+ iter13.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.identityServerTenant is not None:
+ oprot.writeFieldBegin('identityServerTenant', TType.STRING, 5)
+ oprot.writeString(self.identityServerTenant.encode('utf-8') if sys.version_info[0] == 2 else self.identityServerTenant)
+ oprot.writeFieldEnd()
+ if self.identityServerPwdCredToken is not None:
+ oprot.writeFieldBegin('identityServerPwdCredToken', TType.STRING, 6)
+ oprot.writeString(self.identityServerPwdCredToken.encode('utf-8') if sys.version_info[0] == 2 else self.identityServerPwdCredToken)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.gatewayID is None:
+ raise TProtocolException(message='Required field gatewayID is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/parallelism/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/parallelism/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/parallelism/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/parallelism/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/parallelism/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/parallelism/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/parallelism/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/parallelism/ttypes.py
index 485d97e..4acb602 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/parallelism/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/parallelism/ttypes.py
@@ -1,60 +1,56 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class ApplicationParallelismType:
- """
- Enumeration of application parallelism supported by Airavata
-
- SERIAL:
- Single processor applications without any parallelization.
-
- MPI:
- Messaging Passing Interface.
-
- OPENMP:
- Shared Memory Implementtaion.
-
- OPENMP_MPI:
- Hybrid Applications.
-
- """
- SERIAL = 0
- MPI = 1
- OPENMP = 2
- OPENMP_MPI = 3
- CCM = 4
- CRAY_MPI = 5
-
- _VALUES_TO_NAMES = {
- 0: "SERIAL",
- 1: "MPI",
- 2: "OPENMP",
- 3: "OPENMP_MPI",
- 4: "CCM",
- 5: "CRAY_MPI",
- }
-
- _NAMES_TO_VALUES = {
- "SERIAL": 0,
- "MPI": 1,
- "OPENMP": 2,
- "OPENMP_MPI": 3,
- "CCM": 4,
- "CRAY_MPI": 5,
- }
+
+class ApplicationParallelismType(object):
+ """
+ Enumeration of application parallelism supported by Airavata
+
+ SERIAL:
+ Single processor applications without any parallelization.
+
+ MPI:
+ Messaging Passing Interface.
+
+ OPENMP:
+ Shared Memory Implementtaion.
+
+ OPENMP_MPI:
+ Hybrid Applications.
+
+ """
+ SERIAL = 0
+ MPI = 1
+ OPENMP = 2
+ OPENMP_MPI = 3
+ CCM = 4
+ CRAY_MPI = 5
+
+ _VALUES_TO_NAMES = {
+ 0: "SERIAL",
+ 1: "MPI",
+ 2: "OPENMP",
+ 3: "OPENMP_MPI",
+ 4: "CCM",
+ 5: "CRAY_MPI",
+ }
+
+ _NAMES_TO_VALUES = {
+ "SERIAL": 0,
+ "MPI": 1,
+ "OPENMP": 2,
+ "OPENMP_MPI": 3,
+ "CCM": 4,
+ "CRAY_MPI": 5,
+ }
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/storageresource/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/storageresource/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/storageresource/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/storageresource/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/storageresource/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/storageresource/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/storageresource/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/storageresource/ttypes.py
index 32a9325..a33b14a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/storageresource/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/storageresource/ttypes.py
@@ -1,167 +1,152 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.commons.ttypes
import apache.airavata.model.data.movement.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-
-class StorageResourceDescription:
- """
- Storage Resource Description
-
- storageResourceId: Airavata Internal Unique Identifier to distinguish Compute Resource.
-
- hostName:
- Fully Qualified Host Name.
-
- storageResourceDescription:
- A user friendly description of the resource.
-
-
- DataMovementProtocol:
- Option to specify a prefered data movement mechanism of the available options.
-
-
-
- Attributes:
- - storageResourceId
- - hostName
- - storageResourceDescription
- - enabled
- - dataMovementInterfaces
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'storageResourceId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.STRING, 'hostName', None, None, ), # 2
- (3, TType.STRING, 'storageResourceDescription', None, None, ), # 3
- (4, TType.BOOL, 'enabled', None, None, ), # 4
- (5, TType.LIST, 'dataMovementInterfaces', (TType.STRUCT,(apache.airavata.model.data.movement.ttypes.DataMovementInterface, apache.airavata.model.data.movement.ttypes.DataMovementInterface.thrift_spec)), None, ), # 5
- )
-
- def __init__(self, storageResourceId=thrift_spec[1][4], hostName=None, storageResourceDescription=None, enabled=None, dataMovementInterfaces=None,):
- self.storageResourceId = storageResourceId
- self.hostName = hostName
- self.storageResourceDescription = storageResourceDescription
- self.enabled = enabled
- self.dataMovementInterfaces = dataMovementInterfaces
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.storageResourceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.hostName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.storageResourceDescription = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.BOOL:
- self.enabled = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.LIST:
- self.dataMovementInterfaces = []
- (_etype3, _size0) = iprot.readListBegin()
- for _i4 in xrange(_size0):
- _elem5 = apache.airavata.model.data.movement.ttypes.DataMovementInterface()
- _elem5.read(iprot)
- self.dataMovementInterfaces.append(_elem5)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('StorageResourceDescription')
- if self.storageResourceId is not None:
- oprot.writeFieldBegin('storageResourceId', TType.STRING, 1)
- oprot.writeString(self.storageResourceId)
- oprot.writeFieldEnd()
- if self.hostName is not None:
- oprot.writeFieldBegin('hostName', TType.STRING, 2)
- oprot.writeString(self.hostName)
- oprot.writeFieldEnd()
- if self.storageResourceDescription is not None:
- oprot.writeFieldBegin('storageResourceDescription', TType.STRING, 3)
- oprot.writeString(self.storageResourceDescription)
- oprot.writeFieldEnd()
- if self.enabled is not None:
- oprot.writeFieldBegin('enabled', TType.BOOL, 4)
- oprot.writeBool(self.enabled)
- oprot.writeFieldEnd()
- if self.dataMovementInterfaces is not None:
- oprot.writeFieldBegin('dataMovementInterfaces', TType.LIST, 5)
- oprot.writeListBegin(TType.STRUCT, len(self.dataMovementInterfaces))
- for iter6 in self.dataMovementInterfaces:
- iter6.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.storageResourceId is None:
- raise TProtocol.TProtocolException(message='Required field storageResourceId is unset!')
- if self.hostName is None:
- raise TProtocol.TProtocolException(message='Required field hostName is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.storageResourceId)
- value = (value * 31) ^ hash(self.hostName)
- value = (value * 31) ^ hash(self.storageResourceDescription)
- value = (value * 31) ^ hash(self.enabled)
- value = (value * 31) ^ hash(self.dataMovementInterfaces)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class StorageResourceDescription(object):
+ """
+ Storage Resource Description
+
+ storageResourceId: Airavata Internal Unique Identifier to distinguish Compute Resource.
+
+ hostName:
+ Fully Qualified Host Name.
+
+ storageResourceDescription:
+ A user friendly description of the resource.
+
+
+ DataMovementProtocol:
+ Option to specify a prefered data movement mechanism of the available options.
+
+
+
+ Attributes:
+ - storageResourceId
+ - hostName
+ - storageResourceDescription
+ - enabled
+ - dataMovementInterfaces
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'storageResourceId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.STRING, 'hostName', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'storageResourceDescription', 'UTF8', None, ), # 3
+ (4, TType.BOOL, 'enabled', None, None, ), # 4
+ (5, TType.LIST, 'dataMovementInterfaces', (TType.STRUCT, (apache.airavata.model.data.movement.ttypes.DataMovementInterface, apache.airavata.model.data.movement.ttypes.DataMovementInterface.thrift_spec), False), None, ), # 5
+ )
+
+ def __init__(self, storageResourceId=thrift_spec[1][4], hostName=None, storageResourceDescription=None, enabled=None, dataMovementInterfaces=None,):
+ self.storageResourceId = storageResourceId
+ self.hostName = hostName
+ self.storageResourceDescription = storageResourceDescription
+ self.enabled = enabled
+ self.dataMovementInterfaces = dataMovementInterfaces
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.storageResourceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.hostName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.storageResourceDescription = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.BOOL:
+ self.enabled = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.LIST:
+ self.dataMovementInterfaces = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in range(_size0):
+ _elem5 = apache.airavata.model.data.movement.ttypes.DataMovementInterface()
+ _elem5.read(iprot)
+ self.dataMovementInterfaces.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('StorageResourceDescription')
+ if self.storageResourceId is not None:
+ oprot.writeFieldBegin('storageResourceId', TType.STRING, 1)
+ oprot.writeString(self.storageResourceId.encode('utf-8') if sys.version_info[0] == 2 else self.storageResourceId)
+ oprot.writeFieldEnd()
+ if self.hostName is not None:
+ oprot.writeFieldBegin('hostName', TType.STRING, 2)
+ oprot.writeString(self.hostName.encode('utf-8') if sys.version_info[0] == 2 else self.hostName)
+ oprot.writeFieldEnd()
+ if self.storageResourceDescription is not None:
+ oprot.writeFieldBegin('storageResourceDescription', TType.STRING, 3)
+ oprot.writeString(self.storageResourceDescription.encode('utf-8') if sys.version_info[0] == 2 else self.storageResourceDescription)
+ oprot.writeFieldEnd()
+ if self.enabled is not None:
+ oprot.writeFieldBegin('enabled', TType.BOOL, 4)
+ oprot.writeBool(self.enabled)
+ oprot.writeFieldEnd()
+ if self.dataMovementInterfaces is not None:
+ oprot.writeFieldBegin('dataMovementInterfaces', TType.LIST, 5)
+ oprot.writeListBegin(TType.STRUCT, len(self.dataMovementInterfaces))
+ for iter6 in self.dataMovementInterfaces:
+ iter6.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.storageResourceId is None:
+ raise TProtocolException(message='Required field storageResourceId is unset!')
+ if self.hostName is None:
+ raise TProtocolException(message='Required field hostName is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/userresourceprofile/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/userresourceprofile/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/userresourceprofile/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/userresourceprofile/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/userresourceprofile/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
[28/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workflow/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workflow/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workflow/ttypes.py
index a18a061..068863a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workflow/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workflow/ttypes.py
@@ -1,822 +1,764 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.application.io.ttypes
import apache.airavata.model.commons.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class WorkflowState:
- CREATED = 0
- STARTED = 1
- EXECUTING = 2
- COMPLETED = 3
- FAILED = 4
- CANCELLING = 5
- CANCELED = 6
-
- _VALUES_TO_NAMES = {
- 0: "CREATED",
- 1: "STARTED",
- 2: "EXECUTING",
- 3: "COMPLETED",
- 4: "FAILED",
- 5: "CANCELLING",
- 6: "CANCELED",
- }
-
- _NAMES_TO_VALUES = {
- "CREATED": 0,
- "STARTED": 1,
- "EXECUTING": 2,
- "COMPLETED": 3,
- "FAILED": 4,
- "CANCELLING": 5,
- "CANCELED": 6,
- }
-
-class ComponentState:
- CREATED = 0
- WAITING = 1
- READY = 2
- RUNNING = 3
- COMPLETED = 4
- FAILED = 5
- CANCELED = 6
-
- _VALUES_TO_NAMES = {
- 0: "CREATED",
- 1: "WAITING",
- 2: "READY",
- 3: "RUNNING",
- 4: "COMPLETED",
- 5: "FAILED",
- 6: "CANCELED",
- }
-
- _NAMES_TO_VALUES = {
- "CREATED": 0,
- "WAITING": 1,
- "READY": 2,
- "RUNNING": 3,
- "COMPLETED": 4,
- "FAILED": 5,
- "CANCELED": 6,
- }
-
-
-class WorkflowModel:
- """
- Attributes:
- - templateId
- - name
- - graph
- - gatewayId
- - createdUser
- - image
- - workflowInputs
- - workflowOutputs
- - creationTime
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'templateId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.STRING, 'name', None, None, ), # 2
- (3, TType.STRING, 'graph', None, None, ), # 3
- (4, TType.STRING, 'gatewayId', None, None, ), # 4
- (5, TType.STRING, 'createdUser', None, None, ), # 5
- (6, TType.STRING, 'image', None, None, ), # 6
- (7, TType.LIST, 'workflowInputs', (TType.STRUCT,(apache.airavata.model.application.io.ttypes.InputDataObjectType, apache.airavata.model.application.io.ttypes.InputDataObjectType.thrift_spec)), None, ), # 7
- (8, TType.LIST, 'workflowOutputs', (TType.STRUCT,(apache.airavata.model.application.io.ttypes.OutputDataObjectType, apache.airavata.model.application.io.ttypes.OutputDataObjectType.thrift_spec)), None, ), # 8
- (9, TType.I64, 'creationTime', None, None, ), # 9
- )
-
- def __init__(self, templateId=thrift_spec[1][4], name=None, graph=None, gatewayId=None, createdUser=None, image=None, workflowInputs=None, workflowOutputs=None, creationTime=None,):
- self.templateId = templateId
- self.name = name
- self.graph = graph
- self.gatewayId = gatewayId
- self.createdUser = createdUser
- self.image = image
- self.workflowInputs = workflowInputs
- self.workflowOutputs = workflowOutputs
- self.creationTime = creationTime
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.templateId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.name = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.graph = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.createdUser = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.image = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.LIST:
- self.workflowInputs = []
- (_etype3, _size0) = iprot.readListBegin()
- for _i4 in xrange(_size0):
- _elem5 = apache.airavata.model.application.io.ttypes.InputDataObjectType()
- _elem5.read(iprot)
- self.workflowInputs.append(_elem5)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.LIST:
- self.workflowOutputs = []
- (_etype9, _size6) = iprot.readListBegin()
- for _i10 in xrange(_size6):
- _elem11 = apache.airavata.model.application.io.ttypes.OutputDataObjectType()
- _elem11.read(iprot)
- self.workflowOutputs.append(_elem11)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.I64:
- self.creationTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('WorkflowModel')
- if self.templateId is not None:
- oprot.writeFieldBegin('templateId', TType.STRING, 1)
- oprot.writeString(self.templateId)
- oprot.writeFieldEnd()
- if self.name is not None:
- oprot.writeFieldBegin('name', TType.STRING, 2)
- oprot.writeString(self.name)
- oprot.writeFieldEnd()
- if self.graph is not None:
- oprot.writeFieldBegin('graph', TType.STRING, 3)
- oprot.writeString(self.graph)
- oprot.writeFieldEnd()
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 4)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- if self.createdUser is not None:
- oprot.writeFieldBegin('createdUser', TType.STRING, 5)
- oprot.writeString(self.createdUser)
- oprot.writeFieldEnd()
- if self.image is not None:
- oprot.writeFieldBegin('image', TType.STRING, 6)
- oprot.writeString(self.image)
- oprot.writeFieldEnd()
- if self.workflowInputs is not None:
- oprot.writeFieldBegin('workflowInputs', TType.LIST, 7)
- oprot.writeListBegin(TType.STRUCT, len(self.workflowInputs))
- for iter12 in self.workflowInputs:
- iter12.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.workflowOutputs is not None:
- oprot.writeFieldBegin('workflowOutputs', TType.LIST, 8)
- oprot.writeListBegin(TType.STRUCT, len(self.workflowOutputs))
- for iter13 in self.workflowOutputs:
- iter13.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.creationTime is not None:
- oprot.writeFieldBegin('creationTime', TType.I64, 9)
- oprot.writeI64(self.creationTime)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.templateId is None:
- raise TProtocol.TProtocolException(message='Required field templateId is unset!')
- if self.name is None:
- raise TProtocol.TProtocolException(message='Required field name is unset!')
- if self.graph is None:
- raise TProtocol.TProtocolException(message='Required field graph is unset!')
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- if self.createdUser is None:
- raise TProtocol.TProtocolException(message='Required field createdUser is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.templateId)
- value = (value * 31) ^ hash(self.name)
- value = (value * 31) ^ hash(self.graph)
- value = (value * 31) ^ hash(self.gatewayId)
- value = (value * 31) ^ hash(self.createdUser)
- value = (value * 31) ^ hash(self.image)
- value = (value * 31) ^ hash(self.workflowInputs)
- value = (value * 31) ^ hash(self.workflowOutputs)
- value = (value * 31) ^ hash(self.creationTime)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ComponentStatus:
- """
- Attributes:
- - state
- - reason
- - timeofStateChange
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'state', None, 0, ), # 1
- (2, TType.STRING, 'reason', None, None, ), # 2
- (3, TType.I64, 'timeofStateChange', None, None, ), # 3
- )
-
- def __init__(self, state=thrift_spec[1][4], reason=None, timeofStateChange=None,):
- self.state = state
- self.reason = reason
- self.timeofStateChange = timeofStateChange
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.state = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.reason = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.I64:
- self.timeofStateChange = iprot.readI64()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ComponentStatus')
- if self.state is not None:
- oprot.writeFieldBegin('state', TType.I32, 1)
- oprot.writeI32(self.state)
- oprot.writeFieldEnd()
- if self.reason is not None:
- oprot.writeFieldBegin('reason', TType.STRING, 2)
- oprot.writeString(self.reason)
- oprot.writeFieldEnd()
- if self.timeofStateChange is not None:
- oprot.writeFieldBegin('timeofStateChange', TType.I64, 3)
- oprot.writeI64(self.timeofStateChange)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.state is None:
- raise TProtocol.TProtocolException(message='Required field state is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.state)
- value = (value * 31) ^ hash(self.reason)
- value = (value * 31) ^ hash(self.timeofStateChange)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class WorkflowStatus:
- """
- Attributes:
- - state
- - timeOfStateChange
- - reason
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'state', None, None, ), # 1
- (2, TType.I64, 'timeOfStateChange', None, None, ), # 2
- (3, TType.STRING, 'reason', None, None, ), # 3
- )
-
- def __init__(self, state=None, timeOfStateChange=None, reason=None,):
- self.state = state
- self.timeOfStateChange = timeOfStateChange
- self.reason = reason
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.state = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I64:
- self.timeOfStateChange = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.reason = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('WorkflowStatus')
- if self.state is not None:
- oprot.writeFieldBegin('state', TType.I32, 1)
- oprot.writeI32(self.state)
- oprot.writeFieldEnd()
- if self.timeOfStateChange is not None:
- oprot.writeFieldBegin('timeOfStateChange', TType.I64, 2)
- oprot.writeI64(self.timeOfStateChange)
- oprot.writeFieldEnd()
- if self.reason is not None:
- oprot.writeFieldBegin('reason', TType.STRING, 3)
- oprot.writeString(self.reason)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.state is None:
- raise TProtocol.TProtocolException(message='Required field state is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.state)
- value = (value * 31) ^ hash(self.timeOfStateChange)
- value = (value * 31) ^ hash(self.reason)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class EdgeModel:
- """
- Attributes:
- - edgeId
- - name
- - status
- - description
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'edgeId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.STRING, 'name', None, None, ), # 2
- (3, TType.STRUCT, 'status', (ComponentStatus, ComponentStatus.thrift_spec), None, ), # 3
- (4, TType.STRING, 'description', None, None, ), # 4
- )
-
- def __init__(self, edgeId=thrift_spec[1][4], name=None, status=None, description=None,):
- self.edgeId = edgeId
- self.name = name
- self.status = status
- self.description = description
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.edgeId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.name = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRUCT:
- self.status = ComponentStatus()
- self.status.read(iprot)
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.description = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('EdgeModel')
- if self.edgeId is not None:
- oprot.writeFieldBegin('edgeId', TType.STRING, 1)
- oprot.writeString(self.edgeId)
- oprot.writeFieldEnd()
- if self.name is not None:
- oprot.writeFieldBegin('name', TType.STRING, 2)
- oprot.writeString(self.name)
- oprot.writeFieldEnd()
- if self.status is not None:
- oprot.writeFieldBegin('status', TType.STRUCT, 3)
- self.status.write(oprot)
- oprot.writeFieldEnd()
- if self.description is not None:
- oprot.writeFieldBegin('description', TType.STRING, 4)
- oprot.writeString(self.description)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.edgeId is None:
- raise TProtocol.TProtocolException(message='Required field edgeId is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.edgeId)
- value = (value * 31) ^ hash(self.name)
- value = (value * 31) ^ hash(self.status)
- value = (value * 31) ^ hash(self.description)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class PortModel:
- """
- Attributes:
- - portId
- - name
- - status
- - value
- - description
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'portId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.STRING, 'name', None, None, ), # 2
- (3, TType.STRUCT, 'status', (ComponentStatus, ComponentStatus.thrift_spec), None, ), # 3
- (4, TType.STRING, 'value', None, None, ), # 4
- (5, TType.STRING, 'description', None, None, ), # 5
- )
-
- def __init__(self, portId=thrift_spec[1][4], name=None, status=None, value=None, description=None,):
- self.portId = portId
- self.name = name
- self.status = status
- self.value = value
- self.description = description
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.portId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.name = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRUCT:
- self.status = ComponentStatus()
- self.status.read(iprot)
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.value = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.description = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('PortModel')
- if self.portId is not None:
- oprot.writeFieldBegin('portId', TType.STRING, 1)
- oprot.writeString(self.portId)
- oprot.writeFieldEnd()
- if self.name is not None:
- oprot.writeFieldBegin('name', TType.STRING, 2)
- oprot.writeString(self.name)
- oprot.writeFieldEnd()
- if self.status is not None:
- oprot.writeFieldBegin('status', TType.STRUCT, 3)
- self.status.write(oprot)
- oprot.writeFieldEnd()
- if self.value is not None:
- oprot.writeFieldBegin('value', TType.STRING, 4)
- oprot.writeString(self.value)
- oprot.writeFieldEnd()
- if self.description is not None:
- oprot.writeFieldBegin('description', TType.STRING, 5)
- oprot.writeString(self.description)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.portId is None:
- raise TProtocol.TProtocolException(message='Required field portId is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.portId)
- value = (value * 31) ^ hash(self.name)
- value = (value * 31) ^ hash(self.status)
- value = (value * 31) ^ hash(self.value)
- value = (value * 31) ^ hash(self.description)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class NodeModel:
- """
- Attributes:
- - nodeId
- - name
- - applicationId
- - applicationName
- - status
- - description
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'nodeId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.STRING, 'name', None, None, ), # 2
- (3, TType.STRING, 'applicationId', None, None, ), # 3
- (4, TType.STRING, 'applicationName', None, None, ), # 4
- (5, TType.STRUCT, 'status', (ComponentStatus, ComponentStatus.thrift_spec), None, ), # 5
- (6, TType.STRING, 'description', None, None, ), # 6
- )
-
- def __init__(self, nodeId=thrift_spec[1][4], name=None, applicationId=None, applicationName=None, status=None, description=None,):
- self.nodeId = nodeId
- self.name = name
- self.applicationId = applicationId
- self.applicationName = applicationName
- self.status = status
- self.description = description
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.nodeId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.name = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.applicationId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.applicationName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRUCT:
- self.status = ComponentStatus()
- self.status.read(iprot)
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.description = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('NodeModel')
- if self.nodeId is not None:
- oprot.writeFieldBegin('nodeId', TType.STRING, 1)
- oprot.writeString(self.nodeId)
- oprot.writeFieldEnd()
- if self.name is not None:
- oprot.writeFieldBegin('name', TType.STRING, 2)
- oprot.writeString(self.name)
- oprot.writeFieldEnd()
- if self.applicationId is not None:
- oprot.writeFieldBegin('applicationId', TType.STRING, 3)
- oprot.writeString(self.applicationId)
- oprot.writeFieldEnd()
- if self.applicationName is not None:
- oprot.writeFieldBegin('applicationName', TType.STRING, 4)
- oprot.writeString(self.applicationName)
- oprot.writeFieldEnd()
- if self.status is not None:
- oprot.writeFieldBegin('status', TType.STRUCT, 5)
- self.status.write(oprot)
- oprot.writeFieldEnd()
- if self.description is not None:
- oprot.writeFieldBegin('description', TType.STRING, 6)
- oprot.writeString(self.description)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.nodeId is None:
- raise TProtocol.TProtocolException(message='Required field nodeId is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.nodeId)
- value = (value * 31) ^ hash(self.name)
- value = (value * 31) ^ hash(self.applicationId)
- value = (value * 31) ^ hash(self.applicationName)
- value = (value * 31) ^ hash(self.status)
- value = (value * 31) ^ hash(self.description)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class WorkflowState(object):
+ CREATED = 0
+ STARTED = 1
+ EXECUTING = 2
+ COMPLETED = 3
+ FAILED = 4
+ CANCELLING = 5
+ CANCELED = 6
+
+ _VALUES_TO_NAMES = {
+ 0: "CREATED",
+ 1: "STARTED",
+ 2: "EXECUTING",
+ 3: "COMPLETED",
+ 4: "FAILED",
+ 5: "CANCELLING",
+ 6: "CANCELED",
+ }
+
+ _NAMES_TO_VALUES = {
+ "CREATED": 0,
+ "STARTED": 1,
+ "EXECUTING": 2,
+ "COMPLETED": 3,
+ "FAILED": 4,
+ "CANCELLING": 5,
+ "CANCELED": 6,
+ }
+
+
+class ComponentState(object):
+ CREATED = 0
+ WAITING = 1
+ READY = 2
+ RUNNING = 3
+ COMPLETED = 4
+ FAILED = 5
+ CANCELED = 6
+
+ _VALUES_TO_NAMES = {
+ 0: "CREATED",
+ 1: "WAITING",
+ 2: "READY",
+ 3: "RUNNING",
+ 4: "COMPLETED",
+ 5: "FAILED",
+ 6: "CANCELED",
+ }
+
+ _NAMES_TO_VALUES = {
+ "CREATED": 0,
+ "WAITING": 1,
+ "READY": 2,
+ "RUNNING": 3,
+ "COMPLETED": 4,
+ "FAILED": 5,
+ "CANCELED": 6,
+ }
+
+
+class WorkflowModel(object):
+ """
+ Attributes:
+ - templateId
+ - name
+ - graph
+ - gatewayId
+ - createdUser
+ - image
+ - workflowInputs
+ - workflowOutputs
+ - creationTime
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'templateId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.STRING, 'name', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'graph', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'gatewayId', 'UTF8', None, ), # 4
+ (5, TType.STRING, 'createdUser', 'UTF8', None, ), # 5
+ (6, TType.STRING, 'image', 'BINARY', None, ), # 6
+ (7, TType.LIST, 'workflowInputs', (TType.STRUCT, (apache.airavata.model.application.io.ttypes.InputDataObjectType, apache.airavata.model.application.io.ttypes.InputDataObjectType.thrift_spec), False), None, ), # 7
+ (8, TType.LIST, 'workflowOutputs', (TType.STRUCT, (apache.airavata.model.application.io.ttypes.OutputDataObjectType, apache.airavata.model.application.io.ttypes.OutputDataObjectType.thrift_spec), False), None, ), # 8
+ (9, TType.I64, 'creationTime', None, None, ), # 9
+ )
+
+ def __init__(self, templateId=thrift_spec[1][4], name=None, graph=None, gatewayId=None, createdUser=None, image=None, workflowInputs=None, workflowOutputs=None, creationTime=None,):
+ self.templateId = templateId
+ self.name = name
+ self.graph = graph
+ self.gatewayId = gatewayId
+ self.createdUser = createdUser
+ self.image = image
+ self.workflowInputs = workflowInputs
+ self.workflowOutputs = workflowOutputs
+ self.creationTime = creationTime
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.templateId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.name = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.graph = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRING:
+ self.createdUser = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.image = iprot.readBinary()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.LIST:
+ self.workflowInputs = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in range(_size0):
+ _elem5 = apache.airavata.model.application.io.ttypes.InputDataObjectType()
+ _elem5.read(iprot)
+ self.workflowInputs.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.LIST:
+ self.workflowOutputs = []
+ (_etype9, _size6) = iprot.readListBegin()
+ for _i10 in range(_size6):
+ _elem11 = apache.airavata.model.application.io.ttypes.OutputDataObjectType()
+ _elem11.read(iprot)
+ self.workflowOutputs.append(_elem11)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.I64:
+ self.creationTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('WorkflowModel')
+ if self.templateId is not None:
+ oprot.writeFieldBegin('templateId', TType.STRING, 1)
+ oprot.writeString(self.templateId.encode('utf-8') if sys.version_info[0] == 2 else self.templateId)
+ oprot.writeFieldEnd()
+ if self.name is not None:
+ oprot.writeFieldBegin('name', TType.STRING, 2)
+ oprot.writeString(self.name.encode('utf-8') if sys.version_info[0] == 2 else self.name)
+ oprot.writeFieldEnd()
+ if self.graph is not None:
+ oprot.writeFieldBegin('graph', TType.STRING, 3)
+ oprot.writeString(self.graph.encode('utf-8') if sys.version_info[0] == 2 else self.graph)
+ oprot.writeFieldEnd()
+ if self.gatewayId is not None:
+ oprot.writeFieldBegin('gatewayId', TType.STRING, 4)
+ oprot.writeString(self.gatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayId)
+ oprot.writeFieldEnd()
+ if self.createdUser is not None:
+ oprot.writeFieldBegin('createdUser', TType.STRING, 5)
+ oprot.writeString(self.createdUser.encode('utf-8') if sys.version_info[0] == 2 else self.createdUser)
+ oprot.writeFieldEnd()
+ if self.image is not None:
+ oprot.writeFieldBegin('image', TType.STRING, 6)
+ oprot.writeBinary(self.image)
+ oprot.writeFieldEnd()
+ if self.workflowInputs is not None:
+ oprot.writeFieldBegin('workflowInputs', TType.LIST, 7)
+ oprot.writeListBegin(TType.STRUCT, len(self.workflowInputs))
+ for iter12 in self.workflowInputs:
+ iter12.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.workflowOutputs is not None:
+ oprot.writeFieldBegin('workflowOutputs', TType.LIST, 8)
+ oprot.writeListBegin(TType.STRUCT, len(self.workflowOutputs))
+ for iter13 in self.workflowOutputs:
+ iter13.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.creationTime is not None:
+ oprot.writeFieldBegin('creationTime', TType.I64, 9)
+ oprot.writeI64(self.creationTime)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.templateId is None:
+ raise TProtocolException(message='Required field templateId is unset!')
+ if self.name is None:
+ raise TProtocolException(message='Required field name is unset!')
+ if self.graph is None:
+ raise TProtocolException(message='Required field graph is unset!')
+ if self.gatewayId is None:
+ raise TProtocolException(message='Required field gatewayId is unset!')
+ if self.createdUser is None:
+ raise TProtocolException(message='Required field createdUser is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class ComponentStatus(object):
+ """
+ Attributes:
+ - state
+ - reason
+ - timeofStateChange
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'state', None, 0, ), # 1
+ (2, TType.STRING, 'reason', 'UTF8', None, ), # 2
+ (3, TType.I64, 'timeofStateChange', None, None, ), # 3
+ )
+
+ def __init__(self, state=thrift_spec[1][4], reason=None, timeofStateChange=None,):
+ self.state = state
+ self.reason = reason
+ self.timeofStateChange = timeofStateChange
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.state = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.reason = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I64:
+ self.timeofStateChange = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ComponentStatus')
+ if self.state is not None:
+ oprot.writeFieldBegin('state', TType.I32, 1)
+ oprot.writeI32(self.state)
+ oprot.writeFieldEnd()
+ if self.reason is not None:
+ oprot.writeFieldBegin('reason', TType.STRING, 2)
+ oprot.writeString(self.reason.encode('utf-8') if sys.version_info[0] == 2 else self.reason)
+ oprot.writeFieldEnd()
+ if self.timeofStateChange is not None:
+ oprot.writeFieldBegin('timeofStateChange', TType.I64, 3)
+ oprot.writeI64(self.timeofStateChange)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.state is None:
+ raise TProtocolException(message='Required field state is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class WorkflowStatus(object):
+ """
+ Attributes:
+ - state
+ - timeOfStateChange
+ - reason
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'state', None, None, ), # 1
+ (2, TType.I64, 'timeOfStateChange', None, None, ), # 2
+ (3, TType.STRING, 'reason', 'UTF8', None, ), # 3
+ )
+
+ def __init__(self, state=None, timeOfStateChange=None, reason=None,):
+ self.state = state
+ self.timeOfStateChange = timeOfStateChange
+ self.reason = reason
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.state = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I64:
+ self.timeOfStateChange = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.reason = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('WorkflowStatus')
+ if self.state is not None:
+ oprot.writeFieldBegin('state', TType.I32, 1)
+ oprot.writeI32(self.state)
+ oprot.writeFieldEnd()
+ if self.timeOfStateChange is not None:
+ oprot.writeFieldBegin('timeOfStateChange', TType.I64, 2)
+ oprot.writeI64(self.timeOfStateChange)
+ oprot.writeFieldEnd()
+ if self.reason is not None:
+ oprot.writeFieldBegin('reason', TType.STRING, 3)
+ oprot.writeString(self.reason.encode('utf-8') if sys.version_info[0] == 2 else self.reason)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.state is None:
+ raise TProtocolException(message='Required field state is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class EdgeModel(object):
+ """
+ Attributes:
+ - edgeId
+ - name
+ - status
+ - description
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'edgeId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.STRING, 'name', 'UTF8', None, ), # 2
+ (3, TType.STRUCT, 'status', (ComponentStatus, ComponentStatus.thrift_spec), None, ), # 3
+ (4, TType.STRING, 'description', 'UTF8', None, ), # 4
+ )
+
+ def __init__(self, edgeId=thrift_spec[1][4], name=None, status=None, description=None,):
+ self.edgeId = edgeId
+ self.name = name
+ self.status = status
+ self.description = description
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.edgeId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.name = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRUCT:
+ self.status = ComponentStatus()
+ self.status.read(iprot)
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.description = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('EdgeModel')
+ if self.edgeId is not None:
+ oprot.writeFieldBegin('edgeId', TType.STRING, 1)
+ oprot.writeString(self.edgeId.encode('utf-8') if sys.version_info[0] == 2 else self.edgeId)
+ oprot.writeFieldEnd()
+ if self.name is not None:
+ oprot.writeFieldBegin('name', TType.STRING, 2)
+ oprot.writeString(self.name.encode('utf-8') if sys.version_info[0] == 2 else self.name)
+ oprot.writeFieldEnd()
+ if self.status is not None:
+ oprot.writeFieldBegin('status', TType.STRUCT, 3)
+ self.status.write(oprot)
+ oprot.writeFieldEnd()
+ if self.description is not None:
+ oprot.writeFieldBegin('description', TType.STRING, 4)
+ oprot.writeString(self.description.encode('utf-8') if sys.version_info[0] == 2 else self.description)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.edgeId is None:
+ raise TProtocolException(message='Required field edgeId is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class PortModel(object):
+ """
+ Attributes:
+ - portId
+ - name
+ - status
+ - value
+ - description
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'portId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.STRING, 'name', 'UTF8', None, ), # 2
+ (3, TType.STRUCT, 'status', (ComponentStatus, ComponentStatus.thrift_spec), None, ), # 3
+ (4, TType.STRING, 'value', 'UTF8', None, ), # 4
+ (5, TType.STRING, 'description', 'UTF8', None, ), # 5
+ )
+
+ def __init__(self, portId=thrift_spec[1][4], name=None, status=None, value=None, description=None,):
+ self.portId = portId
+ self.name = name
+ self.status = status
+ self.value = value
+ self.description = description
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.portId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.name = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRUCT:
+ self.status = ComponentStatus()
+ self.status.read(iprot)
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.value = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRING:
+ self.description = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('PortModel')
+ if self.portId is not None:
+ oprot.writeFieldBegin('portId', TType.STRING, 1)
+ oprot.writeString(self.portId.encode('utf-8') if sys.version_info[0] == 2 else self.portId)
+ oprot.writeFieldEnd()
+ if self.name is not None:
+ oprot.writeFieldBegin('name', TType.STRING, 2)
+ oprot.writeString(self.name.encode('utf-8') if sys.version_info[0] == 2 else self.name)
+ oprot.writeFieldEnd()
+ if self.status is not None:
+ oprot.writeFieldBegin('status', TType.STRUCT, 3)
+ self.status.write(oprot)
+ oprot.writeFieldEnd()
+ if self.value is not None:
+ oprot.writeFieldBegin('value', TType.STRING, 4)
+ oprot.writeString(self.value.encode('utf-8') if sys.version_info[0] == 2 else self.value)
+ oprot.writeFieldEnd()
+ if self.description is not None:
+ oprot.writeFieldBegin('description', TType.STRING, 5)
+ oprot.writeString(self.description.encode('utf-8') if sys.version_info[0] == 2 else self.description)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.portId is None:
+ raise TProtocolException(message='Required field portId is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class NodeModel(object):
+ """
+ Attributes:
+ - nodeId
+ - name
+ - applicationId
+ - applicationName
+ - status
+ - description
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'nodeId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.STRING, 'name', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'applicationId', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'applicationName', 'UTF8', None, ), # 4
+ (5, TType.STRUCT, 'status', (ComponentStatus, ComponentStatus.thrift_spec), None, ), # 5
+ (6, TType.STRING, 'description', 'UTF8', None, ), # 6
+ )
+
+ def __init__(self, nodeId=thrift_spec[1][4], name=None, applicationId=None, applicationName=None, status=None, description=None,):
+ self.nodeId = nodeId
+ self.name = name
+ self.applicationId = applicationId
+ self.applicationName = applicationName
+ self.status = status
+ self.description = description
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.nodeId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.name = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.applicationId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.applicationName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRUCT:
+ self.status = ComponentStatus()
+ self.status.read(iprot)
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.description = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('NodeModel')
+ if self.nodeId is not None:
+ oprot.writeFieldBegin('nodeId', TType.STRING, 1)
+ oprot.writeString(self.nodeId.encode('utf-8') if sys.version_info[0] == 2 else self.nodeId)
+ oprot.writeFieldEnd()
+ if self.name is not None:
+ oprot.writeFieldBegin('name', TType.STRING, 2)
+ oprot.writeString(self.name.encode('utf-8') if sys.version_info[0] == 2 else self.name)
+ oprot.writeFieldEnd()
+ if self.applicationId is not None:
+ oprot.writeFieldBegin('applicationId', TType.STRING, 3)
+ oprot.writeString(self.applicationId.encode('utf-8') if sys.version_info[0] == 2 else self.applicationId)
+ oprot.writeFieldEnd()
+ if self.applicationName is not None:
+ oprot.writeFieldBegin('applicationName', TType.STRING, 4)
+ oprot.writeString(self.applicationName.encode('utf-8') if sys.version_info[0] == 2 else self.applicationName)
+ oprot.writeFieldEnd()
+ if self.status is not None:
+ oprot.writeFieldBegin('status', TType.STRUCT, 5)
+ self.status.write(oprot)
+ oprot.writeFieldEnd()
+ if self.description is not None:
+ oprot.writeFieldBegin('description', TType.STRING, 6)
+ oprot.writeString(self.description.encode('utf-8') if sys.version_info[0] == 2 else self.description)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.nodeId is None:
+ raise TProtocolException(message='Required field nodeId is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workspace/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workspace/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workspace/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workspace/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workspace/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
[07/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AiravataClientException.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AiravataClientException.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AiravataClientException.java
index dfc6630..74192f1 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AiravataClientException.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AiravataClientException.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.error;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* This exception is thrown by Airavata Services when a call fails as a result of
* a problem that a client may be able to resolve. For example, if the user
@@ -66,21 +39,18 @@ import org.slf4j.LoggerFactory;
* parameter: If the error applied to a particular input parameter, this will
* indicate which parameter.
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
-public class AiravataClientException extends TException implements org.apache.thrift.TBase<AiravataClientException, AiravataClientException._Fields>, java.io.Serializable, Cloneable, Comparable<AiravataClientException> {
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
+public class AiravataClientException extends org.apache.thrift.TException implements org.apache.thrift.TBase<AiravataClientException, AiravataClientException._Fields>, java.io.Serializable, Cloneable, Comparable<AiravataClientException> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("AiravataClientException");
private static final org.apache.thrift.protocol.TField AIRAVATA_ERROR_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("airavataErrorType", org.apache.thrift.protocol.TType.I32, (short)1);
private static final org.apache.thrift.protocol.TField PARAMETER_FIELD_DESC = new org.apache.thrift.protocol.TField("parameter", org.apache.thrift.protocol.TType.STRING, (short)2);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new AiravataClientExceptionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new AiravataClientExceptionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new AiravataClientExceptionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new AiravataClientExceptionTupleSchemeFactory();
private AiravataErrorType airavataErrorType; // required
- private String parameter; // optional
+ private java.lang.String parameter; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -91,10 +61,10 @@ public class AiravataClientException extends TException implements org.apache.th
AIRAVATA_ERROR_TYPE((short)1, "airavataErrorType"),
PARAMETER((short)2, "parameter");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -119,21 +89,21 @@ public class AiravataClientException extends TException implements org.apache.th
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -142,21 +112,21 @@ public class AiravataClientException extends TException implements org.apache.th
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
private static final _Fields optionals[] = {_Fields.PARAMETER};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.AIRAVATA_ERROR_TYPE, new org.apache.thrift.meta_data.FieldMetaData("airavataErrorType", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, AiravataErrorType.class)));
tmpMap.put(_Fields.PARAMETER, new org.apache.thrift.meta_data.FieldMetaData("parameter", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(AiravataClientException.class, metaDataMap);
}
@@ -223,11 +193,11 @@ public class AiravataClientException extends TException implements org.apache.th
}
}
- public String getParameter() {
+ public java.lang.String getParameter() {
return this.parameter;
}
- public void setParameter(String parameter) {
+ public void setParameter(java.lang.String parameter) {
this.parameter = parameter;
}
@@ -246,7 +216,7 @@ public class AiravataClientException extends TException implements org.apache.th
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case AIRAVATA_ERROR_TYPE:
if (value == null) {
@@ -260,14 +230,14 @@ public class AiravataClientException extends TException implements org.apache.th
if (value == null) {
unsetParameter();
} else {
- setParameter((String)value);
+ setParameter((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case AIRAVATA_ERROR_TYPE:
return getAiravataErrorType();
@@ -276,13 +246,13 @@ public class AiravataClientException extends TException implements org.apache.th
return getParameter();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -291,11 +261,11 @@ public class AiravataClientException extends TException implements org.apache.th
case PARAMETER:
return isSetParameter();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof AiravataClientException)
@@ -306,6 +276,8 @@ public class AiravataClientException extends TException implements org.apache.th
public boolean equals(AiravataClientException that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_airavataErrorType = true && this.isSetAiravataErrorType();
boolean that_present_airavataErrorType = true && that.isSetAiravataErrorType();
@@ -330,19 +302,17 @@ public class AiravataClientException extends TException implements org.apache.th
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_airavataErrorType = true && (isSetAiravataErrorType());
- list.add(present_airavataErrorType);
- if (present_airavataErrorType)
- list.add(airavataErrorType.getValue());
+ hashCode = hashCode * 8191 + ((isSetAiravataErrorType()) ? 131071 : 524287);
+ if (isSetAiravataErrorType())
+ hashCode = hashCode * 8191 + airavataErrorType.getValue();
- boolean present_parameter = true && (isSetParameter());
- list.add(present_parameter);
- if (present_parameter)
- list.add(parameter);
+ hashCode = hashCode * 8191 + ((isSetParameter()) ? 131071 : 524287);
+ if (isSetParameter())
+ hashCode = hashCode * 8191 + parameter.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -353,7 +323,7 @@ public class AiravataClientException extends TException implements org.apache.th
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetAiravataErrorType()).compareTo(other.isSetAiravataErrorType());
+ lastComparison = java.lang.Boolean.valueOf(isSetAiravataErrorType()).compareTo(other.isSetAiravataErrorType());
if (lastComparison != 0) {
return lastComparison;
}
@@ -363,7 +333,7 @@ public class AiravataClientException extends TException implements org.apache.th
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetParameter()).compareTo(other.isSetParameter());
+ lastComparison = java.lang.Boolean.valueOf(isSetParameter()).compareTo(other.isSetParameter());
if (lastComparison != 0) {
return lastComparison;
}
@@ -381,16 +351,16 @@ public class AiravataClientException extends TException implements org.apache.th
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("AiravataClientException(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("AiravataClientException(");
boolean first = true;
sb.append("airavataErrorType:");
@@ -431,7 +401,7 @@ public class AiravataClientException extends TException implements org.apache.th
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -439,13 +409,13 @@ public class AiravataClientException extends TException implements org.apache.th
}
}
- private static class AiravataClientExceptionStandardSchemeFactory implements SchemeFactory {
+ private static class AiravataClientExceptionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public AiravataClientExceptionStandardScheme getScheme() {
return new AiravataClientExceptionStandardScheme();
}
}
- private static class AiravataClientExceptionStandardScheme extends StandardScheme<AiravataClientException> {
+ private static class AiravataClientExceptionStandardScheme extends org.apache.thrift.scheme.StandardScheme<AiravataClientException> {
public void read(org.apache.thrift.protocol.TProtocol iprot, AiravataClientException struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -504,19 +474,19 @@ public class AiravataClientException extends TException implements org.apache.th
}
- private static class AiravataClientExceptionTupleSchemeFactory implements SchemeFactory {
+ private static class AiravataClientExceptionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public AiravataClientExceptionTupleScheme getScheme() {
return new AiravataClientExceptionTupleScheme();
}
}
- private static class AiravataClientExceptionTupleScheme extends TupleScheme<AiravataClientException> {
+ private static class AiravataClientExceptionTupleScheme extends org.apache.thrift.scheme.TupleScheme<AiravataClientException> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, AiravataClientException struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeI32(struct.airavataErrorType.getValue());
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetParameter()) {
optionals.set(0);
}
@@ -528,10 +498,10 @@ public class AiravataClientException extends TException implements org.apache.th
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, AiravataClientException struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.airavataErrorType = org.apache.airavata.model.error.AiravataErrorType.findByValue(iprot.readI32());
struct.setAiravataErrorTypeIsSet(true);
- BitSet incoming = iprot.readBitSet(1);
+ java.util.BitSet incoming = iprot.readBitSet(1);
if (incoming.get(0)) {
struct.parameter = iprot.readString();
struct.setParameterIsSet(true);
@@ -539,5 +509,8 @@ public class AiravataClientException extends TException implements org.apache.th
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AiravataErrorType.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AiravataErrorType.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AiravataErrorType.java
index 323195f..320f88a 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AiravataErrorType.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AiravataErrorType.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AiravataSystemException.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AiravataSystemException.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AiravataSystemException.java
index feb658c..ec00625 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AiravataSystemException.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AiravataSystemException.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.error;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* This exception is thrown by Airavata Services when a call fails as a result of
* a problem in the service that could not be changed through client's action.
@@ -61,21 +34,18 @@ import org.slf4j.LoggerFactory;
* message: This may contain additional information about the error
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
-public class AiravataSystemException extends TException implements org.apache.thrift.TBase<AiravataSystemException, AiravataSystemException._Fields>, java.io.Serializable, Cloneable, Comparable<AiravataSystemException> {
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
+public class AiravataSystemException extends org.apache.thrift.TException implements org.apache.thrift.TBase<AiravataSystemException, AiravataSystemException._Fields>, java.io.Serializable, Cloneable, Comparable<AiravataSystemException> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("AiravataSystemException");
private static final org.apache.thrift.protocol.TField AIRAVATA_ERROR_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("airavataErrorType", org.apache.thrift.protocol.TType.I32, (short)1);
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)2);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new AiravataSystemExceptionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new AiravataSystemExceptionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new AiravataSystemExceptionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new AiravataSystemExceptionTupleSchemeFactory();
private AiravataErrorType airavataErrorType; // required
- private String message; // optional
+ private java.lang.String message; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -86,10 +56,10 @@ public class AiravataSystemException extends TException implements org.apache.th
AIRAVATA_ERROR_TYPE((short)1, "airavataErrorType"),
MESSAGE((short)2, "message");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -114,21 +84,21 @@ public class AiravataSystemException extends TException implements org.apache.th
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -137,21 +107,21 @@ public class AiravataSystemException extends TException implements org.apache.th
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
private static final _Fields optionals[] = {_Fields.MESSAGE};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.AIRAVATA_ERROR_TYPE, new org.apache.thrift.meta_data.FieldMetaData("airavataErrorType", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, AiravataErrorType.class)));
tmpMap.put(_Fields.MESSAGE, new org.apache.thrift.meta_data.FieldMetaData("message", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(AiravataSystemException.class, metaDataMap);
}
@@ -218,11 +188,11 @@ public class AiravataSystemException extends TException implements org.apache.th
}
}
- public String getMessage() {
+ public java.lang.String getMessage() {
return this.message;
}
- public void setMessage(String message) {
+ public void setMessage(java.lang.String message) {
this.message = message;
}
@@ -241,7 +211,7 @@ public class AiravataSystemException extends TException implements org.apache.th
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case AIRAVATA_ERROR_TYPE:
if (value == null) {
@@ -255,14 +225,14 @@ public class AiravataSystemException extends TException implements org.apache.th
if (value == null) {
unsetMessage();
} else {
- setMessage((String)value);
+ setMessage((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case AIRAVATA_ERROR_TYPE:
return getAiravataErrorType();
@@ -271,13 +241,13 @@ public class AiravataSystemException extends TException implements org.apache.th
return getMessage();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -286,11 +256,11 @@ public class AiravataSystemException extends TException implements org.apache.th
case MESSAGE:
return isSetMessage();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof AiravataSystemException)
@@ -301,6 +271,8 @@ public class AiravataSystemException extends TException implements org.apache.th
public boolean equals(AiravataSystemException that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_airavataErrorType = true && this.isSetAiravataErrorType();
boolean that_present_airavataErrorType = true && that.isSetAiravataErrorType();
@@ -325,19 +297,17 @@ public class AiravataSystemException extends TException implements org.apache.th
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_airavataErrorType = true && (isSetAiravataErrorType());
- list.add(present_airavataErrorType);
- if (present_airavataErrorType)
- list.add(airavataErrorType.getValue());
+ hashCode = hashCode * 8191 + ((isSetAiravataErrorType()) ? 131071 : 524287);
+ if (isSetAiravataErrorType())
+ hashCode = hashCode * 8191 + airavataErrorType.getValue();
- boolean present_message = true && (isSetMessage());
- list.add(present_message);
- if (present_message)
- list.add(message);
+ hashCode = hashCode * 8191 + ((isSetMessage()) ? 131071 : 524287);
+ if (isSetMessage())
+ hashCode = hashCode * 8191 + message.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -348,7 +318,7 @@ public class AiravataSystemException extends TException implements org.apache.th
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetAiravataErrorType()).compareTo(other.isSetAiravataErrorType());
+ lastComparison = java.lang.Boolean.valueOf(isSetAiravataErrorType()).compareTo(other.isSetAiravataErrorType());
if (lastComparison != 0) {
return lastComparison;
}
@@ -358,7 +328,7 @@ public class AiravataSystemException extends TException implements org.apache.th
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetMessage()).compareTo(other.isSetMessage());
+ lastComparison = java.lang.Boolean.valueOf(isSetMessage()).compareTo(other.isSetMessage());
if (lastComparison != 0) {
return lastComparison;
}
@@ -376,16 +346,16 @@ public class AiravataSystemException extends TException implements org.apache.th
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("AiravataSystemException(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("AiravataSystemException(");
boolean first = true;
sb.append("airavataErrorType:");
@@ -426,7 +396,7 @@ public class AiravataSystemException extends TException implements org.apache.th
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -434,13 +404,13 @@ public class AiravataSystemException extends TException implements org.apache.th
}
}
- private static class AiravataSystemExceptionStandardSchemeFactory implements SchemeFactory {
+ private static class AiravataSystemExceptionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public AiravataSystemExceptionStandardScheme getScheme() {
return new AiravataSystemExceptionStandardScheme();
}
}
- private static class AiravataSystemExceptionStandardScheme extends StandardScheme<AiravataSystemException> {
+ private static class AiravataSystemExceptionStandardScheme extends org.apache.thrift.scheme.StandardScheme<AiravataSystemException> {
public void read(org.apache.thrift.protocol.TProtocol iprot, AiravataSystemException struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -499,19 +469,19 @@ public class AiravataSystemException extends TException implements org.apache.th
}
- private static class AiravataSystemExceptionTupleSchemeFactory implements SchemeFactory {
+ private static class AiravataSystemExceptionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public AiravataSystemExceptionTupleScheme getScheme() {
return new AiravataSystemExceptionTupleScheme();
}
}
- private static class AiravataSystemExceptionTupleScheme extends TupleScheme<AiravataSystemException> {
+ private static class AiravataSystemExceptionTupleScheme extends org.apache.thrift.scheme.TupleScheme<AiravataSystemException> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, AiravataSystemException struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeI32(struct.airavataErrorType.getValue());
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetMessage()) {
optionals.set(0);
}
@@ -523,10 +493,10 @@ public class AiravataSystemException extends TException implements org.apache.th
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, AiravataSystemException struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.airavataErrorType = org.apache.airavata.model.error.AiravataErrorType.findByValue(iprot.readI32());
struct.setAiravataErrorTypeIsSet(true);
- BitSet incoming = iprot.readBitSet(1);
+ java.util.BitSet incoming = iprot.readBitSet(1);
if (incoming.get(0)) {
struct.message = iprot.readString();
struct.setMessageIsSet(true);
@@ -534,5 +504,8 @@ public class AiravataSystemException extends TException implements org.apache.th
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AuthenticationException.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AuthenticationException.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AuthenticationException.java
index 8d45a52..1aa546f 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AuthenticationException.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AuthenticationException.java
@@ -16,68 +16,38 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.error;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* This exception is thrown for invalid sshKeyAuthentication requests.
*
* message: contains the cause of the authorization failure.
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
-public class AuthenticationException extends TException implements org.apache.thrift.TBase<AuthenticationException, AuthenticationException._Fields>, java.io.Serializable, Cloneable, Comparable<AuthenticationException> {
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
+public class AuthenticationException extends org.apache.thrift.TException implements org.apache.thrift.TBase<AuthenticationException, AuthenticationException._Fields>, java.io.Serializable, Cloneable, Comparable<AuthenticationException> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("AuthenticationException");
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 AuthenticationExceptionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new AuthenticationExceptionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new AuthenticationExceptionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new AuthenticationExceptionTupleSchemeFactory();
- private String message; // required
+ private java.lang.String message; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
MESSAGE((short)1, "message");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -100,21 +70,21 @@ public class AuthenticationException extends TException implements org.apache.th
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -123,18 +93,18 @@ public class AuthenticationException extends TException implements org.apache.th
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.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);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(AuthenticationException.class, metaDataMap);
}
@@ -142,7 +112,7 @@ public class AuthenticationException extends TException implements org.apache.th
}
public AuthenticationException(
- String message)
+ java.lang.String message)
{
this();
this.message = message;
@@ -166,11 +136,11 @@ public class AuthenticationException extends TException implements org.apache.th
this.message = null;
}
- public String getMessage() {
+ public java.lang.String getMessage() {
return this.message;
}
- public void setMessage(String message) {
+ public void setMessage(java.lang.String message) {
this.message = message;
}
@@ -189,43 +159,43 @@ public class AuthenticationException extends TException implements org.apache.th
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case MESSAGE:
if (value == null) {
unsetMessage();
} else {
- setMessage((String)value);
+ setMessage((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case MESSAGE:
return getMessage();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
case MESSAGE:
return isSetMessage();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof AuthenticationException)
@@ -236,6 +206,8 @@ public class AuthenticationException extends TException implements org.apache.th
public boolean equals(AuthenticationException that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_message = true && this.isSetMessage();
boolean that_present_message = true && that.isSetMessage();
@@ -251,14 +223,13 @@ public class AuthenticationException extends TException implements org.apache.th
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_message = true && (isSetMessage());
- list.add(present_message);
- if (present_message)
- list.add(message);
+ hashCode = hashCode * 8191 + ((isSetMessage()) ? 131071 : 524287);
+ if (isSetMessage())
+ hashCode = hashCode * 8191 + message.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -269,7 +240,7 @@ public class AuthenticationException extends TException implements org.apache.th
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetMessage()).compareTo(other.isSetMessage());
+ lastComparison = java.lang.Boolean.valueOf(isSetMessage()).compareTo(other.isSetMessage());
if (lastComparison != 0) {
return lastComparison;
}
@@ -287,16 +258,16 @@ public class AuthenticationException extends TException implements org.apache.th
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("AuthenticationException(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("AuthenticationException(");
boolean first = true;
sb.append("message:");
@@ -327,7 +298,7 @@ public class AuthenticationException extends TException implements org.apache.th
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -335,13 +306,13 @@ public class AuthenticationException extends TException implements org.apache.th
}
}
- private static class AuthenticationExceptionStandardSchemeFactory implements SchemeFactory {
+ private static class AuthenticationExceptionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public AuthenticationExceptionStandardScheme getScheme() {
return new AuthenticationExceptionStandardScheme();
}
}
- private static class AuthenticationExceptionStandardScheme extends StandardScheme<AuthenticationException> {
+ private static class AuthenticationExceptionStandardScheme extends org.apache.thrift.scheme.StandardScheme<AuthenticationException> {
public void read(org.apache.thrift.protocol.TProtocol iprot, AuthenticationException struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -385,27 +356,30 @@ public class AuthenticationException extends TException implements org.apache.th
}
- private static class AuthenticationExceptionTupleSchemeFactory implements SchemeFactory {
+ private static class AuthenticationExceptionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public AuthenticationExceptionTupleScheme getScheme() {
return new AuthenticationExceptionTupleScheme();
}
}
- private static class AuthenticationExceptionTupleScheme extends TupleScheme<AuthenticationException> {
+ private static class AuthenticationExceptionTupleScheme extends org.apache.thrift.scheme.TupleScheme<AuthenticationException> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, AuthenticationException struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.message);
}
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, AuthenticationException struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.message = iprot.readString();
struct.setMessageIsSet(true);
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AuthorizationException.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AuthorizationException.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AuthorizationException.java
index bc27ae6..8c1725c 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AuthorizationException.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/AuthorizationException.java
@@ -16,68 +16,38 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.error;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* This exception is thrown for invalid authorization requests such user does not have acces to an aplication or resource.
*
* message: contains the authorization failure message
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
-public class AuthorizationException extends TException implements org.apache.thrift.TBase<AuthorizationException, AuthorizationException._Fields>, java.io.Serializable, Cloneable, Comparable<AuthorizationException> {
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
+public class AuthorizationException extends org.apache.thrift.TException implements org.apache.thrift.TBase<AuthorizationException, AuthorizationException._Fields>, java.io.Serializable, Cloneable, Comparable<AuthorizationException> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("AuthorizationException");
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 AuthorizationExceptionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new AuthorizationExceptionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new AuthorizationExceptionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new AuthorizationExceptionTupleSchemeFactory();
- private String message; // required
+ private java.lang.String message; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
MESSAGE((short)1, "message");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -100,21 +70,21 @@ public class AuthorizationException extends TException implements org.apache.thr
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -123,18 +93,18 @@ public class AuthorizationException extends TException implements org.apache.thr
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.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);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(AuthorizationException.class, metaDataMap);
}
@@ -142,7 +112,7 @@ public class AuthorizationException extends TException implements org.apache.thr
}
public AuthorizationException(
- String message)
+ java.lang.String message)
{
this();
this.message = message;
@@ -166,11 +136,11 @@ public class AuthorizationException extends TException implements org.apache.thr
this.message = null;
}
- public String getMessage() {
+ public java.lang.String getMessage() {
return this.message;
}
- public void setMessage(String message) {
+ public void setMessage(java.lang.String message) {
this.message = message;
}
@@ -189,43 +159,43 @@ public class AuthorizationException extends TException implements org.apache.thr
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case MESSAGE:
if (value == null) {
unsetMessage();
} else {
- setMessage((String)value);
+ setMessage((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case MESSAGE:
return getMessage();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
case MESSAGE:
return isSetMessage();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof AuthorizationException)
@@ -236,6 +206,8 @@ public class AuthorizationException extends TException implements org.apache.thr
public boolean equals(AuthorizationException that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_message = true && this.isSetMessage();
boolean that_present_message = true && that.isSetMessage();
@@ -251,14 +223,13 @@ public class AuthorizationException extends TException implements org.apache.thr
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_message = true && (isSetMessage());
- list.add(present_message);
- if (present_message)
- list.add(message);
+ hashCode = hashCode * 8191 + ((isSetMessage()) ? 131071 : 524287);
+ if (isSetMessage())
+ hashCode = hashCode * 8191 + message.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -269,7 +240,7 @@ public class AuthorizationException extends TException implements org.apache.thr
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetMessage()).compareTo(other.isSetMessage());
+ lastComparison = java.lang.Boolean.valueOf(isSetMessage()).compareTo(other.isSetMessage());
if (lastComparison != 0) {
return lastComparison;
}
@@ -287,16 +258,16 @@ public class AuthorizationException extends TException implements org.apache.thr
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("AuthorizationException(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("AuthorizationException(");
boolean first = true;
sb.append("message:");
@@ -327,7 +298,7 @@ public class AuthorizationException extends TException implements org.apache.thr
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -335,13 +306,13 @@ public class AuthorizationException extends TException implements org.apache.thr
}
}
- private static class AuthorizationExceptionStandardSchemeFactory implements SchemeFactory {
+ private static class AuthorizationExceptionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public AuthorizationExceptionStandardScheme getScheme() {
return new AuthorizationExceptionStandardScheme();
}
}
- private static class AuthorizationExceptionStandardScheme extends StandardScheme<AuthorizationException> {
+ private static class AuthorizationExceptionStandardScheme extends org.apache.thrift.scheme.StandardScheme<AuthorizationException> {
public void read(org.apache.thrift.protocol.TProtocol iprot, AuthorizationException struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -385,27 +356,30 @@ public class AuthorizationException extends TException implements org.apache.thr
}
- private static class AuthorizationExceptionTupleSchemeFactory implements SchemeFactory {
+ private static class AuthorizationExceptionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public AuthorizationExceptionTupleScheme getScheme() {
return new AuthorizationExceptionTupleScheme();
}
}
- private static class AuthorizationExceptionTupleScheme extends TupleScheme<AuthorizationException> {
+ private static class AuthorizationExceptionTupleScheme extends org.apache.thrift.scheme.TupleScheme<AuthorizationException> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, AuthorizationException struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.message);
}
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, AuthorizationException struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.message = iprot.readString();
struct.setMessageIsSet(true);
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/DuplicateEntryException.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/DuplicateEntryException.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/DuplicateEntryException.java
index 27b3947..a22dcc8 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/DuplicateEntryException.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/DuplicateEntryException.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.error;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* This exception is thrown when you try to save a duplicate entity that already exists
* in the database.
@@ -58,28 +31,25 @@ import org.slf4j.LoggerFactory;
* message: contains the associated error message
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
-public class DuplicateEntryException extends TException implements org.apache.thrift.TBase<DuplicateEntryException, DuplicateEntryException._Fields>, java.io.Serializable, Cloneable, Comparable<DuplicateEntryException> {
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
+public class DuplicateEntryException extends org.apache.thrift.TException implements org.apache.thrift.TBase<DuplicateEntryException, DuplicateEntryException._Fields>, java.io.Serializable, Cloneable, Comparable<DuplicateEntryException> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("DuplicateEntryException");
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 DuplicateEntryExceptionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new DuplicateEntryExceptionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new DuplicateEntryExceptionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new DuplicateEntryExceptionTupleSchemeFactory();
- private String message; // required
+ private java.lang.String message; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
MESSAGE((short)1, "message");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -102,21 +72,21 @@ public class DuplicateEntryException extends TException implements org.apache.th
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -125,18 +95,18 @@ public class DuplicateEntryException extends TException implements org.apache.th
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.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);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(DuplicateEntryException.class, metaDataMap);
}
@@ -144,7 +114,7 @@ public class DuplicateEntryException extends TException implements org.apache.th
}
public DuplicateEntryException(
- String message)
+ java.lang.String message)
{
this();
this.message = message;
@@ -168,11 +138,11 @@ public class DuplicateEntryException extends TException implements org.apache.th
this.message = null;
}
- public String getMessage() {
+ public java.lang.String getMessage() {
return this.message;
}
- public void setMessage(String message) {
+ public void setMessage(java.lang.String message) {
this.message = message;
}
@@ -191,43 +161,43 @@ public class DuplicateEntryException extends TException implements org.apache.th
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case MESSAGE:
if (value == null) {
unsetMessage();
} else {
- setMessage((String)value);
+ setMessage((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case MESSAGE:
return getMessage();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
case MESSAGE:
return isSetMessage();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof DuplicateEntryException)
@@ -238,6 +208,8 @@ public class DuplicateEntryException extends TException implements org.apache.th
public boolean equals(DuplicateEntryException that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_message = true && this.isSetMessage();
boolean that_present_message = true && that.isSetMessage();
@@ -253,14 +225,13 @@ public class DuplicateEntryException extends TException implements org.apache.th
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_message = true && (isSetMessage());
- list.add(present_message);
- if (present_message)
- list.add(message);
+ hashCode = hashCode * 8191 + ((isSetMessage()) ? 131071 : 524287);
+ if (isSetMessage())
+ hashCode = hashCode * 8191 + message.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -271,7 +242,7 @@ public class DuplicateEntryException extends TException implements org.apache.th
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetMessage()).compareTo(other.isSetMessage());
+ lastComparison = java.lang.Boolean.valueOf(isSetMessage()).compareTo(other.isSetMessage());
if (lastComparison != 0) {
return lastComparison;
}
@@ -289,16 +260,16 @@ public class DuplicateEntryException extends TException implements org.apache.th
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("DuplicateEntryException(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("DuplicateEntryException(");
boolean first = true;
sb.append("message:");
@@ -329,7 +300,7 @@ public class DuplicateEntryException extends TException implements org.apache.th
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -337,13 +308,13 @@ public class DuplicateEntryException extends TException implements org.apache.th
}
}
- private static class DuplicateEntryExceptionStandardSchemeFactory implements SchemeFactory {
+ private static class DuplicateEntryExceptionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public DuplicateEntryExceptionStandardScheme getScheme() {
return new DuplicateEntryExceptionStandardScheme();
}
}
- private static class DuplicateEntryExceptionStandardScheme extends StandardScheme<DuplicateEntryException> {
+ private static class DuplicateEntryExceptionStandardScheme extends org.apache.thrift.scheme.StandardScheme<DuplicateEntryException> {
public void read(org.apache.thrift.protocol.TProtocol iprot, DuplicateEntryException struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -387,27 +358,30 @@ public class DuplicateEntryException extends TException implements org.apache.th
}
- private static class DuplicateEntryExceptionTupleSchemeFactory implements SchemeFactory {
+ private static class DuplicateEntryExceptionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public DuplicateEntryExceptionTupleScheme getScheme() {
return new DuplicateEntryExceptionTupleScheme();
}
}
- private static class DuplicateEntryExceptionTupleScheme extends TupleScheme<DuplicateEntryException> {
+ private static class DuplicateEntryExceptionTupleScheme extends org.apache.thrift.scheme.TupleScheme<DuplicateEntryException> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, DuplicateEntryException struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.message);
}
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, DuplicateEntryException struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.message = iprot.readString();
struct.setMessageIsSet(true);
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
[02/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/UserConfigurationDataModel.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/UserConfigurationDataModel.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/UserConfigurationDataModel.java
index 664c922..ccef706 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/UserConfigurationDataModel.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/UserConfigurationDataModel.java
@@ -16,47 +16,20 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.experiment;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* A structure holding the experiment configuration.
*
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserConfigurationDataModel, UserConfigurationDataModel._Fields>, java.io.Serializable, Cloneable, Comparable<UserConfigurationDataModel> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("UserConfigurationDataModel");
@@ -71,21 +44,18 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
private static final org.apache.thrift.protocol.TField EXPERIMENT_DATA_DIR_FIELD_DESC = new org.apache.thrift.protocol.TField("experimentDataDir", org.apache.thrift.protocol.TType.STRING, (short)9);
private static final org.apache.thrift.protocol.TField USE_USER_CRPREF_FIELD_DESC = new org.apache.thrift.protocol.TField("useUserCRPref", org.apache.thrift.protocol.TType.BOOL, (short)10);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new UserConfigurationDataModelStandardSchemeFactory());
- schemes.put(TupleScheme.class, new UserConfigurationDataModelTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new UserConfigurationDataModelStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new UserConfigurationDataModelTupleSchemeFactory();
private boolean airavataAutoSchedule; // required
private boolean overrideManualScheduledParams; // required
private boolean shareExperimentPublicly; // optional
private org.apache.airavata.model.scheduling.ComputationalResourceSchedulingModel computationalResourceScheduling; // optional
private boolean throttleResources; // optional
- private String userDN; // optional
+ private java.lang.String userDN; // optional
private boolean generateCert; // optional
- private String storageId; // optional
- private String experimentDataDir; // optional
+ private java.lang.String storageId; // optional
+ private java.lang.String experimentDataDir; // optional
private boolean useUserCRPref; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
@@ -101,10 +71,10 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
EXPERIMENT_DATA_DIR((short)9, "experimentDataDir"),
USE_USER_CRPREF((short)10, "useUserCRPref");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -145,21 +115,21 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -168,7 +138,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -182,9 +152,9 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
private static final int __USEUSERCRPREF_ISSET_ID = 5;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.SHARE_EXPERIMENT_PUBLICLY,_Fields.COMPUTATIONAL_RESOURCE_SCHEDULING,_Fields.THROTTLE_RESOURCES,_Fields.USER_DN,_Fields.GENERATE_CERT,_Fields.STORAGE_ID,_Fields.EXPERIMENT_DATA_DIR,_Fields.USE_USER_CRPREF};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.AIRAVATA_AUTO_SCHEDULE, new org.apache.thrift.meta_data.FieldMetaData("airavataAutoSchedule", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
tmpMap.put(_Fields.OVERRIDE_MANUAL_SCHEDULED_PARAMS, new org.apache.thrift.meta_data.FieldMetaData("overrideManualScheduledParams", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -205,7 +175,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.USE_USER_CRPREF, new org.apache.thrift.meta_data.FieldMetaData("useUserCRPref", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(UserConfigurationDataModel.class, metaDataMap);
}
@@ -292,16 +262,16 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
}
public void unsetAiravataAutoSchedule() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __AIRAVATAAUTOSCHEDULE_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __AIRAVATAAUTOSCHEDULE_ISSET_ID);
}
/** Returns true if field airavataAutoSchedule is set (has been assigned a value) and false otherwise */
public boolean isSetAiravataAutoSchedule() {
- return EncodingUtils.testBit(__isset_bitfield, __AIRAVATAAUTOSCHEDULE_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __AIRAVATAAUTOSCHEDULE_ISSET_ID);
}
public void setAiravataAutoScheduleIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __AIRAVATAAUTOSCHEDULE_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __AIRAVATAAUTOSCHEDULE_ISSET_ID, value);
}
public boolean isOverrideManualScheduledParams() {
@@ -314,16 +284,16 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
}
public void unsetOverrideManualScheduledParams() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __OVERRIDEMANUALSCHEDULEDPARAMS_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __OVERRIDEMANUALSCHEDULEDPARAMS_ISSET_ID);
}
/** Returns true if field overrideManualScheduledParams is set (has been assigned a value) and false otherwise */
public boolean isSetOverrideManualScheduledParams() {
- return EncodingUtils.testBit(__isset_bitfield, __OVERRIDEMANUALSCHEDULEDPARAMS_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __OVERRIDEMANUALSCHEDULEDPARAMS_ISSET_ID);
}
public void setOverrideManualScheduledParamsIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __OVERRIDEMANUALSCHEDULEDPARAMS_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __OVERRIDEMANUALSCHEDULEDPARAMS_ISSET_ID, value);
}
public boolean isShareExperimentPublicly() {
@@ -336,16 +306,16 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
}
public void unsetShareExperimentPublicly() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __SHAREEXPERIMENTPUBLICLY_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __SHAREEXPERIMENTPUBLICLY_ISSET_ID);
}
/** Returns true if field shareExperimentPublicly is set (has been assigned a value) and false otherwise */
public boolean isSetShareExperimentPublicly() {
- return EncodingUtils.testBit(__isset_bitfield, __SHAREEXPERIMENTPUBLICLY_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __SHAREEXPERIMENTPUBLICLY_ISSET_ID);
}
public void setShareExperimentPubliclyIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SHAREEXPERIMENTPUBLICLY_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __SHAREEXPERIMENTPUBLICLY_ISSET_ID, value);
}
public org.apache.airavata.model.scheduling.ComputationalResourceSchedulingModel getComputationalResourceScheduling() {
@@ -381,23 +351,23 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
}
public void unsetThrottleResources() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __THROTTLERESOURCES_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __THROTTLERESOURCES_ISSET_ID);
}
/** Returns true if field throttleResources is set (has been assigned a value) and false otherwise */
public boolean isSetThrottleResources() {
- return EncodingUtils.testBit(__isset_bitfield, __THROTTLERESOURCES_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __THROTTLERESOURCES_ISSET_ID);
}
public void setThrottleResourcesIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __THROTTLERESOURCES_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __THROTTLERESOURCES_ISSET_ID, value);
}
- public String getUserDN() {
+ public java.lang.String getUserDN() {
return this.userDN;
}
- public void setUserDN(String userDN) {
+ public void setUserDN(java.lang.String userDN) {
this.userDN = userDN;
}
@@ -426,23 +396,23 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
}
public void unsetGenerateCert() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __GENERATECERT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __GENERATECERT_ISSET_ID);
}
/** Returns true if field generateCert is set (has been assigned a value) and false otherwise */
public boolean isSetGenerateCert() {
- return EncodingUtils.testBit(__isset_bitfield, __GENERATECERT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __GENERATECERT_ISSET_ID);
}
public void setGenerateCertIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __GENERATECERT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __GENERATECERT_ISSET_ID, value);
}
- public String getStorageId() {
+ public java.lang.String getStorageId() {
return this.storageId;
}
- public void setStorageId(String storageId) {
+ public void setStorageId(java.lang.String storageId) {
this.storageId = storageId;
}
@@ -461,11 +431,11 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
}
}
- public String getExperimentDataDir() {
+ public java.lang.String getExperimentDataDir() {
return this.experimentDataDir;
}
- public void setExperimentDataDir(String experimentDataDir) {
+ public void setExperimentDataDir(java.lang.String experimentDataDir) {
this.experimentDataDir = experimentDataDir;
}
@@ -494,25 +464,25 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
}
public void unsetUseUserCRPref() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __USEUSERCRPREF_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __USEUSERCRPREF_ISSET_ID);
}
/** Returns true if field useUserCRPref is set (has been assigned a value) and false otherwise */
public boolean isSetUseUserCRPref() {
- return EncodingUtils.testBit(__isset_bitfield, __USEUSERCRPREF_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __USEUSERCRPREF_ISSET_ID);
}
public void setUseUserCRPrefIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __USEUSERCRPREF_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __USEUSERCRPREF_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case AIRAVATA_AUTO_SCHEDULE:
if (value == null) {
unsetAiravataAutoSchedule();
} else {
- setAiravataAutoSchedule((Boolean)value);
+ setAiravataAutoSchedule((java.lang.Boolean)value);
}
break;
@@ -520,7 +490,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
if (value == null) {
unsetOverrideManualScheduledParams();
} else {
- setOverrideManualScheduledParams((Boolean)value);
+ setOverrideManualScheduledParams((java.lang.Boolean)value);
}
break;
@@ -528,7 +498,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
if (value == null) {
unsetShareExperimentPublicly();
} else {
- setShareExperimentPublicly((Boolean)value);
+ setShareExperimentPublicly((java.lang.Boolean)value);
}
break;
@@ -544,7 +514,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
if (value == null) {
unsetThrottleResources();
} else {
- setThrottleResources((Boolean)value);
+ setThrottleResources((java.lang.Boolean)value);
}
break;
@@ -552,7 +522,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
if (value == null) {
unsetUserDN();
} else {
- setUserDN((String)value);
+ setUserDN((java.lang.String)value);
}
break;
@@ -560,7 +530,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
if (value == null) {
unsetGenerateCert();
} else {
- setGenerateCert((Boolean)value);
+ setGenerateCert((java.lang.Boolean)value);
}
break;
@@ -568,7 +538,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
if (value == null) {
unsetStorageId();
} else {
- setStorageId((String)value);
+ setStorageId((java.lang.String)value);
}
break;
@@ -576,7 +546,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
if (value == null) {
unsetExperimentDataDir();
} else {
- setExperimentDataDir((String)value);
+ setExperimentDataDir((java.lang.String)value);
}
break;
@@ -584,14 +554,14 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
if (value == null) {
unsetUseUserCRPref();
} else {
- setUseUserCRPref((Boolean)value);
+ setUseUserCRPref((java.lang.Boolean)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case AIRAVATA_AUTO_SCHEDULE:
return isAiravataAutoSchedule();
@@ -624,13 +594,13 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
return isUseUserCRPref();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -655,11 +625,11 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
case USE_USER_CRPREF:
return isSetUseUserCRPref();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof UserConfigurationDataModel)
@@ -670,6 +640,8 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
public boolean equals(UserConfigurationDataModel that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_airavataAutoSchedule = true;
boolean that_present_airavataAutoSchedule = true;
@@ -766,59 +738,45 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_airavataAutoSchedule = true;
- list.add(present_airavataAutoSchedule);
- if (present_airavataAutoSchedule)
- list.add(airavataAutoSchedule);
+ hashCode = hashCode * 8191 + ((airavataAutoSchedule) ? 131071 : 524287);
- boolean present_overrideManualScheduledParams = true;
- list.add(present_overrideManualScheduledParams);
- if (present_overrideManualScheduledParams)
- list.add(overrideManualScheduledParams);
+ hashCode = hashCode * 8191 + ((overrideManualScheduledParams) ? 131071 : 524287);
- boolean present_shareExperimentPublicly = true && (isSetShareExperimentPublicly());
- list.add(present_shareExperimentPublicly);
- if (present_shareExperimentPublicly)
- list.add(shareExperimentPublicly);
+ hashCode = hashCode * 8191 + ((isSetShareExperimentPublicly()) ? 131071 : 524287);
+ if (isSetShareExperimentPublicly())
+ hashCode = hashCode * 8191 + ((shareExperimentPublicly) ? 131071 : 524287);
- boolean present_computationalResourceScheduling = true && (isSetComputationalResourceScheduling());
- list.add(present_computationalResourceScheduling);
- if (present_computationalResourceScheduling)
- list.add(computationalResourceScheduling);
+ hashCode = hashCode * 8191 + ((isSetComputationalResourceScheduling()) ? 131071 : 524287);
+ if (isSetComputationalResourceScheduling())
+ hashCode = hashCode * 8191 + computationalResourceScheduling.hashCode();
- boolean present_throttleResources = true && (isSetThrottleResources());
- list.add(present_throttleResources);
- if (present_throttleResources)
- list.add(throttleResources);
+ hashCode = hashCode * 8191 + ((isSetThrottleResources()) ? 131071 : 524287);
+ if (isSetThrottleResources())
+ hashCode = hashCode * 8191 + ((throttleResources) ? 131071 : 524287);
- boolean present_userDN = true && (isSetUserDN());
- list.add(present_userDN);
- if (present_userDN)
- list.add(userDN);
+ hashCode = hashCode * 8191 + ((isSetUserDN()) ? 131071 : 524287);
+ if (isSetUserDN())
+ hashCode = hashCode * 8191 + userDN.hashCode();
- boolean present_generateCert = true && (isSetGenerateCert());
- list.add(present_generateCert);
- if (present_generateCert)
- list.add(generateCert);
+ hashCode = hashCode * 8191 + ((isSetGenerateCert()) ? 131071 : 524287);
+ if (isSetGenerateCert())
+ hashCode = hashCode * 8191 + ((generateCert) ? 131071 : 524287);
- boolean present_storageId = true && (isSetStorageId());
- list.add(present_storageId);
- if (present_storageId)
- list.add(storageId);
+ hashCode = hashCode * 8191 + ((isSetStorageId()) ? 131071 : 524287);
+ if (isSetStorageId())
+ hashCode = hashCode * 8191 + storageId.hashCode();
- boolean present_experimentDataDir = true && (isSetExperimentDataDir());
- list.add(present_experimentDataDir);
- if (present_experimentDataDir)
- list.add(experimentDataDir);
+ hashCode = hashCode * 8191 + ((isSetExperimentDataDir()) ? 131071 : 524287);
+ if (isSetExperimentDataDir())
+ hashCode = hashCode * 8191 + experimentDataDir.hashCode();
- boolean present_useUserCRPref = true && (isSetUseUserCRPref());
- list.add(present_useUserCRPref);
- if (present_useUserCRPref)
- list.add(useUserCRPref);
+ hashCode = hashCode * 8191 + ((isSetUseUserCRPref()) ? 131071 : 524287);
+ if (isSetUseUserCRPref())
+ hashCode = hashCode * 8191 + ((useUserCRPref) ? 131071 : 524287);
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -829,7 +787,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetAiravataAutoSchedule()).compareTo(other.isSetAiravataAutoSchedule());
+ lastComparison = java.lang.Boolean.valueOf(isSetAiravataAutoSchedule()).compareTo(other.isSetAiravataAutoSchedule());
if (lastComparison != 0) {
return lastComparison;
}
@@ -839,7 +797,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetOverrideManualScheduledParams()).compareTo(other.isSetOverrideManualScheduledParams());
+ lastComparison = java.lang.Boolean.valueOf(isSetOverrideManualScheduledParams()).compareTo(other.isSetOverrideManualScheduledParams());
if (lastComparison != 0) {
return lastComparison;
}
@@ -849,7 +807,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetShareExperimentPublicly()).compareTo(other.isSetShareExperimentPublicly());
+ lastComparison = java.lang.Boolean.valueOf(isSetShareExperimentPublicly()).compareTo(other.isSetShareExperimentPublicly());
if (lastComparison != 0) {
return lastComparison;
}
@@ -859,7 +817,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetComputationalResourceScheduling()).compareTo(other.isSetComputationalResourceScheduling());
+ lastComparison = java.lang.Boolean.valueOf(isSetComputationalResourceScheduling()).compareTo(other.isSetComputationalResourceScheduling());
if (lastComparison != 0) {
return lastComparison;
}
@@ -869,7 +827,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetThrottleResources()).compareTo(other.isSetThrottleResources());
+ lastComparison = java.lang.Boolean.valueOf(isSetThrottleResources()).compareTo(other.isSetThrottleResources());
if (lastComparison != 0) {
return lastComparison;
}
@@ -879,7 +837,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUserDN()).compareTo(other.isSetUserDN());
+ lastComparison = java.lang.Boolean.valueOf(isSetUserDN()).compareTo(other.isSetUserDN());
if (lastComparison != 0) {
return lastComparison;
}
@@ -889,7 +847,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetGenerateCert()).compareTo(other.isSetGenerateCert());
+ lastComparison = java.lang.Boolean.valueOf(isSetGenerateCert()).compareTo(other.isSetGenerateCert());
if (lastComparison != 0) {
return lastComparison;
}
@@ -899,7 +857,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetStorageId()).compareTo(other.isSetStorageId());
+ lastComparison = java.lang.Boolean.valueOf(isSetStorageId()).compareTo(other.isSetStorageId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -909,7 +867,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetExperimentDataDir()).compareTo(other.isSetExperimentDataDir());
+ lastComparison = java.lang.Boolean.valueOf(isSetExperimentDataDir()).compareTo(other.isSetExperimentDataDir());
if (lastComparison != 0) {
return lastComparison;
}
@@ -919,7 +877,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUseUserCRPref()).compareTo(other.isSetUseUserCRPref());
+ lastComparison = java.lang.Boolean.valueOf(isSetUseUserCRPref()).compareTo(other.isSetUseUserCRPref());
if (lastComparison != 0) {
return lastComparison;
}
@@ -937,16 +895,16 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("UserConfigurationDataModel(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("UserConfigurationDataModel(");
boolean first = true;
sb.append("airavataAutoSchedule:");
@@ -1048,7 +1006,7 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -1058,13 +1016,13 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
}
}
- private static class UserConfigurationDataModelStandardSchemeFactory implements SchemeFactory {
+ private static class UserConfigurationDataModelStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public UserConfigurationDataModelStandardScheme getScheme() {
return new UserConfigurationDataModelStandardScheme();
}
}
- private static class UserConfigurationDataModelStandardScheme extends StandardScheme<UserConfigurationDataModel> {
+ private static class UserConfigurationDataModelStandardScheme extends org.apache.thrift.scheme.StandardScheme<UserConfigurationDataModel> {
public void read(org.apache.thrift.protocol.TProtocol iprot, UserConfigurationDataModel struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1230,20 +1188,20 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
}
- private static class UserConfigurationDataModelTupleSchemeFactory implements SchemeFactory {
+ private static class UserConfigurationDataModelTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public UserConfigurationDataModelTupleScheme getScheme() {
return new UserConfigurationDataModelTupleScheme();
}
}
- private static class UserConfigurationDataModelTupleScheme extends TupleScheme<UserConfigurationDataModel> {
+ private static class UserConfigurationDataModelTupleScheme extends org.apache.thrift.scheme.TupleScheme<UserConfigurationDataModel> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, UserConfigurationDataModel struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeBool(struct.airavataAutoSchedule);
oprot.writeBool(struct.overrideManualScheduledParams);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetShareExperimentPublicly()) {
optionals.set(0);
}
@@ -1297,12 +1255,12 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, UserConfigurationDataModel struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.airavataAutoSchedule = iprot.readBool();
struct.setAiravataAutoScheduleIsSet(true);
struct.overrideManualScheduledParams = iprot.readBool();
struct.setOverrideManualScheduledParamsIsSet(true);
- BitSet incoming = iprot.readBitSet(8);
+ java.util.BitSet incoming = iprot.readBitSet(8);
if (incoming.get(0)) {
struct.shareExperimentPublicly = iprot.readBool();
struct.setShareExperimentPubliclyIsSet(true);
@@ -1339,5 +1297,8 @@ public class UserConfigurationDataModel implements org.apache.thrift.TBase<UserC
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/group/GroupModel.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/group/GroupModel.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/group/GroupModel.java
index 4db9ae4..369efa6 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/group/GroupModel.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/group/GroupModel.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.group;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupModel._Fields>, java.io.Serializable, Cloneable, Comparable<GroupModel> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("GroupModel");
@@ -61,17 +34,14 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
private static final org.apache.thrift.protocol.TField DESCRIPTION_FIELD_DESC = new org.apache.thrift.protocol.TField("description", org.apache.thrift.protocol.TType.STRING, (short)4);
private static final org.apache.thrift.protocol.TField MEMBERS_FIELD_DESC = new org.apache.thrift.protocol.TField("members", org.apache.thrift.protocol.TType.LIST, (short)5);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new GroupModelStandardSchemeFactory());
- schemes.put(TupleScheme.class, new GroupModelTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new GroupModelStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new GroupModelTupleSchemeFactory();
- private String id; // optional
- private String name; // optional
- private String ownerId; // optional
- private String description; // optional
- private List<String> members; // optional
+ private java.lang.String id; // optional
+ private java.lang.String name; // optional
+ private java.lang.String ownerId; // optional
+ private java.lang.String description; // optional
+ private java.util.List<java.lang.String> members; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -81,10 +51,10 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
DESCRIPTION((short)4, "description"),
MEMBERS((short)5, "members");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -115,21 +85,21 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -138,16 +108,16 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
private static final _Fields optionals[] = {_Fields.ID,_Fields.NAME,_Fields.OWNER_ID,_Fields.DESCRIPTION,_Fields.MEMBERS};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.ID, new org.apache.thrift.meta_data.FieldMetaData("id", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.NAME, new org.apache.thrift.meta_data.FieldMetaData("name", org.apache.thrift.TFieldRequirementType.OPTIONAL,
@@ -159,7 +129,7 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
tmpMap.put(_Fields.MEMBERS, new org.apache.thrift.meta_data.FieldMetaData("members", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(GroupModel.class, metaDataMap);
}
@@ -183,7 +153,7 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
this.description = other.description;
}
if (other.isSetMembers()) {
- List<String> __this__members = new ArrayList<String>(other.members);
+ java.util.List<java.lang.String> __this__members = new java.util.ArrayList<java.lang.String>(other.members);
this.members = __this__members;
}
}
@@ -201,11 +171,11 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
this.members = null;
}
- public String getId() {
+ public java.lang.String getId() {
return this.id;
}
- public void setId(String id) {
+ public void setId(java.lang.String id) {
this.id = id;
}
@@ -224,11 +194,11 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
}
}
- public String getName() {
+ public java.lang.String getName() {
return this.name;
}
- public void setName(String name) {
+ public void setName(java.lang.String name) {
this.name = name;
}
@@ -247,11 +217,11 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
}
}
- public String getOwnerId() {
+ public java.lang.String getOwnerId() {
return this.ownerId;
}
- public void setOwnerId(String ownerId) {
+ public void setOwnerId(java.lang.String ownerId) {
this.ownerId = ownerId;
}
@@ -270,11 +240,11 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
}
}
- public String getDescription() {
+ public java.lang.String getDescription() {
return this.description;
}
- public void setDescription(String description) {
+ public void setDescription(java.lang.String description) {
this.description = description;
}
@@ -297,22 +267,22 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
return (this.members == null) ? 0 : this.members.size();
}
- public java.util.Iterator<String> getMembersIterator() {
+ public java.util.Iterator<java.lang.String> getMembersIterator() {
return (this.members == null) ? null : this.members.iterator();
}
- public void addToMembers(String elem) {
+ public void addToMembers(java.lang.String elem) {
if (this.members == null) {
- this.members = new ArrayList<String>();
+ this.members = new java.util.ArrayList<java.lang.String>();
}
this.members.add(elem);
}
- public List<String> getMembers() {
+ public java.util.List<java.lang.String> getMembers() {
return this.members;
}
- public void setMembers(List<String> members) {
+ public void setMembers(java.util.List<java.lang.String> members) {
this.members = members;
}
@@ -331,13 +301,13 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case ID:
if (value == null) {
unsetId();
} else {
- setId((String)value);
+ setId((java.lang.String)value);
}
break;
@@ -345,7 +315,7 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
if (value == null) {
unsetName();
} else {
- setName((String)value);
+ setName((java.lang.String)value);
}
break;
@@ -353,7 +323,7 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
if (value == null) {
unsetOwnerId();
} else {
- setOwnerId((String)value);
+ setOwnerId((java.lang.String)value);
}
break;
@@ -361,7 +331,7 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
if (value == null) {
unsetDescription();
} else {
- setDescription((String)value);
+ setDescription((java.lang.String)value);
}
break;
@@ -369,14 +339,14 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
if (value == null) {
unsetMembers();
} else {
- setMembers((List<String>)value);
+ setMembers((java.util.List<java.lang.String>)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case ID:
return getId();
@@ -394,13 +364,13 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
return getMembers();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -415,11 +385,11 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
case MEMBERS:
return isSetMembers();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof GroupModel)
@@ -430,6 +400,8 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
public boolean equals(GroupModel that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_id = true && this.isSetId();
boolean that_present_id = true && that.isSetId();
@@ -481,34 +453,29 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_id = true && (isSetId());
- list.add(present_id);
- if (present_id)
- list.add(id);
+ hashCode = hashCode * 8191 + ((isSetId()) ? 131071 : 524287);
+ if (isSetId())
+ hashCode = hashCode * 8191 + id.hashCode();
- boolean present_name = true && (isSetName());
- list.add(present_name);
- if (present_name)
- list.add(name);
+ hashCode = hashCode * 8191 + ((isSetName()) ? 131071 : 524287);
+ if (isSetName())
+ hashCode = hashCode * 8191 + name.hashCode();
- boolean present_ownerId = true && (isSetOwnerId());
- list.add(present_ownerId);
- if (present_ownerId)
- list.add(ownerId);
+ hashCode = hashCode * 8191 + ((isSetOwnerId()) ? 131071 : 524287);
+ if (isSetOwnerId())
+ hashCode = hashCode * 8191 + ownerId.hashCode();
- boolean present_description = true && (isSetDescription());
- list.add(present_description);
- if (present_description)
- list.add(description);
+ hashCode = hashCode * 8191 + ((isSetDescription()) ? 131071 : 524287);
+ if (isSetDescription())
+ hashCode = hashCode * 8191 + description.hashCode();
- boolean present_members = true && (isSetMembers());
- list.add(present_members);
- if (present_members)
- list.add(members);
+ hashCode = hashCode * 8191 + ((isSetMembers()) ? 131071 : 524287);
+ if (isSetMembers())
+ hashCode = hashCode * 8191 + members.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -519,7 +486,7 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetId()).compareTo(other.isSetId());
+ lastComparison = java.lang.Boolean.valueOf(isSetId()).compareTo(other.isSetId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -529,7 +496,7 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetName()).compareTo(other.isSetName());
+ lastComparison = java.lang.Boolean.valueOf(isSetName()).compareTo(other.isSetName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -539,7 +506,7 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetOwnerId()).compareTo(other.isSetOwnerId());
+ lastComparison = java.lang.Boolean.valueOf(isSetOwnerId()).compareTo(other.isSetOwnerId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -549,7 +516,7 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -559,7 +526,7 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetMembers()).compareTo(other.isSetMembers());
+ lastComparison = java.lang.Boolean.valueOf(isSetMembers()).compareTo(other.isSetMembers());
if (lastComparison != 0) {
return lastComparison;
}
@@ -577,16 +544,16 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("GroupModel(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("GroupModel(");
boolean first = true;
if (isSetId()) {
@@ -655,7 +622,7 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -663,13 +630,13 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
}
}
- private static class GroupModelStandardSchemeFactory implements SchemeFactory {
+ private static class GroupModelStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public GroupModelStandardScheme getScheme() {
return new GroupModelStandardScheme();
}
}
- private static class GroupModelStandardScheme extends StandardScheme<GroupModel> {
+ private static class GroupModelStandardScheme extends org.apache.thrift.scheme.StandardScheme<GroupModel> {
public void read(org.apache.thrift.protocol.TProtocol iprot, GroupModel struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -717,8 +684,8 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list0 = iprot.readListBegin();
- struct.members = new ArrayList<String>(_list0.size);
- String _elem1;
+ struct.members = new java.util.ArrayList<java.lang.String>(_list0.size);
+ java.lang.String _elem1;
for (int _i2 = 0; _i2 < _list0.size; ++_i2)
{
_elem1 = iprot.readString();
@@ -777,7 +744,7 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
oprot.writeFieldBegin(MEMBERS_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.members.size()));
- for (String _iter3 : struct.members)
+ for (java.lang.String _iter3 : struct.members)
{
oprot.writeString(_iter3);
}
@@ -792,18 +759,18 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
}
- private static class GroupModelTupleSchemeFactory implements SchemeFactory {
+ private static class GroupModelTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public GroupModelTupleScheme getScheme() {
return new GroupModelTupleScheme();
}
}
- private static class GroupModelTupleScheme extends TupleScheme<GroupModel> {
+ private static class GroupModelTupleScheme extends org.apache.thrift.scheme.TupleScheme<GroupModel> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, GroupModel struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetId()) {
optionals.set(0);
}
@@ -835,7 +802,7 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
if (struct.isSetMembers()) {
{
oprot.writeI32(struct.members.size());
- for (String _iter4 : struct.members)
+ for (java.lang.String _iter4 : struct.members)
{
oprot.writeString(_iter4);
}
@@ -845,8 +812,8 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, GroupModel struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(5);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(5);
if (incoming.get(0)) {
struct.id = iprot.readString();
struct.setIdIsSet(true);
@@ -866,8 +833,8 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
if (incoming.get(4)) {
{
org.apache.thrift.protocol.TList _list5 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.members = new ArrayList<String>(_list5.size);
- String _elem6;
+ struct.members = new java.util.ArrayList<java.lang.String>(_list5.size);
+ java.lang.String _elem6;
for (int _i7 = 0; _i7 < _list5.size; ++_i7)
{
_elem6 = iprot.readString();
@@ -879,5 +846,8 @@ public class GroupModel implements org.apache.thrift.TBase<GroupModel, GroupMode
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/group/ResourcePermissionType.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/group/ResourcePermissionType.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/group/ResourcePermissionType.java
index 558ed59..17fecdf 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/group/ResourcePermissionType.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/group/ResourcePermissionType.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/group/ResourceType.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/group/ResourceType.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/group/ResourceType.java
index e9b034a..7817ede 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/group/ResourceType.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/group/ResourceType.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
[03/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentStatistics.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentStatistics.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentStatistics.java
index 03aa46a..54e7c2a 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentStatistics.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentStatistics.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.experiment;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentStatistics, ExperimentStatistics._Fields>, java.io.Serializable, Cloneable, Comparable<ExperimentStatistics> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ExperimentStatistics");
@@ -68,11 +41,8 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
private static final org.apache.thrift.protocol.TField CREATED_EXPERIMENTS_FIELD_DESC = new org.apache.thrift.protocol.TField("createdExperiments", org.apache.thrift.protocol.TType.LIST, (short)11);
private static final org.apache.thrift.protocol.TField RUNNING_EXPERIMENTS_FIELD_DESC = new org.apache.thrift.protocol.TField("runningExperiments", org.apache.thrift.protocol.TType.LIST, (short)12);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new ExperimentStatisticsStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ExperimentStatisticsTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ExperimentStatisticsStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ExperimentStatisticsTupleSchemeFactory();
private int allExperimentCount; // required
private int completedExperimentCount; // required
@@ -80,12 +50,12 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
private int failedExperimentCount; // required
private int createdExperimentCount; // required
private int runningExperimentCount; // required
- private List<ExperimentSummaryModel> allExperiments; // required
- private List<ExperimentSummaryModel> completedExperiments; // optional
- private List<ExperimentSummaryModel> failedExperiments; // optional
- private List<ExperimentSummaryModel> cancelledExperiments; // optional
- private List<ExperimentSummaryModel> createdExperiments; // optional
- private List<ExperimentSummaryModel> runningExperiments; // optional
+ private java.util.List<ExperimentSummaryModel> allExperiments; // required
+ private java.util.List<ExperimentSummaryModel> completedExperiments; // optional
+ private java.util.List<ExperimentSummaryModel> failedExperiments; // optional
+ private java.util.List<ExperimentSummaryModel> cancelledExperiments; // optional
+ private java.util.List<ExperimentSummaryModel> createdExperiments; // optional
+ private java.util.List<ExperimentSummaryModel> runningExperiments; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -102,10 +72,10 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
CREATED_EXPERIMENTS((short)11, "createdExperiments"),
RUNNING_EXPERIMENTS((short)12, "runningExperiments");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -150,21 +120,21 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -173,7 +143,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -187,9 +157,9 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
private static final int __RUNNINGEXPERIMENTCOUNT_ISSET_ID = 5;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.CANCELLED_EXPERIMENT_COUNT,_Fields.COMPLETED_EXPERIMENTS,_Fields.FAILED_EXPERIMENTS,_Fields.CANCELLED_EXPERIMENTS,_Fields.CREATED_EXPERIMENTS,_Fields.RUNNING_EXPERIMENTS};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.ALL_EXPERIMENT_COUNT, new org.apache.thrift.meta_data.FieldMetaData("allExperimentCount", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
tmpMap.put(_Fields.COMPLETED_EXPERIMENT_COUNT, new org.apache.thrift.meta_data.FieldMetaData("completedExperimentCount", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -220,7 +190,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
tmpMap.put(_Fields.RUNNING_EXPERIMENTS, new org.apache.thrift.meta_data.FieldMetaData("runningExperiments", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ExperimentSummaryModel.class))));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ExperimentStatistics.class, metaDataMap);
}
@@ -233,7 +203,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
int failedExperimentCount,
int createdExperimentCount,
int runningExperimentCount,
- List<ExperimentSummaryModel> allExperiments)
+ java.util.List<ExperimentSummaryModel> allExperiments)
{
this();
this.allExperimentCount = allExperimentCount;
@@ -261,42 +231,42 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
this.createdExperimentCount = other.createdExperimentCount;
this.runningExperimentCount = other.runningExperimentCount;
if (other.isSetAllExperiments()) {
- List<ExperimentSummaryModel> __this__allExperiments = new ArrayList<ExperimentSummaryModel>(other.allExperiments.size());
+ java.util.List<ExperimentSummaryModel> __this__allExperiments = new java.util.ArrayList<ExperimentSummaryModel>(other.allExperiments.size());
for (ExperimentSummaryModel other_element : other.allExperiments) {
__this__allExperiments.add(new ExperimentSummaryModel(other_element));
}
this.allExperiments = __this__allExperiments;
}
if (other.isSetCompletedExperiments()) {
- List<ExperimentSummaryModel> __this__completedExperiments = new ArrayList<ExperimentSummaryModel>(other.completedExperiments.size());
+ java.util.List<ExperimentSummaryModel> __this__completedExperiments = new java.util.ArrayList<ExperimentSummaryModel>(other.completedExperiments.size());
for (ExperimentSummaryModel other_element : other.completedExperiments) {
__this__completedExperiments.add(new ExperimentSummaryModel(other_element));
}
this.completedExperiments = __this__completedExperiments;
}
if (other.isSetFailedExperiments()) {
- List<ExperimentSummaryModel> __this__failedExperiments = new ArrayList<ExperimentSummaryModel>(other.failedExperiments.size());
+ java.util.List<ExperimentSummaryModel> __this__failedExperiments = new java.util.ArrayList<ExperimentSummaryModel>(other.failedExperiments.size());
for (ExperimentSummaryModel other_element : other.failedExperiments) {
__this__failedExperiments.add(new ExperimentSummaryModel(other_element));
}
this.failedExperiments = __this__failedExperiments;
}
if (other.isSetCancelledExperiments()) {
- List<ExperimentSummaryModel> __this__cancelledExperiments = new ArrayList<ExperimentSummaryModel>(other.cancelledExperiments.size());
+ java.util.List<ExperimentSummaryModel> __this__cancelledExperiments = new java.util.ArrayList<ExperimentSummaryModel>(other.cancelledExperiments.size());
for (ExperimentSummaryModel other_element : other.cancelledExperiments) {
__this__cancelledExperiments.add(new ExperimentSummaryModel(other_element));
}
this.cancelledExperiments = __this__cancelledExperiments;
}
if (other.isSetCreatedExperiments()) {
- List<ExperimentSummaryModel> __this__createdExperiments = new ArrayList<ExperimentSummaryModel>(other.createdExperiments.size());
+ java.util.List<ExperimentSummaryModel> __this__createdExperiments = new java.util.ArrayList<ExperimentSummaryModel>(other.createdExperiments.size());
for (ExperimentSummaryModel other_element : other.createdExperiments) {
__this__createdExperiments.add(new ExperimentSummaryModel(other_element));
}
this.createdExperiments = __this__createdExperiments;
}
if (other.isSetRunningExperiments()) {
- List<ExperimentSummaryModel> __this__runningExperiments = new ArrayList<ExperimentSummaryModel>(other.runningExperiments.size());
+ java.util.List<ExperimentSummaryModel> __this__runningExperiments = new java.util.ArrayList<ExperimentSummaryModel>(other.runningExperiments.size());
for (ExperimentSummaryModel other_element : other.runningExperiments) {
__this__runningExperiments.add(new ExperimentSummaryModel(other_element));
}
@@ -340,16 +310,16 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
}
public void unsetAllExperimentCount() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ALLEXPERIMENTCOUNT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ALLEXPERIMENTCOUNT_ISSET_ID);
}
/** Returns true if field allExperimentCount is set (has been assigned a value) and false otherwise */
public boolean isSetAllExperimentCount() {
- return EncodingUtils.testBit(__isset_bitfield, __ALLEXPERIMENTCOUNT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ALLEXPERIMENTCOUNT_ISSET_ID);
}
public void setAllExperimentCountIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ALLEXPERIMENTCOUNT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ALLEXPERIMENTCOUNT_ISSET_ID, value);
}
public int getCompletedExperimentCount() {
@@ -362,16 +332,16 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
}
public void unsetCompletedExperimentCount() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __COMPLETEDEXPERIMENTCOUNT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __COMPLETEDEXPERIMENTCOUNT_ISSET_ID);
}
/** Returns true if field completedExperimentCount is set (has been assigned a value) and false otherwise */
public boolean isSetCompletedExperimentCount() {
- return EncodingUtils.testBit(__isset_bitfield, __COMPLETEDEXPERIMENTCOUNT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __COMPLETEDEXPERIMENTCOUNT_ISSET_ID);
}
public void setCompletedExperimentCountIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __COMPLETEDEXPERIMENTCOUNT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __COMPLETEDEXPERIMENTCOUNT_ISSET_ID, value);
}
public int getCancelledExperimentCount() {
@@ -384,16 +354,16 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
}
public void unsetCancelledExperimentCount() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __CANCELLEDEXPERIMENTCOUNT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __CANCELLEDEXPERIMENTCOUNT_ISSET_ID);
}
/** Returns true if field cancelledExperimentCount is set (has been assigned a value) and false otherwise */
public boolean isSetCancelledExperimentCount() {
- return EncodingUtils.testBit(__isset_bitfield, __CANCELLEDEXPERIMENTCOUNT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __CANCELLEDEXPERIMENTCOUNT_ISSET_ID);
}
public void setCancelledExperimentCountIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __CANCELLEDEXPERIMENTCOUNT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __CANCELLEDEXPERIMENTCOUNT_ISSET_ID, value);
}
public int getFailedExperimentCount() {
@@ -406,16 +376,16 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
}
public void unsetFailedExperimentCount() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __FAILEDEXPERIMENTCOUNT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __FAILEDEXPERIMENTCOUNT_ISSET_ID);
}
/** Returns true if field failedExperimentCount is set (has been assigned a value) and false otherwise */
public boolean isSetFailedExperimentCount() {
- return EncodingUtils.testBit(__isset_bitfield, __FAILEDEXPERIMENTCOUNT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __FAILEDEXPERIMENTCOUNT_ISSET_ID);
}
public void setFailedExperimentCountIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __FAILEDEXPERIMENTCOUNT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __FAILEDEXPERIMENTCOUNT_ISSET_ID, value);
}
public int getCreatedExperimentCount() {
@@ -428,16 +398,16 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
}
public void unsetCreatedExperimentCount() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __CREATEDEXPERIMENTCOUNT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __CREATEDEXPERIMENTCOUNT_ISSET_ID);
}
/** Returns true if field createdExperimentCount is set (has been assigned a value) and false otherwise */
public boolean isSetCreatedExperimentCount() {
- return EncodingUtils.testBit(__isset_bitfield, __CREATEDEXPERIMENTCOUNT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __CREATEDEXPERIMENTCOUNT_ISSET_ID);
}
public void setCreatedExperimentCountIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __CREATEDEXPERIMENTCOUNT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __CREATEDEXPERIMENTCOUNT_ISSET_ID, value);
}
public int getRunningExperimentCount() {
@@ -450,16 +420,16 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
}
public void unsetRunningExperimentCount() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __RUNNINGEXPERIMENTCOUNT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __RUNNINGEXPERIMENTCOUNT_ISSET_ID);
}
/** Returns true if field runningExperimentCount is set (has been assigned a value) and false otherwise */
public boolean isSetRunningExperimentCount() {
- return EncodingUtils.testBit(__isset_bitfield, __RUNNINGEXPERIMENTCOUNT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __RUNNINGEXPERIMENTCOUNT_ISSET_ID);
}
public void setRunningExperimentCountIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __RUNNINGEXPERIMENTCOUNT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __RUNNINGEXPERIMENTCOUNT_ISSET_ID, value);
}
public int getAllExperimentsSize() {
@@ -472,16 +442,16 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
public void addToAllExperiments(ExperimentSummaryModel elem) {
if (this.allExperiments == null) {
- this.allExperiments = new ArrayList<ExperimentSummaryModel>();
+ this.allExperiments = new java.util.ArrayList<ExperimentSummaryModel>();
}
this.allExperiments.add(elem);
}
- public List<ExperimentSummaryModel> getAllExperiments() {
+ public java.util.List<ExperimentSummaryModel> getAllExperiments() {
return this.allExperiments;
}
- public void setAllExperiments(List<ExperimentSummaryModel> allExperiments) {
+ public void setAllExperiments(java.util.List<ExperimentSummaryModel> allExperiments) {
this.allExperiments = allExperiments;
}
@@ -510,16 +480,16 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
public void addToCompletedExperiments(ExperimentSummaryModel elem) {
if (this.completedExperiments == null) {
- this.completedExperiments = new ArrayList<ExperimentSummaryModel>();
+ this.completedExperiments = new java.util.ArrayList<ExperimentSummaryModel>();
}
this.completedExperiments.add(elem);
}
- public List<ExperimentSummaryModel> getCompletedExperiments() {
+ public java.util.List<ExperimentSummaryModel> getCompletedExperiments() {
return this.completedExperiments;
}
- public void setCompletedExperiments(List<ExperimentSummaryModel> completedExperiments) {
+ public void setCompletedExperiments(java.util.List<ExperimentSummaryModel> completedExperiments) {
this.completedExperiments = completedExperiments;
}
@@ -548,16 +518,16 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
public void addToFailedExperiments(ExperimentSummaryModel elem) {
if (this.failedExperiments == null) {
- this.failedExperiments = new ArrayList<ExperimentSummaryModel>();
+ this.failedExperiments = new java.util.ArrayList<ExperimentSummaryModel>();
}
this.failedExperiments.add(elem);
}
- public List<ExperimentSummaryModel> getFailedExperiments() {
+ public java.util.List<ExperimentSummaryModel> getFailedExperiments() {
return this.failedExperiments;
}
- public void setFailedExperiments(List<ExperimentSummaryModel> failedExperiments) {
+ public void setFailedExperiments(java.util.List<ExperimentSummaryModel> failedExperiments) {
this.failedExperiments = failedExperiments;
}
@@ -586,16 +556,16 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
public void addToCancelledExperiments(ExperimentSummaryModel elem) {
if (this.cancelledExperiments == null) {
- this.cancelledExperiments = new ArrayList<ExperimentSummaryModel>();
+ this.cancelledExperiments = new java.util.ArrayList<ExperimentSummaryModel>();
}
this.cancelledExperiments.add(elem);
}
- public List<ExperimentSummaryModel> getCancelledExperiments() {
+ public java.util.List<ExperimentSummaryModel> getCancelledExperiments() {
return this.cancelledExperiments;
}
- public void setCancelledExperiments(List<ExperimentSummaryModel> cancelledExperiments) {
+ public void setCancelledExperiments(java.util.List<ExperimentSummaryModel> cancelledExperiments) {
this.cancelledExperiments = cancelledExperiments;
}
@@ -624,16 +594,16 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
public void addToCreatedExperiments(ExperimentSummaryModel elem) {
if (this.createdExperiments == null) {
- this.createdExperiments = new ArrayList<ExperimentSummaryModel>();
+ this.createdExperiments = new java.util.ArrayList<ExperimentSummaryModel>();
}
this.createdExperiments.add(elem);
}
- public List<ExperimentSummaryModel> getCreatedExperiments() {
+ public java.util.List<ExperimentSummaryModel> getCreatedExperiments() {
return this.createdExperiments;
}
- public void setCreatedExperiments(List<ExperimentSummaryModel> createdExperiments) {
+ public void setCreatedExperiments(java.util.List<ExperimentSummaryModel> createdExperiments) {
this.createdExperiments = createdExperiments;
}
@@ -662,16 +632,16 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
public void addToRunningExperiments(ExperimentSummaryModel elem) {
if (this.runningExperiments == null) {
- this.runningExperiments = new ArrayList<ExperimentSummaryModel>();
+ this.runningExperiments = new java.util.ArrayList<ExperimentSummaryModel>();
}
this.runningExperiments.add(elem);
}
- public List<ExperimentSummaryModel> getRunningExperiments() {
+ public java.util.List<ExperimentSummaryModel> getRunningExperiments() {
return this.runningExperiments;
}
- public void setRunningExperiments(List<ExperimentSummaryModel> runningExperiments) {
+ public void setRunningExperiments(java.util.List<ExperimentSummaryModel> runningExperiments) {
this.runningExperiments = runningExperiments;
}
@@ -690,13 +660,13 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case ALL_EXPERIMENT_COUNT:
if (value == null) {
unsetAllExperimentCount();
} else {
- setAllExperimentCount((Integer)value);
+ setAllExperimentCount((java.lang.Integer)value);
}
break;
@@ -704,7 +674,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (value == null) {
unsetCompletedExperimentCount();
} else {
- setCompletedExperimentCount((Integer)value);
+ setCompletedExperimentCount((java.lang.Integer)value);
}
break;
@@ -712,7 +682,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (value == null) {
unsetCancelledExperimentCount();
} else {
- setCancelledExperimentCount((Integer)value);
+ setCancelledExperimentCount((java.lang.Integer)value);
}
break;
@@ -720,7 +690,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (value == null) {
unsetFailedExperimentCount();
} else {
- setFailedExperimentCount((Integer)value);
+ setFailedExperimentCount((java.lang.Integer)value);
}
break;
@@ -728,7 +698,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (value == null) {
unsetCreatedExperimentCount();
} else {
- setCreatedExperimentCount((Integer)value);
+ setCreatedExperimentCount((java.lang.Integer)value);
}
break;
@@ -736,7 +706,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (value == null) {
unsetRunningExperimentCount();
} else {
- setRunningExperimentCount((Integer)value);
+ setRunningExperimentCount((java.lang.Integer)value);
}
break;
@@ -744,7 +714,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (value == null) {
unsetAllExperiments();
} else {
- setAllExperiments((List<ExperimentSummaryModel>)value);
+ setAllExperiments((java.util.List<ExperimentSummaryModel>)value);
}
break;
@@ -752,7 +722,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (value == null) {
unsetCompletedExperiments();
} else {
- setCompletedExperiments((List<ExperimentSummaryModel>)value);
+ setCompletedExperiments((java.util.List<ExperimentSummaryModel>)value);
}
break;
@@ -760,7 +730,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (value == null) {
unsetFailedExperiments();
} else {
- setFailedExperiments((List<ExperimentSummaryModel>)value);
+ setFailedExperiments((java.util.List<ExperimentSummaryModel>)value);
}
break;
@@ -768,7 +738,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (value == null) {
unsetCancelledExperiments();
} else {
- setCancelledExperiments((List<ExperimentSummaryModel>)value);
+ setCancelledExperiments((java.util.List<ExperimentSummaryModel>)value);
}
break;
@@ -776,7 +746,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (value == null) {
unsetCreatedExperiments();
} else {
- setCreatedExperiments((List<ExperimentSummaryModel>)value);
+ setCreatedExperiments((java.util.List<ExperimentSummaryModel>)value);
}
break;
@@ -784,14 +754,14 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (value == null) {
unsetRunningExperiments();
} else {
- setRunningExperiments((List<ExperimentSummaryModel>)value);
+ setRunningExperiments((java.util.List<ExperimentSummaryModel>)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case ALL_EXPERIMENT_COUNT:
return getAllExperimentCount();
@@ -830,13 +800,13 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
return getRunningExperiments();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -865,11 +835,11 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
case RUNNING_EXPERIMENTS:
return isSetRunningExperiments();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ExperimentStatistics)
@@ -880,6 +850,8 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
public boolean equals(ExperimentStatistics that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_allExperimentCount = true;
boolean that_present_allExperimentCount = true;
@@ -994,69 +966,47 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_allExperimentCount = true;
- list.add(present_allExperimentCount);
- if (present_allExperimentCount)
- list.add(allExperimentCount);
-
- boolean present_completedExperimentCount = true;
- list.add(present_completedExperimentCount);
- if (present_completedExperimentCount)
- list.add(completedExperimentCount);
-
- boolean present_cancelledExperimentCount = true && (isSetCancelledExperimentCount());
- list.add(present_cancelledExperimentCount);
- if (present_cancelledExperimentCount)
- list.add(cancelledExperimentCount);
-
- boolean present_failedExperimentCount = true;
- list.add(present_failedExperimentCount);
- if (present_failedExperimentCount)
- list.add(failedExperimentCount);
-
- boolean present_createdExperimentCount = true;
- list.add(present_createdExperimentCount);
- if (present_createdExperimentCount)
- list.add(createdExperimentCount);
-
- boolean present_runningExperimentCount = true;
- list.add(present_runningExperimentCount);
- if (present_runningExperimentCount)
- list.add(runningExperimentCount);
-
- boolean present_allExperiments = true && (isSetAllExperiments());
- list.add(present_allExperiments);
- if (present_allExperiments)
- list.add(allExperiments);
-
- boolean present_completedExperiments = true && (isSetCompletedExperiments());
- list.add(present_completedExperiments);
- if (present_completedExperiments)
- list.add(completedExperiments);
-
- boolean present_failedExperiments = true && (isSetFailedExperiments());
- list.add(present_failedExperiments);
- if (present_failedExperiments)
- list.add(failedExperiments);
-
- boolean present_cancelledExperiments = true && (isSetCancelledExperiments());
- list.add(present_cancelledExperiments);
- if (present_cancelledExperiments)
- list.add(cancelledExperiments);
-
- boolean present_createdExperiments = true && (isSetCreatedExperiments());
- list.add(present_createdExperiments);
- if (present_createdExperiments)
- list.add(createdExperiments);
-
- boolean present_runningExperiments = true && (isSetRunningExperiments());
- list.add(present_runningExperiments);
- if (present_runningExperiments)
- list.add(runningExperiments);
-
- return list.hashCode();
+ int hashCode = 1;
+
+ hashCode = hashCode * 8191 + allExperimentCount;
+
+ hashCode = hashCode * 8191 + completedExperimentCount;
+
+ hashCode = hashCode * 8191 + ((isSetCancelledExperimentCount()) ? 131071 : 524287);
+ if (isSetCancelledExperimentCount())
+ hashCode = hashCode * 8191 + cancelledExperimentCount;
+
+ hashCode = hashCode * 8191 + failedExperimentCount;
+
+ hashCode = hashCode * 8191 + createdExperimentCount;
+
+ hashCode = hashCode * 8191 + runningExperimentCount;
+
+ hashCode = hashCode * 8191 + ((isSetAllExperiments()) ? 131071 : 524287);
+ if (isSetAllExperiments())
+ hashCode = hashCode * 8191 + allExperiments.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetCompletedExperiments()) ? 131071 : 524287);
+ if (isSetCompletedExperiments())
+ hashCode = hashCode * 8191 + completedExperiments.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetFailedExperiments()) ? 131071 : 524287);
+ if (isSetFailedExperiments())
+ hashCode = hashCode * 8191 + failedExperiments.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetCancelledExperiments()) ? 131071 : 524287);
+ if (isSetCancelledExperiments())
+ hashCode = hashCode * 8191 + cancelledExperiments.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetCreatedExperiments()) ? 131071 : 524287);
+ if (isSetCreatedExperiments())
+ hashCode = hashCode * 8191 + createdExperiments.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetRunningExperiments()) ? 131071 : 524287);
+ if (isSetRunningExperiments())
+ hashCode = hashCode * 8191 + runningExperiments.hashCode();
+
+ return hashCode;
}
@Override
@@ -1067,7 +1017,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetAllExperimentCount()).compareTo(other.isSetAllExperimentCount());
+ lastComparison = java.lang.Boolean.valueOf(isSetAllExperimentCount()).compareTo(other.isSetAllExperimentCount());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1077,7 +1027,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCompletedExperimentCount()).compareTo(other.isSetCompletedExperimentCount());
+ lastComparison = java.lang.Boolean.valueOf(isSetCompletedExperimentCount()).compareTo(other.isSetCompletedExperimentCount());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1087,7 +1037,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCancelledExperimentCount()).compareTo(other.isSetCancelledExperimentCount());
+ lastComparison = java.lang.Boolean.valueOf(isSetCancelledExperimentCount()).compareTo(other.isSetCancelledExperimentCount());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1097,7 +1047,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetFailedExperimentCount()).compareTo(other.isSetFailedExperimentCount());
+ lastComparison = java.lang.Boolean.valueOf(isSetFailedExperimentCount()).compareTo(other.isSetFailedExperimentCount());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1107,7 +1057,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCreatedExperimentCount()).compareTo(other.isSetCreatedExperimentCount());
+ lastComparison = java.lang.Boolean.valueOf(isSetCreatedExperimentCount()).compareTo(other.isSetCreatedExperimentCount());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1117,7 +1067,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetRunningExperimentCount()).compareTo(other.isSetRunningExperimentCount());
+ lastComparison = java.lang.Boolean.valueOf(isSetRunningExperimentCount()).compareTo(other.isSetRunningExperimentCount());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1127,7 +1077,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAllExperiments()).compareTo(other.isSetAllExperiments());
+ lastComparison = java.lang.Boolean.valueOf(isSetAllExperiments()).compareTo(other.isSetAllExperiments());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1137,7 +1087,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCompletedExperiments()).compareTo(other.isSetCompletedExperiments());
+ lastComparison = java.lang.Boolean.valueOf(isSetCompletedExperiments()).compareTo(other.isSetCompletedExperiments());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1147,7 +1097,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetFailedExperiments()).compareTo(other.isSetFailedExperiments());
+ lastComparison = java.lang.Boolean.valueOf(isSetFailedExperiments()).compareTo(other.isSetFailedExperiments());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1157,7 +1107,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCancelledExperiments()).compareTo(other.isSetCancelledExperiments());
+ lastComparison = java.lang.Boolean.valueOf(isSetCancelledExperiments()).compareTo(other.isSetCancelledExperiments());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1167,7 +1117,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCreatedExperiments()).compareTo(other.isSetCreatedExperiments());
+ lastComparison = java.lang.Boolean.valueOf(isSetCreatedExperiments()).compareTo(other.isSetCreatedExperiments());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1177,7 +1127,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetRunningExperiments()).compareTo(other.isSetRunningExperiments());
+ lastComparison = java.lang.Boolean.valueOf(isSetRunningExperiments()).compareTo(other.isSetRunningExperiments());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1195,16 +1145,16 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ExperimentStatistics(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ExperimentStatistics(");
boolean first = true;
sb.append("allExperimentCount:");
@@ -1331,7 +1281,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -1341,13 +1291,13 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
}
}
- private static class ExperimentStatisticsStandardSchemeFactory implements SchemeFactory {
+ private static class ExperimentStatisticsStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ExperimentStatisticsStandardScheme getScheme() {
return new ExperimentStatisticsStandardScheme();
}
}
- private static class ExperimentStatisticsStandardScheme extends StandardScheme<ExperimentStatistics> {
+ private static class ExperimentStatisticsStandardScheme extends org.apache.thrift.scheme.StandardScheme<ExperimentStatistics> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ExperimentStatistics struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1411,7 +1361,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list48 = iprot.readListBegin();
- struct.allExperiments = new ArrayList<ExperimentSummaryModel>(_list48.size);
+ struct.allExperiments = new java.util.ArrayList<ExperimentSummaryModel>(_list48.size);
ExperimentSummaryModel _elem49;
for (int _i50 = 0; _i50 < _list48.size; ++_i50)
{
@@ -1430,7 +1380,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list51 = iprot.readListBegin();
- struct.completedExperiments = new ArrayList<ExperimentSummaryModel>(_list51.size);
+ struct.completedExperiments = new java.util.ArrayList<ExperimentSummaryModel>(_list51.size);
ExperimentSummaryModel _elem52;
for (int _i53 = 0; _i53 < _list51.size; ++_i53)
{
@@ -1449,7 +1399,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list54 = iprot.readListBegin();
- struct.failedExperiments = new ArrayList<ExperimentSummaryModel>(_list54.size);
+ struct.failedExperiments = new java.util.ArrayList<ExperimentSummaryModel>(_list54.size);
ExperimentSummaryModel _elem55;
for (int _i56 = 0; _i56 < _list54.size; ++_i56)
{
@@ -1468,7 +1418,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list57 = iprot.readListBegin();
- struct.cancelledExperiments = new ArrayList<ExperimentSummaryModel>(_list57.size);
+ struct.cancelledExperiments = new java.util.ArrayList<ExperimentSummaryModel>(_list57.size);
ExperimentSummaryModel _elem58;
for (int _i59 = 0; _i59 < _list57.size; ++_i59)
{
@@ -1487,7 +1437,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list60 = iprot.readListBegin();
- struct.createdExperiments = new ArrayList<ExperimentSummaryModel>(_list60.size);
+ struct.createdExperiments = new java.util.ArrayList<ExperimentSummaryModel>(_list60.size);
ExperimentSummaryModel _elem61;
for (int _i62 = 0; _i62 < _list60.size; ++_i62)
{
@@ -1506,7 +1456,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list63 = iprot.readListBegin();
- struct.runningExperiments = new ArrayList<ExperimentSummaryModel>(_list63.size);
+ struct.runningExperiments = new java.util.ArrayList<ExperimentSummaryModel>(_list63.size);
ExperimentSummaryModel _elem64;
for (int _i65 = 0; _i65 < _list63.size; ++_i65)
{
@@ -1642,17 +1592,17 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
}
- private static class ExperimentStatisticsTupleSchemeFactory implements SchemeFactory {
+ private static class ExperimentStatisticsTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ExperimentStatisticsTupleScheme getScheme() {
return new ExperimentStatisticsTupleScheme();
}
}
- private static class ExperimentStatisticsTupleScheme extends TupleScheme<ExperimentStatistics> {
+ private static class ExperimentStatisticsTupleScheme extends org.apache.thrift.scheme.TupleScheme<ExperimentStatistics> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ExperimentStatistics struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeI32(struct.allExperimentCount);
oprot.writeI32(struct.completedExperimentCount);
oprot.writeI32(struct.failedExperimentCount);
@@ -1665,7 +1615,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
_iter72.write(oprot);
}
}
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetCancelledExperimentCount()) {
optionals.set(0);
}
@@ -1737,7 +1687,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ExperimentStatistics struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.allExperimentCount = iprot.readI32();
struct.setAllExperimentCountIsSet(true);
struct.completedExperimentCount = iprot.readI32();
@@ -1750,7 +1700,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
struct.setRunningExperimentCountIsSet(true);
{
org.apache.thrift.protocol.TList _list78 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.allExperiments = new ArrayList<ExperimentSummaryModel>(_list78.size);
+ struct.allExperiments = new java.util.ArrayList<ExperimentSummaryModel>(_list78.size);
ExperimentSummaryModel _elem79;
for (int _i80 = 0; _i80 < _list78.size; ++_i80)
{
@@ -1760,7 +1710,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
}
}
struct.setAllExperimentsIsSet(true);
- BitSet incoming = iprot.readBitSet(6);
+ java.util.BitSet incoming = iprot.readBitSet(6);
if (incoming.get(0)) {
struct.cancelledExperimentCount = iprot.readI32();
struct.setCancelledExperimentCountIsSet(true);
@@ -1768,7 +1718,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (incoming.get(1)) {
{
org.apache.thrift.protocol.TList _list81 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.completedExperiments = new ArrayList<ExperimentSummaryModel>(_list81.size);
+ struct.completedExperiments = new java.util.ArrayList<ExperimentSummaryModel>(_list81.size);
ExperimentSummaryModel _elem82;
for (int _i83 = 0; _i83 < _list81.size; ++_i83)
{
@@ -1782,7 +1732,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (incoming.get(2)) {
{
org.apache.thrift.protocol.TList _list84 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.failedExperiments = new ArrayList<ExperimentSummaryModel>(_list84.size);
+ struct.failedExperiments = new java.util.ArrayList<ExperimentSummaryModel>(_list84.size);
ExperimentSummaryModel _elem85;
for (int _i86 = 0; _i86 < _list84.size; ++_i86)
{
@@ -1796,7 +1746,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (incoming.get(3)) {
{
org.apache.thrift.protocol.TList _list87 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.cancelledExperiments = new ArrayList<ExperimentSummaryModel>(_list87.size);
+ struct.cancelledExperiments = new java.util.ArrayList<ExperimentSummaryModel>(_list87.size);
ExperimentSummaryModel _elem88;
for (int _i89 = 0; _i89 < _list87.size; ++_i89)
{
@@ -1810,7 +1760,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (incoming.get(4)) {
{
org.apache.thrift.protocol.TList _list90 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.createdExperiments = new ArrayList<ExperimentSummaryModel>(_list90.size);
+ struct.createdExperiments = new java.util.ArrayList<ExperimentSummaryModel>(_list90.size);
ExperimentSummaryModel _elem91;
for (int _i92 = 0; _i92 < _list90.size; ++_i92)
{
@@ -1824,7 +1774,7 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
if (incoming.get(5)) {
{
org.apache.thrift.protocol.TList _list93 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.runningExperiments = new ArrayList<ExperimentSummaryModel>(_list93.size);
+ struct.runningExperiments = new java.util.ArrayList<ExperimentSummaryModel>(_list93.size);
ExperimentSummaryModel _elem94;
for (int _i95 = 0; _i95 < _list93.size; ++_i95)
{
@@ -1838,5 +1788,8 @@ public class ExperimentStatistics implements org.apache.thrift.TBase<ExperimentS
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentSummaryModel.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentSummaryModel.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentSummaryModel.java
index 62a568b..f3ce843 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentSummaryModel.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentSummaryModel.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.experiment;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class ExperimentSummaryModel implements org.apache.thrift.TBase<ExperimentSummaryModel, ExperimentSummaryModel._Fields>, java.io.Serializable, Cloneable, Comparable<ExperimentSummaryModel> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ExperimentSummaryModel");
@@ -67,22 +40,19 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
private static final org.apache.thrift.protocol.TField EXPERIMENT_STATUS_FIELD_DESC = new org.apache.thrift.protocol.TField("experimentStatus", org.apache.thrift.protocol.TType.STRING, (short)10);
private static final org.apache.thrift.protocol.TField STATUS_UPDATE_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("statusUpdateTime", org.apache.thrift.protocol.TType.I64, (short)12);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new ExperimentSummaryModelStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ExperimentSummaryModelTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ExperimentSummaryModelStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ExperimentSummaryModelTupleSchemeFactory();
- private String experimentId; // required
- private String projectId; // required
- private String gatewayId; // required
+ private java.lang.String experimentId; // required
+ private java.lang.String projectId; // required
+ private java.lang.String gatewayId; // required
private long creationTime; // optional
- private String userName; // required
- private String name; // required
- private String description; // optional
- private String executionId; // optional
- private String resourceHostId; // optional
- private String experimentStatus; // optional
+ private java.lang.String userName; // required
+ private java.lang.String name; // required
+ private java.lang.String description; // optional
+ private java.lang.String executionId; // optional
+ private java.lang.String resourceHostId; // optional
+ private java.lang.String experimentStatus; // optional
private long statusUpdateTime; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
@@ -99,10 +69,10 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
EXPERIMENT_STATUS((short)10, "experimentStatus"),
STATUS_UPDATE_TIME((short)12, "statusUpdateTime");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -145,21 +115,21 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -168,7 +138,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -178,9 +148,9 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
private static final int __STATUSUPDATETIME_ISSET_ID = 1;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.CREATION_TIME,_Fields.DESCRIPTION,_Fields.EXECUTION_ID,_Fields.RESOURCE_HOST_ID,_Fields.EXPERIMENT_STATUS,_Fields.STATUS_UPDATE_TIME};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.EXPERIMENT_ID, new org.apache.thrift.meta_data.FieldMetaData("experimentId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.PROJECT_ID, new org.apache.thrift.meta_data.FieldMetaData("projectId", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -203,7 +173,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.STATUS_UPDATE_TIME, new org.apache.thrift.meta_data.FieldMetaData("statusUpdateTime", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ExperimentSummaryModel.class, metaDataMap);
}
@@ -211,11 +181,11 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
}
public ExperimentSummaryModel(
- String experimentId,
- String projectId,
- String gatewayId,
- String userName,
- String name)
+ java.lang.String experimentId,
+ java.lang.String projectId,
+ java.lang.String gatewayId,
+ java.lang.String userName,
+ java.lang.String name)
{
this();
this.experimentId = experimentId;
@@ -282,11 +252,11 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
this.statusUpdateTime = 0;
}
- public String getExperimentId() {
+ public java.lang.String getExperimentId() {
return this.experimentId;
}
- public void setExperimentId(String experimentId) {
+ public void setExperimentId(java.lang.String experimentId) {
this.experimentId = experimentId;
}
@@ -305,11 +275,11 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
}
}
- public String getProjectId() {
+ public java.lang.String getProjectId() {
return this.projectId;
}
- public void setProjectId(String projectId) {
+ public void setProjectId(java.lang.String projectId) {
this.projectId = projectId;
}
@@ -328,11 +298,11 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
}
}
- public String getGatewayId() {
+ public java.lang.String getGatewayId() {
return this.gatewayId;
}
- public void setGatewayId(String gatewayId) {
+ public void setGatewayId(java.lang.String gatewayId) {
this.gatewayId = gatewayId;
}
@@ -361,23 +331,23 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
}
public void unsetCreationTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
}
/** Returns true if field creationTime is set (has been assigned a value) and false otherwise */
public boolean isSetCreationTime() {
- return EncodingUtils.testBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
}
public void setCreationTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __CREATIONTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __CREATIONTIME_ISSET_ID, value);
}
- public String getUserName() {
+ public java.lang.String getUserName() {
return this.userName;
}
- public void setUserName(String userName) {
+ public void setUserName(java.lang.String userName) {
this.userName = userName;
}
@@ -396,11 +366,11 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
}
}
- public String getName() {
+ public java.lang.String getName() {
return this.name;
}
- public void setName(String name) {
+ public void setName(java.lang.String name) {
this.name = name;
}
@@ -419,11 +389,11 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
}
}
- public String getDescription() {
+ public java.lang.String getDescription() {
return this.description;
}
- public void setDescription(String description) {
+ public void setDescription(java.lang.String description) {
this.description = description;
}
@@ -442,11 +412,11 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
}
}
- public String getExecutionId() {
+ public java.lang.String getExecutionId() {
return this.executionId;
}
- public void setExecutionId(String executionId) {
+ public void setExecutionId(java.lang.String executionId) {
this.executionId = executionId;
}
@@ -465,11 +435,11 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
}
}
- public String getResourceHostId() {
+ public java.lang.String getResourceHostId() {
return this.resourceHostId;
}
- public void setResourceHostId(String resourceHostId) {
+ public void setResourceHostId(java.lang.String resourceHostId) {
this.resourceHostId = resourceHostId;
}
@@ -488,11 +458,11 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
}
}
- public String getExperimentStatus() {
+ public java.lang.String getExperimentStatus() {
return this.experimentStatus;
}
- public void setExperimentStatus(String experimentStatus) {
+ public void setExperimentStatus(java.lang.String experimentStatus) {
this.experimentStatus = experimentStatus;
}
@@ -521,25 +491,25 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
}
public void unsetStatusUpdateTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __STATUSUPDATETIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __STATUSUPDATETIME_ISSET_ID);
}
/** Returns true if field statusUpdateTime is set (has been assigned a value) and false otherwise */
public boolean isSetStatusUpdateTime() {
- return EncodingUtils.testBit(__isset_bitfield, __STATUSUPDATETIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __STATUSUPDATETIME_ISSET_ID);
}
public void setStatusUpdateTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __STATUSUPDATETIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __STATUSUPDATETIME_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case EXPERIMENT_ID:
if (value == null) {
unsetExperimentId();
} else {
- setExperimentId((String)value);
+ setExperimentId((java.lang.String)value);
}
break;
@@ -547,7 +517,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
if (value == null) {
unsetProjectId();
} else {
- setProjectId((String)value);
+ setProjectId((java.lang.String)value);
}
break;
@@ -555,7 +525,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
if (value == null) {
unsetGatewayId();
} else {
- setGatewayId((String)value);
+ setGatewayId((java.lang.String)value);
}
break;
@@ -563,7 +533,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
if (value == null) {
unsetCreationTime();
} else {
- setCreationTime((Long)value);
+ setCreationTime((java.lang.Long)value);
}
break;
@@ -571,7 +541,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
if (value == null) {
unsetUserName();
} else {
- setUserName((String)value);
+ setUserName((java.lang.String)value);
}
break;
@@ -579,7 +549,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
if (value == null) {
unsetName();
} else {
- setName((String)value);
+ setName((java.lang.String)value);
}
break;
@@ -587,7 +557,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
if (value == null) {
unsetDescription();
} else {
- setDescription((String)value);
+ setDescription((java.lang.String)value);
}
break;
@@ -595,7 +565,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
if (value == null) {
unsetExecutionId();
} else {
- setExecutionId((String)value);
+ setExecutionId((java.lang.String)value);
}
break;
@@ -603,7 +573,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
if (value == null) {
unsetResourceHostId();
} else {
- setResourceHostId((String)value);
+ setResourceHostId((java.lang.String)value);
}
break;
@@ -611,7 +581,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
if (value == null) {
unsetExperimentStatus();
} else {
- setExperimentStatus((String)value);
+ setExperimentStatus((java.lang.String)value);
}
break;
@@ -619,14 +589,14 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
if (value == null) {
unsetStatusUpdateTime();
} else {
- setStatusUpdateTime((Long)value);
+ setStatusUpdateTime((java.lang.Long)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case EXPERIMENT_ID:
return getExperimentId();
@@ -662,13 +632,13 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
return getStatusUpdateTime();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -695,11 +665,11 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
case STATUS_UPDATE_TIME:
return isSetStatusUpdateTime();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ExperimentSummaryModel)
@@ -710,6 +680,8 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
public boolean equals(ExperimentSummaryModel that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_experimentId = true && this.isSetExperimentId();
boolean that_present_experimentId = true && that.isSetExperimentId();
@@ -815,64 +787,53 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_experimentId = true && (isSetExperimentId());
- list.add(present_experimentId);
- if (present_experimentId)
- list.add(experimentId);
-
- boolean present_projectId = true && (isSetProjectId());
- list.add(present_projectId);
- if (present_projectId)
- list.add(projectId);
-
- boolean present_gatewayId = true && (isSetGatewayId());
- list.add(present_gatewayId);
- if (present_gatewayId)
- list.add(gatewayId);
-
- boolean present_creationTime = true && (isSetCreationTime());
- list.add(present_creationTime);
- if (present_creationTime)
- list.add(creationTime);
-
- boolean present_userName = true && (isSetUserName());
- list.add(present_userName);
- if (present_userName)
- list.add(userName);
-
- boolean present_name = true && (isSetName());
- list.add(present_name);
- if (present_name)
- list.add(name);
-
- boolean present_description = true && (isSetDescription());
- list.add(present_description);
- if (present_description)
- list.add(description);
-
- boolean present_executionId = true && (isSetExecutionId());
- list.add(present_executionId);
- if (present_executionId)
- list.add(executionId);
-
- boolean present_resourceHostId = true && (isSetResourceHostId());
- list.add(present_resourceHostId);
- if (present_resourceHostId)
- list.add(resourceHostId);
-
- boolean present_experimentStatus = true && (isSetExperimentStatus());
- list.add(present_experimentStatus);
- if (present_experimentStatus)
- list.add(experimentStatus);
-
- boolean present_statusUpdateTime = true && (isSetStatusUpdateTime());
- list.add(present_statusUpdateTime);
- if (present_statusUpdateTime)
- list.add(statusUpdateTime);
-
- return list.hashCode();
+ int hashCode = 1;
+
+ hashCode = hashCode * 8191 + ((isSetExperimentId()) ? 131071 : 524287);
+ if (isSetExperimentId())
+ hashCode = hashCode * 8191 + experimentId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetProjectId()) ? 131071 : 524287);
+ if (isSetProjectId())
+ hashCode = hashCode * 8191 + projectId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetGatewayId()) ? 131071 : 524287);
+ if (isSetGatewayId())
+ hashCode = hashCode * 8191 + gatewayId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetCreationTime()) ? 131071 : 524287);
+ if (isSetCreationTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(creationTime);
+
+ hashCode = hashCode * 8191 + ((isSetUserName()) ? 131071 : 524287);
+ if (isSetUserName())
+ hashCode = hashCode * 8191 + userName.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetName()) ? 131071 : 524287);
+ if (isSetName())
+ hashCode = hashCode * 8191 + name.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetDescription()) ? 131071 : 524287);
+ if (isSetDescription())
+ hashCode = hashCode * 8191 + description.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetExecutionId()) ? 131071 : 524287);
+ if (isSetExecutionId())
+ hashCode = hashCode * 8191 + executionId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetResourceHostId()) ? 131071 : 524287);
+ if (isSetResourceHostId())
+ hashCode = hashCode * 8191 + resourceHostId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetExperimentStatus()) ? 131071 : 524287);
+ if (isSetExperimentStatus())
+ hashCode = hashCode * 8191 + experimentStatus.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetStatusUpdateTime()) ? 131071 : 524287);
+ if (isSetStatusUpdateTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(statusUpdateTime);
+
+ return hashCode;
}
@Override
@@ -883,7 +844,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetExperimentId()).compareTo(other.isSetExperimentId());
+ lastComparison = java.lang.Boolean.valueOf(isSetExperimentId()).compareTo(other.isSetExperimentId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -893,7 +854,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetProjectId()).compareTo(other.isSetProjectId());
+ lastComparison = java.lang.Boolean.valueOf(isSetProjectId()).compareTo(other.isSetProjectId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -903,7 +864,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(other.isSetGatewayId());
+ lastComparison = java.lang.Boolean.valueOf(isSetGatewayId()).compareTo(other.isSetGatewayId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -913,7 +874,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCreationTime()).compareTo(other.isSetCreationTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetCreationTime()).compareTo(other.isSetCreationTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -923,7 +884,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUserName()).compareTo(other.isSetUserName());
+ lastComparison = java.lang.Boolean.valueOf(isSetUserName()).compareTo(other.isSetUserName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -933,7 +894,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetName()).compareTo(other.isSetName());
+ lastComparison = java.lang.Boolean.valueOf(isSetName()).compareTo(other.isSetName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -943,7 +904,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -953,7 +914,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetExecutionId()).compareTo(other.isSetExecutionId());
+ lastComparison = java.lang.Boolean.valueOf(isSetExecutionId()).compareTo(other.isSetExecutionId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -963,7 +924,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetResourceHostId()).compareTo(other.isSetResourceHostId());
+ lastComparison = java.lang.Boolean.valueOf(isSetResourceHostId()).compareTo(other.isSetResourceHostId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -973,7 +934,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetExperimentStatus()).compareTo(other.isSetExperimentStatus());
+ lastComparison = java.lang.Boolean.valueOf(isSetExperimentStatus()).compareTo(other.isSetExperimentStatus());
if (lastComparison != 0) {
return lastComparison;
}
@@ -983,7 +944,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetStatusUpdateTime()).compareTo(other.isSetStatusUpdateTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetStatusUpdateTime()).compareTo(other.isSetStatusUpdateTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1001,16 +962,16 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ExperimentSummaryModel(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ExperimentSummaryModel(");
boolean first = true;
sb.append("experimentId:");
@@ -1141,7 +1102,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -1151,13 +1112,13 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
}
}
- private static class ExperimentSummaryModelStandardSchemeFactory implements SchemeFactory {
+ private static class ExperimentSummaryModelStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ExperimentSummaryModelStandardScheme getScheme() {
return new ExperimentSummaryModelStandardScheme();
}
}
- private static class ExperimentSummaryModelStandardScheme extends StandardScheme<ExperimentSummaryModel> {
+ private static class ExperimentSummaryModelStandardScheme extends org.apache.thrift.scheme.StandardScheme<ExperimentSummaryModel> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ExperimentSummaryModel struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1339,23 +1300,23 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
}
- private static class ExperimentSummaryModelTupleSchemeFactory implements SchemeFactory {
+ private static class ExperimentSummaryModelTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ExperimentSummaryModelTupleScheme getScheme() {
return new ExperimentSummaryModelTupleScheme();
}
}
- private static class ExperimentSummaryModelTupleScheme extends TupleScheme<ExperimentSummaryModel> {
+ private static class ExperimentSummaryModelTupleScheme extends org.apache.thrift.scheme.TupleScheme<ExperimentSummaryModel> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ExperimentSummaryModel struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.experimentId);
oprot.writeString(struct.projectId);
oprot.writeString(struct.gatewayId);
oprot.writeString(struct.userName);
oprot.writeString(struct.name);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetCreationTime()) {
optionals.set(0);
}
@@ -1397,7 +1358,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ExperimentSummaryModel struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.experimentId = iprot.readString();
struct.setExperimentIdIsSet(true);
struct.projectId = iprot.readString();
@@ -1408,7 +1369,7 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
struct.setUserNameIsSet(true);
struct.name = iprot.readString();
struct.setNameIsSet(true);
- BitSet incoming = iprot.readBitSet(6);
+ java.util.BitSet incoming = iprot.readBitSet(6);
if (incoming.get(0)) {
struct.creationTime = iprot.readI64();
struct.setCreationTimeIsSet(true);
@@ -1436,5 +1397,8 @@ public class ExperimentSummaryModel implements org.apache.thrift.TBase<Experimen
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentType.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentType.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentType.java
index 3e0ae54..4c10281 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentType.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentType.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ProjectSearchFields.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ProjectSearchFields.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ProjectSearchFields.java
index d805c78..8110ea9 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ProjectSearchFields.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ProjectSearchFields.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
[05/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ValidationResults.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ValidationResults.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ValidationResults.java
index 9baedd4..0651523 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ValidationResults.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ValidationResults.java
@@ -16,66 +16,36 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.error;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class ValidationResults implements org.apache.thrift.TBase<ValidationResults, ValidationResults._Fields>, java.io.Serializable, Cloneable, Comparable<ValidationResults> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ValidationResults");
private static final org.apache.thrift.protocol.TField VALIDATION_STATE_FIELD_DESC = new org.apache.thrift.protocol.TField("validationState", org.apache.thrift.protocol.TType.BOOL, (short)1);
private static final org.apache.thrift.protocol.TField VALIDATION_RESULT_LIST_FIELD_DESC = new org.apache.thrift.protocol.TField("validationResultList", org.apache.thrift.protocol.TType.LIST, (short)2);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new ValidationResultsStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ValidationResultsTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ValidationResultsStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ValidationResultsTupleSchemeFactory();
private boolean validationState; // required
- private List<ValidatorResult> validationResultList; // required
+ private java.util.List<ValidatorResult> validationResultList; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
VALIDATION_STATE((short)1, "validationState"),
VALIDATION_RESULT_LIST((short)2, "validationResultList");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -100,21 +70,21 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -123,7 +93,7 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -131,15 +101,15 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
// isset id assignments
private static final int __VALIDATIONSTATE_ISSET_ID = 0;
private byte __isset_bitfield = 0;
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.VALIDATION_STATE, new org.apache.thrift.meta_data.FieldMetaData("validationState", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
tmpMap.put(_Fields.VALIDATION_RESULT_LIST, new org.apache.thrift.meta_data.FieldMetaData("validationResultList", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ValidatorResult.class))));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ValidationResults.class, metaDataMap);
}
@@ -148,7 +118,7 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
public ValidationResults(
boolean validationState,
- List<ValidatorResult> validationResultList)
+ java.util.List<ValidatorResult> validationResultList)
{
this();
this.validationState = validationState;
@@ -163,7 +133,7 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
__isset_bitfield = other.__isset_bitfield;
this.validationState = other.validationState;
if (other.isSetValidationResultList()) {
- List<ValidatorResult> __this__validationResultList = new ArrayList<ValidatorResult>(other.validationResultList.size());
+ java.util.List<ValidatorResult> __this__validationResultList = new java.util.ArrayList<ValidatorResult>(other.validationResultList.size());
for (ValidatorResult other_element : other.validationResultList) {
__this__validationResultList.add(new ValidatorResult(other_element));
}
@@ -192,16 +162,16 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
}
public void unsetValidationState() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __VALIDATIONSTATE_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __VALIDATIONSTATE_ISSET_ID);
}
/** Returns true if field validationState is set (has been assigned a value) and false otherwise */
public boolean isSetValidationState() {
- return EncodingUtils.testBit(__isset_bitfield, __VALIDATIONSTATE_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __VALIDATIONSTATE_ISSET_ID);
}
public void setValidationStateIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __VALIDATIONSTATE_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __VALIDATIONSTATE_ISSET_ID, value);
}
public int getValidationResultListSize() {
@@ -214,16 +184,16 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
public void addToValidationResultList(ValidatorResult elem) {
if (this.validationResultList == null) {
- this.validationResultList = new ArrayList<ValidatorResult>();
+ this.validationResultList = new java.util.ArrayList<ValidatorResult>();
}
this.validationResultList.add(elem);
}
- public List<ValidatorResult> getValidationResultList() {
+ public java.util.List<ValidatorResult> getValidationResultList() {
return this.validationResultList;
}
- public void setValidationResultList(List<ValidatorResult> validationResultList) {
+ public void setValidationResultList(java.util.List<ValidatorResult> validationResultList) {
this.validationResultList = validationResultList;
}
@@ -242,13 +212,13 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case VALIDATION_STATE:
if (value == null) {
unsetValidationState();
} else {
- setValidationState((Boolean)value);
+ setValidationState((java.lang.Boolean)value);
}
break;
@@ -256,14 +226,14 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
if (value == null) {
unsetValidationResultList();
} else {
- setValidationResultList((List<ValidatorResult>)value);
+ setValidationResultList((java.util.List<ValidatorResult>)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case VALIDATION_STATE:
return isValidationState();
@@ -272,13 +242,13 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
return getValidationResultList();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -287,11 +257,11 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
case VALIDATION_RESULT_LIST:
return isSetValidationResultList();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ValidationResults)
@@ -302,6 +272,8 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
public boolean equals(ValidationResults that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_validationState = true;
boolean that_present_validationState = true;
@@ -326,19 +298,15 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_validationState = true;
- list.add(present_validationState);
- if (present_validationState)
- list.add(validationState);
+ hashCode = hashCode * 8191 + ((validationState) ? 131071 : 524287);
- boolean present_validationResultList = true && (isSetValidationResultList());
- list.add(present_validationResultList);
- if (present_validationResultList)
- list.add(validationResultList);
+ hashCode = hashCode * 8191 + ((isSetValidationResultList()) ? 131071 : 524287);
+ if (isSetValidationResultList())
+ hashCode = hashCode * 8191 + validationResultList.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -349,7 +317,7 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetValidationState()).compareTo(other.isSetValidationState());
+ lastComparison = java.lang.Boolean.valueOf(isSetValidationState()).compareTo(other.isSetValidationState());
if (lastComparison != 0) {
return lastComparison;
}
@@ -359,7 +327,7 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetValidationResultList()).compareTo(other.isSetValidationResultList());
+ lastComparison = java.lang.Boolean.valueOf(isSetValidationResultList()).compareTo(other.isSetValidationResultList());
if (lastComparison != 0) {
return lastComparison;
}
@@ -377,16 +345,16 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ValidationResults(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ValidationResults(");
boolean first = true;
sb.append("validationState:");
@@ -425,7 +393,7 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -435,13 +403,13 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
}
}
- private static class ValidationResultsStandardSchemeFactory implements SchemeFactory {
+ private static class ValidationResultsStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ValidationResultsStandardScheme getScheme() {
return new ValidationResultsStandardScheme();
}
}
- private static class ValidationResultsStandardScheme extends StandardScheme<ValidationResults> {
+ private static class ValidationResultsStandardScheme extends org.apache.thrift.scheme.StandardScheme<ValidationResults> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ValidationResults struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -465,7 +433,7 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list0 = iprot.readListBegin();
- struct.validationResultList = new ArrayList<ValidatorResult>(_list0.size);
+ struct.validationResultList = new java.util.ArrayList<ValidatorResult>(_list0.size);
ValidatorResult _elem1;
for (int _i2 = 0; _i2 < _list0.size; ++_i2)
{
@@ -514,17 +482,17 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
}
- private static class ValidationResultsTupleSchemeFactory implements SchemeFactory {
+ private static class ValidationResultsTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ValidationResultsTupleScheme getScheme() {
return new ValidationResultsTupleScheme();
}
}
- private static class ValidationResultsTupleScheme extends TupleScheme<ValidationResults> {
+ private static class ValidationResultsTupleScheme extends org.apache.thrift.scheme.TupleScheme<ValidationResults> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ValidationResults struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeBool(struct.validationState);
{
oprot.writeI32(struct.validationResultList.size());
@@ -537,12 +505,12 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ValidationResults struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.validationState = iprot.readBool();
struct.setValidationStateIsSet(true);
{
org.apache.thrift.protocol.TList _list5 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.validationResultList = new ArrayList<ValidatorResult>(_list5.size);
+ struct.validationResultList = new java.util.ArrayList<ValidatorResult>(_list5.size);
ValidatorResult _elem6;
for (int _i7 = 0; _i7 < _list5.size; ++_i7)
{
@@ -555,5 +523,8 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ValidatorResult.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ValidatorResult.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ValidatorResult.java
index e3de8dc..94c18a7 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ValidatorResult.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/error/ValidatorResult.java
@@ -16,66 +16,36 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.error;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult, ValidatorResult._Fields>, java.io.Serializable, Cloneable, Comparable<ValidatorResult> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ValidatorResult");
private static final org.apache.thrift.protocol.TField RESULT_FIELD_DESC = new org.apache.thrift.protocol.TField("result", org.apache.thrift.protocol.TType.BOOL, (short)1);
private static final org.apache.thrift.protocol.TField ERROR_DETAILS_FIELD_DESC = new org.apache.thrift.protocol.TField("errorDetails", org.apache.thrift.protocol.TType.STRING, (short)2);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new ValidatorResultStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ValidatorResultTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ValidatorResultStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ValidatorResultTupleSchemeFactory();
private boolean result; // required
- private String errorDetails; // optional
+ private java.lang.String errorDetails; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
RESULT((short)1, "result"),
ERROR_DETAILS((short)2, "errorDetails");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -100,21 +70,21 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -123,7 +93,7 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -132,14 +102,14 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
private static final int __RESULT_ISSET_ID = 0;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.ERROR_DETAILS};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.RESULT, new org.apache.thrift.meta_data.FieldMetaData("result", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
tmpMap.put(_Fields.ERROR_DETAILS, new org.apache.thrift.meta_data.FieldMetaData("errorDetails", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ValidatorResult.class, metaDataMap);
}
@@ -186,23 +156,23 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
}
public void unsetResult() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __RESULT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __RESULT_ISSET_ID);
}
/** Returns true if field result is set (has been assigned a value) and false otherwise */
public boolean isSetResult() {
- return EncodingUtils.testBit(__isset_bitfield, __RESULT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __RESULT_ISSET_ID);
}
public void setResultIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __RESULT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __RESULT_ISSET_ID, value);
}
- public String getErrorDetails() {
+ public java.lang.String getErrorDetails() {
return this.errorDetails;
}
- public void setErrorDetails(String errorDetails) {
+ public void setErrorDetails(java.lang.String errorDetails) {
this.errorDetails = errorDetails;
}
@@ -221,13 +191,13 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case RESULT:
if (value == null) {
unsetResult();
} else {
- setResult((Boolean)value);
+ setResult((java.lang.Boolean)value);
}
break;
@@ -235,14 +205,14 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
if (value == null) {
unsetErrorDetails();
} else {
- setErrorDetails((String)value);
+ setErrorDetails((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case RESULT:
return isResult();
@@ -251,13 +221,13 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
return getErrorDetails();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -266,11 +236,11 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
case ERROR_DETAILS:
return isSetErrorDetails();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ValidatorResult)
@@ -281,6 +251,8 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
public boolean equals(ValidatorResult that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_result = true;
boolean that_present_result = true;
@@ -305,19 +277,15 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_result = true;
- list.add(present_result);
- if (present_result)
- list.add(result);
+ hashCode = hashCode * 8191 + ((result) ? 131071 : 524287);
- boolean present_errorDetails = true && (isSetErrorDetails());
- list.add(present_errorDetails);
- if (present_errorDetails)
- list.add(errorDetails);
+ hashCode = hashCode * 8191 + ((isSetErrorDetails()) ? 131071 : 524287);
+ if (isSetErrorDetails())
+ hashCode = hashCode * 8191 + errorDetails.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -328,7 +296,7 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetResult()).compareTo(other.isSetResult());
+ lastComparison = java.lang.Boolean.valueOf(isSetResult()).compareTo(other.isSetResult());
if (lastComparison != 0) {
return lastComparison;
}
@@ -338,7 +306,7 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetErrorDetails()).compareTo(other.isSetErrorDetails());
+ lastComparison = java.lang.Boolean.valueOf(isSetErrorDetails()).compareTo(other.isSetErrorDetails());
if (lastComparison != 0) {
return lastComparison;
}
@@ -356,16 +324,16 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ValidatorResult(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ValidatorResult(");
boolean first = true;
sb.append("result:");
@@ -402,7 +370,7 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -412,13 +380,13 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
}
}
- private static class ValidatorResultStandardSchemeFactory implements SchemeFactory {
+ private static class ValidatorResultStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ValidatorResultStandardScheme getScheme() {
return new ValidatorResultStandardScheme();
}
}
- private static class ValidatorResultStandardScheme extends StandardScheme<ValidatorResult> {
+ private static class ValidatorResultStandardScheme extends org.apache.thrift.scheme.StandardScheme<ValidatorResult> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ValidatorResult struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -475,19 +443,19 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
}
- private static class ValidatorResultTupleSchemeFactory implements SchemeFactory {
+ private static class ValidatorResultTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ValidatorResultTupleScheme getScheme() {
return new ValidatorResultTupleScheme();
}
}
- private static class ValidatorResultTupleScheme extends TupleScheme<ValidatorResult> {
+ private static class ValidatorResultTupleScheme extends org.apache.thrift.scheme.TupleScheme<ValidatorResult> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ValidatorResult struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeBool(struct.result);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetErrorDetails()) {
optionals.set(0);
}
@@ -499,10 +467,10 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ValidatorResult struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.result = iprot.readBool();
struct.setResultIsSet(true);
- BitSet incoming = iprot.readBitSet(1);
+ java.util.BitSet incoming = iprot.readBitSet(1);
if (incoming.get(0)) {
struct.errorDetails = iprot.readString();
struct.setErrorDetailsIsSet(true);
@@ -510,5 +478,8 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
[30/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/tenant/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/tenant/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/tenant/ttypes.py
index 493eaff..0f42429 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/tenant/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/tenant/ttypes.py
@@ -1,488 +1,452 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.commons.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class TenantApprovalStatus:
- REQUESTED = 0
- APPROVED = 1
- ACTIVE = 2
- DEACTIVATED = 3
- CANCELLED = 4
- DENIED = 5
- CREATED = 6
- DEPLOYED = 7
-
- _VALUES_TO_NAMES = {
- 0: "REQUESTED",
- 1: "APPROVED",
- 2: "ACTIVE",
- 3: "DEACTIVATED",
- 4: "CANCELLED",
- 5: "DENIED",
- 6: "CREATED",
- 7: "DEPLOYED",
- }
-
- _NAMES_TO_VALUES = {
- "REQUESTED": 0,
- "APPROVED": 1,
- "ACTIVE": 2,
- "DEACTIVATED": 3,
- "CANCELLED": 4,
- "DENIED": 5,
- "CREATED": 6,
- "DEPLOYED": 7,
- }
-
-
-class TenantPreferences:
- """
- Attributes:
- - tenantAdminFirstName
- - tenantAdminLastName
- - tenantAdminEmail
- """
-
- thrift_spec = (
- None, # 0
- None, # 1
- None, # 2
- None, # 3
- None, # 4
- None, # 5
- None, # 6
- None, # 7
- None, # 8
- None, # 9
- (10, TType.STRING, 'tenantAdminFirstName', None, None, ), # 10
- (11, TType.STRING, 'tenantAdminLastName', None, None, ), # 11
- (12, TType.STRING, 'tenantAdminEmail', None, None, ), # 12
- )
-
- def __init__(self, tenantAdminFirstName=None, tenantAdminLastName=None, tenantAdminEmail=None,):
- self.tenantAdminFirstName = tenantAdminFirstName
- self.tenantAdminLastName = tenantAdminLastName
- self.tenantAdminEmail = tenantAdminEmail
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 10:
- if ftype == TType.STRING:
- self.tenantAdminFirstName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 11:
- if ftype == TType.STRING:
- self.tenantAdminLastName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 12:
- if ftype == TType.STRING:
- self.tenantAdminEmail = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('TenantPreferences')
- if self.tenantAdminFirstName is not None:
- oprot.writeFieldBegin('tenantAdminFirstName', TType.STRING, 10)
- oprot.writeString(self.tenantAdminFirstName)
- oprot.writeFieldEnd()
- if self.tenantAdminLastName is not None:
- oprot.writeFieldBegin('tenantAdminLastName', TType.STRING, 11)
- oprot.writeString(self.tenantAdminLastName)
- oprot.writeFieldEnd()
- if self.tenantAdminEmail is not None:
- oprot.writeFieldBegin('tenantAdminEmail', TType.STRING, 12)
- oprot.writeString(self.tenantAdminEmail)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.tenantAdminFirstName)
- value = (value * 31) ^ hash(self.tenantAdminLastName)
- value = (value * 31) ^ hash(self.tenantAdminEmail)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class TenantConfig:
- """
- Attributes:
- - oauthClientId
- - oauthClientSecret
- - identityServerUserName
- - identityServerPasswordToken
- """
-
- thrift_spec = (
- None, # 0
- None, # 1
- None, # 2
- None, # 3
- None, # 4
- None, # 5
- None, # 6
- None, # 7
- None, # 8
- None, # 9
- None, # 10
- None, # 11
- None, # 12
- (13, TType.STRING, 'identityServerUserName', None, None, ), # 13
- (14, TType.STRING, 'identityServerPasswordToken', None, None, ), # 14
- None, # 15
- (16, TType.STRING, 'oauthClientId', None, None, ), # 16
- (17, TType.STRING, 'oauthClientSecret', None, None, ), # 17
- )
-
- def __init__(self, oauthClientId=None, oauthClientSecret=None, identityServerUserName=None, identityServerPasswordToken=None,):
- self.oauthClientId = oauthClientId
- self.oauthClientSecret = oauthClientSecret
- self.identityServerUserName = identityServerUserName
- self.identityServerPasswordToken = identityServerPasswordToken
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 16:
- if ftype == TType.STRING:
- self.oauthClientId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 17:
- if ftype == TType.STRING:
- self.oauthClientSecret = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 13:
- if ftype == TType.STRING:
- self.identityServerUserName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 14:
- if ftype == TType.STRING:
- self.identityServerPasswordToken = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('TenantConfig')
- if self.identityServerUserName is not None:
- oprot.writeFieldBegin('identityServerUserName', TType.STRING, 13)
- oprot.writeString(self.identityServerUserName)
- oprot.writeFieldEnd()
- if self.identityServerPasswordToken is not None:
- oprot.writeFieldBegin('identityServerPasswordToken', TType.STRING, 14)
- oprot.writeString(self.identityServerPasswordToken)
- oprot.writeFieldEnd()
- if self.oauthClientId is not None:
- oprot.writeFieldBegin('oauthClientId', TType.STRING, 16)
- oprot.writeString(self.oauthClientId)
- oprot.writeFieldEnd()
- if self.oauthClientSecret is not None:
- oprot.writeFieldBegin('oauthClientSecret', TType.STRING, 17)
- oprot.writeString(self.oauthClientSecret)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.oauthClientId)
- value = (value * 31) ^ hash(self.oauthClientSecret)
- value = (value * 31) ^ hash(self.identityServerUserName)
- value = (value * 31) ^ hash(self.identityServerPasswordToken)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class Tenant:
- """
- Attributes:
- - tenantId
- - tenantApprovalStatus
- - tenantName
- - domain
- - emailAddress
- - tenantAcronym
- - tenantURL
- - tenantPublicAbstract
- - reviewProposalDescription
- - declinedReason
- - requestCreationTime
- - requesterUsername
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'tenantId', None, None, ), # 1
- (2, TType.I32, 'tenantApprovalStatus', None, None, ), # 2
- (3, TType.STRING, 'tenantName', None, None, ), # 3
- (4, TType.STRING, 'domain', None, None, ), # 4
- (5, TType.STRING, 'emailAddress', None, None, ), # 5
- (6, TType.STRING, 'tenantAcronym', None, None, ), # 6
- (7, TType.STRING, 'tenantURL', None, None, ), # 7
- (8, TType.STRING, 'tenantPublicAbstract', None, None, ), # 8
- (9, TType.STRING, 'reviewProposalDescription', None, None, ), # 9
- None, # 10
- None, # 11
- None, # 12
- None, # 13
- None, # 14
- (15, TType.STRING, 'declinedReason', None, None, ), # 15
- None, # 16
- None, # 17
- (18, TType.I64, 'requestCreationTime', None, None, ), # 18
- (19, TType.STRING, 'requesterUsername', None, None, ), # 19
- )
-
- def __init__(self, tenantId=None, tenantApprovalStatus=None, tenantName=None, domain=None, emailAddress=None, tenantAcronym=None, tenantURL=None, tenantPublicAbstract=None, reviewProposalDescription=None, declinedReason=None, requestCreationTime=None, requesterUsername=None,):
- self.tenantId = tenantId
- self.tenantApprovalStatus = tenantApprovalStatus
- self.tenantName = tenantName
- self.domain = domain
- self.emailAddress = emailAddress
- self.tenantAcronym = tenantAcronym
- self.tenantURL = tenantURL
- self.tenantPublicAbstract = tenantPublicAbstract
- self.reviewProposalDescription = reviewProposalDescription
- self.declinedReason = declinedReason
- self.requestCreationTime = requestCreationTime
- self.requesterUsername = requesterUsername
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.tenantId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.tenantApprovalStatus = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.tenantName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.domain = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.emailAddress = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.tenantAcronym = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.STRING:
- self.tenantURL = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.STRING:
- self.tenantPublicAbstract = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.STRING:
- self.reviewProposalDescription = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 15:
- if ftype == TType.STRING:
- self.declinedReason = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 18:
- if ftype == TType.I64:
- self.requestCreationTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 19:
- if ftype == TType.STRING:
- self.requesterUsername = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('Tenant')
- if self.tenantId is not None:
- oprot.writeFieldBegin('tenantId', TType.STRING, 1)
- oprot.writeString(self.tenantId)
- oprot.writeFieldEnd()
- if self.tenantApprovalStatus is not None:
- oprot.writeFieldBegin('tenantApprovalStatus', TType.I32, 2)
- oprot.writeI32(self.tenantApprovalStatus)
- oprot.writeFieldEnd()
- if self.tenantName is not None:
- oprot.writeFieldBegin('tenantName', TType.STRING, 3)
- oprot.writeString(self.tenantName)
- oprot.writeFieldEnd()
- if self.domain is not None:
- oprot.writeFieldBegin('domain', TType.STRING, 4)
- oprot.writeString(self.domain)
- oprot.writeFieldEnd()
- if self.emailAddress is not None:
- oprot.writeFieldBegin('emailAddress', TType.STRING, 5)
- oprot.writeString(self.emailAddress)
- oprot.writeFieldEnd()
- if self.tenantAcronym is not None:
- oprot.writeFieldBegin('tenantAcronym', TType.STRING, 6)
- oprot.writeString(self.tenantAcronym)
- oprot.writeFieldEnd()
- if self.tenantURL is not None:
- oprot.writeFieldBegin('tenantURL', TType.STRING, 7)
- oprot.writeString(self.tenantURL)
- oprot.writeFieldEnd()
- if self.tenantPublicAbstract is not None:
- oprot.writeFieldBegin('tenantPublicAbstract', TType.STRING, 8)
- oprot.writeString(self.tenantPublicAbstract)
- oprot.writeFieldEnd()
- if self.reviewProposalDescription is not None:
- oprot.writeFieldBegin('reviewProposalDescription', TType.STRING, 9)
- oprot.writeString(self.reviewProposalDescription)
- oprot.writeFieldEnd()
- if self.declinedReason is not None:
- oprot.writeFieldBegin('declinedReason', TType.STRING, 15)
- oprot.writeString(self.declinedReason)
- oprot.writeFieldEnd()
- if self.requestCreationTime is not None:
- oprot.writeFieldBegin('requestCreationTime', TType.I64, 18)
- oprot.writeI64(self.requestCreationTime)
- oprot.writeFieldEnd()
- if self.requesterUsername is not None:
- oprot.writeFieldBegin('requesterUsername', TType.STRING, 19)
- oprot.writeString(self.requesterUsername)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.tenantId is None:
- raise TProtocol.TProtocolException(message='Required field tenantId is unset!')
- if self.tenantApprovalStatus is None:
- raise TProtocol.TProtocolException(message='Required field tenantApprovalStatus is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.tenantId)
- value = (value * 31) ^ hash(self.tenantApprovalStatus)
- value = (value * 31) ^ hash(self.tenantName)
- value = (value * 31) ^ hash(self.domain)
- value = (value * 31) ^ hash(self.emailAddress)
- value = (value * 31) ^ hash(self.tenantAcronym)
- value = (value * 31) ^ hash(self.tenantURL)
- value = (value * 31) ^ hash(self.tenantPublicAbstract)
- value = (value * 31) ^ hash(self.reviewProposalDescription)
- value = (value * 31) ^ hash(self.declinedReason)
- value = (value * 31) ^ hash(self.requestCreationTime)
- value = (value * 31) ^ hash(self.requesterUsername)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class TenantApprovalStatus(object):
+ REQUESTED = 0
+ APPROVED = 1
+ ACTIVE = 2
+ DEACTIVATED = 3
+ CANCELLED = 4
+ DENIED = 5
+ CREATED = 6
+ DEPLOYED = 7
+
+ _VALUES_TO_NAMES = {
+ 0: "REQUESTED",
+ 1: "APPROVED",
+ 2: "ACTIVE",
+ 3: "DEACTIVATED",
+ 4: "CANCELLED",
+ 5: "DENIED",
+ 6: "CREATED",
+ 7: "DEPLOYED",
+ }
+
+ _NAMES_TO_VALUES = {
+ "REQUESTED": 0,
+ "APPROVED": 1,
+ "ACTIVE": 2,
+ "DEACTIVATED": 3,
+ "CANCELLED": 4,
+ "DENIED": 5,
+ "CREATED": 6,
+ "DEPLOYED": 7,
+ }
+
+
+class TenantPreferences(object):
+ """
+ Attributes:
+ - tenantAdminFirstName
+ - tenantAdminLastName
+ - tenantAdminEmail
+ """
+
+ thrift_spec = (
+ None, # 0
+ None, # 1
+ None, # 2
+ None, # 3
+ None, # 4
+ None, # 5
+ None, # 6
+ None, # 7
+ None, # 8
+ None, # 9
+ (10, TType.STRING, 'tenantAdminFirstName', 'UTF8', None, ), # 10
+ (11, TType.STRING, 'tenantAdminLastName', 'UTF8', None, ), # 11
+ (12, TType.STRING, 'tenantAdminEmail', 'UTF8', None, ), # 12
+ )
+
+ def __init__(self, tenantAdminFirstName=None, tenantAdminLastName=None, tenantAdminEmail=None,):
+ self.tenantAdminFirstName = tenantAdminFirstName
+ self.tenantAdminLastName = tenantAdminLastName
+ self.tenantAdminEmail = tenantAdminEmail
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 10:
+ if ftype == TType.STRING:
+ self.tenantAdminFirstName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 11:
+ if ftype == TType.STRING:
+ self.tenantAdminLastName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 12:
+ if ftype == TType.STRING:
+ self.tenantAdminEmail = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('TenantPreferences')
+ if self.tenantAdminFirstName is not None:
+ oprot.writeFieldBegin('tenantAdminFirstName', TType.STRING, 10)
+ oprot.writeString(self.tenantAdminFirstName.encode('utf-8') if sys.version_info[0] == 2 else self.tenantAdminFirstName)
+ oprot.writeFieldEnd()
+ if self.tenantAdminLastName is not None:
+ oprot.writeFieldBegin('tenantAdminLastName', TType.STRING, 11)
+ oprot.writeString(self.tenantAdminLastName.encode('utf-8') if sys.version_info[0] == 2 else self.tenantAdminLastName)
+ oprot.writeFieldEnd()
+ if self.tenantAdminEmail is not None:
+ oprot.writeFieldBegin('tenantAdminEmail', TType.STRING, 12)
+ oprot.writeString(self.tenantAdminEmail.encode('utf-8') if sys.version_info[0] == 2 else self.tenantAdminEmail)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class TenantConfig(object):
+ """
+ Attributes:
+ - oauthClientId
+ - oauthClientSecret
+ - identityServerUserName
+ - identityServerPasswordToken
+ """
+
+ thrift_spec = (
+ None, # 0
+ None, # 1
+ None, # 2
+ None, # 3
+ None, # 4
+ None, # 5
+ None, # 6
+ None, # 7
+ None, # 8
+ None, # 9
+ None, # 10
+ None, # 11
+ None, # 12
+ (13, TType.STRING, 'identityServerUserName', 'UTF8', None, ), # 13
+ (14, TType.STRING, 'identityServerPasswordToken', 'UTF8', None, ), # 14
+ None, # 15
+ (16, TType.STRING, 'oauthClientId', 'UTF8', None, ), # 16
+ (17, TType.STRING, 'oauthClientSecret', 'UTF8', None, ), # 17
+ )
+
+ def __init__(self, oauthClientId=None, oauthClientSecret=None, identityServerUserName=None, identityServerPasswordToken=None,):
+ self.oauthClientId = oauthClientId
+ self.oauthClientSecret = oauthClientSecret
+ self.identityServerUserName = identityServerUserName
+ self.identityServerPasswordToken = identityServerPasswordToken
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 16:
+ if ftype == TType.STRING:
+ self.oauthClientId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 17:
+ if ftype == TType.STRING:
+ self.oauthClientSecret = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 13:
+ if ftype == TType.STRING:
+ self.identityServerUserName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 14:
+ if ftype == TType.STRING:
+ self.identityServerPasswordToken = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('TenantConfig')
+ if self.identityServerUserName is not None:
+ oprot.writeFieldBegin('identityServerUserName', TType.STRING, 13)
+ oprot.writeString(self.identityServerUserName.encode('utf-8') if sys.version_info[0] == 2 else self.identityServerUserName)
+ oprot.writeFieldEnd()
+ if self.identityServerPasswordToken is not None:
+ oprot.writeFieldBegin('identityServerPasswordToken', TType.STRING, 14)
+ oprot.writeString(self.identityServerPasswordToken.encode('utf-8') if sys.version_info[0] == 2 else self.identityServerPasswordToken)
+ oprot.writeFieldEnd()
+ if self.oauthClientId is not None:
+ oprot.writeFieldBegin('oauthClientId', TType.STRING, 16)
+ oprot.writeString(self.oauthClientId.encode('utf-8') if sys.version_info[0] == 2 else self.oauthClientId)
+ oprot.writeFieldEnd()
+ if self.oauthClientSecret is not None:
+ oprot.writeFieldBegin('oauthClientSecret', TType.STRING, 17)
+ oprot.writeString(self.oauthClientSecret.encode('utf-8') if sys.version_info[0] == 2 else self.oauthClientSecret)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class Tenant(object):
+ """
+ Attributes:
+ - tenantId
+ - tenantApprovalStatus
+ - tenantName
+ - domain
+ - emailAddress
+ - tenantAcronym
+ - tenantURL
+ - tenantPublicAbstract
+ - reviewProposalDescription
+ - declinedReason
+ - requestCreationTime
+ - requesterUsername
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'tenantId', 'UTF8', None, ), # 1
+ (2, TType.I32, 'tenantApprovalStatus', None, None, ), # 2
+ (3, TType.STRING, 'tenantName', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'domain', 'UTF8', None, ), # 4
+ (5, TType.STRING, 'emailAddress', 'UTF8', None, ), # 5
+ (6, TType.STRING, 'tenantAcronym', 'UTF8', None, ), # 6
+ (7, TType.STRING, 'tenantURL', 'UTF8', None, ), # 7
+ (8, TType.STRING, 'tenantPublicAbstract', 'UTF8', None, ), # 8
+ (9, TType.STRING, 'reviewProposalDescription', 'UTF8', None, ), # 9
+ None, # 10
+ None, # 11
+ None, # 12
+ None, # 13
+ None, # 14
+ (15, TType.STRING, 'declinedReason', 'UTF8', None, ), # 15
+ None, # 16
+ None, # 17
+ (18, TType.I64, 'requestCreationTime', None, None, ), # 18
+ (19, TType.STRING, 'requesterUsername', 'UTF8', None, ), # 19
+ )
+
+ def __init__(self, tenantId=None, tenantApprovalStatus=None, tenantName=None, domain=None, emailAddress=None, tenantAcronym=None, tenantURL=None, tenantPublicAbstract=None, reviewProposalDescription=None, declinedReason=None, requestCreationTime=None, requesterUsername=None,):
+ self.tenantId = tenantId
+ self.tenantApprovalStatus = tenantApprovalStatus
+ self.tenantName = tenantName
+ self.domain = domain
+ self.emailAddress = emailAddress
+ self.tenantAcronym = tenantAcronym
+ self.tenantURL = tenantURL
+ self.tenantPublicAbstract = tenantPublicAbstract
+ self.reviewProposalDescription = reviewProposalDescription
+ self.declinedReason = declinedReason
+ self.requestCreationTime = requestCreationTime
+ self.requesterUsername = requesterUsername
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.tenantId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I32:
+ self.tenantApprovalStatus = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.tenantName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.domain = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRING:
+ self.emailAddress = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.tenantAcronym = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.STRING:
+ self.tenantURL = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.STRING:
+ self.tenantPublicAbstract = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.STRING:
+ self.reviewProposalDescription = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 15:
+ if ftype == TType.STRING:
+ self.declinedReason = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 18:
+ if ftype == TType.I64:
+ self.requestCreationTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 19:
+ if ftype == TType.STRING:
+ self.requesterUsername = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('Tenant')
+ if self.tenantId is not None:
+ oprot.writeFieldBegin('tenantId', TType.STRING, 1)
+ oprot.writeString(self.tenantId.encode('utf-8') if sys.version_info[0] == 2 else self.tenantId)
+ oprot.writeFieldEnd()
+ if self.tenantApprovalStatus is not None:
+ oprot.writeFieldBegin('tenantApprovalStatus', TType.I32, 2)
+ oprot.writeI32(self.tenantApprovalStatus)
+ oprot.writeFieldEnd()
+ if self.tenantName is not None:
+ oprot.writeFieldBegin('tenantName', TType.STRING, 3)
+ oprot.writeString(self.tenantName.encode('utf-8') if sys.version_info[0] == 2 else self.tenantName)
+ oprot.writeFieldEnd()
+ if self.domain is not None:
+ oprot.writeFieldBegin('domain', TType.STRING, 4)
+ oprot.writeString(self.domain.encode('utf-8') if sys.version_info[0] == 2 else self.domain)
+ oprot.writeFieldEnd()
+ if self.emailAddress is not None:
+ oprot.writeFieldBegin('emailAddress', TType.STRING, 5)
+ oprot.writeString(self.emailAddress.encode('utf-8') if sys.version_info[0] == 2 else self.emailAddress)
+ oprot.writeFieldEnd()
+ if self.tenantAcronym is not None:
+ oprot.writeFieldBegin('tenantAcronym', TType.STRING, 6)
+ oprot.writeString(self.tenantAcronym.encode('utf-8') if sys.version_info[0] == 2 else self.tenantAcronym)
+ oprot.writeFieldEnd()
+ if self.tenantURL is not None:
+ oprot.writeFieldBegin('tenantURL', TType.STRING, 7)
+ oprot.writeString(self.tenantURL.encode('utf-8') if sys.version_info[0] == 2 else self.tenantURL)
+ oprot.writeFieldEnd()
+ if self.tenantPublicAbstract is not None:
+ oprot.writeFieldBegin('tenantPublicAbstract', TType.STRING, 8)
+ oprot.writeString(self.tenantPublicAbstract.encode('utf-8') if sys.version_info[0] == 2 else self.tenantPublicAbstract)
+ oprot.writeFieldEnd()
+ if self.reviewProposalDescription is not None:
+ oprot.writeFieldBegin('reviewProposalDescription', TType.STRING, 9)
+ oprot.writeString(self.reviewProposalDescription.encode('utf-8') if sys.version_info[0] == 2 else self.reviewProposalDescription)
+ oprot.writeFieldEnd()
+ if self.declinedReason is not None:
+ oprot.writeFieldBegin('declinedReason', TType.STRING, 15)
+ oprot.writeString(self.declinedReason.encode('utf-8') if sys.version_info[0] == 2 else self.declinedReason)
+ oprot.writeFieldEnd()
+ if self.requestCreationTime is not None:
+ oprot.writeFieldBegin('requestCreationTime', TType.I64, 18)
+ oprot.writeI64(self.requestCreationTime)
+ oprot.writeFieldEnd()
+ if self.requesterUsername is not None:
+ oprot.writeFieldBegin('requesterUsername', TType.STRING, 19)
+ oprot.writeString(self.requesterUsername.encode('utf-8') if sys.version_info[0] == 2 else self.requesterUsername)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.tenantId is None:
+ raise TProtocolException(message='Required field tenantId is unset!')
+ if self.tenantApprovalStatus is None:
+ raise TProtocolException(message='Required field tenantApprovalStatus is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/ttypes.py
index efe717c..b77af5f4 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/ttypes.py
@@ -1,12 +1,14 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.commons.ttypes
import apache.airavata.model.workspace.ttypes
import apache.airavata.api.error.ttypes
@@ -26,12 +28,4 @@ import apache.airavata.model.group.ttypes
import apache.airavata.model.tenant.ttypes
import credential_store_data_models.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/user/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/user/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/user/constants.py
index e3e9481..fcc6e7c 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/user/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/user/constants.py
@@ -1,12 +1,13 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
USER_PROFILE_VERSION = "1.0"
[48/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/Airavata-remote
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/Airavata-remote b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/Airavata-remote
index 6e93167..72c6ce6 100755
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/Airavata-remote
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/Airavata-remote
@@ -1,6 +1,6 @@
#!/usr/bin/env python
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
@@ -9,1262 +9,1285 @@
import sys
import pprint
-from urlparse import urlparse
-from thrift.transport import TTransport
-from thrift.transport import TSocket
-from thrift.transport import TSSLSocket
-from thrift.transport import THttpClient
-from thrift.protocol import TBinaryProtocol
+if sys.version_info[0] > 2:
+ from urllib.parse import urlparse
+else:
+ from urlparse import urlparse
+from thrift.transport import TTransport, TSocket, TSSLSocket, THttpClient
+from thrift.protocol.TBinaryProtocol import TBinaryProtocol
from apache.airavata.api import Airavata
from apache.airavata.api.ttypes import *
if len(sys.argv) <= 1 or sys.argv[1] == '--help':
- print('')
- print('Usage: ' + sys.argv[0] + ' [-h host[:port]] [-u url] [-f[ramed]] [-s[sl]] function [arg1 [arg2...]]')
- print('')
- print('Functions:')
- print(' string getAPIVersion(AuthzToken authzToken)')
- print(' bool isUserExists(AuthzToken authzToken, string gatewayId, string userName)')
- print(' string addGateway(AuthzToken authzToken, Gateway gateway)')
- print(' getAllUsersInGateway(AuthzToken authzToken, string gatewayId)')
- print(' bool updateGateway(AuthzToken authzToken, string gatewayId, Gateway updatedGateway)')
- print(' Gateway getGateway(AuthzToken authzToken, string gatewayId)')
- print(' bool deleteGateway(AuthzToken authzToken, string gatewayId)')
- print(' getAllGateways(AuthzToken authzToken)')
- print(' bool isGatewayExist(AuthzToken authzToken, string gatewayId)')
- print(' string createNotification(AuthzToken authzToken, Notification notification)')
- print(' bool updateNotification(AuthzToken authzToken, Notification notification)')
- print(' bool deleteNotification(AuthzToken authzToken, string gatewayId, string notificationId)')
- print(' Notification getNotification(AuthzToken authzToken, string gatewayId, string notificationId)')
- print(' getAllNotifications(AuthzToken authzToken, string gatewayId)')
- print(' string generateAndRegisterSSHKeys(AuthzToken authzToken, string gatewayId, string userName, string description, CredentialOwnerType credentialOwnerType)')
- print(' string registerPwdCredential(AuthzToken authzToken, string gatewayId, string portalUserName, string loginUserName, string password, string description)')
- print(' string getSSHPubKey(AuthzToken authzToken, string airavataCredStoreToken, string gatewayId)')
- print(' getAllGatewaySSHPubKeys(AuthzToken authzToken, string gatewayId)')
- print(' getAllCredentialSummaryForGateway(AuthzToken authzToken, SummaryType type, string gatewayId)')
- print(' getAllCredentialSummaryForUsersInGateway(AuthzToken authzToken, SummaryType type, string gatewayId, string userId)')
- print(' getAllGatewayPWDCredentials(AuthzToken authzToken, string gatewayId)')
- print(' bool deleteSSHPubKey(AuthzToken authzToken, string airavataCredStoreToken, string gatewayId)')
- print(' bool deletePWDCredential(AuthzToken authzToken, string airavataCredStoreToken, string gatewayId)')
- print(' string createProject(AuthzToken authzToken, string gatewayId, Project project)')
- print(' void updateProject(AuthzToken authzToken, string projectId, Project updatedProject)')
- print(' Project getProject(AuthzToken authzToken, string projectId)')
- print(' bool deleteProject(AuthzToken authzToken, string projectId)')
- print(' getUserProjects(AuthzToken authzToken, string gatewayId, string userName, i32 limit, i32 offset)')
- print(' searchProjects(AuthzToken authzToken, string gatewayId, string userName, filters, i32 limit, i32 offset)')
- print(' searchExperiments(AuthzToken authzToken, string gatewayId, string userName, filters, i32 limit, i32 offset)')
- print(' ExperimentStatistics getExperimentStatistics(AuthzToken authzToken, string gatewayId, i64 fromTime, i64 toTime, string userName, string applicationName, string resourceHostName)')
- print(' getExperimentsInProject(AuthzToken authzToken, string projectId, i32 limit, i32 offset)')
- print(' getUserExperiments(AuthzToken authzToken, string gatewayId, string userName, i32 limit, i32 offset)')
- print(' string createExperiment(AuthzToken authzToken, string gatewayId, ExperimentModel experiment)')
- print(' bool deleteExperiment(AuthzToken authzToken, string experimentId)')
- print(' ExperimentModel getExperiment(AuthzToken authzToken, string airavataExperimentId)')
- print(' ExperimentModel getExperimentByAdmin(AuthzToken authzToken, string airavataExperimentId)')
- print(' ExperimentModel getDetailedExperimentTree(AuthzToken authzToken, string airavataExperimentId)')
- print(' void updateExperiment(AuthzToken authzToken, string airavataExperimentId, ExperimentModel experiment)')
- print(' void updateExperimentConfiguration(AuthzToken authzToken, string airavataExperimentId, UserConfigurationDataModel userConfiguration)')
- print(' void updateResourceScheduleing(AuthzToken authzToken, string airavataExperimentId, ComputationalResourceSchedulingModel resourceScheduling)')
- print(' bool validateExperiment(AuthzToken authzToken, string airavataExperimentId)')
- print(' void launchExperiment(AuthzToken authzToken, string airavataExperimentId, string gatewayId)')
- print(' ExperimentStatus getExperimentStatus(AuthzToken authzToken, string airavataExperimentId)')
- print(' getExperimentOutputs(AuthzToken authzToken, string airavataExperimentId)')
- print(' getIntermediateOutputs(AuthzToken authzToken, string airavataExperimentId)')
- print(' getJobStatuses(AuthzToken authzToken, string airavataExperimentId)')
- print(' getJobDetails(AuthzToken authzToken, string airavataExperimentId)')
- print(' string cloneExperiment(AuthzToken authzToken, string existingExperimentID, string newExperimentName, string newExperimentProjectId)')
- print(' string cloneExperimentByAdmin(AuthzToken authzToken, string existingExperimentID, string newExperimentName, string newExperimentProjectId)')
- print(' void terminateExperiment(AuthzToken authzToken, string airavataExperimentId, string gatewayId)')
- print(' string registerApplicationModule(AuthzToken authzToken, string gatewayId, ApplicationModule applicationModule)')
- print(' ApplicationModule getApplicationModule(AuthzToken authzToken, string appModuleId)')
- print(' bool updateApplicationModule(AuthzToken authzToken, string appModuleId, ApplicationModule applicationModule)')
- print(' getAllAppModules(AuthzToken authzToken, string gatewayId)')
- print(' bool deleteApplicationModule(AuthzToken authzToken, string appModuleId)')
- print(' string registerApplicationDeployment(AuthzToken authzToken, string gatewayId, ApplicationDeploymentDescription applicationDeployment)')
- print(' ApplicationDeploymentDescription getApplicationDeployment(AuthzToken authzToken, string appDeploymentId)')
- print(' bool updateApplicationDeployment(AuthzToken authzToken, string appDeploymentId, ApplicationDeploymentDescription applicationDeployment)')
- print(' bool deleteApplicationDeployment(AuthzToken authzToken, string appDeploymentId)')
- print(' getAllApplicationDeployments(AuthzToken authzToken, string gatewayId)')
- print(' getAppModuleDeployedResources(AuthzToken authzToken, string appModuleId)')
- print(' string registerApplicationInterface(AuthzToken authzToken, string gatewayId, ApplicationInterfaceDescription applicationInterface)')
- print(' string cloneApplicationInterface(AuthzToken authzToken, string existingAppInterfaceID, string newApplicationName, string gatewayId)')
- print(' ApplicationInterfaceDescription getApplicationInterface(AuthzToken authzToken, string appInterfaceId)')
- print(' bool updateApplicationInterface(AuthzToken authzToken, string appInterfaceId, ApplicationInterfaceDescription applicationInterface)')
- print(' bool deleteApplicationInterface(AuthzToken authzToken, string appInterfaceId)')
- print(' getAllApplicationInterfaceNames(AuthzToken authzToken, string gatewayId)')
- print(' getAllApplicationInterfaces(AuthzToken authzToken, string gatewayId)')
- print(' getApplicationInputs(AuthzToken authzToken, string appInterfaceId)')
- print(' getApplicationOutputs(AuthzToken authzToken, string appInterfaceId)')
- print(' getAvailableAppInterfaceComputeResources(AuthzToken authzToken, string appInterfaceId)')
- print(' string registerComputeResource(AuthzToken authzToken, ComputeResourceDescription computeResourceDescription)')
- print(' ComputeResourceDescription getComputeResource(AuthzToken authzToken, string computeResourceId)')
- print(' getAllComputeResourceNames(AuthzToken authzToken)')
- print(' bool updateComputeResource(AuthzToken authzToken, string computeResourceId, ComputeResourceDescription computeResourceDescription)')
- print(' bool deleteComputeResource(AuthzToken authzToken, string computeResourceId)')
- print(' string registerStorageResource(AuthzToken authzToken, StorageResourceDescription storageResourceDescription)')
- print(' StorageResourceDescription getStorageResource(AuthzToken authzToken, string storageResourceId)')
- print(' getAllStorageResourceNames(AuthzToken authzToken)')
- print(' bool updateStorageResource(AuthzToken authzToken, string storageResourceId, StorageResourceDescription storageResourceDescription)')
- print(' bool deleteStorageResource(AuthzToken authzToken, string storageResourceId)')
- print(' string addLocalSubmissionDetails(AuthzToken authzToken, string computeResourceId, i32 priorityOrder, LOCALSubmission localSubmission)')
- print(' bool updateLocalSubmissionDetails(AuthzToken authzToken, string jobSubmissionInterfaceId, LOCALSubmission localSubmission)')
- print(' LOCALSubmission getLocalJobSubmission(AuthzToken authzToken, string jobSubmissionId)')
- print(' string addSSHJobSubmissionDetails(AuthzToken authzToken, string computeResourceId, i32 priorityOrder, SSHJobSubmission sshJobSubmission)')
- print(' string addSSHForkJobSubmissionDetails(AuthzToken authzToken, string computeResourceId, i32 priorityOrder, SSHJobSubmission sshJobSubmission)')
- print(' SSHJobSubmission getSSHJobSubmission(AuthzToken authzToken, string jobSubmissionId)')
- print(' string addUNICOREJobSubmissionDetails(AuthzToken authzToken, string computeResourceId, i32 priorityOrder, UnicoreJobSubmission unicoreJobSubmission)')
- print(' UnicoreJobSubmission getUnicoreJobSubmission(AuthzToken authzToken, string jobSubmissionId)')
- print(' string addCloudJobSubmissionDetails(AuthzToken authzToken, string computeResourceId, i32 priorityOrder, CloudJobSubmission cloudSubmission)')
- print(' CloudJobSubmission getCloudJobSubmission(AuthzToken authzToken, string jobSubmissionId)')
- print(' bool updateSSHJobSubmissionDetails(AuthzToken authzToken, string jobSubmissionInterfaceId, SSHJobSubmission sshJobSubmission)')
- print(' bool updateCloudJobSubmissionDetails(AuthzToken authzToken, string jobSubmissionInterfaceId, CloudJobSubmission sshJobSubmission)')
- print(' bool updateUnicoreJobSubmissionDetails(AuthzToken authzToken, string jobSubmissionInterfaceId, UnicoreJobSubmission unicoreJobSubmission)')
- print(' string addLocalDataMovementDetails(AuthzToken authzToken, string productUri, DMType dataMoveType, i32 priorityOrder, LOCALDataMovement localDataMovement)')
- print(' bool updateLocalDataMovementDetails(AuthzToken authzToken, string dataMovementInterfaceId, LOCALDataMovement localDataMovement)')
- print(' LOCALDataMovement getLocalDataMovement(AuthzToken authzToken, string dataMovementId)')
- print(' string addSCPDataMovementDetails(AuthzToken authzToken, string productUri, DMType dataMoveType, i32 priorityOrder, SCPDataMovement scpDataMovement)')
- print(' bool updateSCPDataMovementDetails(AuthzToken authzToken, string dataMovementInterfaceId, SCPDataMovement scpDataMovement)')
- print(' SCPDataMovement getSCPDataMovement(AuthzToken authzToken, string dataMovementId)')
- print(' string addUnicoreDataMovementDetails(AuthzToken authzToken, string productUri, DMType dataMoveType, i32 priorityOrder, UnicoreDataMovement unicoreDataMovement)')
- print(' bool updateUnicoreDataMovementDetails(AuthzToken authzToken, string dataMovementInterfaceId, UnicoreDataMovement unicoreDataMovement)')
- print(' UnicoreDataMovement getUnicoreDataMovement(AuthzToken authzToken, string dataMovementId)')
- print(' string addGridFTPDataMovementDetails(AuthzToken authzToken, string productUri, DMType dataMoveType, i32 priorityOrder, GridFTPDataMovement gridFTPDataMovement)')
- print(' bool updateGridFTPDataMovementDetails(AuthzToken authzToken, string dataMovementInterfaceId, GridFTPDataMovement gridFTPDataMovement)')
- print(' GridFTPDataMovement getGridFTPDataMovement(AuthzToken authzToken, string dataMovementId)')
- print(' bool changeJobSubmissionPriority(AuthzToken authzToken, string jobSubmissionInterfaceId, i32 newPriorityOrder)')
- print(' bool changeDataMovementPriority(AuthzToken authzToken, string dataMovementInterfaceId, i32 newPriorityOrder)')
- print(' bool changeJobSubmissionPriorities(AuthzToken authzToken, jobSubmissionPriorityMap)')
- print(' bool changeDataMovementPriorities(AuthzToken authzToken, dataMovementPriorityMap)')
- print(' bool deleteJobSubmissionInterface(AuthzToken authzToken, string computeResourceId, string jobSubmissionInterfaceId)')
- print(' bool deleteDataMovementInterface(AuthzToken authzToken, string productUri, string dataMovementInterfaceId, DMType dataMoveType)')
- print(' string registerResourceJobManager(AuthzToken authzToken, ResourceJobManager resourceJobManager)')
- print(' bool updateResourceJobManager(AuthzToken authzToken, string resourceJobManagerId, ResourceJobManager updatedResourceJobManager)')
- print(' ResourceJobManager getResourceJobManager(AuthzToken authzToken, string resourceJobManagerId)')
- print(' bool deleteResourceJobManager(AuthzToken authzToken, string resourceJobManagerId)')
- print(' bool deleteBatchQueue(AuthzToken authzToken, string computeResourceId, string queueName)')
- print(' string registerGatewayResourceProfile(AuthzToken authzToken, GatewayResourceProfile gatewayResourceProfile)')
- print(' GatewayResourceProfile getGatewayResourceProfile(AuthzToken authzToken, string gatewayID)')
- print(' bool updateGatewayResourceProfile(AuthzToken authzToken, string gatewayID, GatewayResourceProfile gatewayResourceProfile)')
- print(' bool deleteGatewayResourceProfile(AuthzToken authzToken, string gatewayID)')
- print(' bool addGatewayComputeResourcePreference(AuthzToken authzToken, string gatewayID, string computeResourceId, ComputeResourcePreference computeResourcePreference)')
- print(' bool addGatewayStoragePreference(AuthzToken authzToken, string gatewayID, string storageResourceId, StoragePreference storagePreference)')
- print(' ComputeResourcePreference getGatewayComputeResourcePreference(AuthzToken authzToken, string gatewayID, string computeResourceId)')
- print(' StoragePreference getGatewayStoragePreference(AuthzToken authzToken, string gatewayID, string storageResourceId)')
- print(' getAllGatewayComputeResourcePreferences(AuthzToken authzToken, string gatewayID)')
- print(' getAllGatewayStoragePreferences(AuthzToken authzToken, string gatewayID)')
- print(' getAllGatewayResourceProfiles(AuthzToken authzToken)')
- print(' bool updateGatewayComputeResourcePreference(AuthzToken authzToken, string gatewayID, string computeResourceId, ComputeResourcePreference computeResourcePreference)')
- print(' bool updateGatewayStoragePreference(AuthzToken authzToken, string gatewayID, string storageId, StoragePreference storagePreference)')
- print(' bool deleteGatewayComputeResourcePreference(AuthzToken authzToken, string gatewayID, string computeResourceId)')
- print(' bool deleteGatewayStoragePreference(AuthzToken authzToken, string gatewayID, string storageId)')
- print(' string registerUserResourceProfile(AuthzToken authzToken, UserResourceProfile userResourceProfile)')
- print(' UserResourceProfile getUserResourceProfile(AuthzToken authzToken, string userId, string gatewayID)')
- print(' bool updateUserResourceProfile(AuthzToken authzToken, string userId, string gatewayID, UserResourceProfile userResourceProfile)')
- print(' bool deleteUserResourceProfile(AuthzToken authzToken, string userId, string gatewayID)')
- print(' bool addUserComputeResourcePreference(AuthzToken authzToken, string userId, string gatewayID, string userComputeResourceId, UserComputeResourcePreference userComputeResourcePreference)')
- print(' bool addUserStoragePreference(AuthzToken authzToken, string userId, string gatewayID, string userStorageResourceId, UserStoragePreference userStoragePreference)')
- print(' UserComputeResourcePreference getUserComputeResourcePreference(AuthzToken authzToken, string userId, string gatewayID, string userComputeResourceId)')
- print(' UserStoragePreference getUserStoragePreference(AuthzToken authzToken, string userId, string gatewayID, string userStorageResourceId)')
- print(' getAllUserComputeResourcePreferences(AuthzToken authzToken, string userId, string gatewayID)')
- print(' getAllUserStoragePreferences(AuthzToken authzToken, string userId, string gatewayID)')
- print(' getAllUserResourceProfiles(AuthzToken authzToken)')
- print(' bool updateUserComputeResourcePreference(AuthzToken authzToken, string userId, string gatewayID, string userComputeResourceId, UserComputeResourcePreference userComputeResourcePreference)')
- print(' bool updateUserStoragePreference(AuthzToken authzToken, string userId, string gatewayID, string userStorageId, UserStoragePreference userStoragePreference)')
- print(' bool deleteUserComputeResourcePreference(AuthzToken authzToken, string userId, string gatewayID, string userComputeResourceId)')
- print(' bool deleteUserStoragePreference(AuthzToken authzToken, string userId, string gatewayID, string userStorageId)')
- print(' getAllWorkflows(AuthzToken authzToken, string gatewayId)')
- print(' getLatestQueueStatuses(AuthzToken authzToken)')
- print(' WorkflowModel getWorkflow(AuthzToken authzToken, string workflowTemplateId)')
- print(' void deleteWorkflow(AuthzToken authzToken, string workflowTemplateId)')
- print(' string registerWorkflow(AuthzToken authzToken, string gatewayId, WorkflowModel workflow)')
- print(' void updateWorkflow(AuthzToken authzToken, string workflowTemplateId, WorkflowModel workflow)')
- print(' string getWorkflowTemplateId(AuthzToken authzToken, string workflowName)')
- print(' bool isWorkflowExistWithName(AuthzToken authzToken, string workflowName)')
- print(' string registerDataProduct(AuthzToken authzToken, DataProductModel dataProductModel)')
- print(' DataProductModel getDataProduct(AuthzToken authzToken, string dataProductUri)')
- print(' string registerReplicaLocation(AuthzToken authzToken, DataReplicaLocationModel replicaLocationModel)')
- print(' DataProductModel getParentDataProduct(AuthzToken authzToken, string productUri)')
- print(' getChildDataProducts(AuthzToken authzToken, string productUri)')
- print(' bool shareResourceWithUsers(AuthzToken authzToken, string resourceId, ResourceType resourceType, userPermissionList)')
- print(' bool revokeSharingOfResourceFromUsers(AuthzToken authzToken, string resourceId, ResourceType resourceType, userPermissionList)')
- print(' getAllAccessibleUsers(AuthzToken authzToken, string resourceId, ResourceType resourceType, ResourcePermissionType permissionType)')
- print(' string createGroup(AuthzToken authzToken, GroupModel groupModel)')
- print(' bool updateGroup(AuthzToken authzToken, GroupModel groupModel)')
- print(' bool deleteGroup(AuthzToken authzToken, string groupId, string ownerId)')
- print(' GroupModel getGroup(AuthzToken authzToken, string groupId)')
- print(' getAllGroupsUserBelongs(AuthzToken authzToken, string userName)')
- print('')
- sys.exit(0)
-
-pp = pprint.PrettyPrinter(indent = 2)
+ print('')
+ print('Usage: ' + sys.argv[0] + ' [-h host[:port]] [-u url] [-f[ramed]] [-s[sl]] [-novalidate] [-ca_certs certs] [-keyfile keyfile] [-certfile certfile] function [arg1 [arg2...]]')
+ print('')
+ print('Functions:')
+ print(' string getAPIVersion(AuthzToken authzToken)')
+ print(' bool isUserExists(AuthzToken authzToken, string gatewayId, string userName)')
+ print(' string addGateway(AuthzToken authzToken, Gateway gateway)')
+ print(' getAllUsersInGateway(AuthzToken authzToken, string gatewayId)')
+ print(' bool updateGateway(AuthzToken authzToken, string gatewayId, Gateway updatedGateway)')
+ print(' Gateway getGateway(AuthzToken authzToken, string gatewayId)')
+ print(' bool deleteGateway(AuthzToken authzToken, string gatewayId)')
+ print(' getAllGateways(AuthzToken authzToken)')
+ print(' bool isGatewayExist(AuthzToken authzToken, string gatewayId)')
+ print(' string createNotification(AuthzToken authzToken, Notification notification)')
+ print(' bool updateNotification(AuthzToken authzToken, Notification notification)')
+ print(' bool deleteNotification(AuthzToken authzToken, string gatewayId, string notificationId)')
+ print(' Notification getNotification(AuthzToken authzToken, string gatewayId, string notificationId)')
+ print(' getAllNotifications(AuthzToken authzToken, string gatewayId)')
+ print(' string generateAndRegisterSSHKeys(AuthzToken authzToken, string gatewayId, string userName, string description, CredentialOwnerType credentialOwnerType)')
+ print(' string registerPwdCredential(AuthzToken authzToken, string gatewayId, string portalUserName, string loginUserName, string password, string description)')
+ print(' string getSSHPubKey(AuthzToken authzToken, string airavataCredStoreToken, string gatewayId)')
+ print(' getAllGatewaySSHPubKeys(AuthzToken authzToken, string gatewayId)')
+ print(' getAllCredentialSummaryForGateway(AuthzToken authzToken, SummaryType type, string gatewayId)')
+ print(' getAllCredentialSummaryForUsersInGateway(AuthzToken authzToken, SummaryType type, string gatewayId, string userId)')
+ print(' getAllGatewayPWDCredentials(AuthzToken authzToken, string gatewayId)')
+ print(' bool deleteSSHPubKey(AuthzToken authzToken, string airavataCredStoreToken, string gatewayId)')
+ print(' bool deletePWDCredential(AuthzToken authzToken, string airavataCredStoreToken, string gatewayId)')
+ print(' string createProject(AuthzToken authzToken, string gatewayId, Project project)')
+ print(' void updateProject(AuthzToken authzToken, string projectId, Project updatedProject)')
+ print(' Project getProject(AuthzToken authzToken, string projectId)')
+ print(' bool deleteProject(AuthzToken authzToken, string projectId)')
+ print(' getUserProjects(AuthzToken authzToken, string gatewayId, string userName, i32 limit, i32 offset)')
+ print(' searchProjects(AuthzToken authzToken, string gatewayId, string userName, filters, i32 limit, i32 offset)')
+ print(' searchExperiments(AuthzToken authzToken, string gatewayId, string userName, filters, i32 limit, i32 offset)')
+ print(' ExperimentStatistics getExperimentStatistics(AuthzToken authzToken, string gatewayId, i64 fromTime, i64 toTime, string userName, string applicationName, string resourceHostName)')
+ print(' getExperimentsInProject(AuthzToken authzToken, string projectId, i32 limit, i32 offset)')
+ print(' getUserExperiments(AuthzToken authzToken, string gatewayId, string userName, i32 limit, i32 offset)')
+ print(' string createExperiment(AuthzToken authzToken, string gatewayId, ExperimentModel experiment)')
+ print(' bool deleteExperiment(AuthzToken authzToken, string experimentId)')
+ print(' ExperimentModel getExperiment(AuthzToken authzToken, string airavataExperimentId)')
+ print(' ExperimentModel getExperimentByAdmin(AuthzToken authzToken, string airavataExperimentId)')
+ print(' ExperimentModel getDetailedExperimentTree(AuthzToken authzToken, string airavataExperimentId)')
+ print(' void updateExperiment(AuthzToken authzToken, string airavataExperimentId, ExperimentModel experiment)')
+ print(' void updateExperimentConfiguration(AuthzToken authzToken, string airavataExperimentId, UserConfigurationDataModel userConfiguration)')
+ print(' void updateResourceScheduleing(AuthzToken authzToken, string airavataExperimentId, ComputationalResourceSchedulingModel resourceScheduling)')
+ print(' bool validateExperiment(AuthzToken authzToken, string airavataExperimentId)')
+ print(' void launchExperiment(AuthzToken authzToken, string airavataExperimentId, string gatewayId)')
+ print(' ExperimentStatus getExperimentStatus(AuthzToken authzToken, string airavataExperimentId)')
+ print(' getExperimentOutputs(AuthzToken authzToken, string airavataExperimentId)')
+ print(' getIntermediateOutputs(AuthzToken authzToken, string airavataExperimentId)')
+ print(' getJobStatuses(AuthzToken authzToken, string airavataExperimentId)')
+ print(' getJobDetails(AuthzToken authzToken, string airavataExperimentId)')
+ print(' string cloneExperiment(AuthzToken authzToken, string existingExperimentID, string newExperimentName, string newExperimentProjectId)')
+ print(' string cloneExperimentByAdmin(AuthzToken authzToken, string existingExperimentID, string newExperimentName, string newExperimentProjectId)')
+ print(' void terminateExperiment(AuthzToken authzToken, string airavataExperimentId, string gatewayId)')
+ print(' string registerApplicationModule(AuthzToken authzToken, string gatewayId, ApplicationModule applicationModule)')
+ print(' ApplicationModule getApplicationModule(AuthzToken authzToken, string appModuleId)')
+ print(' bool updateApplicationModule(AuthzToken authzToken, string appModuleId, ApplicationModule applicationModule)')
+ print(' getAllAppModules(AuthzToken authzToken, string gatewayId)')
+ print(' bool deleteApplicationModule(AuthzToken authzToken, string appModuleId)')
+ print(' string registerApplicationDeployment(AuthzToken authzToken, string gatewayId, ApplicationDeploymentDescription applicationDeployment)')
+ print(' ApplicationDeploymentDescription getApplicationDeployment(AuthzToken authzToken, string appDeploymentId)')
+ print(' bool updateApplicationDeployment(AuthzToken authzToken, string appDeploymentId, ApplicationDeploymentDescription applicationDeployment)')
+ print(' bool deleteApplicationDeployment(AuthzToken authzToken, string appDeploymentId)')
+ print(' getAllApplicationDeployments(AuthzToken authzToken, string gatewayId)')
+ print(' getAppModuleDeployedResources(AuthzToken authzToken, string appModuleId)')
+ print(' string registerApplicationInterface(AuthzToken authzToken, string gatewayId, ApplicationInterfaceDescription applicationInterface)')
+ print(' string cloneApplicationInterface(AuthzToken authzToken, string existingAppInterfaceID, string newApplicationName, string gatewayId)')
+ print(' ApplicationInterfaceDescription getApplicationInterface(AuthzToken authzToken, string appInterfaceId)')
+ print(' bool updateApplicationInterface(AuthzToken authzToken, string appInterfaceId, ApplicationInterfaceDescription applicationInterface)')
+ print(' bool deleteApplicationInterface(AuthzToken authzToken, string appInterfaceId)')
+ print(' getAllApplicationInterfaceNames(AuthzToken authzToken, string gatewayId)')
+ print(' getAllApplicationInterfaces(AuthzToken authzToken, string gatewayId)')
+ print(' getApplicationInputs(AuthzToken authzToken, string appInterfaceId)')
+ print(' getApplicationOutputs(AuthzToken authzToken, string appInterfaceId)')
+ print(' getAvailableAppInterfaceComputeResources(AuthzToken authzToken, string appInterfaceId)')
+ print(' string registerComputeResource(AuthzToken authzToken, ComputeResourceDescription computeResourceDescription)')
+ print(' ComputeResourceDescription getComputeResource(AuthzToken authzToken, string computeResourceId)')
+ print(' getAllComputeResourceNames(AuthzToken authzToken)')
+ print(' bool updateComputeResource(AuthzToken authzToken, string computeResourceId, ComputeResourceDescription computeResourceDescription)')
+ print(' bool deleteComputeResource(AuthzToken authzToken, string computeResourceId)')
+ print(' string registerStorageResource(AuthzToken authzToken, StorageResourceDescription storageResourceDescription)')
+ print(' StorageResourceDescription getStorageResource(AuthzToken authzToken, string storageResourceId)')
+ print(' getAllStorageResourceNames(AuthzToken authzToken)')
+ print(' bool updateStorageResource(AuthzToken authzToken, string storageResourceId, StorageResourceDescription storageResourceDescription)')
+ print(' bool deleteStorageResource(AuthzToken authzToken, string storageResourceId)')
+ print(' string addLocalSubmissionDetails(AuthzToken authzToken, string computeResourceId, i32 priorityOrder, LOCALSubmission localSubmission)')
+ print(' bool updateLocalSubmissionDetails(AuthzToken authzToken, string jobSubmissionInterfaceId, LOCALSubmission localSubmission)')
+ print(' LOCALSubmission getLocalJobSubmission(AuthzToken authzToken, string jobSubmissionId)')
+ print(' string addSSHJobSubmissionDetails(AuthzToken authzToken, string computeResourceId, i32 priorityOrder, SSHJobSubmission sshJobSubmission)')
+ print(' string addSSHForkJobSubmissionDetails(AuthzToken authzToken, string computeResourceId, i32 priorityOrder, SSHJobSubmission sshJobSubmission)')
+ print(' SSHJobSubmission getSSHJobSubmission(AuthzToken authzToken, string jobSubmissionId)')
+ print(' string addUNICOREJobSubmissionDetails(AuthzToken authzToken, string computeResourceId, i32 priorityOrder, UnicoreJobSubmission unicoreJobSubmission)')
+ print(' UnicoreJobSubmission getUnicoreJobSubmission(AuthzToken authzToken, string jobSubmissionId)')
+ print(' string addCloudJobSubmissionDetails(AuthzToken authzToken, string computeResourceId, i32 priorityOrder, CloudJobSubmission cloudSubmission)')
+ print(' CloudJobSubmission getCloudJobSubmission(AuthzToken authzToken, string jobSubmissionId)')
+ print(' bool updateSSHJobSubmissionDetails(AuthzToken authzToken, string jobSubmissionInterfaceId, SSHJobSubmission sshJobSubmission)')
+ print(' bool updateCloudJobSubmissionDetails(AuthzToken authzToken, string jobSubmissionInterfaceId, CloudJobSubmission sshJobSubmission)')
+ print(' bool updateUnicoreJobSubmissionDetails(AuthzToken authzToken, string jobSubmissionInterfaceId, UnicoreJobSubmission unicoreJobSubmission)')
+ print(' string addLocalDataMovementDetails(AuthzToken authzToken, string productUri, DMType dataMoveType, i32 priorityOrder, LOCALDataMovement localDataMovement)')
+ print(' bool updateLocalDataMovementDetails(AuthzToken authzToken, string dataMovementInterfaceId, LOCALDataMovement localDataMovement)')
+ print(' LOCALDataMovement getLocalDataMovement(AuthzToken authzToken, string dataMovementId)')
+ print(' string addSCPDataMovementDetails(AuthzToken authzToken, string productUri, DMType dataMoveType, i32 priorityOrder, SCPDataMovement scpDataMovement)')
+ print(' bool updateSCPDataMovementDetails(AuthzToken authzToken, string dataMovementInterfaceId, SCPDataMovement scpDataMovement)')
+ print(' SCPDataMovement getSCPDataMovement(AuthzToken authzToken, string dataMovementId)')
+ print(' string addUnicoreDataMovementDetails(AuthzToken authzToken, string productUri, DMType dataMoveType, i32 priorityOrder, UnicoreDataMovement unicoreDataMovement)')
+ print(' bool updateUnicoreDataMovementDetails(AuthzToken authzToken, string dataMovementInterfaceId, UnicoreDataMovement unicoreDataMovement)')
+ print(' UnicoreDataMovement getUnicoreDataMovement(AuthzToken authzToken, string dataMovementId)')
+ print(' string addGridFTPDataMovementDetails(AuthzToken authzToken, string productUri, DMType dataMoveType, i32 priorityOrder, GridFTPDataMovement gridFTPDataMovement)')
+ print(' bool updateGridFTPDataMovementDetails(AuthzToken authzToken, string dataMovementInterfaceId, GridFTPDataMovement gridFTPDataMovement)')
+ print(' GridFTPDataMovement getGridFTPDataMovement(AuthzToken authzToken, string dataMovementId)')
+ print(' bool changeJobSubmissionPriority(AuthzToken authzToken, string jobSubmissionInterfaceId, i32 newPriorityOrder)')
+ print(' bool changeDataMovementPriority(AuthzToken authzToken, string dataMovementInterfaceId, i32 newPriorityOrder)')
+ print(' bool changeJobSubmissionPriorities(AuthzToken authzToken, jobSubmissionPriorityMap)')
+ print(' bool changeDataMovementPriorities(AuthzToken authzToken, dataMovementPriorityMap)')
+ print(' bool deleteJobSubmissionInterface(AuthzToken authzToken, string computeResourceId, string jobSubmissionInterfaceId)')
+ print(' bool deleteDataMovementInterface(AuthzToken authzToken, string productUri, string dataMovementInterfaceId, DMType dataMoveType)')
+ print(' string registerResourceJobManager(AuthzToken authzToken, ResourceJobManager resourceJobManager)')
+ print(' bool updateResourceJobManager(AuthzToken authzToken, string resourceJobManagerId, ResourceJobManager updatedResourceJobManager)')
+ print(' ResourceJobManager getResourceJobManager(AuthzToken authzToken, string resourceJobManagerId)')
+ print(' bool deleteResourceJobManager(AuthzToken authzToken, string resourceJobManagerId)')
+ print(' bool deleteBatchQueue(AuthzToken authzToken, string computeResourceId, string queueName)')
+ print(' string registerGatewayResourceProfile(AuthzToken authzToken, GatewayResourceProfile gatewayResourceProfile)')
+ print(' GatewayResourceProfile getGatewayResourceProfile(AuthzToken authzToken, string gatewayID)')
+ print(' bool updateGatewayResourceProfile(AuthzToken authzToken, string gatewayID, GatewayResourceProfile gatewayResourceProfile)')
+ print(' bool deleteGatewayResourceProfile(AuthzToken authzToken, string gatewayID)')
+ print(' bool addGatewayComputeResourcePreference(AuthzToken authzToken, string gatewayID, string computeResourceId, ComputeResourcePreference computeResourcePreference)')
+ print(' bool addGatewayStoragePreference(AuthzToken authzToken, string gatewayID, string storageResourceId, StoragePreference storagePreference)')
+ print(' ComputeResourcePreference getGatewayComputeResourcePreference(AuthzToken authzToken, string gatewayID, string computeResourceId)')
+ print(' StoragePreference getGatewayStoragePreference(AuthzToken authzToken, string gatewayID, string storageResourceId)')
+ print(' getAllGatewayComputeResourcePreferences(AuthzToken authzToken, string gatewayID)')
+ print(' getAllGatewayStoragePreferences(AuthzToken authzToken, string gatewayID)')
+ print(' getAllGatewayResourceProfiles(AuthzToken authzToken)')
+ print(' bool updateGatewayComputeResourcePreference(AuthzToken authzToken, string gatewayID, string computeResourceId, ComputeResourcePreference computeResourcePreference)')
+ print(' bool updateGatewayStoragePreference(AuthzToken authzToken, string gatewayID, string storageId, StoragePreference storagePreference)')
+ print(' bool deleteGatewayComputeResourcePreference(AuthzToken authzToken, string gatewayID, string computeResourceId)')
+ print(' bool deleteGatewayStoragePreference(AuthzToken authzToken, string gatewayID, string storageId)')
+ print(' string registerUserResourceProfile(AuthzToken authzToken, UserResourceProfile userResourceProfile)')
+ print(' UserResourceProfile getUserResourceProfile(AuthzToken authzToken, string userId, string gatewayID)')
+ print(' bool updateUserResourceProfile(AuthzToken authzToken, string userId, string gatewayID, UserResourceProfile userResourceProfile)')
+ print(' bool deleteUserResourceProfile(AuthzToken authzToken, string userId, string gatewayID)')
+ print(' bool addUserComputeResourcePreference(AuthzToken authzToken, string userId, string gatewayID, string userComputeResourceId, UserComputeResourcePreference userComputeResourcePreference)')
+ print(' bool addUserStoragePreference(AuthzToken authzToken, string userId, string gatewayID, string userStorageResourceId, UserStoragePreference userStoragePreference)')
+ print(' UserComputeResourcePreference getUserComputeResourcePreference(AuthzToken authzToken, string userId, string gatewayID, string userComputeResourceId)')
+ print(' UserStoragePreference getUserStoragePreference(AuthzToken authzToken, string userId, string gatewayID, string userStorageResourceId)')
+ print(' getAllUserComputeResourcePreferences(AuthzToken authzToken, string userId, string gatewayID)')
+ print(' getAllUserStoragePreferences(AuthzToken authzToken, string userId, string gatewayID)')
+ print(' getAllUserResourceProfiles(AuthzToken authzToken)')
+ print(' bool updateUserComputeResourcePreference(AuthzToken authzToken, string userId, string gatewayID, string userComputeResourceId, UserComputeResourcePreference userComputeResourcePreference)')
+ print(' bool updateUserStoragePreference(AuthzToken authzToken, string userId, string gatewayID, string userStorageId, UserStoragePreference userStoragePreference)')
+ print(' bool deleteUserComputeResourcePreference(AuthzToken authzToken, string userId, string gatewayID, string userComputeResourceId)')
+ print(' bool deleteUserStoragePreference(AuthzToken authzToken, string userId, string gatewayID, string userStorageId)')
+ print(' getAllWorkflows(AuthzToken authzToken, string gatewayId)')
+ print(' getLatestQueueStatuses(AuthzToken authzToken)')
+ print(' WorkflowModel getWorkflow(AuthzToken authzToken, string workflowTemplateId)')
+ print(' void deleteWorkflow(AuthzToken authzToken, string workflowTemplateId)')
+ print(' string registerWorkflow(AuthzToken authzToken, string gatewayId, WorkflowModel workflow)')
+ print(' void updateWorkflow(AuthzToken authzToken, string workflowTemplateId, WorkflowModel workflow)')
+ print(' string getWorkflowTemplateId(AuthzToken authzToken, string workflowName)')
+ print(' bool isWorkflowExistWithName(AuthzToken authzToken, string workflowName)')
+ print(' string registerDataProduct(AuthzToken authzToken, DataProductModel dataProductModel)')
+ print(' DataProductModel getDataProduct(AuthzToken authzToken, string dataProductUri)')
+ print(' string registerReplicaLocation(AuthzToken authzToken, DataReplicaLocationModel replicaLocationModel)')
+ print(' DataProductModel getParentDataProduct(AuthzToken authzToken, string productUri)')
+ print(' getChildDataProducts(AuthzToken authzToken, string productUri)')
+ print(' bool shareResourceWithUsers(AuthzToken authzToken, string resourceId, ResourceType resourceType, userPermissionList)')
+ print(' bool revokeSharingOfResourceFromUsers(AuthzToken authzToken, string resourceId, ResourceType resourceType, userPermissionList)')
+ print(' getAllAccessibleUsers(AuthzToken authzToken, string resourceId, ResourceType resourceType, ResourcePermissionType permissionType)')
+ print(' string createGroup(AuthzToken authzToken, GroupModel groupModel)')
+ print(' bool updateGroup(AuthzToken authzToken, GroupModel groupModel)')
+ print(' bool deleteGroup(AuthzToken authzToken, string groupId, string ownerId)')
+ print(' GroupModel getGroup(AuthzToken authzToken, string groupId)')
+ print(' getAllGroupsUserBelongs(AuthzToken authzToken, string userName)')
+ print('')
+ sys.exit(0)
+
+pp = pprint.PrettyPrinter(indent=2)
host = 'localhost'
port = 9090
uri = ''
framed = False
ssl = False
+validate = True
+ca_certs = None
+keyfile = None
+certfile = None
http = False
argi = 1
if sys.argv[argi] == '-h':
- parts = sys.argv[argi+1].split(':')
- host = parts[0]
- if len(parts) > 1:
- port = int(parts[1])
- argi += 2
+ parts = sys.argv[argi + 1].split(':')
+ host = parts[0]
+ if len(parts) > 1:
+ port = int(parts[1])
+ argi += 2
if sys.argv[argi] == '-u':
- url = urlparse(sys.argv[argi+1])
- parts = url[1].split(':')
- host = parts[0]
- if len(parts) > 1:
- port = int(parts[1])
- else:
- port = 80
- uri = url[2]
- if url[4]:
- uri += '?%s' % url[4]
- http = True
- argi += 2
+ url = urlparse(sys.argv[argi + 1])
+ parts = url[1].split(':')
+ host = parts[0]
+ if len(parts) > 1:
+ port = int(parts[1])
+ else:
+ port = 80
+ uri = url[2]
+ if url[4]:
+ uri += '?%s' % url[4]
+ http = True
+ argi += 2
if sys.argv[argi] == '-f' or sys.argv[argi] == '-framed':
- framed = True
- argi += 1
+ framed = True
+ argi += 1
if sys.argv[argi] == '-s' or sys.argv[argi] == '-ssl':
- ssl = True
- argi += 1
+ ssl = True
+ argi += 1
+
+if sys.argv[argi] == '-novalidate':
+ validate = False
+ argi += 1
+
+if sys.argv[argi] == '-ca_certs':
+ ca_certs = sys.argv[argi+1]
+ argi += 2
+
+if sys.argv[argi] == '-keyfile':
+ keyfile = sys.argv[argi+1]
+ argi += 2
+
+if sys.argv[argi] == '-certfile':
+ certfile = sys.argv[argi+1]
+ argi += 2
cmd = sys.argv[argi]
-args = sys.argv[argi+1:]
+args = sys.argv[argi + 1:]
if http:
- transport = THttpClient.THttpClient(host, port, uri)
+ transport = THttpClient.THttpClient(host, port, uri)
else:
- socket = TSSLSocket.TSSLSocket(host, port, validate=False) if ssl else TSocket.TSocket(host, port)
- if framed:
- transport = TTransport.TFramedTransport(socket)
- else:
- transport = TTransport.TBufferedTransport(socket)
-protocol = TBinaryProtocol.TBinaryProtocol(transport)
+ if ssl:
+ socket = TSSLSocket.TSSLSocket(host, port, validate=validate, ca_certs=ca_certs, keyfile=keyfile, certfile=certfile)
+ else:
+ socket = TSocket.TSocket(host, port)
+ if framed:
+ transport = TTransport.TFramedTransport(socket)
+ else:
+ transport = TTransport.TBufferedTransport(socket)
+protocol = TBinaryProtocol(transport)
client = Airavata.Client(protocol)
transport.open()
if cmd == 'getAPIVersion':
- if len(args) != 1:
- print('getAPIVersion requires 1 args')
- sys.exit(1)
- pp.pprint(client.getAPIVersion(eval(args[0]),))
+ if len(args) != 1:
+ print('getAPIVersion requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.getAPIVersion(eval(args[0]),))
elif cmd == 'isUserExists':
- if len(args) != 3:
- print('isUserExists requires 3 args')
- sys.exit(1)
- pp.pprint(client.isUserExists(eval(args[0]),args[1],args[2],))
+ if len(args) != 3:
+ print('isUserExists requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.isUserExists(eval(args[0]), args[1], args[2],))
elif cmd == 'addGateway':
- if len(args) != 2:
- print('addGateway requires 2 args')
- sys.exit(1)
- pp.pprint(client.addGateway(eval(args[0]),eval(args[1]),))
+ if len(args) != 2:
+ print('addGateway requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.addGateway(eval(args[0]), eval(args[1]),))
elif cmd == 'getAllUsersInGateway':
- if len(args) != 2:
- print('getAllUsersInGateway requires 2 args')
- sys.exit(1)
- pp.pprint(client.getAllUsersInGateway(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getAllUsersInGateway requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getAllUsersInGateway(eval(args[0]), args[1],))
elif cmd == 'updateGateway':
- if len(args) != 3:
- print('updateGateway requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateGateway(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateGateway requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateGateway(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'getGateway':
- if len(args) != 2:
- print('getGateway requires 2 args')
- sys.exit(1)
- pp.pprint(client.getGateway(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getGateway requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getGateway(eval(args[0]), args[1],))
elif cmd == 'deleteGateway':
- if len(args) != 2:
- print('deleteGateway requires 2 args')
- sys.exit(1)
- pp.pprint(client.deleteGateway(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('deleteGateway requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.deleteGateway(eval(args[0]), args[1],))
elif cmd == 'getAllGateways':
- if len(args) != 1:
- print('getAllGateways requires 1 args')
- sys.exit(1)
- pp.pprint(client.getAllGateways(eval(args[0]),))
+ if len(args) != 1:
+ print('getAllGateways requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.getAllGateways(eval(args[0]),))
elif cmd == 'isGatewayExist':
- if len(args) != 2:
- print('isGatewayExist requires 2 args')
- sys.exit(1)
- pp.pprint(client.isGatewayExist(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('isGatewayExist requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.isGatewayExist(eval(args[0]), args[1],))
elif cmd == 'createNotification':
- if len(args) != 2:
- print('createNotification requires 2 args')
- sys.exit(1)
- pp.pprint(client.createNotification(eval(args[0]),eval(args[1]),))
+ if len(args) != 2:
+ print('createNotification requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.createNotification(eval(args[0]), eval(args[1]),))
elif cmd == 'updateNotification':
- if len(args) != 2:
- print('updateNotification requires 2 args')
- sys.exit(1)
- pp.pprint(client.updateNotification(eval(args[0]),eval(args[1]),))
+ if len(args) != 2:
+ print('updateNotification requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.updateNotification(eval(args[0]), eval(args[1]),))
elif cmd == 'deleteNotification':
- if len(args) != 3:
- print('deleteNotification requires 3 args')
- sys.exit(1)
- pp.pprint(client.deleteNotification(eval(args[0]),args[1],args[2],))
+ if len(args) != 3:
+ print('deleteNotification requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.deleteNotification(eval(args[0]), args[1], args[2],))
elif cmd == 'getNotification':
- if len(args) != 3:
- print('getNotification requires 3 args')
- sys.exit(1)
- pp.pprint(client.getNotification(eval(args[0]),args[1],args[2],))
+ if len(args) != 3:
+ print('getNotification requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.getNotification(eval(args[0]), args[1], args[2],))
elif cmd == 'getAllNotifications':
- if len(args) != 2:
- print('getAllNotifications requires 2 args')
- sys.exit(1)
- pp.pprint(client.getAllNotifications(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getAllNotifications requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getAllNotifications(eval(args[0]), args[1],))
elif cmd == 'generateAndRegisterSSHKeys':
- if len(args) != 5:
- print('generateAndRegisterSSHKeys requires 5 args')
- sys.exit(1)
- pp.pprint(client.generateAndRegisterSSHKeys(eval(args[0]),args[1],args[2],args[3],eval(args[4]),))
+ if len(args) != 5:
+ print('generateAndRegisterSSHKeys requires 5 args')
+ sys.exit(1)
+ pp.pprint(client.generateAndRegisterSSHKeys(eval(args[0]), args[1], args[2], args[3], eval(args[4]),))
elif cmd == 'registerPwdCredential':
- if len(args) != 6:
- print('registerPwdCredential requires 6 args')
- sys.exit(1)
- pp.pprint(client.registerPwdCredential(eval(args[0]),args[1],args[2],args[3],args[4],args[5],))
+ if len(args) != 6:
+ print('registerPwdCredential requires 6 args')
+ sys.exit(1)
+ pp.pprint(client.registerPwdCredential(eval(args[0]), args[1], args[2], args[3], args[4], args[5],))
elif cmd == 'getSSHPubKey':
- if len(args) != 3:
- print('getSSHPubKey requires 3 args')
- sys.exit(1)
- pp.pprint(client.getSSHPubKey(eval(args[0]),args[1],args[2],))
+ if len(args) != 3:
+ print('getSSHPubKey requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.getSSHPubKey(eval(args[0]), args[1], args[2],))
elif cmd == 'getAllGatewaySSHPubKeys':
- if len(args) != 2:
- print('getAllGatewaySSHPubKeys requires 2 args')
- sys.exit(1)
- pp.pprint(client.getAllGatewaySSHPubKeys(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getAllGatewaySSHPubKeys requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getAllGatewaySSHPubKeys(eval(args[0]), args[1],))
elif cmd == 'getAllCredentialSummaryForGateway':
- if len(args) != 3:
- print('getAllCredentialSummaryForGateway requires 3 args')
- sys.exit(1)
- pp.pprint(client.getAllCredentialSummaryForGateway(eval(args[0]),eval(args[1]),args[2],))
+ if len(args) != 3:
+ print('getAllCredentialSummaryForGateway requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.getAllCredentialSummaryForGateway(eval(args[0]), eval(args[1]), args[2],))
elif cmd == 'getAllCredentialSummaryForUsersInGateway':
- if len(args) != 4:
- print('getAllCredentialSummaryForUsersInGateway requires 4 args')
- sys.exit(1)
- pp.pprint(client.getAllCredentialSummaryForUsersInGateway(eval(args[0]),eval(args[1]),args[2],args[3],))
+ if len(args) != 4:
+ print('getAllCredentialSummaryForUsersInGateway requires 4 args')
+ sys.exit(1)
+ pp.pprint(client.getAllCredentialSummaryForUsersInGateway(eval(args[0]), eval(args[1]), args[2], args[3],))
elif cmd == 'getAllGatewayPWDCredentials':
- if len(args) != 2:
- print('getAllGatewayPWDCredentials requires 2 args')
- sys.exit(1)
- pp.pprint(client.getAllGatewayPWDCredentials(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getAllGatewayPWDCredentials requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getAllGatewayPWDCredentials(eval(args[0]), args[1],))
elif cmd == 'deleteSSHPubKey':
- if len(args) != 3:
- print('deleteSSHPubKey requires 3 args')
- sys.exit(1)
- pp.pprint(client.deleteSSHPubKey(eval(args[0]),args[1],args[2],))
+ if len(args) != 3:
+ print('deleteSSHPubKey requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.deleteSSHPubKey(eval(args[0]), args[1], args[2],))
elif cmd == 'deletePWDCredential':
- if len(args) != 3:
- print('deletePWDCredential requires 3 args')
- sys.exit(1)
- pp.pprint(client.deletePWDCredential(eval(args[0]),args[1],args[2],))
+ if len(args) != 3:
+ print('deletePWDCredential requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.deletePWDCredential(eval(args[0]), args[1], args[2],))
elif cmd == 'createProject':
- if len(args) != 3:
- print('createProject requires 3 args')
- sys.exit(1)
- pp.pprint(client.createProject(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('createProject requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.createProject(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'updateProject':
- if len(args) != 3:
- print('updateProject requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateProject(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateProject requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateProject(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'getProject':
- if len(args) != 2:
- print('getProject requires 2 args')
- sys.exit(1)
- pp.pprint(client.getProject(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getProject requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getProject(eval(args[0]), args[1],))
elif cmd == 'deleteProject':
- if len(args) != 2:
- print('deleteProject requires 2 args')
- sys.exit(1)
- pp.pprint(client.deleteProject(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('deleteProject requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.deleteProject(eval(args[0]), args[1],))
elif cmd == 'getUserProjects':
- if len(args) != 5:
- print('getUserProjects requires 5 args')
- sys.exit(1)
- pp.pprint(client.getUserProjects(eval(args[0]),args[1],args[2],eval(args[3]),eval(args[4]),))
+ if len(args) != 5:
+ print('getUserProjects requires 5 args')
+ sys.exit(1)
+ pp.pprint(client.getUserProjects(eval(args[0]), args[1], args[2], eval(args[3]), eval(args[4]),))
elif cmd == 'searchProjects':
- if len(args) != 6:
- print('searchProjects requires 6 args')
- sys.exit(1)
- pp.pprint(client.searchProjects(eval(args[0]),args[1],args[2],eval(args[3]),eval(args[4]),eval(args[5]),))
+ if len(args) != 6:
+ print('searchProjects requires 6 args')
+ sys.exit(1)
+ pp.pprint(client.searchProjects(eval(args[0]), args[1], args[2], eval(args[3]), eval(args[4]), eval(args[5]),))
elif cmd == 'searchExperiments':
- if len(args) != 6:
- print('searchExperiments requires 6 args')
- sys.exit(1)
- pp.pprint(client.searchExperiments(eval(args[0]),args[1],args[2],eval(args[3]),eval(args[4]),eval(args[5]),))
+ if len(args) != 6:
+ print('searchExperiments requires 6 args')
+ sys.exit(1)
+ pp.pprint(client.searchExperiments(eval(args[0]), args[1], args[2], eval(args[3]), eval(args[4]), eval(args[5]),))
elif cmd == 'getExperimentStatistics':
- if len(args) != 7:
- print('getExperimentStatistics requires 7 args')
- sys.exit(1)
- pp.pprint(client.getExperimentStatistics(eval(args[0]),args[1],eval(args[2]),eval(args[3]),args[4],args[5],args[6],))
+ if len(args) != 7:
+ print('getExperimentStatistics requires 7 args')
+ sys.exit(1)
+ pp.pprint(client.getExperimentStatistics(eval(args[0]), args[1], eval(args[2]), eval(args[3]), args[4], args[5], args[6],))
elif cmd == 'getExperimentsInProject':
- if len(args) != 4:
- print('getExperimentsInProject requires 4 args')
- sys.exit(1)
- pp.pprint(client.getExperimentsInProject(eval(args[0]),args[1],eval(args[2]),eval(args[3]),))
+ if len(args) != 4:
+ print('getExperimentsInProject requires 4 args')
+ sys.exit(1)
+ pp.pprint(client.getExperimentsInProject(eval(args[0]), args[1], eval(args[2]), eval(args[3]),))
elif cmd == 'getUserExperiments':
- if len(args) != 5:
- print('getUserExperiments requires 5 args')
- sys.exit(1)
- pp.pprint(client.getUserExperiments(eval(args[0]),args[1],args[2],eval(args[3]),eval(args[4]),))
+ if len(args) != 5:
+ print('getUserExperiments requires 5 args')
+ sys.exit(1)
+ pp.pprint(client.getUserExperiments(eval(args[0]), args[1], args[2], eval(args[3]), eval(args[4]),))
elif cmd == 'createExperiment':
- if len(args) != 3:
- print('createExperiment requires 3 args')
- sys.exit(1)
- pp.pprint(client.createExperiment(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('createExperiment requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.createExperiment(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'deleteExperiment':
- if len(args) != 2:
- print('deleteExperiment requires 2 args')
- sys.exit(1)
- pp.pprint(client.deleteExperiment(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('deleteExperiment requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.deleteExperiment(eval(args[0]), args[1],))
elif cmd == 'getExperiment':
- if len(args) != 2:
- print('getExperiment requires 2 args')
- sys.exit(1)
- pp.pprint(client.getExperiment(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getExperiment requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getExperiment(eval(args[0]), args[1],))
elif cmd == 'getExperimentByAdmin':
- if len(args) != 2:
- print('getExperimentByAdmin requires 2 args')
- sys.exit(1)
- pp.pprint(client.getExperimentByAdmin(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getExperimentByAdmin requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getExperimentByAdmin(eval(args[0]), args[1],))
elif cmd == 'getDetailedExperimentTree':
- if len(args) != 2:
- print('getDetailedExperimentTree requires 2 args')
- sys.exit(1)
- pp.pprint(client.getDetailedExperimentTree(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getDetailedExperimentTree requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getDetailedExperimentTree(eval(args[0]), args[1],))
elif cmd == 'updateExperiment':
- if len(args) != 3:
- print('updateExperiment requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateExperiment(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateExperiment requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateExperiment(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'updateExperimentConfiguration':
- if len(args) != 3:
- print('updateExperimentConfiguration requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateExperimentConfiguration(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateExperimentConfiguration requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateExperimentConfiguration(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'updateResourceScheduleing':
- if len(args) != 3:
- print('updateResourceScheduleing requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateResourceScheduleing(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateResourceScheduleing requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateResourceScheduleing(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'validateExperiment':
- if len(args) != 2:
- print('validateExperiment requires 2 args')
- sys.exit(1)
- pp.pprint(client.validateExperiment(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('validateExperiment requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.validateExperiment(eval(args[0]), args[1],))
elif cmd == 'launchExperiment':
- if len(args) != 3:
- print('launchExperiment requires 3 args')
- sys.exit(1)
- pp.pprint(client.launchExperiment(eval(args[0]),args[1],args[2],))
+ if len(args) != 3:
+ print('launchExperiment requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.launchExperiment(eval(args[0]), args[1], args[2],))
elif cmd == 'getExperimentStatus':
- if len(args) != 2:
- print('getExperimentStatus requires 2 args')
- sys.exit(1)
- pp.pprint(client.getExperimentStatus(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getExperimentStatus requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getExperimentStatus(eval(args[0]), args[1],))
elif cmd == 'getExperimentOutputs':
- if len(args) != 2:
- print('getExperimentOutputs requires 2 args')
- sys.exit(1)
- pp.pprint(client.getExperimentOutputs(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getExperimentOutputs requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getExperimentOutputs(eval(args[0]), args[1],))
elif cmd == 'getIntermediateOutputs':
- if len(args) != 2:
- print('getIntermediateOutputs requires 2 args')
- sys.exit(1)
- pp.pprint(client.getIntermediateOutputs(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getIntermediateOutputs requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getIntermediateOutputs(eval(args[0]), args[1],))
elif cmd == 'getJobStatuses':
- if len(args) != 2:
- print('getJobStatuses requires 2 args')
- sys.exit(1)
- pp.pprint(client.getJobStatuses(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getJobStatuses requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getJobStatuses(eval(args[0]), args[1],))
elif cmd == 'getJobDetails':
- if len(args) != 2:
- print('getJobDetails requires 2 args')
- sys.exit(1)
- pp.pprint(client.getJobDetails(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getJobDetails requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getJobDetails(eval(args[0]), args[1],))
elif cmd == 'cloneExperiment':
- if len(args) != 4:
- print('cloneExperiment requires 4 args')
- sys.exit(1)
- pp.pprint(client.cloneExperiment(eval(args[0]),args[1],args[2],args[3],))
+ if len(args) != 4:
+ print('cloneExperiment requires 4 args')
+ sys.exit(1)
+ pp.pprint(client.cloneExperiment(eval(args[0]), args[1], args[2], args[3],))
elif cmd == 'cloneExperimentByAdmin':
- if len(args) != 4:
- print('cloneExperimentByAdmin requires 4 args')
- sys.exit(1)
- pp.pprint(client.cloneExperimentByAdmin(eval(args[0]),args[1],args[2],args[3],))
+ if len(args) != 4:
+ print('cloneExperimentByAdmin requires 4 args')
+ sys.exit(1)
+ pp.pprint(client.cloneExperimentByAdmin(eval(args[0]), args[1], args[2], args[3],))
elif cmd == 'terminateExperiment':
- if len(args) != 3:
- print('terminateExperiment requires 3 args')
- sys.exit(1)
- pp.pprint(client.terminateExperiment(eval(args[0]),args[1],args[2],))
+ if len(args) != 3:
+ print('terminateExperiment requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.terminateExperiment(eval(args[0]), args[1], args[2],))
elif cmd == 'registerApplicationModule':
- if len(args) != 3:
- print('registerApplicationModule requires 3 args')
- sys.exit(1)
- pp.pprint(client.registerApplicationModule(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('registerApplicationModule requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.registerApplicationModule(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'getApplicationModule':
- if len(args) != 2:
- print('getApplicationModule requires 2 args')
- sys.exit(1)
- pp.pprint(client.getApplicationModule(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getApplicationModule requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getApplicationModule(eval(args[0]), args[1],))
elif cmd == 'updateApplicationModule':
- if len(args) != 3:
- print('updateApplicationModule requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateApplicationModule(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateApplicationModule requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateApplicationModule(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'getAllAppModules':
- if len(args) != 2:
- print('getAllAppModules requires 2 args')
- sys.exit(1)
- pp.pprint(client.getAllAppModules(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getAllAppModules requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getAllAppModules(eval(args[0]), args[1],))
elif cmd == 'deleteApplicationModule':
- if len(args) != 2:
- print('deleteApplicationModule requires 2 args')
- sys.exit(1)
- pp.pprint(client.deleteApplicationModule(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('deleteApplicationModule requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.deleteApplicationModule(eval(args[0]), args[1],))
elif cmd == 'registerApplicationDeployment':
- if len(args) != 3:
- print('registerApplicationDeployment requires 3 args')
- sys.exit(1)
- pp.pprint(client.registerApplicationDeployment(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('registerApplicationDeployment requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.registerApplicationDeployment(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'getApplicationDeployment':
- if len(args) != 2:
- print('getApplicationDeployment requires 2 args')
- sys.exit(1)
- pp.pprint(client.getApplicationDeployment(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getApplicationDeployment requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getApplicationDeployment(eval(args[0]), args[1],))
elif cmd == 'updateApplicationDeployment':
- if len(args) != 3:
- print('updateApplicationDeployment requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateApplicationDeployment(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateApplicationDeployment requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateApplicationDeployment(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'deleteApplicationDeployment':
- if len(args) != 2:
- print('deleteApplicationDeployment requires 2 args')
- sys.exit(1)
- pp.pprint(client.deleteApplicationDeployment(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('deleteApplicationDeployment requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.deleteApplicationDeployment(eval(args[0]), args[1],))
elif cmd == 'getAllApplicationDeployments':
- if len(args) != 2:
- print('getAllApplicationDeployments requires 2 args')
- sys.exit(1)
- pp.pprint(client.getAllApplicationDeployments(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getAllApplicationDeployments requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getAllApplicationDeployments(eval(args[0]), args[1],))
elif cmd == 'getAppModuleDeployedResources':
- if len(args) != 2:
- print('getAppModuleDeployedResources requires 2 args')
- sys.exit(1)
- pp.pprint(client.getAppModuleDeployedResources(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getAppModuleDeployedResources requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getAppModuleDeployedResources(eval(args[0]), args[1],))
elif cmd == 'registerApplicationInterface':
- if len(args) != 3:
- print('registerApplicationInterface requires 3 args')
- sys.exit(1)
- pp.pprint(client.registerApplicationInterface(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('registerApplicationInterface requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.registerApplicationInterface(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'cloneApplicationInterface':
- if len(args) != 4:
- print('cloneApplicationInterface requires 4 args')
- sys.exit(1)
- pp.pprint(client.cloneApplicationInterface(eval(args[0]),args[1],args[2],args[3],))
+ if len(args) != 4:
+ print('cloneApplicationInterface requires 4 args')
+ sys.exit(1)
+ pp.pprint(client.cloneApplicationInterface(eval(args[0]), args[1], args[2], args[3],))
elif cmd == 'getApplicationInterface':
- if len(args) != 2:
- print('getApplicationInterface requires 2 args')
- sys.exit(1)
- pp.pprint(client.getApplicationInterface(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getApplicationInterface requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getApplicationInterface(eval(args[0]), args[1],))
elif cmd == 'updateApplicationInterface':
- if len(args) != 3:
- print('updateApplicationInterface requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateApplicationInterface(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateApplicationInterface requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateApplicationInterface(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'deleteApplicationInterface':
- if len(args) != 2:
- print('deleteApplicationInterface requires 2 args')
- sys.exit(1)
- pp.pprint(client.deleteApplicationInterface(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('deleteApplicationInterface requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.deleteApplicationInterface(eval(args[0]), args[1],))
elif cmd == 'getAllApplicationInterfaceNames':
- if len(args) != 2:
- print('getAllApplicationInterfaceNames requires 2 args')
- sys.exit(1)
- pp.pprint(client.getAllApplicationInterfaceNames(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getAllApplicationInterfaceNames requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getAllApplicationInterfaceNames(eval(args[0]), args[1],))
elif cmd == 'getAllApplicationInterfaces':
- if len(args) != 2:
- print('getAllApplicationInterfaces requires 2 args')
- sys.exit(1)
- pp.pprint(client.getAllApplicationInterfaces(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getAllApplicationInterfaces requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getAllApplicationInterfaces(eval(args[0]), args[1],))
elif cmd == 'getApplicationInputs':
- if len(args) != 2:
- print('getApplicationInputs requires 2 args')
- sys.exit(1)
- pp.pprint(client.getApplicationInputs(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getApplicationInputs requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getApplicationInputs(eval(args[0]), args[1],))
elif cmd == 'getApplicationOutputs':
- if len(args) != 2:
- print('getApplicationOutputs requires 2 args')
- sys.exit(1)
- pp.pprint(client.getApplicationOutputs(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getApplicationOutputs requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getApplicationOutputs(eval(args[0]), args[1],))
elif cmd == 'getAvailableAppInterfaceComputeResources':
- if len(args) != 2:
- print('getAvailableAppInterfaceComputeResources requires 2 args')
- sys.exit(1)
- pp.pprint(client.getAvailableAppInterfaceComputeResources(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getAvailableAppInterfaceComputeResources requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getAvailableAppInterfaceComputeResources(eval(args[0]), args[1],))
elif cmd == 'registerComputeResource':
- if len(args) != 2:
- print('registerComputeResource requires 2 args')
- sys.exit(1)
- pp.pprint(client.registerComputeResource(eval(args[0]),eval(args[1]),))
+ if len(args) != 2:
+ print('registerComputeResource requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.registerComputeResource(eval(args[0]), eval(args[1]),))
elif cmd == 'getComputeResource':
- if len(args) != 2:
- print('getComputeResource requires 2 args')
- sys.exit(1)
- pp.pprint(client.getComputeResource(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getComputeResource requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getComputeResource(eval(args[0]), args[1],))
elif cmd == 'getAllComputeResourceNames':
- if len(args) != 1:
- print('getAllComputeResourceNames requires 1 args')
- sys.exit(1)
- pp.pprint(client.getAllComputeResourceNames(eval(args[0]),))
+ if len(args) != 1:
+ print('getAllComputeResourceNames requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.getAllComputeResourceNames(eval(args[0]),))
elif cmd == 'updateComputeResource':
- if len(args) != 3:
- print('updateComputeResource requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateComputeResource(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateComputeResource requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateComputeResource(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'deleteComputeResource':
- if len(args) != 2:
- print('deleteComputeResource requires 2 args')
- sys.exit(1)
- pp.pprint(client.deleteComputeResource(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('deleteComputeResource requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.deleteComputeResource(eval(args[0]), args[1],))
elif cmd == 'registerStorageResource':
- if len(args) != 2:
- print('registerStorageResource requires 2 args')
- sys.exit(1)
- pp.pprint(client.registerStorageResource(eval(args[0]),eval(args[1]),))
+ if len(args) != 2:
+ print('registerStorageResource requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.registerStorageResource(eval(args[0]), eval(args[1]),))
elif cmd == 'getStorageResource':
- if len(args) != 2:
- print('getStorageResource requires 2 args')
- sys.exit(1)
- pp.pprint(client.getStorageResource(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getStorageResource requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getStorageResource(eval(args[0]), args[1],))
elif cmd == 'getAllStorageResourceNames':
- if len(args) != 1:
- print('getAllStorageResourceNames requires 1 args')
- sys.exit(1)
- pp.pprint(client.getAllStorageResourceNames(eval(args[0]),))
+ if len(args) != 1:
+ print('getAllStorageResourceNames requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.getAllStorageResourceNames(eval(args[0]),))
elif cmd == 'updateStorageResource':
- if len(args) != 3:
- print('updateStorageResource requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateStorageResource(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateStorageResource requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateStorageResource(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'deleteStorageResource':
- if len(args) != 2:
- print('deleteStorageResource requires 2 args')
- sys.exit(1)
- pp.pprint(client.deleteStorageResource(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('deleteStorageResource requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.deleteStorageResource(eval(args[0]), args[1],))
elif cmd == 'addLocalSubmissionDetails':
- if len(args) != 4:
- print('addLocalSubmissionDetails requires 4 args')
- sys.exit(1)
- pp.pprint(client.addLocalSubmissionDetails(eval(args[0]),args[1],eval(args[2]),eval(args[3]),))
+ if len(args) != 4:
+ print('addLocalSubmissionDetails requires 4 args')
+ sys.exit(1)
+ pp.pprint(client.addLocalSubmissionDetails(eval(args[0]), args[1], eval(args[2]), eval(args[3]),))
elif cmd == 'updateLocalSubmissionDetails':
- if len(args) != 3:
- print('updateLocalSubmissionDetails requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateLocalSubmissionDetails(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateLocalSubmissionDetails requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateLocalSubmissionDetails(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'getLocalJobSubmission':
- if len(args) != 2:
- print('getLocalJobSubmission requires 2 args')
- sys.exit(1)
- pp.pprint(client.getLocalJobSubmission(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getLocalJobSubmission requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getLocalJobSubmission(eval(args[0]), args[1],))
elif cmd == 'addSSHJobSubmissionDetails':
- if len(args) != 4:
- print('addSSHJobSubmissionDetails requires 4 args')
- sys.exit(1)
- pp.pprint(client.addSSHJobSubmissionDetails(eval(args[0]),args[1],eval(args[2]),eval(args[3]),))
+ if len(args) != 4:
+ print('addSSHJobSubmissionDetails requires 4 args')
+ sys.exit(1)
+ pp.pprint(client.addSSHJobSubmissionDetails(eval(args[0]), args[1], eval(args[2]), eval(args[3]),))
elif cmd == 'addSSHForkJobSubmissionDetails':
- if len(args) != 4:
- print('addSSHForkJobSubmissionDetails requires 4 args')
- sys.exit(1)
- pp.pprint(client.addSSHForkJobSubmissionDetails(eval(args[0]),args[1],eval(args[2]),eval(args[3]),))
+ if len(args) != 4:
+ print('addSSHForkJobSubmissionDetails requires 4 args')
+ sys.exit(1)
+ pp.pprint(client.addSSHForkJobSubmissionDetails(eval(args[0]), args[1], eval(args[2]), eval(args[3]),))
elif cmd == 'getSSHJobSubmission':
- if len(args) != 2:
- print('getSSHJobSubmission requires 2 args')
- sys.exit(1)
- pp.pprint(client.getSSHJobSubmission(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getSSHJobSubmission requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getSSHJobSubmission(eval(args[0]), args[1],))
elif cmd == 'addUNICOREJobSubmissionDetails':
- if len(args) != 4:
- print('addUNICOREJobSubmissionDetails requires 4 args')
- sys.exit(1)
- pp.pprint(client.addUNICOREJobSubmissionDetails(eval(args[0]),args[1],eval(args[2]),eval(args[3]),))
+ if len(args) != 4:
+ print('addUNICOREJobSubmissionDetails requires 4 args')
+ sys.exit(1)
+ pp.pprint(client.addUNICOREJobSubmissionDetails(eval(args[0]), args[1], eval(args[2]), eval(args[3]),))
elif cmd == 'getUnicoreJobSubmission':
- if len(args) != 2:
- print('getUnicoreJobSubmission requires 2 args')
- sys.exit(1)
- pp.pprint(client.getUnicoreJobSubmission(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getUnicoreJobSubmission requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getUnicoreJobSubmission(eval(args[0]), args[1],))
elif cmd == 'addCloudJobSubmissionDetails':
- if len(args) != 4:
- print('addCloudJobSubmissionDetails requires 4 args')
- sys.exit(1)
- pp.pprint(client.addCloudJobSubmissionDetails(eval(args[0]),args[1],eval(args[2]),eval(args[3]),))
+ if len(args) != 4:
+ print('addCloudJobSubmissionDetails requires 4 args')
+ sys.exit(1)
+ pp.pprint(client.addCloudJobSubmissionDetails(eval(args[0]), args[1], eval(args[2]), eval(args[3]),))
elif cmd == 'getCloudJobSubmission':
- if len(args) != 2:
- print('getCloudJobSubmission requires 2 args')
- sys.exit(1)
- pp.pprint(client.getCloudJobSubmission(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getCloudJobSubmission requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getCloudJobSubmission(eval(args[0]), args[1],))
elif cmd == 'updateSSHJobSubmissionDetails':
- if len(args) != 3:
- print('updateSSHJobSubmissionDetails requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateSSHJobSubmissionDetails(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateSSHJobSubmissionDetails requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateSSHJobSubmissionDetails(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'updateCloudJobSubmissionDetails':
- if len(args) != 3:
- print('updateCloudJobSubmissionDetails requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateCloudJobSubmissionDetails(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateCloudJobSubmissionDetails requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateCloudJobSubmissionDetails(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'updateUnicoreJobSubmissionDetails':
- if len(args) != 3:
- print('updateUnicoreJobSubmissionDetails requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateUnicoreJobSubmissionDetails(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateUnicoreJobSubmissionDetails requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateUnicoreJobSubmissionDetails(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'addLocalDataMovementDetails':
- if len(args) != 5:
- print('addLocalDataMovementDetails requires 5 args')
- sys.exit(1)
- pp.pprint(client.addLocalDataMovementDetails(eval(args[0]),args[1],eval(args[2]),eval(args[3]),eval(args[4]),))
+ if len(args) != 5:
+ print('addLocalDataMovementDetails requires 5 args')
+ sys.exit(1)
+ pp.pprint(client.addLocalDataMovementDetails(eval(args[0]), args[1], eval(args[2]), eval(args[3]), eval(args[4]),))
elif cmd == 'updateLocalDataMovementDetails':
- if len(args) != 3:
- print('updateLocalDataMovementDetails requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateLocalDataMovementDetails(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateLocalDataMovementDetails requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateLocalDataMovementDetails(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'getLocalDataMovement':
- if len(args) != 2:
- print('getLocalDataMovement requires 2 args')
- sys.exit(1)
- pp.pprint(client.getLocalDataMovement(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getLocalDataMovement requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getLocalDataMovement(eval(args[0]), args[1],))
elif cmd == 'addSCPDataMovementDetails':
- if len(args) != 5:
- print('addSCPDataMovementDetails requires 5 args')
- sys.exit(1)
- pp.pprint(client.addSCPDataMovementDetails(eval(args[0]),args[1],eval(args[2]),eval(args[3]),eval(args[4]),))
+ if len(args) != 5:
+ print('addSCPDataMovementDetails requires 5 args')
+ sys.exit(1)
+ pp.pprint(client.addSCPDataMovementDetails(eval(args[0]), args[1], eval(args[2]), eval(args[3]), eval(args[4]),))
elif cmd == 'updateSCPDataMovementDetails':
- if len(args) != 3:
- print('updateSCPDataMovementDetails requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateSCPDataMovementDetails(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateSCPDataMovementDetails requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateSCPDataMovementDetails(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'getSCPDataMovement':
- if len(args) != 2:
- print('getSCPDataMovement requires 2 args')
- sys.exit(1)
- pp.pprint(client.getSCPDataMovement(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getSCPDataMovement requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getSCPDataMovement(eval(args[0]), args[1],))
elif cmd == 'addUnicoreDataMovementDetails':
- if len(args) != 5:
- print('addUnicoreDataMovementDetails requires 5 args')
- sys.exit(1)
- pp.pprint(client.addUnicoreDataMovementDetails(eval(args[0]),args[1],eval(args[2]),eval(args[3]),eval(args[4]),))
+ if len(args) != 5:
+ print('addUnicoreDataMovementDetails requires 5 args')
+ sys.exit(1)
+ pp.pprint(client.addUnicoreDataMovementDetails(eval(args[0]), args[1], eval(args[2]), eval(args[3]), eval(args[4]),))
elif cmd == 'updateUnicoreDataMovementDetails':
- if len(args) != 3:
- print('updateUnicoreDataMovementDetails requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateUnicoreDataMovementDetails(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateUnicoreDataMovementDetails requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateUnicoreDataMovementDetails(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'getUnicoreDataMovement':
- if len(args) != 2:
- print('getUnicoreDataMovement requires 2 args')
- sys.exit(1)
- pp.pprint(client.getUnicoreDataMovement(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getUnicoreDataMovement requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getUnicoreDataMovement(eval(args[0]), args[1],))
elif cmd == 'addGridFTPDataMovementDetails':
- if len(args) != 5:
- print('addGridFTPDataMovementDetails requires 5 args')
- sys.exit(1)
- pp.pprint(client.addGridFTPDataMovementDetails(eval(args[0]),args[1],eval(args[2]),eval(args[3]),eval(args[4]),))
+ if len(args) != 5:
+ print('addGridFTPDataMovementDetails requires 5 args')
+ sys.exit(1)
+ pp.pprint(client.addGridFTPDataMovementDetails(eval(args[0]), args[1], eval(args[2]), eval(args[3]), eval(args[4]),))
elif cmd == 'updateGridFTPDataMovementDetails':
- if len(args) != 3:
- print('updateGridFTPDataMovementDetails requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateGridFTPDataMovementDetails(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateGridFTPDataMovementDetails requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateGridFTPDataMovementDetails(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'getGridFTPDataMovement':
- if len(args) != 2:
- print('getGridFTPDataMovement requires 2 args')
- sys.exit(1)
- pp.pprint(client.getGridFTPDataMovement(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getGridFTPDataMovement requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getGridFTPDataMovement(eval(args[0]), args[1],))
elif cmd == 'changeJobSubmissionPriority':
- if len(args) != 3:
- print('changeJobSubmissionPriority requires 3 args')
- sys.exit(1)
- pp.pprint(client.changeJobSubmissionPriority(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('changeJobSubmissionPriority requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.changeJobSubmissionPriority(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'changeDataMovementPriority':
- if len(args) != 3:
- print('changeDataMovementPriority requires 3 args')
- sys.exit(1)
- pp.pprint(client.changeDataMovementPriority(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('changeDataMovementPriority requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.changeDataMovementPriority(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'changeJobSubmissionPriorities':
- if len(args) != 2:
- print('changeJobSubmissionPriorities requires 2 args')
- sys.exit(1)
- pp.pprint(client.changeJobSubmissionPriorities(eval(args[0]),eval(args[1]),))
+ if len(args) != 2:
+ print('changeJobSubmissionPriorities requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.changeJobSubmissionPriorities(eval(args[0]), eval(args[1]),))
elif cmd == 'changeDataMovementPriorities':
- if len(args) != 2:
- print('changeDataMovementPriorities requires 2 args')
- sys.exit(1)
- pp.pprint(client.changeDataMovementPriorities(eval(args[0]),eval(args[1]),))
+ if len(args) != 2:
+ print('changeDataMovementPriorities requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.changeDataMovementPriorities(eval(args[0]), eval(args[1]),))
elif cmd == 'deleteJobSubmissionInterface':
- if len(args) != 3:
- print('deleteJobSubmissionInterface requires 3 args')
- sys.exit(1)
- pp.pprint(client.deleteJobSubmissionInterface(eval(args[0]),args[1],args[2],))
+ if len(args) != 3:
+ print('deleteJobSubmissionInterface requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.deleteJobSubmissionInterface(eval(args[0]), args[1], args[2],))
elif cmd == 'deleteDataMovementInterface':
- if len(args) != 4:
- print('deleteDataMovementInterface requires 4 args')
- sys.exit(1)
- pp.pprint(client.deleteDataMovementInterface(eval(args[0]),args[1],args[2],eval(args[3]),))
+ if len(args) != 4:
+ print('deleteDataMovementInterface requires 4 args')
+ sys.exit(1)
+ pp.pprint(client.deleteDataMovementInterface(eval(args[0]), args[1], args[2], eval(args[3]),))
elif cmd == 'registerResourceJobManager':
- if len(args) != 2:
- print('registerResourceJobManager requires 2 args')
- sys.exit(1)
- pp.pprint(client.registerResourceJobManager(eval(args[0]),eval(args[1]),))
+ if len(args) != 2:
+ print('registerResourceJobManager requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.registerResourceJobManager(eval(args[0]), eval(args[1]),))
elif cmd == 'updateResourceJobManager':
- if len(args) != 3:
- print('updateResourceJobManager requires 3 args')
- sys.exit(1)
- pp.pprint(client.updateResourceJobManager(eval(args[0]),args[1],eval(args[2]),))
+ if len(args) != 3:
+ print('updateResourceJobManager requires 3 args')
+ sys.exit(1)
+ pp.pprint(client.updateResourceJobManager(eval(args[0]), args[1], eval(args[2]),))
elif cmd == 'getResourceJobManager':
- if len(args) != 2:
- print('getResourceJobManager requires 2 args')
- sys.exit(1)
- pp.pprint(client.getResourceJobManager(eval(args[0]),args[1],))
+ if len(args) != 2:
+ print('getResourceJobManager requires 2 args')
+ sys.exit(1)
+ pp.pprint(client.getResourceJobManager(eval(args[0]), args[1],))
elif cmd == 'deleteResourceJobManager':
- if len(args) != 2:
- print('deleteResourceJobManager requires 2 args')
- sys.exit(1)
- pp.pprint(client.deleteResourceJobManager(eval(args[0]),args[1],))
+ if l
<TRUNCATED>
[16/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/gatewayprofile/StoragePreference.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/gatewayprofile/StoragePreference.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/gatewayprofile/StoragePreference.java
index 9c274d6..b8754ed 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/gatewayprofile/StoragePreference.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/gatewayprofile/StoragePreference.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.gatewayprofile;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class StoragePreference implements org.apache.thrift.TBase<StoragePreference, StoragePreference._Fields>, java.io.Serializable, Cloneable, Comparable<StoragePreference> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("StoragePreference");
@@ -60,16 +33,13 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
private static final org.apache.thrift.protocol.TField FILE_SYSTEM_ROOT_LOCATION_FIELD_DESC = new org.apache.thrift.protocol.TField("fileSystemRootLocation", org.apache.thrift.protocol.TType.STRING, (short)3);
private static final org.apache.thrift.protocol.TField RESOURCE_SPECIFIC_CREDENTIAL_STORE_TOKEN_FIELD_DESC = new org.apache.thrift.protocol.TField("resourceSpecificCredentialStoreToken", 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 StoragePreferenceStandardSchemeFactory());
- schemes.put(TupleScheme.class, new StoragePreferenceTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new StoragePreferenceStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new StoragePreferenceTupleSchemeFactory();
- private String storageResourceId; // required
- private String loginUserName; // optional
- private String fileSystemRootLocation; // optional
- private String resourceSpecificCredentialStoreToken; // optional
+ private java.lang.String storageResourceId; // required
+ private java.lang.String loginUserName; // optional
+ private java.lang.String fileSystemRootLocation; // optional
+ private java.lang.String resourceSpecificCredentialStoreToken; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -78,10 +48,10 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
FILE_SYSTEM_ROOT_LOCATION((short)3, "fileSystemRootLocation"),
RESOURCE_SPECIFIC_CREDENTIAL_STORE_TOKEN((short)4, "resourceSpecificCredentialStoreToken");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -110,21 +80,21 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -133,16 +103,16 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
private static final _Fields optionals[] = {_Fields.LOGIN_USER_NAME,_Fields.FILE_SYSTEM_ROOT_LOCATION,_Fields.RESOURCE_SPECIFIC_CREDENTIAL_STORE_TOKEN};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.STORAGE_RESOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("storageResourceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.LOGIN_USER_NAME, new org.apache.thrift.meta_data.FieldMetaData("loginUserName", org.apache.thrift.TFieldRequirementType.OPTIONAL,
@@ -151,7 +121,7 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.RESOURCE_SPECIFIC_CREDENTIAL_STORE_TOKEN, new org.apache.thrift.meta_data.FieldMetaData("resourceSpecificCredentialStoreToken", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(StoragePreference.class, metaDataMap);
}
@@ -159,7 +129,7 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
}
public StoragePreference(
- String storageResourceId)
+ java.lang.String storageResourceId)
{
this();
this.storageResourceId = storageResourceId;
@@ -195,11 +165,11 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
this.resourceSpecificCredentialStoreToken = null;
}
- public String getStorageResourceId() {
+ public java.lang.String getStorageResourceId() {
return this.storageResourceId;
}
- public void setStorageResourceId(String storageResourceId) {
+ public void setStorageResourceId(java.lang.String storageResourceId) {
this.storageResourceId = storageResourceId;
}
@@ -218,11 +188,11 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
}
}
- public String getLoginUserName() {
+ public java.lang.String getLoginUserName() {
return this.loginUserName;
}
- public void setLoginUserName(String loginUserName) {
+ public void setLoginUserName(java.lang.String loginUserName) {
this.loginUserName = loginUserName;
}
@@ -241,11 +211,11 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
}
}
- public String getFileSystemRootLocation() {
+ public java.lang.String getFileSystemRootLocation() {
return this.fileSystemRootLocation;
}
- public void setFileSystemRootLocation(String fileSystemRootLocation) {
+ public void setFileSystemRootLocation(java.lang.String fileSystemRootLocation) {
this.fileSystemRootLocation = fileSystemRootLocation;
}
@@ -264,11 +234,11 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
}
}
- public String getResourceSpecificCredentialStoreToken() {
+ public java.lang.String getResourceSpecificCredentialStoreToken() {
return this.resourceSpecificCredentialStoreToken;
}
- public void setResourceSpecificCredentialStoreToken(String resourceSpecificCredentialStoreToken) {
+ public void setResourceSpecificCredentialStoreToken(java.lang.String resourceSpecificCredentialStoreToken) {
this.resourceSpecificCredentialStoreToken = resourceSpecificCredentialStoreToken;
}
@@ -287,13 +257,13 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case STORAGE_RESOURCE_ID:
if (value == null) {
unsetStorageResourceId();
} else {
- setStorageResourceId((String)value);
+ setStorageResourceId((java.lang.String)value);
}
break;
@@ -301,7 +271,7 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
if (value == null) {
unsetLoginUserName();
} else {
- setLoginUserName((String)value);
+ setLoginUserName((java.lang.String)value);
}
break;
@@ -309,7 +279,7 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
if (value == null) {
unsetFileSystemRootLocation();
} else {
- setFileSystemRootLocation((String)value);
+ setFileSystemRootLocation((java.lang.String)value);
}
break;
@@ -317,14 +287,14 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
if (value == null) {
unsetResourceSpecificCredentialStoreToken();
} else {
- setResourceSpecificCredentialStoreToken((String)value);
+ setResourceSpecificCredentialStoreToken((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case STORAGE_RESOURCE_ID:
return getStorageResourceId();
@@ -339,13 +309,13 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
return getResourceSpecificCredentialStoreToken();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -358,11 +328,11 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
case RESOURCE_SPECIFIC_CREDENTIAL_STORE_TOKEN:
return isSetResourceSpecificCredentialStoreToken();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof StoragePreference)
@@ -373,6 +343,8 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
public boolean equals(StoragePreference that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_storageResourceId = true && this.isSetStorageResourceId();
boolean that_present_storageResourceId = true && that.isSetStorageResourceId();
@@ -415,29 +387,25 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_storageResourceId = true && (isSetStorageResourceId());
- list.add(present_storageResourceId);
- if (present_storageResourceId)
- list.add(storageResourceId);
+ hashCode = hashCode * 8191 + ((isSetStorageResourceId()) ? 131071 : 524287);
+ if (isSetStorageResourceId())
+ hashCode = hashCode * 8191 + storageResourceId.hashCode();
- boolean present_loginUserName = true && (isSetLoginUserName());
- list.add(present_loginUserName);
- if (present_loginUserName)
- list.add(loginUserName);
+ hashCode = hashCode * 8191 + ((isSetLoginUserName()) ? 131071 : 524287);
+ if (isSetLoginUserName())
+ hashCode = hashCode * 8191 + loginUserName.hashCode();
- boolean present_fileSystemRootLocation = true && (isSetFileSystemRootLocation());
- list.add(present_fileSystemRootLocation);
- if (present_fileSystemRootLocation)
- list.add(fileSystemRootLocation);
+ hashCode = hashCode * 8191 + ((isSetFileSystemRootLocation()) ? 131071 : 524287);
+ if (isSetFileSystemRootLocation())
+ hashCode = hashCode * 8191 + fileSystemRootLocation.hashCode();
- boolean present_resourceSpecificCredentialStoreToken = true && (isSetResourceSpecificCredentialStoreToken());
- list.add(present_resourceSpecificCredentialStoreToken);
- if (present_resourceSpecificCredentialStoreToken)
- list.add(resourceSpecificCredentialStoreToken);
+ hashCode = hashCode * 8191 + ((isSetResourceSpecificCredentialStoreToken()) ? 131071 : 524287);
+ if (isSetResourceSpecificCredentialStoreToken())
+ hashCode = hashCode * 8191 + resourceSpecificCredentialStoreToken.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -448,7 +416,7 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetStorageResourceId()).compareTo(other.isSetStorageResourceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetStorageResourceId()).compareTo(other.isSetStorageResourceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -458,7 +426,7 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetLoginUserName()).compareTo(other.isSetLoginUserName());
+ lastComparison = java.lang.Boolean.valueOf(isSetLoginUserName()).compareTo(other.isSetLoginUserName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -468,7 +436,7 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetFileSystemRootLocation()).compareTo(other.isSetFileSystemRootLocation());
+ lastComparison = java.lang.Boolean.valueOf(isSetFileSystemRootLocation()).compareTo(other.isSetFileSystemRootLocation());
if (lastComparison != 0) {
return lastComparison;
}
@@ -478,7 +446,7 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetResourceSpecificCredentialStoreToken()).compareTo(other.isSetResourceSpecificCredentialStoreToken());
+ lastComparison = java.lang.Boolean.valueOf(isSetResourceSpecificCredentialStoreToken()).compareTo(other.isSetResourceSpecificCredentialStoreToken());
if (lastComparison != 0) {
return lastComparison;
}
@@ -496,16 +464,16 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("StoragePreference(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("StoragePreference(");
boolean first = true;
sb.append("storageResourceId:");
@@ -566,7 +534,7 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -574,13 +542,13 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
}
}
- private static class StoragePreferenceStandardSchemeFactory implements SchemeFactory {
+ private static class StoragePreferenceStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public StoragePreferenceStandardScheme getScheme() {
return new StoragePreferenceStandardScheme();
}
}
- private static class StoragePreferenceStandardScheme extends StandardScheme<StoragePreference> {
+ private static class StoragePreferenceStandardScheme extends org.apache.thrift.scheme.StandardScheme<StoragePreference> {
public void read(org.apache.thrift.protocol.TProtocol iprot, StoragePreference struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -669,19 +637,19 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
}
- private static class StoragePreferenceTupleSchemeFactory implements SchemeFactory {
+ private static class StoragePreferenceTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public StoragePreferenceTupleScheme getScheme() {
return new StoragePreferenceTupleScheme();
}
}
- private static class StoragePreferenceTupleScheme extends TupleScheme<StoragePreference> {
+ private static class StoragePreferenceTupleScheme extends org.apache.thrift.scheme.TupleScheme<StoragePreference> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, StoragePreference struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.storageResourceId);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetLoginUserName()) {
optionals.set(0);
}
@@ -705,10 +673,10 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, StoragePreference struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.storageResourceId = iprot.readString();
struct.setStorageResourceIdIsSet(true);
- BitSet incoming = iprot.readBitSet(3);
+ java.util.BitSet incoming = iprot.readBitSet(3);
if (incoming.get(0)) {
struct.loginUserName = iprot.readString();
struct.setLoginUserNameIsSet(true);
@@ -724,5 +692,8 @@ public class StoragePreference implements org.apache.thrift.TBase<StoragePrefere
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/storageresource/StorageResourceDescription.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/storageresource/StorageResourceDescription.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/storageresource/StorageResourceDescription.java
index 1499cd8..600819f 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/storageresource/StorageResourceDescription.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/storageresource/StorageResourceDescription.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.storageresource;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Storage Resource Description
*
@@ -68,7 +41,7 @@ import org.slf4j.LoggerFactory;
*
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class StorageResourceDescription implements org.apache.thrift.TBase<StorageResourceDescription, StorageResourceDescription._Fields>, java.io.Serializable, Cloneable, Comparable<StorageResourceDescription> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("StorageResourceDescription");
@@ -78,17 +51,14 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
private static final org.apache.thrift.protocol.TField ENABLED_FIELD_DESC = new org.apache.thrift.protocol.TField("enabled", org.apache.thrift.protocol.TType.BOOL, (short)4);
private static final org.apache.thrift.protocol.TField DATA_MOVEMENT_INTERFACES_FIELD_DESC = new org.apache.thrift.protocol.TField("dataMovementInterfaces", org.apache.thrift.protocol.TType.LIST, (short)5);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new StorageResourceDescriptionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new StorageResourceDescriptionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new StorageResourceDescriptionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new StorageResourceDescriptionTupleSchemeFactory();
- private String storageResourceId; // required
- private String hostName; // required
- private String storageResourceDescription; // optional
+ private java.lang.String storageResourceId; // required
+ private java.lang.String hostName; // required
+ private java.lang.String storageResourceDescription; // optional
private boolean enabled; // optional
- private List<org.apache.airavata.model.data.movement.DataMovementInterface> dataMovementInterfaces; // optional
+ private java.util.List<org.apache.airavata.model.data.movement.DataMovementInterface> dataMovementInterfaces; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -98,10 +68,10 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
ENABLED((short)4, "enabled"),
DATA_MOVEMENT_INTERFACES((short)5, "dataMovementInterfaces");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -132,21 +102,21 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -155,7 +125,7 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -164,9 +134,9 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
private static final int __ENABLED_ISSET_ID = 0;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.STORAGE_RESOURCE_DESCRIPTION,_Fields.ENABLED,_Fields.DATA_MOVEMENT_INTERFACES};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.STORAGE_RESOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("storageResourceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.HOST_NAME, new org.apache.thrift.meta_data.FieldMetaData("hostName", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -178,7 +148,7 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
tmpMap.put(_Fields.DATA_MOVEMENT_INTERFACES, new org.apache.thrift.meta_data.FieldMetaData("dataMovementInterfaces", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, org.apache.airavata.model.data.movement.DataMovementInterface.class))));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(StorageResourceDescription.class, metaDataMap);
}
@@ -188,8 +158,8 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
}
public StorageResourceDescription(
- String storageResourceId,
- String hostName)
+ java.lang.String storageResourceId,
+ java.lang.String hostName)
{
this();
this.storageResourceId = storageResourceId;
@@ -212,7 +182,7 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
}
this.enabled = other.enabled;
if (other.isSetDataMovementInterfaces()) {
- List<org.apache.airavata.model.data.movement.DataMovementInterface> __this__dataMovementInterfaces = new ArrayList<org.apache.airavata.model.data.movement.DataMovementInterface>(other.dataMovementInterfaces.size());
+ java.util.List<org.apache.airavata.model.data.movement.DataMovementInterface> __this__dataMovementInterfaces = new java.util.ArrayList<org.apache.airavata.model.data.movement.DataMovementInterface>(other.dataMovementInterfaces.size());
for (org.apache.airavata.model.data.movement.DataMovementInterface other_element : other.dataMovementInterfaces) {
__this__dataMovementInterfaces.add(new org.apache.airavata.model.data.movement.DataMovementInterface(other_element));
}
@@ -235,11 +205,11 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
this.dataMovementInterfaces = null;
}
- public String getStorageResourceId() {
+ public java.lang.String getStorageResourceId() {
return this.storageResourceId;
}
- public void setStorageResourceId(String storageResourceId) {
+ public void setStorageResourceId(java.lang.String storageResourceId) {
this.storageResourceId = storageResourceId;
}
@@ -258,11 +228,11 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
}
}
- public String getHostName() {
+ public java.lang.String getHostName() {
return this.hostName;
}
- public void setHostName(String hostName) {
+ public void setHostName(java.lang.String hostName) {
this.hostName = hostName;
}
@@ -281,11 +251,11 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
}
}
- public String getStorageResourceDescription() {
+ public java.lang.String getStorageResourceDescription() {
return this.storageResourceDescription;
}
- public void setStorageResourceDescription(String storageResourceDescription) {
+ public void setStorageResourceDescription(java.lang.String storageResourceDescription) {
this.storageResourceDescription = storageResourceDescription;
}
@@ -314,16 +284,16 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
}
public void unsetEnabled() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ENABLED_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ENABLED_ISSET_ID);
}
/** Returns true if field enabled is set (has been assigned a value) and false otherwise */
public boolean isSetEnabled() {
- return EncodingUtils.testBit(__isset_bitfield, __ENABLED_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ENABLED_ISSET_ID);
}
public void setEnabledIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ENABLED_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ENABLED_ISSET_ID, value);
}
public int getDataMovementInterfacesSize() {
@@ -336,16 +306,16 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
public void addToDataMovementInterfaces(org.apache.airavata.model.data.movement.DataMovementInterface elem) {
if (this.dataMovementInterfaces == null) {
- this.dataMovementInterfaces = new ArrayList<org.apache.airavata.model.data.movement.DataMovementInterface>();
+ this.dataMovementInterfaces = new java.util.ArrayList<org.apache.airavata.model.data.movement.DataMovementInterface>();
}
this.dataMovementInterfaces.add(elem);
}
- public List<org.apache.airavata.model.data.movement.DataMovementInterface> getDataMovementInterfaces() {
+ public java.util.List<org.apache.airavata.model.data.movement.DataMovementInterface> getDataMovementInterfaces() {
return this.dataMovementInterfaces;
}
- public void setDataMovementInterfaces(List<org.apache.airavata.model.data.movement.DataMovementInterface> dataMovementInterfaces) {
+ public void setDataMovementInterfaces(java.util.List<org.apache.airavata.model.data.movement.DataMovementInterface> dataMovementInterfaces) {
this.dataMovementInterfaces = dataMovementInterfaces;
}
@@ -364,13 +334,13 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case STORAGE_RESOURCE_ID:
if (value == null) {
unsetStorageResourceId();
} else {
- setStorageResourceId((String)value);
+ setStorageResourceId((java.lang.String)value);
}
break;
@@ -378,7 +348,7 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
if (value == null) {
unsetHostName();
} else {
- setHostName((String)value);
+ setHostName((java.lang.String)value);
}
break;
@@ -386,7 +356,7 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
if (value == null) {
unsetStorageResourceDescription();
} else {
- setStorageResourceDescription((String)value);
+ setStorageResourceDescription((java.lang.String)value);
}
break;
@@ -394,7 +364,7 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
if (value == null) {
unsetEnabled();
} else {
- setEnabled((Boolean)value);
+ setEnabled((java.lang.Boolean)value);
}
break;
@@ -402,14 +372,14 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
if (value == null) {
unsetDataMovementInterfaces();
} else {
- setDataMovementInterfaces((List<org.apache.airavata.model.data.movement.DataMovementInterface>)value);
+ setDataMovementInterfaces((java.util.List<org.apache.airavata.model.data.movement.DataMovementInterface>)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case STORAGE_RESOURCE_ID:
return getStorageResourceId();
@@ -427,13 +397,13 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
return getDataMovementInterfaces();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -448,11 +418,11 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
case DATA_MOVEMENT_INTERFACES:
return isSetDataMovementInterfaces();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof StorageResourceDescription)
@@ -463,6 +433,8 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
public boolean equals(StorageResourceDescription that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_storageResourceId = true && this.isSetStorageResourceId();
boolean that_present_storageResourceId = true && that.isSetStorageResourceId();
@@ -514,34 +486,29 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_storageResourceId = true && (isSetStorageResourceId());
- list.add(present_storageResourceId);
- if (present_storageResourceId)
- list.add(storageResourceId);
+ hashCode = hashCode * 8191 + ((isSetStorageResourceId()) ? 131071 : 524287);
+ if (isSetStorageResourceId())
+ hashCode = hashCode * 8191 + storageResourceId.hashCode();
- boolean present_hostName = true && (isSetHostName());
- list.add(present_hostName);
- if (present_hostName)
- list.add(hostName);
+ hashCode = hashCode * 8191 + ((isSetHostName()) ? 131071 : 524287);
+ if (isSetHostName())
+ hashCode = hashCode * 8191 + hostName.hashCode();
- boolean present_storageResourceDescription = true && (isSetStorageResourceDescription());
- list.add(present_storageResourceDescription);
- if (present_storageResourceDescription)
- list.add(storageResourceDescription);
+ hashCode = hashCode * 8191 + ((isSetStorageResourceDescription()) ? 131071 : 524287);
+ if (isSetStorageResourceDescription())
+ hashCode = hashCode * 8191 + storageResourceDescription.hashCode();
- boolean present_enabled = true && (isSetEnabled());
- list.add(present_enabled);
- if (present_enabled)
- list.add(enabled);
+ hashCode = hashCode * 8191 + ((isSetEnabled()) ? 131071 : 524287);
+ if (isSetEnabled())
+ hashCode = hashCode * 8191 + ((enabled) ? 131071 : 524287);
- boolean present_dataMovementInterfaces = true && (isSetDataMovementInterfaces());
- list.add(present_dataMovementInterfaces);
- if (present_dataMovementInterfaces)
- list.add(dataMovementInterfaces);
+ hashCode = hashCode * 8191 + ((isSetDataMovementInterfaces()) ? 131071 : 524287);
+ if (isSetDataMovementInterfaces())
+ hashCode = hashCode * 8191 + dataMovementInterfaces.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -552,7 +519,7 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetStorageResourceId()).compareTo(other.isSetStorageResourceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetStorageResourceId()).compareTo(other.isSetStorageResourceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -562,7 +529,7 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetHostName()).compareTo(other.isSetHostName());
+ lastComparison = java.lang.Boolean.valueOf(isSetHostName()).compareTo(other.isSetHostName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -572,7 +539,7 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetStorageResourceDescription()).compareTo(other.isSetStorageResourceDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetStorageResourceDescription()).compareTo(other.isSetStorageResourceDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -582,7 +549,7 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetEnabled()).compareTo(other.isSetEnabled());
+ lastComparison = java.lang.Boolean.valueOf(isSetEnabled()).compareTo(other.isSetEnabled());
if (lastComparison != 0) {
return lastComparison;
}
@@ -592,7 +559,7 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDataMovementInterfaces()).compareTo(other.isSetDataMovementInterfaces());
+ lastComparison = java.lang.Boolean.valueOf(isSetDataMovementInterfaces()).compareTo(other.isSetDataMovementInterfaces());
if (lastComparison != 0) {
return lastComparison;
}
@@ -610,16 +577,16 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("StorageResourceDescription(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("StorageResourceDescription(");
boolean first = true;
sb.append("storageResourceId:");
@@ -688,7 +655,7 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -698,13 +665,13 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
}
}
- private static class StorageResourceDescriptionStandardSchemeFactory implements SchemeFactory {
+ private static class StorageResourceDescriptionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public StorageResourceDescriptionStandardScheme getScheme() {
return new StorageResourceDescriptionStandardScheme();
}
}
- private static class StorageResourceDescriptionStandardScheme extends StandardScheme<StorageResourceDescription> {
+ private static class StorageResourceDescriptionStandardScheme extends org.apache.thrift.scheme.StandardScheme<StorageResourceDescription> {
public void read(org.apache.thrift.protocol.TProtocol iprot, StorageResourceDescription struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -752,7 +719,7 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list0 = iprot.readListBegin();
- struct.dataMovementInterfaces = new ArrayList<org.apache.airavata.model.data.movement.DataMovementInterface>(_list0.size);
+ struct.dataMovementInterfaces = new java.util.ArrayList<org.apache.airavata.model.data.movement.DataMovementInterface>(_list0.size);
org.apache.airavata.model.data.movement.DataMovementInterface _elem1;
for (int _i2 = 0; _i2 < _list0.size; ++_i2)
{
@@ -822,20 +789,20 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
}
- private static class StorageResourceDescriptionTupleSchemeFactory implements SchemeFactory {
+ private static class StorageResourceDescriptionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public StorageResourceDescriptionTupleScheme getScheme() {
return new StorageResourceDescriptionTupleScheme();
}
}
- private static class StorageResourceDescriptionTupleScheme extends TupleScheme<StorageResourceDescription> {
+ private static class StorageResourceDescriptionTupleScheme extends org.apache.thrift.scheme.TupleScheme<StorageResourceDescription> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, StorageResourceDescription struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.storageResourceId);
oprot.writeString(struct.hostName);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetStorageResourceDescription()) {
optionals.set(0);
}
@@ -865,12 +832,12 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, StorageResourceDescription struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.storageResourceId = iprot.readString();
struct.setStorageResourceIdIsSet(true);
struct.hostName = iprot.readString();
struct.setHostNameIsSet(true);
- BitSet incoming = iprot.readBitSet(3);
+ java.util.BitSet incoming = iprot.readBitSet(3);
if (incoming.get(0)) {
struct.storageResourceDescription = iprot.readString();
struct.setStorageResourceDescriptionIsSet(true);
@@ -882,7 +849,7 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
if (incoming.get(2)) {
{
org.apache.thrift.protocol.TList _list5 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.dataMovementInterfaces = new ArrayList<org.apache.airavata.model.data.movement.DataMovementInterface>(_list5.size);
+ struct.dataMovementInterfaces = new java.util.ArrayList<org.apache.airavata.model.data.movement.DataMovementInterface>(_list5.size);
org.apache.airavata.model.data.movement.DataMovementInterface _elem6;
for (int _i7 = 0; _i7 < _list5.size; ++_i7)
{
@@ -896,5 +863,8 @@ public class StorageResourceDescription implements org.apache.thrift.TBase<Stora
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/userresourceprofile/UserComputeResourcePreference.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/userresourceprofile/UserComputeResourcePreference.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/userresourceprofile/UserComputeResourcePreference.java
index 276b7ca..c4a179c 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/userresourceprofile/UserComputeResourcePreference.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/userresourceprofile/UserComputeResourcePreference.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.userresourceprofile;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* User specific preferences for a Computer Resource
*
@@ -78,7 +51,7 @@ import org.slf4j.LoggerFactory;
* default credential store.
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class UserComputeResourcePreference implements org.apache.thrift.TBase<UserComputeResourcePreference, UserComputeResourcePreference._Fields>, java.io.Serializable, Cloneable, Comparable<UserComputeResourcePreference> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("UserComputeResourcePreference");
@@ -93,20 +66,17 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
private static final org.apache.thrift.protocol.TField RESERVATION_START_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("reservationStartTime", org.apache.thrift.protocol.TType.I64, (short)9);
private static final org.apache.thrift.protocol.TField RESERVATION_END_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("reservationEndTime", org.apache.thrift.protocol.TType.I64, (short)10);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new UserComputeResourcePreferenceStandardSchemeFactory());
- schemes.put(TupleScheme.class, new UserComputeResourcePreferenceTupleSchemeFactory());
- }
-
- private String computeResourceId; // required
- private String loginUserName; // optional
- private String preferredBatchQueue; // optional
- private String scratchLocation; // optional
- private String allocationProjectNumber; // optional
- private String resourceSpecificCredentialStoreToken; // optional
- private String qualityOfService; // optional
- private String reservation; // optional
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new UserComputeResourcePreferenceStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new UserComputeResourcePreferenceTupleSchemeFactory();
+
+ private java.lang.String computeResourceId; // required
+ private java.lang.String loginUserName; // optional
+ private java.lang.String preferredBatchQueue; // optional
+ private java.lang.String scratchLocation; // optional
+ private java.lang.String allocationProjectNumber; // optional
+ private java.lang.String resourceSpecificCredentialStoreToken; // optional
+ private java.lang.String qualityOfService; // optional
+ private java.lang.String reservation; // optional
private long reservationStartTime; // optional
private long reservationEndTime; // optional
@@ -123,10 +93,10 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
RESERVATION_START_TIME((short)9, "reservationStartTime"),
RESERVATION_END_TIME((short)10, "reservationEndTime");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -167,21 +137,21 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -190,7 +160,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -200,9 +170,9 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
private static final int __RESERVATIONENDTIME_ISSET_ID = 1;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.LOGIN_USER_NAME,_Fields.PREFERRED_BATCH_QUEUE,_Fields.SCRATCH_LOCATION,_Fields.ALLOCATION_PROJECT_NUMBER,_Fields.RESOURCE_SPECIFIC_CREDENTIAL_STORE_TOKEN,_Fields.QUALITY_OF_SERVICE,_Fields.RESERVATION,_Fields.RESERVATION_START_TIME,_Fields.RESERVATION_END_TIME};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.COMPUTE_RESOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("computeResourceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.LOGIN_USER_NAME, new org.apache.thrift.meta_data.FieldMetaData("loginUserName", org.apache.thrift.TFieldRequirementType.OPTIONAL,
@@ -223,7 +193,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
tmpMap.put(_Fields.RESERVATION_END_TIME, new org.apache.thrift.meta_data.FieldMetaData("reservationEndTime", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(UserComputeResourcePreference.class, metaDataMap);
}
@@ -231,7 +201,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
}
public UserComputeResourcePreference(
- String computeResourceId)
+ java.lang.String computeResourceId)
{
this();
this.computeResourceId = computeResourceId;
@@ -290,11 +260,11 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
this.reservationEndTime = 0;
}
- public String getComputeResourceId() {
+ public java.lang.String getComputeResourceId() {
return this.computeResourceId;
}
- public void setComputeResourceId(String computeResourceId) {
+ public void setComputeResourceId(java.lang.String computeResourceId) {
this.computeResourceId = computeResourceId;
}
@@ -313,11 +283,11 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
}
}
- public String getLoginUserName() {
+ public java.lang.String getLoginUserName() {
return this.loginUserName;
}
- public void setLoginUserName(String loginUserName) {
+ public void setLoginUserName(java.lang.String loginUserName) {
this.loginUserName = loginUserName;
}
@@ -336,11 +306,11 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
}
}
- public String getPreferredBatchQueue() {
+ public java.lang.String getPreferredBatchQueue() {
return this.preferredBatchQueue;
}
- public void setPreferredBatchQueue(String preferredBatchQueue) {
+ public void setPreferredBatchQueue(java.lang.String preferredBatchQueue) {
this.preferredBatchQueue = preferredBatchQueue;
}
@@ -359,11 +329,11 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
}
}
- public String getScratchLocation() {
+ public java.lang.String getScratchLocation() {
return this.scratchLocation;
}
- public void setScratchLocation(String scratchLocation) {
+ public void setScratchLocation(java.lang.String scratchLocation) {
this.scratchLocation = scratchLocation;
}
@@ -382,11 +352,11 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
}
}
- public String getAllocationProjectNumber() {
+ public java.lang.String getAllocationProjectNumber() {
return this.allocationProjectNumber;
}
- public void setAllocationProjectNumber(String allocationProjectNumber) {
+ public void setAllocationProjectNumber(java.lang.String allocationProjectNumber) {
this.allocationProjectNumber = allocationProjectNumber;
}
@@ -405,11 +375,11 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
}
}
- public String getResourceSpecificCredentialStoreToken() {
+ public java.lang.String getResourceSpecificCredentialStoreToken() {
return this.resourceSpecificCredentialStoreToken;
}
- public void setResourceSpecificCredentialStoreToken(String resourceSpecificCredentialStoreToken) {
+ public void setResourceSpecificCredentialStoreToken(java.lang.String resourceSpecificCredentialStoreToken) {
this.resourceSpecificCredentialStoreToken = resourceSpecificCredentialStoreToken;
}
@@ -428,11 +398,11 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
}
}
- public String getQualityOfService() {
+ public java.lang.String getQualityOfService() {
return this.qualityOfService;
}
- public void setQualityOfService(String qualityOfService) {
+ public void setQualityOfService(java.lang.String qualityOfService) {
this.qualityOfService = qualityOfService;
}
@@ -451,11 +421,11 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
}
}
- public String getReservation() {
+ public java.lang.String getReservation() {
return this.reservation;
}
- public void setReservation(String reservation) {
+ public void setReservation(java.lang.String reservation) {
this.reservation = reservation;
}
@@ -484,16 +454,16 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
}
public void unsetReservationStartTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __RESERVATIONSTARTTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __RESERVATIONSTARTTIME_ISSET_ID);
}
/** Returns true if field reservationStartTime is set (has been assigned a value) and false otherwise */
public boolean isSetReservationStartTime() {
- return EncodingUtils.testBit(__isset_bitfield, __RESERVATIONSTARTTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __RESERVATIONSTARTTIME_ISSET_ID);
}
public void setReservationStartTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __RESERVATIONSTARTTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __RESERVATIONSTARTTIME_ISSET_ID, value);
}
public long getReservationEndTime() {
@@ -506,25 +476,25 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
}
public void unsetReservationEndTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __RESERVATIONENDTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __RESERVATIONENDTIME_ISSET_ID);
}
/** Returns true if field reservationEndTime is set (has been assigned a value) and false otherwise */
public boolean isSetReservationEndTime() {
- return EncodingUtils.testBit(__isset_bitfield, __RESERVATIONENDTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __RESERVATIONENDTIME_ISSET_ID);
}
public void setReservationEndTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __RESERVATIONENDTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __RESERVATIONENDTIME_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case COMPUTE_RESOURCE_ID:
if (value == null) {
unsetComputeResourceId();
} else {
- setComputeResourceId((String)value);
+ setComputeResourceId((java.lang.String)value);
}
break;
@@ -532,7 +502,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
if (value == null) {
unsetLoginUserName();
} else {
- setLoginUserName((String)value);
+ setLoginUserName((java.lang.String)value);
}
break;
@@ -540,7 +510,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
if (value == null) {
unsetPreferredBatchQueue();
} else {
- setPreferredBatchQueue((String)value);
+ setPreferredBatchQueue((java.lang.String)value);
}
break;
@@ -548,7 +518,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
if (value == null) {
unsetScratchLocation();
} else {
- setScratchLocation((String)value);
+ setScratchLocation((java.lang.String)value);
}
break;
@@ -556,7 +526,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
if (value == null) {
unsetAllocationProjectNumber();
} else {
- setAllocationProjectNumber((String)value);
+ setAllocationProjectNumber((java.lang.String)value);
}
break;
@@ -564,7 +534,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
if (value == null) {
unsetResourceSpecificCredentialStoreToken();
} else {
- setResourceSpecificCredentialStoreToken((String)value);
+ setResourceSpecificCredentialStoreToken((java.lang.String)value);
}
break;
@@ -572,7 +542,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
if (value == null) {
unsetQualityOfService();
} else {
- setQualityOfService((String)value);
+ setQualityOfService((java.lang.String)value);
}
break;
@@ -580,7 +550,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
if (value == null) {
unsetReservation();
} else {
- setReservation((String)value);
+ setReservation((java.lang.String)value);
}
break;
@@ -588,7 +558,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
if (value == null) {
unsetReservationStartTime();
} else {
- setReservationStartTime((Long)value);
+ setReservationStartTime((java.lang.Long)value);
}
break;
@@ -596,14 +566,14 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
if (value == null) {
unsetReservationEndTime();
} else {
- setReservationEndTime((Long)value);
+ setReservationEndTime((java.lang.Long)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case COMPUTE_RESOURCE_ID:
return getComputeResourceId();
@@ -636,13 +606,13 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
return getReservationEndTime();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -667,11 +637,11 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
case RESERVATION_END_TIME:
return isSetReservationEndTime();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof UserComputeResourcePreference)
@@ -682,6 +652,8 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
public boolean equals(UserComputeResourcePreference that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_computeResourceId = true && this.isSetComputeResourceId();
boolean that_present_computeResourceId = true && that.isSetComputeResourceId();
@@ -778,59 +750,49 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_computeResourceId = true && (isSetComputeResourceId());
- list.add(present_computeResourceId);
- if (present_computeResourceId)
- list.add(computeResourceId);
+ hashCode = hashCode * 8191 + ((isSetComputeResourceId()) ? 131071 : 524287);
+ if (isSetComputeResourceId())
+ hashCode = hashCode * 8191 + computeResourceId.hashCode();
- boolean present_loginUserName = true && (isSetLoginUserName());
- list.add(present_loginUserName);
- if (present_loginUserName)
- list.add(loginUserName);
+ hashCode = hashCode * 8191 + ((isSetLoginUserName()) ? 131071 : 524287);
+ if (isSetLoginUserName())
+ hashCode = hashCode * 8191 + loginUserName.hashCode();
- boolean present_preferredBatchQueue = true && (isSetPreferredBatchQueue());
- list.add(present_preferredBatchQueue);
- if (present_preferredBatchQueue)
- list.add(preferredBatchQueue);
+ hashCode = hashCode * 8191 + ((isSetPreferredBatchQueue()) ? 131071 : 524287);
+ if (isSetPreferredBatchQueue())
+ hashCode = hashCode * 8191 + preferredBatchQueue.hashCode();
- boolean present_scratchLocation = true && (isSetScratchLocation());
- list.add(present_scratchLocation);
- if (present_scratchLocation)
- list.add(scratchLocation);
+ hashCode = hashCode * 8191 + ((isSetScratchLocation()) ? 131071 : 524287);
+ if (isSetScratchLocation())
+ hashCode = hashCode * 8191 + scratchLocation.hashCode();
- boolean present_allocationProjectNumber = true && (isSetAllocationProjectNumber());
- list.add(present_allocationProjectNumber);
- if (present_allocationProjectNumber)
- list.add(allocationProjectNumber);
+ hashCode = hashCode * 8191 + ((isSetAllocationProjectNumber()) ? 131071 : 524287);
+ if (isSetAllocationProjectNumber())
+ hashCode = hashCode * 8191 + allocationProjectNumber.hashCode();
- boolean present_resourceSpecificCredentialStoreToken = true && (isSetResourceSpecificCredentialStoreToken());
- list.add(present_resourceSpecificCredentialStoreToken);
- if (present_resourceSpecificCredentialStoreToken)
- list.add(resourceSpecificCredentialStoreToken);
+ hashCode = hashCode * 8191 + ((isSetResourceSpecificCredentialStoreToken()) ? 131071 : 524287);
+ if (isSetResourceSpecificCredentialStoreToken())
+ hashCode = hashCode * 8191 + resourceSpecificCredentialStoreToken.hashCode();
- boolean present_qualityOfService = true && (isSetQualityOfService());
- list.add(present_qualityOfService);
- if (present_qualityOfService)
- list.add(qualityOfService);
+ hashCode = hashCode * 8191 + ((isSetQualityOfService()) ? 131071 : 524287);
+ if (isSetQualityOfService())
+ hashCode = hashCode * 8191 + qualityOfService.hashCode();
- boolean present_reservation = true && (isSetReservation());
- list.add(present_reservation);
- if (present_reservation)
- list.add(reservation);
+ hashCode = hashCode * 8191 + ((isSetReservation()) ? 131071 : 524287);
+ if (isSetReservation())
+ hashCode = hashCode * 8191 + reservation.hashCode();
- boolean present_reservationStartTime = true && (isSetReservationStartTime());
- list.add(present_reservationStartTime);
- if (present_reservationStartTime)
- list.add(reservationStartTime);
+ hashCode = hashCode * 8191 + ((isSetReservationStartTime()) ? 131071 : 524287);
+ if (isSetReservationStartTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(reservationStartTime);
- boolean present_reservationEndTime = true && (isSetReservationEndTime());
- list.add(present_reservationEndTime);
- if (present_reservationEndTime)
- list.add(reservationEndTime);
+ hashCode = hashCode * 8191 + ((isSetReservationEndTime()) ? 131071 : 524287);
+ if (isSetReservationEndTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(reservationEndTime);
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -841,7 +803,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetComputeResourceId()).compareTo(other.isSetComputeResourceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetComputeResourceId()).compareTo(other.isSetComputeResourceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -851,7 +813,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetLoginUserName()).compareTo(other.isSetLoginUserName());
+ lastComparison = java.lang.Boolean.valueOf(isSetLoginUserName()).compareTo(other.isSetLoginUserName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -861,7 +823,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPreferredBatchQueue()).compareTo(other.isSetPreferredBatchQueue());
+ lastComparison = java.lang.Boolean.valueOf(isSetPreferredBatchQueue()).compareTo(other.isSetPreferredBatchQueue());
if (lastComparison != 0) {
return lastComparison;
}
@@ -871,7 +833,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetScratchLocation()).compareTo(other.isSetScratchLocation());
+ lastComparison = java.lang.Boolean.valueOf(isSetScratchLocation()).compareTo(other.isSetScratchLocation());
if (lastComparison != 0) {
return lastComparison;
}
@@ -881,7 +843,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAllocationProjectNumber()).compareTo(other.isSetAllocationProjectNumber());
+ lastComparison = java.lang.Boolean.valueOf(isSetAllocationProjectNumber()).compareTo(other.isSetAllocationProjectNumber());
if (lastComparison != 0) {
return lastComparison;
}
@@ -891,7 +853,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetResourceSpecificCredentialStoreToken()).compareTo(other.isSetResourceSpecificCredentialStoreToken());
+ lastComparison = java.lang.Boolean.valueOf(isSetResourceSpecificCredentialStoreToken()).compareTo(other.isSetResourceSpecificCredentialStoreToken());
if (lastComparison != 0) {
return lastComparison;
}
@@ -901,7 +863,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetQualityOfService()).compareTo(other.isSetQualityOfService());
+ lastComparison = java.lang.Boolean.valueOf(isSetQualityOfService()).compareTo(other.isSetQualityOfService());
if (lastComparison != 0) {
return lastComparison;
}
@@ -911,7 +873,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetReservation()).compareTo(other.isSetReservation());
+ lastComparison = java.lang.Boolean.valueOf(isSetReservation()).compareTo(other.isSetReservation());
if (lastComparison != 0) {
return lastComparison;
}
@@ -921,7 +883,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetReservationStartTime()).compareTo(other.isSetReservationStartTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetReservationStartTime()).compareTo(other.isSetReservationStartTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -931,7 +893,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetReservationEndTime()).compareTo(other.isSetReservationEndTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetReservationEndTime()).compareTo(other.isSetReservationEndTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -949,16 +911,16 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("UserComputeResourcePreference(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("UserComputeResourcePreference(");
boolean first = true;
sb.append("computeResourceId:");
@@ -1071,7 +1033,7 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -1081,13 +1043,13 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
}
}
- private static class UserComputeResourcePreferenceStandardSchemeFactory implements SchemeFactory {
+ private static class UserComputeResourcePreferenceStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public UserComputeResourcePreferenceStandardScheme getScheme() {
return new UserComputeResourcePreferenceStandardScheme();
}
}
- private static class UserComputeResourcePreferenceStandardScheme extends StandardScheme<UserComputeResourcePreference> {
+ private static class UserComputeResourcePreferenceStandardScheme extends org.apache.thrift.scheme.StandardScheme<UserComputeResourcePreference> {
public void read(org.apache.thrift.protocol.TProtocol iprot, UserComputeResourcePreference struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1262,19 +1224,19 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
}
- private static class UserComputeResourcePreferenceTupleSchemeFactory implements SchemeFactory {
+ private static class UserComputeResourcePreferenceTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public UserComputeResourcePreferenceTupleScheme getScheme() {
return new UserComputeResourcePreferenceTupleScheme();
}
}
- private static class UserComputeResourcePreferenceTupleScheme extends TupleScheme<UserComputeResourcePreference> {
+ private static class UserComputeResourcePreferenceTupleScheme extends org.apache.thrift.scheme.TupleScheme<UserComputeResourcePreference> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, UserComputeResourcePreference struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.computeResourceId);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetLoginUserName()) {
optionals.set(0);
}
@@ -1334,10 +1296,10 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, UserComputeResourcePreference struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.computeResourceId = iprot.readString();
struct.setComputeResourceIdIsSet(true);
- BitSet incoming = iprot.readBitSet(9);
+ java.util.BitSet incoming = iprot.readBitSet(9);
if (incoming.get(0)) {
struct.loginUserName = iprot.readString();
struct.setLoginUserNameIsSet(true);
@@ -1377,5 +1339,8 @@ public class UserComputeResourcePreference implements org.apache.thrift.TBase<Us
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
[24/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/WorkflowModel.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/WorkflowModel.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/WorkflowModel.java
index ba6569c..12f8a9b 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/WorkflowModel.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/WorkflowModel.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, WorkflowModel._Fields>, java.io.Serializable, Cloneable, Comparable<WorkflowModel> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("WorkflowModel");
@@ -65,20 +38,17 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
private static final org.apache.thrift.protocol.TField WORKFLOW_OUTPUTS_FIELD_DESC = new org.apache.thrift.protocol.TField("workflowOutputs", org.apache.thrift.protocol.TType.LIST, (short)8);
private static final org.apache.thrift.protocol.TField CREATION_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("creationTime", org.apache.thrift.protocol.TType.I64, (short)9);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new WorkflowModelStandardSchemeFactory());
- schemes.put(TupleScheme.class, new WorkflowModelTupleSchemeFactory());
- }
-
- private String templateId; // required
- private String name; // required
- private String graph; // required
- private String gatewayId; // required
- private String createdUser; // required
- private ByteBuffer image; // optional
- private List<org.apache.airavata.model.application.io.InputDataObjectType> workflowInputs; // optional
- private List<org.apache.airavata.model.application.io.OutputDataObjectType> workflowOutputs; // optional
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new WorkflowModelStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new WorkflowModelTupleSchemeFactory();
+
+ private java.lang.String templateId; // required
+ private java.lang.String name; // required
+ private java.lang.String graph; // required
+ private java.lang.String gatewayId; // required
+ private java.lang.String createdUser; // required
+ private java.nio.ByteBuffer image; // optional
+ private java.util.List<org.apache.airavata.model.application.io.InputDataObjectType> workflowInputs; // optional
+ private java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType> workflowOutputs; // optional
private long creationTime; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
@@ -93,10 +63,10 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
WORKFLOW_OUTPUTS((short)8, "workflowOutputs"),
CREATION_TIME((short)9, "creationTime");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -135,21 +105,21 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -158,7 +128,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -167,9 +137,9 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
private static final int __CREATIONTIME_ISSET_ID = 0;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.IMAGE,_Fields.WORKFLOW_INPUTS,_Fields.WORKFLOW_OUTPUTS,_Fields.CREATION_TIME};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.TEMPLATE_ID, new org.apache.thrift.meta_data.FieldMetaData("templateId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.NAME, new org.apache.thrift.meta_data.FieldMetaData("name", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -190,7 +160,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, org.apache.airavata.model.application.io.OutputDataObjectType.class))));
tmpMap.put(_Fields.CREATION_TIME, new org.apache.thrift.meta_data.FieldMetaData("creationTime", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(WorkflowModel.class, metaDataMap);
}
@@ -200,11 +170,11 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
}
public WorkflowModel(
- String templateId,
- String name,
- String graph,
- String gatewayId,
- String createdUser)
+ java.lang.String templateId,
+ java.lang.String name,
+ java.lang.String graph,
+ java.lang.String gatewayId,
+ java.lang.String createdUser)
{
this();
this.templateId = templateId;
@@ -238,14 +208,14 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
this.image = org.apache.thrift.TBaseHelper.copyBinary(other.image);
}
if (other.isSetWorkflowInputs()) {
- List<org.apache.airavata.model.application.io.InputDataObjectType> __this__workflowInputs = new ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(other.workflowInputs.size());
+ java.util.List<org.apache.airavata.model.application.io.InputDataObjectType> __this__workflowInputs = new java.util.ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(other.workflowInputs.size());
for (org.apache.airavata.model.application.io.InputDataObjectType other_element : other.workflowInputs) {
__this__workflowInputs.add(new org.apache.airavata.model.application.io.InputDataObjectType(other_element));
}
this.workflowInputs = __this__workflowInputs;
}
if (other.isSetWorkflowOutputs()) {
- List<org.apache.airavata.model.application.io.OutputDataObjectType> __this__workflowOutputs = new ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(other.workflowOutputs.size());
+ java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType> __this__workflowOutputs = new java.util.ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(other.workflowOutputs.size());
for (org.apache.airavata.model.application.io.OutputDataObjectType other_element : other.workflowOutputs) {
__this__workflowOutputs.add(new org.apache.airavata.model.application.io.OutputDataObjectType(other_element));
}
@@ -273,11 +243,11 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
this.creationTime = 0;
}
- public String getTemplateId() {
+ public java.lang.String getTemplateId() {
return this.templateId;
}
- public void setTemplateId(String templateId) {
+ public void setTemplateId(java.lang.String templateId) {
this.templateId = templateId;
}
@@ -296,11 +266,11 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
}
}
- public String getName() {
+ public java.lang.String getName() {
return this.name;
}
- public void setName(String name) {
+ public void setName(java.lang.String name) {
this.name = name;
}
@@ -319,11 +289,11 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
}
}
- public String getGraph() {
+ public java.lang.String getGraph() {
return this.graph;
}
- public void setGraph(String graph) {
+ public void setGraph(java.lang.String graph) {
this.graph = graph;
}
@@ -342,11 +312,11 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
}
}
- public String getGatewayId() {
+ public java.lang.String getGatewayId() {
return this.gatewayId;
}
- public void setGatewayId(String gatewayId) {
+ public void setGatewayId(java.lang.String gatewayId) {
this.gatewayId = gatewayId;
}
@@ -365,11 +335,11 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
}
}
- public String getCreatedUser() {
+ public java.lang.String getCreatedUser() {
return this.createdUser;
}
- public void setCreatedUser(String createdUser) {
+ public void setCreatedUser(java.lang.String createdUser) {
this.createdUser = createdUser;
}
@@ -393,15 +363,15 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
return image == null ? null : image.array();
}
- public ByteBuffer bufferForImage() {
+ public java.nio.ByteBuffer bufferForImage() {
return org.apache.thrift.TBaseHelper.copyBinary(image);
}
public void setImage(byte[] image) {
- this.image = image == null ? (ByteBuffer)null : ByteBuffer.wrap(Arrays.copyOf(image, image.length));
+ this.image = image == null ? (java.nio.ByteBuffer)null : java.nio.ByteBuffer.wrap(image.clone());
}
- public void setImage(ByteBuffer image) {
+ public void setImage(java.nio.ByteBuffer image) {
this.image = org.apache.thrift.TBaseHelper.copyBinary(image);
}
@@ -430,16 +400,16 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
public void addToWorkflowInputs(org.apache.airavata.model.application.io.InputDataObjectType elem) {
if (this.workflowInputs == null) {
- this.workflowInputs = new ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>();
+ this.workflowInputs = new java.util.ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>();
}
this.workflowInputs.add(elem);
}
- public List<org.apache.airavata.model.application.io.InputDataObjectType> getWorkflowInputs() {
+ public java.util.List<org.apache.airavata.model.application.io.InputDataObjectType> getWorkflowInputs() {
return this.workflowInputs;
}
- public void setWorkflowInputs(List<org.apache.airavata.model.application.io.InputDataObjectType> workflowInputs) {
+ public void setWorkflowInputs(java.util.List<org.apache.airavata.model.application.io.InputDataObjectType> workflowInputs) {
this.workflowInputs = workflowInputs;
}
@@ -468,16 +438,16 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
public void addToWorkflowOutputs(org.apache.airavata.model.application.io.OutputDataObjectType elem) {
if (this.workflowOutputs == null) {
- this.workflowOutputs = new ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>();
+ this.workflowOutputs = new java.util.ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>();
}
this.workflowOutputs.add(elem);
}
- public List<org.apache.airavata.model.application.io.OutputDataObjectType> getWorkflowOutputs() {
+ public java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType> getWorkflowOutputs() {
return this.workflowOutputs;
}
- public void setWorkflowOutputs(List<org.apache.airavata.model.application.io.OutputDataObjectType> workflowOutputs) {
+ public void setWorkflowOutputs(java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType> workflowOutputs) {
this.workflowOutputs = workflowOutputs;
}
@@ -506,25 +476,25 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
}
public void unsetCreationTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
}
/** Returns true if field creationTime is set (has been assigned a value) and false otherwise */
public boolean isSetCreationTime() {
- return EncodingUtils.testBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
}
public void setCreationTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __CREATIONTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __CREATIONTIME_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case TEMPLATE_ID:
if (value == null) {
unsetTemplateId();
} else {
- setTemplateId((String)value);
+ setTemplateId((java.lang.String)value);
}
break;
@@ -532,7 +502,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
if (value == null) {
unsetName();
} else {
- setName((String)value);
+ setName((java.lang.String)value);
}
break;
@@ -540,7 +510,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
if (value == null) {
unsetGraph();
} else {
- setGraph((String)value);
+ setGraph((java.lang.String)value);
}
break;
@@ -548,7 +518,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
if (value == null) {
unsetGatewayId();
} else {
- setGatewayId((String)value);
+ setGatewayId((java.lang.String)value);
}
break;
@@ -556,7 +526,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
if (value == null) {
unsetCreatedUser();
} else {
- setCreatedUser((String)value);
+ setCreatedUser((java.lang.String)value);
}
break;
@@ -564,7 +534,11 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
if (value == null) {
unsetImage();
} else {
- setImage((ByteBuffer)value);
+ if (value instanceof byte[]) {
+ setImage((byte[])value);
+ } else {
+ setImage((java.nio.ByteBuffer)value);
+ }
}
break;
@@ -572,7 +546,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
if (value == null) {
unsetWorkflowInputs();
} else {
- setWorkflowInputs((List<org.apache.airavata.model.application.io.InputDataObjectType>)value);
+ setWorkflowInputs((java.util.List<org.apache.airavata.model.application.io.InputDataObjectType>)value);
}
break;
@@ -580,7 +554,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
if (value == null) {
unsetWorkflowOutputs();
} else {
- setWorkflowOutputs((List<org.apache.airavata.model.application.io.OutputDataObjectType>)value);
+ setWorkflowOutputs((java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType>)value);
}
break;
@@ -588,14 +562,14 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
if (value == null) {
unsetCreationTime();
} else {
- setCreationTime((Long)value);
+ setCreationTime((java.lang.Long)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case TEMPLATE_ID:
return getTemplateId();
@@ -625,13 +599,13 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
return getCreationTime();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -654,11 +628,11 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
case CREATION_TIME:
return isSetCreationTime();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof WorkflowModel)
@@ -669,6 +643,8 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
public boolean equals(WorkflowModel that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_templateId = true && this.isSetTemplateId();
boolean that_present_templateId = true && that.isSetTemplateId();
@@ -756,54 +732,45 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_templateId = true && (isSetTemplateId());
- list.add(present_templateId);
- if (present_templateId)
- list.add(templateId);
+ hashCode = hashCode * 8191 + ((isSetTemplateId()) ? 131071 : 524287);
+ if (isSetTemplateId())
+ hashCode = hashCode * 8191 + templateId.hashCode();
- boolean present_name = true && (isSetName());
- list.add(present_name);
- if (present_name)
- list.add(name);
+ hashCode = hashCode * 8191 + ((isSetName()) ? 131071 : 524287);
+ if (isSetName())
+ hashCode = hashCode * 8191 + name.hashCode();
- boolean present_graph = true && (isSetGraph());
- list.add(present_graph);
- if (present_graph)
- list.add(graph);
+ hashCode = hashCode * 8191 + ((isSetGraph()) ? 131071 : 524287);
+ if (isSetGraph())
+ hashCode = hashCode * 8191 + graph.hashCode();
- boolean present_gatewayId = true && (isSetGatewayId());
- list.add(present_gatewayId);
- if (present_gatewayId)
- list.add(gatewayId);
+ hashCode = hashCode * 8191 + ((isSetGatewayId()) ? 131071 : 524287);
+ if (isSetGatewayId())
+ hashCode = hashCode * 8191 + gatewayId.hashCode();
- boolean present_createdUser = true && (isSetCreatedUser());
- list.add(present_createdUser);
- if (present_createdUser)
- list.add(createdUser);
+ hashCode = hashCode * 8191 + ((isSetCreatedUser()) ? 131071 : 524287);
+ if (isSetCreatedUser())
+ hashCode = hashCode * 8191 + createdUser.hashCode();
- boolean present_image = true && (isSetImage());
- list.add(present_image);
- if (present_image)
- list.add(image);
+ hashCode = hashCode * 8191 + ((isSetImage()) ? 131071 : 524287);
+ if (isSetImage())
+ hashCode = hashCode * 8191 + image.hashCode();
- boolean present_workflowInputs = true && (isSetWorkflowInputs());
- list.add(present_workflowInputs);
- if (present_workflowInputs)
- list.add(workflowInputs);
+ hashCode = hashCode * 8191 + ((isSetWorkflowInputs()) ? 131071 : 524287);
+ if (isSetWorkflowInputs())
+ hashCode = hashCode * 8191 + workflowInputs.hashCode();
- boolean present_workflowOutputs = true && (isSetWorkflowOutputs());
- list.add(present_workflowOutputs);
- if (present_workflowOutputs)
- list.add(workflowOutputs);
+ hashCode = hashCode * 8191 + ((isSetWorkflowOutputs()) ? 131071 : 524287);
+ if (isSetWorkflowOutputs())
+ hashCode = hashCode * 8191 + workflowOutputs.hashCode();
- boolean present_creationTime = true && (isSetCreationTime());
- list.add(present_creationTime);
- if (present_creationTime)
- list.add(creationTime);
+ hashCode = hashCode * 8191 + ((isSetCreationTime()) ? 131071 : 524287);
+ if (isSetCreationTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(creationTime);
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -814,7 +781,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetTemplateId()).compareTo(other.isSetTemplateId());
+ lastComparison = java.lang.Boolean.valueOf(isSetTemplateId()).compareTo(other.isSetTemplateId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -824,7 +791,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetName()).compareTo(other.isSetName());
+ lastComparison = java.lang.Boolean.valueOf(isSetName()).compareTo(other.isSetName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -834,7 +801,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetGraph()).compareTo(other.isSetGraph());
+ lastComparison = java.lang.Boolean.valueOf(isSetGraph()).compareTo(other.isSetGraph());
if (lastComparison != 0) {
return lastComparison;
}
@@ -844,7 +811,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(other.isSetGatewayId());
+ lastComparison = java.lang.Boolean.valueOf(isSetGatewayId()).compareTo(other.isSetGatewayId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -854,7 +821,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCreatedUser()).compareTo(other.isSetCreatedUser());
+ lastComparison = java.lang.Boolean.valueOf(isSetCreatedUser()).compareTo(other.isSetCreatedUser());
if (lastComparison != 0) {
return lastComparison;
}
@@ -864,7 +831,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetImage()).compareTo(other.isSetImage());
+ lastComparison = java.lang.Boolean.valueOf(isSetImage()).compareTo(other.isSetImage());
if (lastComparison != 0) {
return lastComparison;
}
@@ -874,7 +841,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetWorkflowInputs()).compareTo(other.isSetWorkflowInputs());
+ lastComparison = java.lang.Boolean.valueOf(isSetWorkflowInputs()).compareTo(other.isSetWorkflowInputs());
if (lastComparison != 0) {
return lastComparison;
}
@@ -884,7 +851,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetWorkflowOutputs()).compareTo(other.isSetWorkflowOutputs());
+ lastComparison = java.lang.Boolean.valueOf(isSetWorkflowOutputs()).compareTo(other.isSetWorkflowOutputs());
if (lastComparison != 0) {
return lastComparison;
}
@@ -894,7 +861,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCreationTime()).compareTo(other.isSetCreationTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetCreationTime()).compareTo(other.isSetCreationTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -912,16 +879,16 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("WorkflowModel(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("WorkflowModel(");
boolean first = true;
sb.append("templateId:");
@@ -1036,7 +1003,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -1046,13 +1013,13 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
}
}
- private static class WorkflowModelStandardSchemeFactory implements SchemeFactory {
+ private static class WorkflowModelStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public WorkflowModelStandardScheme getScheme() {
return new WorkflowModelStandardScheme();
}
}
- private static class WorkflowModelStandardScheme extends StandardScheme<WorkflowModel> {
+ private static class WorkflowModelStandardScheme extends org.apache.thrift.scheme.StandardScheme<WorkflowModel> {
public void read(org.apache.thrift.protocol.TProtocol iprot, WorkflowModel struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1116,7 +1083,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list0 = iprot.readListBegin();
- struct.workflowInputs = new ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(_list0.size);
+ struct.workflowInputs = new java.util.ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(_list0.size);
org.apache.airavata.model.application.io.InputDataObjectType _elem1;
for (int _i2 = 0; _i2 < _list0.size; ++_i2)
{
@@ -1135,7 +1102,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list3 = iprot.readListBegin();
- struct.workflowOutputs = new ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(_list3.size);
+ struct.workflowOutputs = new java.util.ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(_list3.size);
org.apache.airavata.model.application.io.OutputDataObjectType _elem4;
for (int _i5 = 0; _i5 < _list3.size; ++_i5)
{
@@ -1242,23 +1209,23 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
}
- private static class WorkflowModelTupleSchemeFactory implements SchemeFactory {
+ private static class WorkflowModelTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public WorkflowModelTupleScheme getScheme() {
return new WorkflowModelTupleScheme();
}
}
- private static class WorkflowModelTupleScheme extends TupleScheme<WorkflowModel> {
+ private static class WorkflowModelTupleScheme extends org.apache.thrift.scheme.TupleScheme<WorkflowModel> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, WorkflowModel struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.templateId);
oprot.writeString(struct.name);
oprot.writeString(struct.graph);
oprot.writeString(struct.gatewayId);
oprot.writeString(struct.createdUser);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetImage()) {
optionals.set(0);
}
@@ -1300,7 +1267,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, WorkflowModel struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.templateId = iprot.readString();
struct.setTemplateIdIsSet(true);
struct.name = iprot.readString();
@@ -1311,7 +1278,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
struct.setGatewayIdIsSet(true);
struct.createdUser = iprot.readString();
struct.setCreatedUserIsSet(true);
- BitSet incoming = iprot.readBitSet(4);
+ java.util.BitSet incoming = iprot.readBitSet(4);
if (incoming.get(0)) {
struct.image = iprot.readBinary();
struct.setImageIsSet(true);
@@ -1319,7 +1286,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
if (incoming.get(1)) {
{
org.apache.thrift.protocol.TList _list10 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.workflowInputs = new ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(_list10.size);
+ struct.workflowInputs = new java.util.ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(_list10.size);
org.apache.airavata.model.application.io.InputDataObjectType _elem11;
for (int _i12 = 0; _i12 < _list10.size; ++_i12)
{
@@ -1333,7 +1300,7 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
if (incoming.get(2)) {
{
org.apache.thrift.protocol.TList _list13 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.workflowOutputs = new ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(_list13.size);
+ struct.workflowOutputs = new java.util.ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(_list13.size);
org.apache.airavata.model.application.io.OutputDataObjectType _elem14;
for (int _i15 = 0; _i15 < _list13.size; ++_i15)
{
@@ -1351,5 +1318,8 @@ public class WorkflowModel implements org.apache.thrift.TBase<WorkflowModel, Wor
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/WorkflowState.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/WorkflowState.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/WorkflowState.java
index 5faac14..7348214 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/WorkflowState.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/WorkflowState.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/WorkflowStatus.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/WorkflowStatus.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/WorkflowStatus.java
index deadf51..6b642f1 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/WorkflowStatus.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/WorkflowStatus.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, WorkflowStatus._Fields>, java.io.Serializable, Cloneable, Comparable<WorkflowStatus> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("WorkflowStatus");
@@ -59,15 +32,12 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
private static final org.apache.thrift.protocol.TField TIME_OF_STATE_CHANGE_FIELD_DESC = new org.apache.thrift.protocol.TField("timeOfStateChange", org.apache.thrift.protocol.TType.I64, (short)2);
private static final org.apache.thrift.protocol.TField REASON_FIELD_DESC = new org.apache.thrift.protocol.TField("reason", 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 WorkflowStatusStandardSchemeFactory());
- schemes.put(TupleScheme.class, new WorkflowStatusTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new WorkflowStatusStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new WorkflowStatusTupleSchemeFactory();
private WorkflowState state; // required
private long timeOfStateChange; // optional
- private String reason; // optional
+ private java.lang.String reason; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -79,10 +49,10 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
TIME_OF_STATE_CHANGE((short)2, "timeOfStateChange"),
REASON((short)3, "reason");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -109,21 +79,21 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -132,7 +102,7 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -141,16 +111,16 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
private static final int __TIMEOFSTATECHANGE_ISSET_ID = 0;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.TIME_OF_STATE_CHANGE,_Fields.REASON};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.STATE, new org.apache.thrift.meta_data.FieldMetaData("state", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, WorkflowState.class)));
tmpMap.put(_Fields.TIME_OF_STATE_CHANGE, new org.apache.thrift.meta_data.FieldMetaData("timeOfStateChange", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
tmpMap.put(_Fields.REASON, new org.apache.thrift.meta_data.FieldMetaData("reason", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(WorkflowStatus.class, metaDataMap);
}
@@ -231,23 +201,23 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
}
public void unsetTimeOfStateChange() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __TIMEOFSTATECHANGE_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __TIMEOFSTATECHANGE_ISSET_ID);
}
/** Returns true if field timeOfStateChange is set (has been assigned a value) and false otherwise */
public boolean isSetTimeOfStateChange() {
- return EncodingUtils.testBit(__isset_bitfield, __TIMEOFSTATECHANGE_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __TIMEOFSTATECHANGE_ISSET_ID);
}
public void setTimeOfStateChangeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __TIMEOFSTATECHANGE_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __TIMEOFSTATECHANGE_ISSET_ID, value);
}
- public String getReason() {
+ public java.lang.String getReason() {
return this.reason;
}
- public void setReason(String reason) {
+ public void setReason(java.lang.String reason) {
this.reason = reason;
}
@@ -266,7 +236,7 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case STATE:
if (value == null) {
@@ -280,7 +250,7 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
if (value == null) {
unsetTimeOfStateChange();
} else {
- setTimeOfStateChange((Long)value);
+ setTimeOfStateChange((java.lang.Long)value);
}
break;
@@ -288,14 +258,14 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
if (value == null) {
unsetReason();
} else {
- setReason((String)value);
+ setReason((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case STATE:
return getState();
@@ -307,13 +277,13 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
return getReason();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -324,11 +294,11 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
case REASON:
return isSetReason();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof WorkflowStatus)
@@ -339,6 +309,8 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
public boolean equals(WorkflowStatus that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_state = true && this.isSetState();
boolean that_present_state = true && that.isSetState();
@@ -372,24 +344,21 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_state = true && (isSetState());
- list.add(present_state);
- if (present_state)
- list.add(state.getValue());
+ hashCode = hashCode * 8191 + ((isSetState()) ? 131071 : 524287);
+ if (isSetState())
+ hashCode = hashCode * 8191 + state.getValue();
- boolean present_timeOfStateChange = true && (isSetTimeOfStateChange());
- list.add(present_timeOfStateChange);
- if (present_timeOfStateChange)
- list.add(timeOfStateChange);
+ hashCode = hashCode * 8191 + ((isSetTimeOfStateChange()) ? 131071 : 524287);
+ if (isSetTimeOfStateChange())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(timeOfStateChange);
- boolean present_reason = true && (isSetReason());
- list.add(present_reason);
- if (present_reason)
- list.add(reason);
+ hashCode = hashCode * 8191 + ((isSetReason()) ? 131071 : 524287);
+ if (isSetReason())
+ hashCode = hashCode * 8191 + reason.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -400,7 +369,7 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetState()).compareTo(other.isSetState());
+ lastComparison = java.lang.Boolean.valueOf(isSetState()).compareTo(other.isSetState());
if (lastComparison != 0) {
return lastComparison;
}
@@ -410,7 +379,7 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetTimeOfStateChange()).compareTo(other.isSetTimeOfStateChange());
+ lastComparison = java.lang.Boolean.valueOf(isSetTimeOfStateChange()).compareTo(other.isSetTimeOfStateChange());
if (lastComparison != 0) {
return lastComparison;
}
@@ -420,7 +389,7 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetReason()).compareTo(other.isSetReason());
+ lastComparison = java.lang.Boolean.valueOf(isSetReason()).compareTo(other.isSetReason());
if (lastComparison != 0) {
return lastComparison;
}
@@ -438,16 +407,16 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("WorkflowStatus(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("WorkflowStatus(");
boolean first = true;
sb.append("state:");
@@ -494,7 +463,7 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -504,13 +473,13 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
}
}
- private static class WorkflowStatusStandardSchemeFactory implements SchemeFactory {
+ private static class WorkflowStatusStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public WorkflowStatusStandardScheme getScheme() {
return new WorkflowStatusStandardScheme();
}
}
- private static class WorkflowStatusStandardScheme extends StandardScheme<WorkflowStatus> {
+ private static class WorkflowStatusStandardScheme extends org.apache.thrift.scheme.StandardScheme<WorkflowStatus> {
public void read(org.apache.thrift.protocol.TProtocol iprot, WorkflowStatus struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -582,19 +551,19 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
}
- private static class WorkflowStatusTupleSchemeFactory implements SchemeFactory {
+ private static class WorkflowStatusTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public WorkflowStatusTupleScheme getScheme() {
return new WorkflowStatusTupleScheme();
}
}
- private static class WorkflowStatusTupleScheme extends TupleScheme<WorkflowStatus> {
+ private static class WorkflowStatusTupleScheme extends org.apache.thrift.scheme.TupleScheme<WorkflowStatus> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, WorkflowStatus struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeI32(struct.state.getValue());
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetTimeOfStateChange()) {
optionals.set(0);
}
@@ -612,10 +581,10 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, WorkflowStatus struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.state = org.apache.airavata.model.WorkflowState.findByValue(iprot.readI32());
struct.setStateIsSet(true);
- BitSet incoming = iprot.readBitSet(2);
+ java.util.BitSet incoming = iprot.readBitSet(2);
if (incoming.get(0)) {
struct.timeOfStateChange = iprot.readI64();
struct.setTimeOfStateChangeIsSet(true);
@@ -627,5 +596,8 @@ public class WorkflowStatus implements org.apache.thrift.TBase<WorkflowStatus, W
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
[50/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-api-stubs/src/main/java/org/apache/airavata/api/Airavata.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-api-stubs/src/main/java/org/apache/airavata/api/Airavata.java b/airavata-api/airavata-api-stubs/src/main/java/org/apache/airavata/api/Airavata.java
index 6ef1610..88b5f90 100644
--- a/airavata-api/airavata-api-stubs/src/main/java/org/apache/airavata/api/Airavata.java
+++ b/airavata-api/airavata-api-stubs/src/main/java/org/apache/airavata/api/Airavata.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.api;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class Airavata {
public interface Iface {
@@ -62,7 +35,7 @@ public class Airavata {
*
* @param authzToken
*/
- public String getAPIVersion(org.apache.airavata.model.security.AuthzToken authzToken) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.lang.String getAPIVersion(org.apache.airavata.model.security.AuthzToken authzToken) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Verify if User Exists within Airavata.
@@ -79,7 +52,7 @@ public class Airavata {
* @param gatewayId
* @param userName
*/
- public boolean isUserExists(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId, String userName) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean isUserExists(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId, java.lang.String userName) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Register a Gateway with Airavata.
@@ -95,7 +68,7 @@ public class Airavata {
* @param authzToken
* @param gateway
*/
- public String addGateway(org.apache.airavata.model.security.AuthzToken authzToken, org.apache.airavata.model.workspace.Gateway gateway) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.lang.String addGateway(org.apache.airavata.model.security.AuthzToken authzToken, org.apache.airavata.model.workspace.Gateway gateway) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Get all users in the gateway
@@ -111,7 +84,7 @@ public class Airavata {
* @param authzToken
* @param gatewayId
*/
- public List<String> getAllUsersInGateway(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.List<java.lang.String> getAllUsersInGateway(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Update previously registered Gateway metadata.
@@ -130,7 +103,7 @@ public class Airavata {
* @param gatewayId
* @param updatedGateway
*/
- public boolean updateGateway(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId, org.apache.airavata.model.workspace.Gateway updatedGateway) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean updateGateway(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId, org.apache.airavata.model.workspace.Gateway updatedGateway) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Get Gateway details by providing gatewayId
@@ -146,7 +119,7 @@ public class Airavata {
* @param authzToken
* @param gatewayId
*/
- public org.apache.airavata.model.workspace.Gateway getGateway(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public org.apache.airavata.model.workspace.Gateway getGateway(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Delete a Gateway
@@ -162,7 +135,7 @@ public class Airavata {
* @param authzToken
* @param gatewayId
*/
- public boolean deleteGateway(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean deleteGateway(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Get All the Gateways Connected to Airavata.
@@ -170,7 +143,7 @@ public class Airavata {
*
* @param authzToken
*/
- public List<org.apache.airavata.model.workspace.Gateway> getAllGateways(org.apache.airavata.model.security.AuthzToken authzToken) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.List<org.apache.airavata.model.workspace.Gateway> getAllGateways(org.apache.airavata.model.security.AuthzToken authzToken) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Check for the Existance of a Gateway within Airavata
@@ -189,7 +162,7 @@ public class Airavata {
* @param authzToken
* @param gatewayId
*/
- public boolean isGatewayExist(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean isGatewayExist(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* * API methods to retrieve notifications
@@ -198,15 +171,15 @@ public class Airavata {
* @param authzToken
* @param notification
*/
- public String createNotification(org.apache.airavata.model.security.AuthzToken authzToken, org.apache.airavata.model.workspace.Notification notification) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.lang.String createNotification(org.apache.airavata.model.security.AuthzToken authzToken, org.apache.airavata.model.workspace.Notification notification) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
public boolean updateNotification(org.apache.airavata.model.security.AuthzToken authzToken, org.apache.airavata.model.workspace.Notification notification) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
- public boolean deleteNotification(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId, String notificationId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean deleteNotification(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId, java.lang.String notificationId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
- public org.apache.airavata.model.workspace.Notification getNotification(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId, String notificationId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public org.apache.airavata.model.workspace.Notification getNotification(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId, java.lang.String notificationId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
- public List<org.apache.airavata.model.workspace.Notification> getAllNotifications(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.List<org.apache.airavata.model.workspace.Notification> getAllNotifications(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Generate and Register SSH Key Pair with Airavata Credential Store.
@@ -236,7 +209,7 @@ public class Airavata {
* @param description
* @param credentialOwnerType
*/
- public String generateAndRegisterSSHKeys(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId, String userName, String description, org.apache.airavata.model.credential.store.CredentialOwnerType credentialOwnerType) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
+ public java.lang.String generateAndRegisterSSHKeys(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId, java.lang.String userName, java.lang.String description, org.apache.airavata.model.credential.store.CredentialOwnerType credentialOwnerType) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
/**
* Generate and Register Username PWD Pair with Airavata Credential Store.
@@ -265,7 +238,7 @@ public class Airavata {
* @param password
* @param description
*/
- public String registerPwdCredential(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId, String portalUserName, String loginUserName, String password, String description) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
+ public java.lang.String registerPwdCredential(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId, java.lang.String portalUserName, java.lang.String loginUserName, java.lang.String password, java.lang.String description) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
/**
* Get a Public Key by Providing the Token
@@ -284,7 +257,7 @@ public class Airavata {
* @param airavataCredStoreToken
* @param gatewayId
*/
- public String getSSHPubKey(org.apache.airavata.model.security.AuthzToken authzToken, String airavataCredStoreToken, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
+ public java.lang.String getSSHPubKey(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String airavataCredStoreToken, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
/**
*
@@ -303,7 +276,7 @@ public class Airavata {
* @param authzToken
* @param gatewayId
*/
- public Map<String,String> getAllGatewaySSHPubKeys(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
+ public java.util.Map<java.lang.String,java.lang.String> getAllGatewaySSHPubKeys(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
/**
*
@@ -326,7 +299,7 @@ public class Airavata {
* @param type
* @param gatewayId
*/
- public List<org.apache.airavata.model.credential.store.CredentialSummary> getAllCredentialSummaryForGateway(org.apache.airavata.model.security.AuthzToken authzToken, org.apache.airavata.model.credential.store.SummaryType type, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
+ public java.util.List<org.apache.airavata.model.credential.store.CredentialSummary> getAllCredentialSummaryForGateway(org.apache.airavata.model.security.AuthzToken authzToken, org.apache.airavata.model.credential.store.SummaryType type, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
/**
*
@@ -353,9 +326,9 @@ public class Airavata {
* @param gatewayId
* @param userId
*/
- public List<org.apache.airavata.model.credential.store.CredentialSummary> getAllCredentialSummaryForUsersInGateway(org.apache.airavata.model.security.AuthzToken authzToken, org.apache.airavata.model.credential.store.SummaryType type, String gatewayId, String userId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
+ public java.util.List<org.apache.airavata.model.credential.store.CredentialSummary> getAllCredentialSummaryForUsersInGateway(org.apache.airavata.model.security.AuthzToken authzToken, org.apache.airavata.model.credential.store.SummaryType type, java.lang.String gatewayId, java.lang.String userId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
- public Map<String,String> getAllGatewayPWDCredentials(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
+ public java.util.Map<java.lang.String,java.lang.String> getAllGatewayPWDCredentials(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
/**
*
@@ -373,9 +346,9 @@ public class Airavata {
* @param airavataCredStoreToken
* @param gatewayId
*/
- public boolean deleteSSHPubKey(org.apache.airavata.model.security.AuthzToken authzToken, String airavataCredStoreToken, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
+ public boolean deleteSSHPubKey(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String airavataCredStoreToken, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
- public boolean deletePWDCredential(org.apache.airavata.model.security.AuthzToken authzToken, String airavataCredStoreToken, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
+ public boolean deletePWDCredential(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String airavataCredStoreToken, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.thrift.TException;
/**
*
@@ -394,7 +367,7 @@ public class Airavata {
* @param gatewayId
* @param project
*/
- public String createProject(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId, org.apache.airavata.model.workspace.Project project) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.lang.String createProject(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId, org.apache.airavata.model.workspace.Project project) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -412,7 +385,7 @@ public class Airavata {
* @param projectId
* @param updatedProject
*/
- public void updateProject(org.apache.airavata.model.security.AuthzToken authzToken, String projectId, org.apache.airavata.model.workspace.Project updatedProject) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.ProjectNotFoundException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public void updateProject(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String projectId, org.apache.airavata.model.workspace.Project updatedProject) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.ProjectNotFoundException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -430,7 +403,7 @@ public class Airavata {
* @param authzToken
* @param projectId
*/
- public org.apache.airavata.model.workspace.Project getProject(org.apache.airavata.model.security.AuthzToken authzToken, String projectId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.ProjectNotFoundException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public org.apache.airavata.model.workspace.Project getProject(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String projectId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.ProjectNotFoundException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -450,7 +423,7 @@ public class Airavata {
* @param authzToken
* @param projectId
*/
- public boolean deleteProject(org.apache.airavata.model.security.AuthzToken authzToken, String projectId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.ProjectNotFoundException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean deleteProject(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String projectId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.ProjectNotFoundException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -477,7 +450,7 @@ public class Airavata {
* @param limit
* @param offset
*/
- public List<org.apache.airavata.model.workspace.Project> getUserProjects(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId, String userName, int limit, int offset) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.List<org.apache.airavata.model.workspace.Project> getUserProjects(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId, java.lang.String userName, int limit, int offset) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -509,7 +482,7 @@ public class Airavata {
* @param limit
* @param offset
*/
- public List<org.apache.airavata.model.workspace.Project> searchProjects(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId, String userName, Map<org.apache.airavata.model.experiment.ProjectSearchFields,String> filters, int limit, int offset) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.List<org.apache.airavata.model.workspace.Project> searchProjects(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId, java.lang.String userName, java.util.Map<org.apache.airavata.model.experiment.ProjectSearchFields,java.lang.String> filters, int limit, int offset) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Search Experiments.
@@ -542,7 +515,7 @@ public class Airavata {
* @param limit
* @param offset
*/
- public List<org.apache.airavata.model.experiment.ExperimentSummaryModel> searchExperiments(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId, String userName, Map<org.apache.airavata.model.experiment.ExperimentSearchFields,String> filters, int limit, int offset) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.List<org.apache.airavata.model.experiment.ExperimentSummaryModel> searchExperiments(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId, java.lang.String userName, java.util.Map<org.apache.airavata.model.experiment.ExperimentSearchFields,java.lang.String> filters, int limit, int offset) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -577,7 +550,7 @@ public class Airavata {
* @param applicationName
* @param resourceHostName
*/
- public org.apache.airavata.model.experiment.ExperimentStatistics getExperimentStatistics(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId, long fromTime, long toTime, String userName, String applicationName, String resourceHostName) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public org.apache.airavata.model.experiment.ExperimentStatistics getExperimentStatistics(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId, long fromTime, long toTime, java.lang.String userName, java.lang.String applicationName, java.lang.String resourceHostName) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -600,7 +573,7 @@ public class Airavata {
* @param limit
* @param offset
*/
- public List<org.apache.airavata.model.experiment.ExperimentModel> getExperimentsInProject(org.apache.airavata.model.security.AuthzToken authzToken, String projectId, int limit, int offset) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.ProjectNotFoundException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.List<org.apache.airavata.model.experiment.ExperimentModel> getExperimentsInProject(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String projectId, int limit, int offset) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.ProjectNotFoundException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -627,7 +600,7 @@ public class Airavata {
* @param limit
* @param offset
*/
- public List<org.apache.airavata.model.experiment.ExperimentModel> getUserExperiments(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId, String userName, int limit, int offset) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.List<org.apache.airavata.model.experiment.ExperimentModel> getUserExperiments(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId, java.lang.String userName, int limit, int offset) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* *
@@ -674,7 +647,7 @@ public class Airavata {
* @param gatewayId
* @param experiment
*/
- public String createExperiment(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId, org.apache.airavata.model.experiment.ExperimentModel experiment) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.lang.String createExperiment(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId, org.apache.airavata.model.experiment.ExperimentModel experiment) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -694,7 +667,7 @@ public class Airavata {
* @param authzToken
* @param experimentId
*/
- public boolean deleteExperiment(org.apache.airavata.model.security.AuthzToken authzToken, String experimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean deleteExperiment(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String experimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* *
@@ -735,7 +708,7 @@ public class Airavata {
* @param authzToken
* @param airavataExperimentId
*/
- public org.apache.airavata.model.experiment.ExperimentModel getExperiment(org.apache.airavata.model.security.AuthzToken authzToken, String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public org.apache.airavata.model.experiment.ExperimentModel getExperiment(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* *
@@ -777,7 +750,7 @@ public class Airavata {
* @param authzToken
* @param airavataExperimentId
*/
- public org.apache.airavata.model.experiment.ExperimentModel getExperimentByAdmin(org.apache.airavata.model.security.AuthzToken authzToken, String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public org.apache.airavata.model.experiment.ExperimentModel getExperimentByAdmin(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -819,7 +792,7 @@ public class Airavata {
* @param authzToken
* @param airavataExperimentId
*/
- public org.apache.airavata.model.experiment.ExperimentModel getDetailedExperimentTree(org.apache.airavata.model.security.AuthzToken authzToken, String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public org.apache.airavata.model.experiment.ExperimentModel getDetailedExperimentTree(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -865,11 +838,11 @@ public class Airavata {
* @param airavataExperimentId
* @param experiment
*/
- public void updateExperiment(org.apache.airavata.model.security.AuthzToken authzToken, String airavataExperimentId, org.apache.airavata.model.experiment.ExperimentModel experiment) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public void updateExperiment(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String airavataExperimentId, org.apache.airavata.model.experiment.ExperimentModel experiment) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
- public void updateExperimentConfiguration(org.apache.airavata.model.security.AuthzToken authzToken, String airavataExperimentId, org.apache.airavata.model.experiment.UserConfigurationDataModel userConfiguration) throws org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public void updateExperimentConfiguration(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String airavataExperimentId, org.apache.airavata.model.experiment.UserConfigurationDataModel userConfiguration) throws org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
- public void updateResourceScheduleing(org.apache.airavata.model.security.AuthzToken authzToken, String airavataExperimentId, org.apache.airavata.model.scheduling.ComputationalResourceSchedulingModel resourceScheduling) throws org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public void updateResourceScheduleing(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String airavataExperimentId, org.apache.airavata.model.scheduling.ComputationalResourceSchedulingModel resourceScheduling) throws org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* *
@@ -887,7 +860,7 @@ public class Airavata {
* @param authzToken
* @param airavataExperimentId
*/
- public boolean validateExperiment(org.apache.airavata.model.security.AuthzToken authzToken, String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean validateExperiment(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -931,7 +904,7 @@ public class Airavata {
* @param airavataExperimentId
* @param gatewayId
*/
- public void launchExperiment(org.apache.airavata.model.security.AuthzToken authzToken, String airavataExperimentId, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public void launchExperiment(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String airavataExperimentId, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -952,7 +925,7 @@ public class Airavata {
* @param authzToken
* @param airavataExperimentId
*/
- public org.apache.airavata.model.status.ExperimentStatus getExperimentStatus(org.apache.airavata.model.security.AuthzToken authzToken, String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public org.apache.airavata.model.status.ExperimentStatus getExperimentStatus(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -972,7 +945,7 @@ public class Airavata {
* @param authzToken
* @param airavataExperimentId
*/
- public List<org.apache.airavata.model.application.io.OutputDataObjectType> getExperimentOutputs(org.apache.airavata.model.security.AuthzToken authzToken, String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType> getExperimentOutputs(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -992,7 +965,7 @@ public class Airavata {
* @param authzToken
* @param airavataExperimentId
*/
- public List<org.apache.airavata.model.application.io.OutputDataObjectType> getIntermediateOutputs(org.apache.airavata.model.security.AuthzToken authzToken, String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType> getIntermediateOutputs(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1012,7 +985,7 @@ public class Airavata {
* @param authzToken
* @param airavataExperimentId
*/
- public Map<String,org.apache.airavata.model.status.JobStatus> getJobStatuses(org.apache.airavata.model.security.AuthzToken authzToken, String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.Map<java.lang.String,org.apache.airavata.model.status.JobStatus> getJobStatuses(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1032,7 +1005,7 @@ public class Airavata {
* @param authzToken
* @param airavataExperimentId
*/
- public List<org.apache.airavata.model.job.JobModel> getJobDetails(org.apache.airavata.model.security.AuthzToken authzToken, String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.List<org.apache.airavata.model.job.JobModel> getJobDetails(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String airavataExperimentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1083,7 +1056,7 @@ public class Airavata {
* @param newExperimentName
* @param newExperimentProjectId
*/
- public String cloneExperiment(org.apache.airavata.model.security.AuthzToken authzToken, String existingExperimentID, String newExperimentName, String newExperimentProjectId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.airavata.model.error.ProjectNotFoundException, org.apache.thrift.TException;
+ public java.lang.String cloneExperiment(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String existingExperimentID, java.lang.String newExperimentName, java.lang.String newExperimentProjectId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.airavata.model.error.ProjectNotFoundException, org.apache.thrift.TException;
/**
*
@@ -1134,7 +1107,7 @@ public class Airavata {
* @param newExperimentName
* @param newExperimentProjectId
*/
- public String cloneExperimentByAdmin(org.apache.airavata.model.security.AuthzToken authzToken, String existingExperimentID, String newExperimentName, String newExperimentProjectId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.airavata.model.error.ProjectNotFoundException, org.apache.thrift.TException;
+ public java.lang.String cloneExperimentByAdmin(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String existingExperimentID, java.lang.String newExperimentName, java.lang.String newExperimentProjectId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.airavata.model.error.ProjectNotFoundException, org.apache.thrift.TException;
/**
*
@@ -1177,7 +1150,7 @@ public class Airavata {
* @param airavataExperimentId
* @param gatewayId
*/
- public void terminateExperiment(org.apache.airavata.model.security.AuthzToken authzToken, String airavataExperimentId, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public void terminateExperiment(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String airavataExperimentId, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.ExperimentNotFoundException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1197,7 +1170,7 @@ public class Airavata {
* @param gatewayId
* @param applicationModule
*/
- public String registerApplicationModule(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId, org.apache.airavata.model.appcatalog.appdeployment.ApplicationModule applicationModule) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.lang.String registerApplicationModule(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId, org.apache.airavata.model.appcatalog.appdeployment.ApplicationModule applicationModule) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1213,7 +1186,7 @@ public class Airavata {
* @param authzToken
* @param appModuleId
*/
- public org.apache.airavata.model.appcatalog.appdeployment.ApplicationModule getApplicationModule(org.apache.airavata.model.security.AuthzToken authzToken, String appModuleId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public org.apache.airavata.model.appcatalog.appdeployment.ApplicationModule getApplicationModule(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String appModuleId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1233,7 +1206,7 @@ public class Airavata {
* @param appModuleId
* @param applicationModule
*/
- public boolean updateApplicationModule(org.apache.airavata.model.security.AuthzToken authzToken, String appModuleId, org.apache.airavata.model.appcatalog.appdeployment.ApplicationModule applicationModule) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean updateApplicationModule(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String appModuleId, org.apache.airavata.model.appcatalog.appdeployment.ApplicationModule applicationModule) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1249,7 +1222,7 @@ public class Airavata {
* @param authzToken
* @param gatewayId
*/
- public List<org.apache.airavata.model.appcatalog.appdeployment.ApplicationModule> getAllAppModules(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.List<org.apache.airavata.model.appcatalog.appdeployment.ApplicationModule> getAllAppModules(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1265,7 +1238,7 @@ public class Airavata {
* @param authzToken
* @param appModuleId
*/
- public boolean deleteApplicationModule(org.apache.airavata.model.security.AuthzToken authzToken, String appModuleId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean deleteApplicationModule(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String appModuleId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1285,7 +1258,7 @@ public class Airavata {
* @param gatewayId
* @param applicationDeployment
*/
- public String registerApplicationDeployment(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId, org.apache.airavata.model.appcatalog.appdeployment.ApplicationDeploymentDescription applicationDeployment) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.lang.String registerApplicationDeployment(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId, org.apache.airavata.model.appcatalog.appdeployment.ApplicationDeploymentDescription applicationDeployment) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1301,7 +1274,7 @@ public class Airavata {
* @param authzToken
* @param appDeploymentId
*/
- public org.apache.airavata.model.appcatalog.appdeployment.ApplicationDeploymentDescription getApplicationDeployment(org.apache.airavata.model.security.AuthzToken authzToken, String appDeploymentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public org.apache.airavata.model.appcatalog.appdeployment.ApplicationDeploymentDescription getApplicationDeployment(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String appDeploymentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1321,7 +1294,7 @@ public class Airavata {
* @param appDeploymentId
* @param applicationDeployment
*/
- public boolean updateApplicationDeployment(org.apache.airavata.model.security.AuthzToken authzToken, String appDeploymentId, org.apache.airavata.model.appcatalog.appdeployment.ApplicationDeploymentDescription applicationDeployment) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean updateApplicationDeployment(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String appDeploymentId, org.apache.airavata.model.appcatalog.appdeployment.ApplicationDeploymentDescription applicationDeployment) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1337,7 +1310,7 @@ public class Airavata {
* @param authzToken
* @param appDeploymentId
*/
- public boolean deleteApplicationDeployment(org.apache.airavata.model.security.AuthzToken authzToken, String appDeploymentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean deleteApplicationDeployment(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String appDeploymentId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1353,7 +1326,7 @@ public class Airavata {
* @param authzToken
* @param gatewayId
*/
- public List<org.apache.airavata.model.appcatalog.appdeployment.ApplicationDeploymentDescription> getAllApplicationDeployments(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.List<org.apache.airavata.model.appcatalog.appdeployment.ApplicationDeploymentDescription> getAllApplicationDeployments(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Fetch a list of Deployed Compute Hosts.
@@ -1368,7 +1341,7 @@ public class Airavata {
* @param authzToken
* @param appModuleId
*/
- public List<String> getAppModuleDeployedResources(org.apache.airavata.model.security.AuthzToken authzToken, String appModuleId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.List<java.lang.String> getAppModuleDeployedResources(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String appModuleId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1385,7 +1358,7 @@ public class Airavata {
* @param gatewayId
* @param applicationInterface
*/
- public String registerApplicationInterface(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId, org.apache.airavata.model.appcatalog.appinterface.ApplicationInterfaceDescription applicationInterface) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.lang.String registerApplicationInterface(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId, org.apache.airavata.model.appcatalog.appinterface.ApplicationInterfaceDescription applicationInterface) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1409,7 +1382,7 @@ public class Airavata {
* @param newApplicationName
* @param gatewayId
*/
- public String cloneApplicationInterface(org.apache.airavata.model.security.AuthzToken authzToken, String existingAppInterfaceID, String newApplicationName, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.lang.String cloneApplicationInterface(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String existingAppInterfaceID, java.lang.String newApplicationName, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1425,7 +1398,7 @@ public class Airavata {
* @param authzToken
* @param appInterfaceId
*/
- public org.apache.airavata.model.appcatalog.appinterface.ApplicationInterfaceDescription getApplicationInterface(org.apache.airavata.model.security.AuthzToken authzToken, String appInterfaceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public org.apache.airavata.model.appcatalog.appinterface.ApplicationInterfaceDescription getApplicationInterface(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String appInterfaceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1445,7 +1418,7 @@ public class Airavata {
* @param appInterfaceId
* @param applicationInterface
*/
- public boolean updateApplicationInterface(org.apache.airavata.model.security.AuthzToken authzToken, String appInterfaceId, org.apache.airavata.model.appcatalog.appinterface.ApplicationInterfaceDescription applicationInterface) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean updateApplicationInterface(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String appInterfaceId, org.apache.airavata.model.appcatalog.appinterface.ApplicationInterfaceDescription applicationInterface) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1461,7 +1434,7 @@ public class Airavata {
* @param authzToken
* @param appInterfaceId
*/
- public boolean deleteApplicationInterface(org.apache.airavata.model.security.AuthzToken authzToken, String appInterfaceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean deleteApplicationInterface(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String appInterfaceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1475,7 +1448,7 @@ public class Airavata {
* @param authzToken
* @param gatewayId
*/
- public Map<String,String> getAllApplicationInterfaceNames(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.Map<java.lang.String,java.lang.String> getAllApplicationInterfaceNames(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1489,7 +1462,7 @@ public class Airavata {
* @param authzToken
* @param gatewayId
*/
- public List<org.apache.airavata.model.appcatalog.appinterface.ApplicationInterfaceDescription> getAllApplicationInterfaces(org.apache.airavata.model.security.AuthzToken authzToken, String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.List<org.apache.airavata.model.appcatalog.appinterface.ApplicationInterfaceDescription> getAllApplicationInterfaces(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String gatewayId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1505,7 +1478,7 @@ public class Airavata {
* @param authzToken
* @param appInterfaceId
*/
- public List<org.apache.airavata.model.application.io.InputDataObjectType> getApplicationInputs(org.apache.airavata.model.security.AuthzToken authzToken, String appInterfaceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.List<org.apache.airavata.model.application.io.InputDataObjectType> getApplicationInputs(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String appInterfaceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1521,7 +1494,7 @@ public class Airavata {
* @param authzToken
* @param appInterfaceId
*/
- public List<org.apache.airavata.model.application.io.OutputDataObjectType> getApplicationOutputs(org.apache.airavata.model.security.AuthzToken authzToken, String appInterfaceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType> getApplicationOutputs(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String appInterfaceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1538,7 +1511,7 @@ public class Airavata {
* @param authzToken
* @param appInterfaceId
*/
- public Map<String,String> getAvailableAppInterfaceComputeResources(org.apache.airavata.model.security.AuthzToken authzToken, String appInterfaceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.Map<java.lang.String,java.lang.String> getAvailableAppInterfaceComputeResources(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String appInterfaceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Register a Compute Resource.
@@ -1553,7 +1526,7 @@ public class Airavata {
* @param authzToken
* @param computeResourceDescription
*/
- public String registerComputeResource(org.apache.airavata.model.security.AuthzToken authzToken, org.apache.airavata.model.appcatalog.computeresource.ComputeResourceDescription computeResourceDescription) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.lang.String registerComputeResource(org.apache.airavata.model.security.AuthzToken authzToken, org.apache.airavata.model.appcatalog.computeresource.ComputeResourceDescription computeResourceDescription) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Fetch the given Compute Resource.
@@ -1568,7 +1541,7 @@ public class Airavata {
* @param authzToken
* @param computeResourceId
*/
- public org.apache.airavata.model.appcatalog.computeresource.ComputeResourceDescription getComputeResource(org.apache.airavata.model.security.AuthzToken authzToken, String computeResourceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public org.apache.airavata.model.appcatalog.computeresource.ComputeResourceDescription getComputeResource(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String computeResourceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
*
@@ -1580,7 +1553,7 @@ public class Airavata {
*
* @param authzToken
*/
- public Map<String,String> getAllComputeResourceNames(org.apache.airavata.model.security.AuthzToken authzToken) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.Map<java.lang.String,java.lang.String> getAllComputeResourceNames(org.apache.airavata.model.security.AuthzToken authzToken) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Update a Compute Resource.
@@ -1599,7 +1572,7 @@ public class Airavata {
* @param computeResourceId
* @param computeResourceDescription
*/
- public boolean updateComputeResource(org.apache.airavata.model.security.AuthzToken authzToken, String computeResourceId, org.apache.airavata.model.appcatalog.computeresource.ComputeResourceDescription computeResourceDescription) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean updateComputeResource(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String computeResourceId, org.apache.airavata.model.appcatalog.computeresource.ComputeResourceDescription computeResourceDescription) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Delete a Compute Resource.
@@ -1614,7 +1587,7 @@ public class Airavata {
* @param authzToken
* @param computeResourceId
*/
- public boolean deleteComputeResource(org.apache.airavata.model.security.AuthzToken authzToken, String computeResourceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean deleteComputeResource(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String computeResourceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Register a Storage Resource.
@@ -1629,7 +1602,7 @@ public class Airavata {
* @param authzToken
* @param storageResourceDescription
*/
- public String registerStorageResource(org.apache.airavata.model.security.AuthzToken authzToken, org.apache.airavata.model.appcatalog.storageresource.StorageResourceDescription storageResourceDescription) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.lang.String registerStorageResource(org.apache.airavata.model.security.AuthzToken authzToken, org.apache.airavata.model.appcatalog.storageresource.StorageResourceDescription storageResourceDescription) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Fetch the given Storage Resource.
@@ -1644,7 +1617,7 @@ public class Airavata {
* @param authzToken
* @param storageResourceId
*/
- public org.apache.airavata.model.appcatalog.storageresource.StorageResourceDescription getStorageResource(org.apache.airavata.model.security.AuthzToken authzToken, String storageResourceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public org.apache.airavata.model.appcatalog.storageresource.StorageResourceDescription getStorageResource(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String storageResourceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Fetch all registered Storage Resources.
@@ -1655,7 +1628,7 @@ public class Airavata {
*
* @param authzToken
*/
- public Map<String,String> getAllStorageResourceNames(org.apache.airavata.model.security.AuthzToken authzToken) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.util.Map<java.lang.String,java.lang.String> getAllStorageResourceNames(org.apache.airavata.model.security.AuthzToken authzToken) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Update a Storage Resource.
@@ -1674,7 +1647,7 @@ public class Airavata {
* @param storageResourceId
* @param storageResourceDescription
*/
- public boolean updateStorageResource(org.apache.airavata.model.security.AuthzToken authzToken, String storageResourceId, org.apache.airavata.model.appcatalog.storageresource.StorageResourceDescription storageResourceDescription) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean updateStorageResource(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String storageResourceId, org.apache.airavata.model.appcatalog.storageresource.StorageResourceDescription storageResourceDescription) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Delete a Storage Resource.
@@ -1689,7 +1662,7 @@ public class Airavata {
* @param authzToken
* @param storageResourceId
*/
- public boolean deleteStorageResource(org.apache.airavata.model.security.AuthzToken authzToken, String storageResourceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean deleteStorageResource(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String storageResourceId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Add a Local Job Submission details to a compute resource
@@ -1713,7 +1686,7 @@ public class Airavata {
* @param priorityOrder
* @param localSubmission
*/
- public String addLocalSubmissionDetails(org.apache.airavata.model.security.AuthzToken authzToken, String computeResourceId, int priorityOrder, org.apache.airavata.model.appcatalog.computeresource.LOCALSubmission localSubmission) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public java.lang.String addLocalSubmissionDetails(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String computeResourceId, int priorityOrder, org.apache.airavata.model.appcatalog.computeresource.LOCALSubmission localSubmission) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* Update the given Local Job Submission details
@@ -1732,7 +1705,7 @@ public class Airavata {
* @param jobSubmissionInterfaceId
* @param localSubmission
*/
- public boolean updateLocalSubmissionDetails(org.apache.airavata.model.security.AuthzToken authzToken, String jobSubmissionInterfaceId, org.apache.airavata.model.appcatalog.computeresource.LOCALSubmission localSubmission) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public boolean updateLocalSubmissionDetails(org.apache.airavata.model.security.AuthzToken authzToken, java.lang.String jobSubmissionInterfaceId, org.apache.airavata.model.appcatalog.computeresource.LOCALSubmission localSubmission) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
/**
* This method returns localJobSubmission object
@@ -1744,7 +1717,7 @@ public class Airavata {
* @param authzToken
* @param jobSubmissionId
*/
- public org.apache.airavata.model.appcatalog.computeresource.LOCALSubmission getLocalJobSubmission(org.apache.airavata.model.security.AuthzToken authzToken, String jobSubmissionId) throws org.apache.airavata.model.error.InvalidRequestException, org.apache.airavata.model.error.AiravataClientException, org.apache.airavata.model.error.AiravataSystemException, org.apache.airavata.model.error.AuthorizationException, org.apache.thrift.TException;
+ public org.apache.airavata.model.appcatalog.computeresource.LOCALSubmission getLocalJob
<TRUNCATED>
[08/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventMessage.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventMessage.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventMessage.java
index 89e06fb..7c06306 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventMessage.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventMessage.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.dbevent;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, DBEventMessage._Fields>, java.io.Serializable, Cloneable, Comparable<DBEventMessage> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("DBEventMessage");
@@ -59,15 +32,12 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
private static final org.apache.thrift.protocol.TField MESSAGE_CONTEXT_FIELD_DESC = new org.apache.thrift.protocol.TField("messageContext", org.apache.thrift.protocol.TType.STRUCT, (short)2);
private static final org.apache.thrift.protocol.TField PUBLISHER_SERVICE_FIELD_DESC = new org.apache.thrift.protocol.TField("publisherService", 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 DBEventMessageStandardSchemeFactory());
- schemes.put(TupleScheme.class, new DBEventMessageTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new DBEventMessageStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new DBEventMessageTupleSchemeFactory();
private DBEventType dbEventType; // required
private DBEventMessageContext messageContext; // required
- private String publisherService; // required
+ private java.lang.String publisherService; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -79,10 +49,10 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
MESSAGE_CONTEXT((short)2, "messageContext"),
PUBLISHER_SERVICE((short)3, "publisherService");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -109,21 +79,21 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -132,22 +102,22 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.DB_EVENT_TYPE, new org.apache.thrift.meta_data.FieldMetaData("dbEventType", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, DBEventType.class)));
tmpMap.put(_Fields.MESSAGE_CONTEXT, new org.apache.thrift.meta_data.FieldMetaData("messageContext", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, DBEventMessageContext.class)));
tmpMap.put(_Fields.PUBLISHER_SERVICE, new org.apache.thrift.meta_data.FieldMetaData("publisherService", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(DBEventMessage.class, metaDataMap);
}
@@ -157,7 +127,7 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
public DBEventMessage(
DBEventType dbEventType,
DBEventMessageContext messageContext,
- String publisherService)
+ java.lang.String publisherService)
{
this();
this.dbEventType = dbEventType;
@@ -245,11 +215,11 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
}
}
- public String getPublisherService() {
+ public java.lang.String getPublisherService() {
return this.publisherService;
}
- public void setPublisherService(String publisherService) {
+ public void setPublisherService(java.lang.String publisherService) {
this.publisherService = publisherService;
}
@@ -268,7 +238,7 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case DB_EVENT_TYPE:
if (value == null) {
@@ -290,14 +260,14 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
if (value == null) {
unsetPublisherService();
} else {
- setPublisherService((String)value);
+ setPublisherService((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case DB_EVENT_TYPE:
return getDbEventType();
@@ -309,13 +279,13 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
return getPublisherService();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -326,11 +296,11 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
case PUBLISHER_SERVICE:
return isSetPublisherService();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof DBEventMessage)
@@ -341,6 +311,8 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
public boolean equals(DBEventMessage that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_dbEventType = true && this.isSetDbEventType();
boolean that_present_dbEventType = true && that.isSetDbEventType();
@@ -374,24 +346,21 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_dbEventType = true && (isSetDbEventType());
- list.add(present_dbEventType);
- if (present_dbEventType)
- list.add(dbEventType.getValue());
+ hashCode = hashCode * 8191 + ((isSetDbEventType()) ? 131071 : 524287);
+ if (isSetDbEventType())
+ hashCode = hashCode * 8191 + dbEventType.getValue();
- boolean present_messageContext = true && (isSetMessageContext());
- list.add(present_messageContext);
- if (present_messageContext)
- list.add(messageContext);
+ hashCode = hashCode * 8191 + ((isSetMessageContext()) ? 131071 : 524287);
+ if (isSetMessageContext())
+ hashCode = hashCode * 8191 + messageContext.hashCode();
- boolean present_publisherService = true && (isSetPublisherService());
- list.add(present_publisherService);
- if (present_publisherService)
- list.add(publisherService);
+ hashCode = hashCode * 8191 + ((isSetPublisherService()) ? 131071 : 524287);
+ if (isSetPublisherService())
+ hashCode = hashCode * 8191 + publisherService.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -402,7 +371,7 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetDbEventType()).compareTo(other.isSetDbEventType());
+ lastComparison = java.lang.Boolean.valueOf(isSetDbEventType()).compareTo(other.isSetDbEventType());
if (lastComparison != 0) {
return lastComparison;
}
@@ -412,7 +381,7 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetMessageContext()).compareTo(other.isSetMessageContext());
+ lastComparison = java.lang.Boolean.valueOf(isSetMessageContext()).compareTo(other.isSetMessageContext());
if (lastComparison != 0) {
return lastComparison;
}
@@ -422,7 +391,7 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPublisherService()).compareTo(other.isSetPublisherService());
+ lastComparison = java.lang.Boolean.valueOf(isSetPublisherService()).compareTo(other.isSetPublisherService());
if (lastComparison != 0) {
return lastComparison;
}
@@ -440,16 +409,16 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("DBEventMessage(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("DBEventMessage(");
boolean first = true;
sb.append("dbEventType:");
@@ -504,7 +473,7 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -512,13 +481,13 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
}
}
- private static class DBEventMessageStandardSchemeFactory implements SchemeFactory {
+ private static class DBEventMessageStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public DBEventMessageStandardScheme getScheme() {
return new DBEventMessageStandardScheme();
}
}
- private static class DBEventMessageStandardScheme extends StandardScheme<DBEventMessage> {
+ private static class DBEventMessageStandardScheme extends org.apache.thrift.scheme.StandardScheme<DBEventMessage> {
public void read(org.apache.thrift.protocol.TProtocol iprot, DBEventMessage struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -589,17 +558,17 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
}
- private static class DBEventMessageTupleSchemeFactory implements SchemeFactory {
+ private static class DBEventMessageTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public DBEventMessageTupleScheme getScheme() {
return new DBEventMessageTupleScheme();
}
}
- private static class DBEventMessageTupleScheme extends TupleScheme<DBEventMessage> {
+ private static class DBEventMessageTupleScheme extends org.apache.thrift.scheme.TupleScheme<DBEventMessage> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, DBEventMessage struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeI32(struct.dbEventType.getValue());
struct.messageContext.write(oprot);
oprot.writeString(struct.publisherService);
@@ -607,7 +576,7 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, DBEventMessage struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.dbEventType = org.apache.airavata.model.dbevent.DBEventType.findByValue(iprot.readI32());
struct.setDbEventTypeIsSet(true);
struct.messageContext = new DBEventMessageContext();
@@ -618,5 +587,8 @@ public class DBEventMessage implements org.apache.thrift.TBase<DBEventMessage, D
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventMessageContext.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventMessageContext.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventMessageContext.java
index b6a6587..5dc839e 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventMessageContext.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventMessageContext.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.dbevent;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
public class DBEventMessageContext extends org.apache.thrift.TUnion<DBEventMessageContext, DBEventMessageContext._Fields> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("DBEventMessageContext");
private static final org.apache.thrift.protocol.TField PUBLISHER_FIELD_DESC = new org.apache.thrift.protocol.TField("publisher", org.apache.thrift.protocol.TType.STRUCT, (short)1);
@@ -61,10 +34,10 @@ public class DBEventMessageContext extends org.apache.thrift.TUnion<DBEventMessa
PUBLISHER((short)1, "publisher"),
SUBSCRIBER((short)2, "subscriber");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -89,21 +62,21 @@ public class DBEventMessageContext extends org.apache.thrift.TUnion<DBEventMessa
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -112,19 +85,19 @@ public class DBEventMessageContext extends org.apache.thrift.TUnion<DBEventMessa
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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.PUBLISHER, new org.apache.thrift.meta_data.FieldMetaData("publisher", org.apache.thrift.TFieldRequirementType.DEFAULT,
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+ tmpMap.put(_Fields.PUBLISHER, new org.apache.thrift.meta_data.FieldMetaData("publisher", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, DBEventPublisher.class)));
- tmpMap.put(_Fields.SUBSCRIBER, new org.apache.thrift.meta_data.FieldMetaData("subscriber", org.apache.thrift.TFieldRequirementType.DEFAULT,
+ tmpMap.put(_Fields.SUBSCRIBER, new org.apache.thrift.meta_data.FieldMetaData("subscriber", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, DBEventSubscriber.class)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(DBEventMessageContext.class, metaDataMap);
}
@@ -132,7 +105,7 @@ public class DBEventMessageContext extends org.apache.thrift.TUnion<DBEventMessa
super();
}
- public DBEventMessageContext(_Fields setField, Object value) {
+ public DBEventMessageContext(_Fields setField, java.lang.Object value) {
super(setField, value);
}
@@ -157,25 +130,25 @@ public class DBEventMessageContext extends org.apache.thrift.TUnion<DBEventMessa
@Override
- protected void checkType(_Fields setField, Object value) throws ClassCastException {
+ protected void checkType(_Fields setField, java.lang.Object value) throws java.lang.ClassCastException {
switch (setField) {
case PUBLISHER:
if (value instanceof DBEventPublisher) {
break;
}
- throw new ClassCastException("Was expecting value of type DBEventPublisher for field 'publisher', but got " + value.getClass().getSimpleName());
+ throw new java.lang.ClassCastException("Was expecting value of type DBEventPublisher for field 'publisher', but got " + value.getClass().getSimpleName());
case SUBSCRIBER:
if (value instanceof DBEventSubscriber) {
break;
}
- throw new ClassCastException("Was expecting value of type DBEventSubscriber for field 'subscriber', but got " + value.getClass().getSimpleName());
+ throw new java.lang.ClassCastException("Was expecting value of type DBEventSubscriber for field 'subscriber', but got " + value.getClass().getSimpleName());
default:
- throw new IllegalArgumentException("Unknown field id " + setField);
+ throw new java.lang.IllegalArgumentException("Unknown field id " + setField);
}
}
@Override
- protected Object standardSchemeReadValue(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TField field) throws org.apache.thrift.TException {
+ protected java.lang.Object standardSchemeReadValue(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TField field) throws org.apache.thrift.TException {
_Fields setField = _Fields.findByThriftId(field.id);
if (setField != null) {
switch (setField) {
@@ -200,7 +173,7 @@ public class DBEventMessageContext extends org.apache.thrift.TUnion<DBEventMessa
return null;
}
default:
- throw new IllegalStateException("setField wasn't null, but didn't match any of the case statements!");
+ throw new java.lang.IllegalStateException("setField wasn't null, but didn't match any of the case statements!");
}
} else {
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
@@ -220,12 +193,12 @@ public class DBEventMessageContext extends org.apache.thrift.TUnion<DBEventMessa
subscriber.write(oprot);
return;
default:
- throw new IllegalStateException("Cannot write union with unknown field " + setField_);
+ throw new java.lang.IllegalStateException("Cannot write union with unknown field " + setField_);
}
}
@Override
- protected Object tupleSchemeReadValue(org.apache.thrift.protocol.TProtocol iprot, short fieldID) throws org.apache.thrift.TException {
+ protected java.lang.Object tupleSchemeReadValue(org.apache.thrift.protocol.TProtocol iprot, short fieldID) throws org.apache.thrift.TException {
_Fields setField = _Fields.findByThriftId(fieldID);
if (setField != null) {
switch (setField) {
@@ -240,10 +213,10 @@ public class DBEventMessageContext extends org.apache.thrift.TUnion<DBEventMessa
subscriber.read(iprot);
return subscriber;
default:
- throw new IllegalStateException("setField wasn't null, but didn't match any of the case statements!");
+ throw new java.lang.IllegalStateException("setField wasn't null, but didn't match any of the case statements!");
}
} else {
- throw new TProtocolException("Couldn't find a field with field id " + fieldID);
+ throw new org.apache.thrift.protocol.TProtocolException("Couldn't find a field with field id " + fieldID);
}
}
@@ -259,7 +232,7 @@ public class DBEventMessageContext extends org.apache.thrift.TUnion<DBEventMessa
subscriber.write(oprot);
return;
default:
- throw new IllegalStateException("Cannot write union with unknown field " + setField_);
+ throw new java.lang.IllegalStateException("Cannot write union with unknown field " + setField_);
}
}
@@ -271,7 +244,7 @@ public class DBEventMessageContext extends org.apache.thrift.TUnion<DBEventMessa
case SUBSCRIBER:
return SUBSCRIBER_FIELD_DESC;
default:
- throw new IllegalArgumentException("Unknown field id " + setField);
+ throw new java.lang.IllegalArgumentException("Unknown field id " + setField);
}
}
@@ -294,12 +267,12 @@ public class DBEventMessageContext extends org.apache.thrift.TUnion<DBEventMessa
if (getSetField() == _Fields.PUBLISHER) {
return (DBEventPublisher)getFieldValue();
} else {
- throw new RuntimeException("Cannot get field 'publisher' because union is currently set to " + getFieldDesc(getSetField()).name);
+ throw new java.lang.RuntimeException("Cannot get field 'publisher' because union is currently set to " + getFieldDesc(getSetField()).name);
}
}
public void setPublisher(DBEventPublisher value) {
- if (value == null) throw new NullPointerException();
+ if (value == null) throw new java.lang.NullPointerException();
setField_ = _Fields.PUBLISHER;
value_ = value;
}
@@ -308,12 +281,12 @@ public class DBEventMessageContext extends org.apache.thrift.TUnion<DBEventMessa
if (getSetField() == _Fields.SUBSCRIBER) {
return (DBEventSubscriber)getFieldValue();
} else {
- throw new RuntimeException("Cannot get field 'subscriber' because union is currently set to " + getFieldDesc(getSetField()).name);
+ throw new java.lang.RuntimeException("Cannot get field 'subscriber' because union is currently set to " + getFieldDesc(getSetField()).name);
}
}
public void setSubscriber(DBEventSubscriber value) {
- if (value == null) throw new NullPointerException();
+ if (value == null) throw new java.lang.NullPointerException();
setField_ = _Fields.SUBSCRIBER;
value_ = value;
}
@@ -328,7 +301,7 @@ public class DBEventMessageContext extends org.apache.thrift.TUnion<DBEventMessa
}
- public boolean equals(Object other) {
+ public boolean equals(java.lang.Object other) {
if (other instanceof DBEventMessageContext) {
return equals((DBEventMessageContext)other);
} else {
@@ -352,12 +325,12 @@ public class DBEventMessageContext extends org.apache.thrift.TUnion<DBEventMessa
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ java.util.List<java.lang.Object> list = new java.util.ArrayList<java.lang.Object>();
list.add(this.getClass().getName());
org.apache.thrift.TFieldIdEnum setField = getSetField();
if (setField != null) {
list.add(setField.getThriftFieldId());
- Object value = getFieldValue();
+ java.lang.Object value = getFieldValue();
if (value instanceof org.apache.thrift.TEnum) {
list.add(((org.apache.thrift.TEnum)getFieldValue()).getValue());
} else {
@@ -375,7 +348,7 @@ public class DBEventMessageContext extends org.apache.thrift.TUnion<DBEventMessa
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventPublisher.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventPublisher.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventPublisher.java
index 4c776d2..f9bfb22 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventPublisher.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventPublisher.java
@@ -16,52 +16,22 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.dbevent;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class DBEventPublisher implements org.apache.thrift.TBase<DBEventPublisher, DBEventPublisher._Fields>, java.io.Serializable, Cloneable, Comparable<DBEventPublisher> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("DBEventPublisher");
private static final org.apache.thrift.protocol.TField PUBLISHER_CONTEXT_FIELD_DESC = new org.apache.thrift.protocol.TField("publisherContext", 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 DBEventPublisherStandardSchemeFactory());
- schemes.put(TupleScheme.class, new DBEventPublisherTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new DBEventPublisherStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new DBEventPublisherTupleSchemeFactory();
private DBEventPublisherContext publisherContext; // required
@@ -69,10 +39,10 @@ public class DBEventPublisher implements org.apache.thrift.TBase<DBEventPublishe
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
PUBLISHER_CONTEXT((short)1, "publisherContext");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -95,21 +65,21 @@ public class DBEventPublisher implements org.apache.thrift.TBase<DBEventPublishe
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -118,18 +88,18 @@ public class DBEventPublisher implements org.apache.thrift.TBase<DBEventPublishe
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.PUBLISHER_CONTEXT, new org.apache.thrift.meta_data.FieldMetaData("publisherContext", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, DBEventPublisherContext.class)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(DBEventPublisher.class, metaDataMap);
}
@@ -184,7 +154,7 @@ public class DBEventPublisher implements org.apache.thrift.TBase<DBEventPublishe
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case PUBLISHER_CONTEXT:
if (value == null) {
@@ -197,30 +167,30 @@ public class DBEventPublisher implements org.apache.thrift.TBase<DBEventPublishe
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case PUBLISHER_CONTEXT:
return getPublisherContext();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
case PUBLISHER_CONTEXT:
return isSetPublisherContext();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof DBEventPublisher)
@@ -231,6 +201,8 @@ public class DBEventPublisher implements org.apache.thrift.TBase<DBEventPublishe
public boolean equals(DBEventPublisher that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_publisherContext = true && this.isSetPublisherContext();
boolean that_present_publisherContext = true && that.isSetPublisherContext();
@@ -246,14 +218,13 @@ public class DBEventPublisher implements org.apache.thrift.TBase<DBEventPublishe
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_publisherContext = true && (isSetPublisherContext());
- list.add(present_publisherContext);
- if (present_publisherContext)
- list.add(publisherContext);
+ hashCode = hashCode * 8191 + ((isSetPublisherContext()) ? 131071 : 524287);
+ if (isSetPublisherContext())
+ hashCode = hashCode * 8191 + publisherContext.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -264,7 +235,7 @@ public class DBEventPublisher implements org.apache.thrift.TBase<DBEventPublishe
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetPublisherContext()).compareTo(other.isSetPublisherContext());
+ lastComparison = java.lang.Boolean.valueOf(isSetPublisherContext()).compareTo(other.isSetPublisherContext());
if (lastComparison != 0) {
return lastComparison;
}
@@ -282,16 +253,16 @@ public class DBEventPublisher implements org.apache.thrift.TBase<DBEventPublishe
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("DBEventPublisher(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("DBEventPublisher(");
boolean first = true;
sb.append("publisherContext:");
@@ -325,7 +296,7 @@ public class DBEventPublisher implements org.apache.thrift.TBase<DBEventPublishe
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -333,13 +304,13 @@ public class DBEventPublisher implements org.apache.thrift.TBase<DBEventPublishe
}
}
- private static class DBEventPublisherStandardSchemeFactory implements SchemeFactory {
+ private static class DBEventPublisherStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public DBEventPublisherStandardScheme getScheme() {
return new DBEventPublisherStandardScheme();
}
}
- private static class DBEventPublisherStandardScheme extends StandardScheme<DBEventPublisher> {
+ private static class DBEventPublisherStandardScheme extends org.apache.thrift.scheme.StandardScheme<DBEventPublisher> {
public void read(org.apache.thrift.protocol.TProtocol iprot, DBEventPublisher struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -384,28 +355,31 @@ public class DBEventPublisher implements org.apache.thrift.TBase<DBEventPublishe
}
- private static class DBEventPublisherTupleSchemeFactory implements SchemeFactory {
+ private static class DBEventPublisherTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public DBEventPublisherTupleScheme getScheme() {
return new DBEventPublisherTupleScheme();
}
}
- private static class DBEventPublisherTupleScheme extends TupleScheme<DBEventPublisher> {
+ private static class DBEventPublisherTupleScheme extends org.apache.thrift.scheme.TupleScheme<DBEventPublisher> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, DBEventPublisher struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.publisherContext.write(oprot);
}
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, DBEventPublisher struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.publisherContext = new DBEventPublisherContext();
struct.publisherContext.read(iprot);
struct.setPublisherContextIsSet(true);
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventPublisherContext.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventPublisherContext.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventPublisherContext.java
index a95a806..2e885e7 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventPublisherContext.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventPublisherContext.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.dbevent;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventPublisherContext, DBEventPublisherContext._Fields>, java.io.Serializable, Cloneable, Comparable<DBEventPublisherContext> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("DBEventPublisherContext");
@@ -59,15 +32,12 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
private static final org.apache.thrift.protocol.TField ENTITY_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("entityType", org.apache.thrift.protocol.TType.I32, (short)2);
private static final org.apache.thrift.protocol.TField ENTITY_DATA_MODEL_FIELD_DESC = new org.apache.thrift.protocol.TField("entityDataModel", 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 DBEventPublisherContextStandardSchemeFactory());
- schemes.put(TupleScheme.class, new DBEventPublisherContextTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new DBEventPublisherContextStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new DBEventPublisherContextTupleSchemeFactory();
private CrudType crudType; // required
private EntityType entityType; // required
- private ByteBuffer entityDataModel; // required
+ private java.nio.ByteBuffer entityDataModel; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -83,10 +53,10 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
ENTITY_TYPE((short)2, "entityType"),
ENTITY_DATA_MODEL((short)3, "entityDataModel");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -113,21 +83,21 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -136,22 +106,22 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.CRUD_TYPE, new org.apache.thrift.meta_data.FieldMetaData("crudType", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, CrudType.class)));
tmpMap.put(_Fields.ENTITY_TYPE, new org.apache.thrift.meta_data.FieldMetaData("entityType", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, EntityType.class)));
tmpMap.put(_Fields.ENTITY_DATA_MODEL, new org.apache.thrift.meta_data.FieldMetaData("entityDataModel", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING , true)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(DBEventPublisherContext.class, metaDataMap);
}
@@ -161,7 +131,7 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
public DBEventPublisherContext(
CrudType crudType,
EntityType entityType,
- ByteBuffer entityDataModel)
+ java.nio.ByteBuffer entityDataModel)
{
this();
this.crudType = crudType;
@@ -262,15 +232,15 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
return entityDataModel == null ? null : entityDataModel.array();
}
- public ByteBuffer bufferForEntityDataModel() {
+ public java.nio.ByteBuffer bufferForEntityDataModel() {
return org.apache.thrift.TBaseHelper.copyBinary(entityDataModel);
}
public void setEntityDataModel(byte[] entityDataModel) {
- this.entityDataModel = entityDataModel == null ? (ByteBuffer)null : ByteBuffer.wrap(Arrays.copyOf(entityDataModel, entityDataModel.length));
+ this.entityDataModel = entityDataModel == null ? (java.nio.ByteBuffer)null : java.nio.ByteBuffer.wrap(entityDataModel.clone());
}
- public void setEntityDataModel(ByteBuffer entityDataModel) {
+ public void setEntityDataModel(java.nio.ByteBuffer entityDataModel) {
this.entityDataModel = org.apache.thrift.TBaseHelper.copyBinary(entityDataModel);
}
@@ -289,7 +259,7 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case CRUD_TYPE:
if (value == null) {
@@ -311,14 +281,18 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
if (value == null) {
unsetEntityDataModel();
} else {
- setEntityDataModel((ByteBuffer)value);
+ if (value instanceof byte[]) {
+ setEntityDataModel((byte[])value);
+ } else {
+ setEntityDataModel((java.nio.ByteBuffer)value);
+ }
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case CRUD_TYPE:
return getCrudType();
@@ -330,13 +304,13 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
return getEntityDataModel();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -347,11 +321,11 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
case ENTITY_DATA_MODEL:
return isSetEntityDataModel();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof DBEventPublisherContext)
@@ -362,6 +336,8 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
public boolean equals(DBEventPublisherContext that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_crudType = true && this.isSetCrudType();
boolean that_present_crudType = true && that.isSetCrudType();
@@ -395,24 +371,21 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_crudType = true && (isSetCrudType());
- list.add(present_crudType);
- if (present_crudType)
- list.add(crudType.getValue());
+ hashCode = hashCode * 8191 + ((isSetCrudType()) ? 131071 : 524287);
+ if (isSetCrudType())
+ hashCode = hashCode * 8191 + crudType.getValue();
- boolean present_entityType = true && (isSetEntityType());
- list.add(present_entityType);
- if (present_entityType)
- list.add(entityType.getValue());
+ hashCode = hashCode * 8191 + ((isSetEntityType()) ? 131071 : 524287);
+ if (isSetEntityType())
+ hashCode = hashCode * 8191 + entityType.getValue();
- boolean present_entityDataModel = true && (isSetEntityDataModel());
- list.add(present_entityDataModel);
- if (present_entityDataModel)
- list.add(entityDataModel);
+ hashCode = hashCode * 8191 + ((isSetEntityDataModel()) ? 131071 : 524287);
+ if (isSetEntityDataModel())
+ hashCode = hashCode * 8191 + entityDataModel.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -423,7 +396,7 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetCrudType()).compareTo(other.isSetCrudType());
+ lastComparison = java.lang.Boolean.valueOf(isSetCrudType()).compareTo(other.isSetCrudType());
if (lastComparison != 0) {
return lastComparison;
}
@@ -433,7 +406,7 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetEntityType()).compareTo(other.isSetEntityType());
+ lastComparison = java.lang.Boolean.valueOf(isSetEntityType()).compareTo(other.isSetEntityType());
if (lastComparison != 0) {
return lastComparison;
}
@@ -443,7 +416,7 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetEntityDataModel()).compareTo(other.isSetEntityDataModel());
+ lastComparison = java.lang.Boolean.valueOf(isSetEntityDataModel()).compareTo(other.isSetEntityDataModel());
if (lastComparison != 0) {
return lastComparison;
}
@@ -461,16 +434,16 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("DBEventPublisherContext(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("DBEventPublisherContext(");
boolean first = true;
sb.append("crudType:");
@@ -525,7 +498,7 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -533,13 +506,13 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
}
}
- private static class DBEventPublisherContextStandardSchemeFactory implements SchemeFactory {
+ private static class DBEventPublisherContextStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public DBEventPublisherContextStandardScheme getScheme() {
return new DBEventPublisherContextStandardScheme();
}
}
- private static class DBEventPublisherContextStandardScheme extends StandardScheme<DBEventPublisherContext> {
+ private static class DBEventPublisherContextStandardScheme extends org.apache.thrift.scheme.StandardScheme<DBEventPublisherContext> {
public void read(org.apache.thrift.protocol.TProtocol iprot, DBEventPublisherContext struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -609,17 +582,17 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
}
- private static class DBEventPublisherContextTupleSchemeFactory implements SchemeFactory {
+ private static class DBEventPublisherContextTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public DBEventPublisherContextTupleScheme getScheme() {
return new DBEventPublisherContextTupleScheme();
}
}
- private static class DBEventPublisherContextTupleScheme extends TupleScheme<DBEventPublisherContext> {
+ private static class DBEventPublisherContextTupleScheme extends org.apache.thrift.scheme.TupleScheme<DBEventPublisherContext> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, DBEventPublisherContext struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeI32(struct.crudType.getValue());
oprot.writeI32(struct.entityType.getValue());
oprot.writeBinary(struct.entityDataModel);
@@ -627,7 +600,7 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, DBEventPublisherContext struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.crudType = org.apache.airavata.model.dbevent.CrudType.findByValue(iprot.readI32());
struct.setCrudTypeIsSet(true);
struct.entityType = org.apache.airavata.model.dbevent.EntityType.findByValue(iprot.readI32());
@@ -637,5 +610,8 @@ public class DBEventPublisherContext implements org.apache.thrift.TBase<DBEventP
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventSubscriber.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventSubscriber.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventSubscriber.java
index 5e3a3d7..366f196 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventSubscriber.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventSubscriber.java
@@ -16,63 +16,33 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.dbevent;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class DBEventSubscriber implements org.apache.thrift.TBase<DBEventSubscriber, DBEventSubscriber._Fields>, java.io.Serializable, Cloneable, Comparable<DBEventSubscriber> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("DBEventSubscriber");
private static final org.apache.thrift.protocol.TField SUBSCRIBER_SERVICE_FIELD_DESC = new org.apache.thrift.protocol.TField("subscriberService", 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 DBEventSubscriberStandardSchemeFactory());
- schemes.put(TupleScheme.class, new DBEventSubscriberTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new DBEventSubscriberStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new DBEventSubscriberTupleSchemeFactory();
- private String subscriberService; // required
+ private java.lang.String subscriberService; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
SUBSCRIBER_SERVICE((short)1, "subscriberService");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -95,21 +65,21 @@ public class DBEventSubscriber implements org.apache.thrift.TBase<DBEventSubscri
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -118,18 +88,18 @@ public class DBEventSubscriber implements org.apache.thrift.TBase<DBEventSubscri
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.SUBSCRIBER_SERVICE, new org.apache.thrift.meta_data.FieldMetaData("subscriberService", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(DBEventSubscriber.class, metaDataMap);
}
@@ -137,7 +107,7 @@ public class DBEventSubscriber implements org.apache.thrift.TBase<DBEventSubscri
}
public DBEventSubscriber(
- String subscriberService)
+ java.lang.String subscriberService)
{
this();
this.subscriberService = subscriberService;
@@ -161,11 +131,11 @@ public class DBEventSubscriber implements org.apache.thrift.TBase<DBEventSubscri
this.subscriberService = null;
}
- public String getSubscriberService() {
+ public java.lang.String getSubscriberService() {
return this.subscriberService;
}
- public void setSubscriberService(String subscriberService) {
+ public void setSubscriberService(java.lang.String subscriberService) {
this.subscriberService = subscriberService;
}
@@ -184,43 +154,43 @@ public class DBEventSubscriber implements org.apache.thrift.TBase<DBEventSubscri
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case SUBSCRIBER_SERVICE:
if (value == null) {
unsetSubscriberService();
} else {
- setSubscriberService((String)value);
+ setSubscriberService((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case SUBSCRIBER_SERVICE:
return getSubscriberService();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
case SUBSCRIBER_SERVICE:
return isSetSubscriberService();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof DBEventSubscriber)
@@ -231,6 +201,8 @@ public class DBEventSubscriber implements org.apache.thrift.TBase<DBEventSubscri
public boolean equals(DBEventSubscriber that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_subscriberService = true && this.isSetSubscriberService();
boolean that_present_subscriberService = true && that.isSetSubscriberService();
@@ -246,14 +218,13 @@ public class DBEventSubscriber implements org.apache.thrift.TBase<DBEventSubscri
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_subscriberService = true && (isSetSubscriberService());
- list.add(present_subscriberService);
- if (present_subscriberService)
- list.add(subscriberService);
+ hashCode = hashCode * 8191 + ((isSetSubscriberService()) ? 131071 : 524287);
+ if (isSetSubscriberService())
+ hashCode = hashCode * 8191 + subscriberService.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -264,7 +235,7 @@ public class DBEventSubscriber implements org.apache.thrift.TBase<DBEventSubscri
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetSubscriberService()).compareTo(other.isSetSubscriberService());
+ lastComparison = java.lang.Boolean.valueOf(isSetSubscriberService()).compareTo(other.isSetSubscriberService());
if (lastComparison != 0) {
return lastComparison;
}
@@ -282,16 +253,16 @@ public class DBEventSubscriber implements org.apache.thrift.TBase<DBEventSubscri
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("DBEventSubscriber(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("DBEventSubscriber(");
boolean first = true;
sb.append("subscriberService:");
@@ -322,7 +293,7 @@ public class DBEventSubscriber implements org.apache.thrift.TBase<DBEventSubscri
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -330,13 +301,13 @@ public class DBEventSubscriber implements org.apache.thrift.TBase<DBEventSubscri
}
}
- private static class DBEventSubscriberStandardSchemeFactory implements SchemeFactory {
+ private static class DBEventSubscriberStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public DBEventSubscriberStandardScheme getScheme() {
return new DBEventSubscriberStandardScheme();
}
}
- private static class DBEventSubscriberStandardScheme extends StandardScheme<DBEventSubscriber> {
+ private static class DBEventSubscriberStandardScheme extends org.apache.thrift.scheme.StandardScheme<DBEventSubscriber> {
public void read(org.apache.thrift.protocol.TProtocol iprot, DBEventSubscriber struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -380,27 +351,30 @@ public class DBEventSubscriber implements org.apache.thrift.TBase<DBEventSubscri
}
- private static class DBEventSubscriberTupleSchemeFactory implements SchemeFactory {
+ private static class DBEventSubscriberTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public DBEventSubscriberTupleScheme getScheme() {
return new DBEventSubscriberTupleScheme();
}
}
- private static class DBEventSubscriberTupleScheme extends TupleScheme<DBEventSubscriber> {
+ private static class DBEventSubscriberTupleScheme extends org.apache.thrift.scheme.TupleScheme<DBEventSubscriber> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, DBEventSubscriber struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.subscriberService);
}
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, DBEventSubscriber struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.subscriberService = iprot.readString();
struct.setSubscriberServiceIsSet(true);
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventType.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventType.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventType.java
index 79a1cf3..756d9f2 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventType.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/DBEventType.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/EntityType.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/EntityType.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/EntityType.java
index 479937f..4832e16 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/EntityType.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/EntityType.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
[44/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/SharingRegistryService.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/SharingRegistryService.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/SharingRegistryService.py
index e0dc634..5276063 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/SharingRegistryService.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/SharingRegistryService.py
@@ -1,12043 +1,11422 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import logging
-from ttypes import *
+from .ttypes import *
from thrift.Thrift import TProcessor
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-class Iface:
- def createDomain(self, domain):
- """
- <p>API method to create a new domain</p>
+class Iface(object):
+ def createDomain(self, domain):
+ """
+ <p>API method to create a new domain</p>
+
+ Parameters:
+ - domain
+ """
+ pass
+
+ def updateDomain(self, domain):
+ """
+ <p>API method to update a domain</p>
+
+ Parameters:
+ - domain
+ """
+ pass
+
+ def isDomainExists(self, domainId):
+ """
+ <p>API method to check Domain Exists</p>
+
+ Parameters:
+ - domainId
+ """
+ pass
+
+ def deleteDomain(self, domainId):
+ """
+ <p>API method to delete domain</p>
+
+ Parameters:
+ - domainId
+ """
+ pass
+
+ def getDomain(self, domainId):
+ """
+ <p>API method to retrieve a domain</p>
+
+ Parameters:
+ - domainId
+ """
+ pass
+
+ def getDomains(self, offset, limit):
+ """
+ <p>API method to get all domain.</p>
+
+ Parameters:
+ - offset
+ - limit
+ """
+ pass
+
+ def createUser(self, user):
+ """
+ <p>API method to register a user in the system</p>
+
+ Parameters:
+ - user
+ """
+ pass
+
+ def updatedUser(self, user):
+ """
+ <p>API method to update existing user</p>
+
+ Parameters:
+ - user
+ """
+ pass
+
+ def isUserExists(self, domainId, userId):
+ """
+ <p>API method to check User Exists</p>
+
+ Parameters:
+ - domainId
+ - userId
+ """
+ pass
+
+ def deleteUser(self, domainId, userId):
+ """
+ <p>API method to delete user</p>
+
+ Parameters:
+ - domainId
+ - userId
+ """
+ pass
+
+ def getUser(self, domainId, userId):
+ """
+ <p>API method to get a user</p>
+
+ Parameters:
+ - domainId
+ - userId
+ """
+ pass
+
+ def getUsers(self, domainId, offset, limit):
+ """
+ <p>API method to get a list of users in a specific domain.</p>
+ <li>domainId : Domain id</li>
+ <li>offset : Starting result number</li>
+ <li>limit : Number of max results to be sent</li>
+
+ Parameters:
+ - domainId
+ - offset
+ - limit
+ """
+ pass
+
+ def createGroup(self, group):
+ """
+ <p>API method to create a new group</p>
+
+ Parameters:
+ - group
+ """
+ pass
+
+ def updateGroup(self, group):
+ """
+ <p>API method to update a group</p>
+
+ Parameters:
+ - group
+ """
+ pass
+
+ def isGroupExists(self, domainId, groupId):
+ """
+ <p>API method to check Group Exists</p>
+
+ Parameters:
+ - domainId
+ - groupId
+ """
+ pass
+
+ def deleteGroup(self, domainId, groupId):
+ """
+ <p>API method to delete a group</p>
+
+ Parameters:
+ - domainId
+ - groupId
+ """
+ pass
+
+ def getGroup(self, domainId, groupId):
+ """
+ <p>API method to get a group</p>
+
+ Parameters:
+ - domainId
+ - groupId
+ """
+ pass
+
+ def getGroups(self, domainId, offset, limit):
+ """
+ <p>API method to get groups in a domainId.</p>
+
+ Parameters:
+ - domainId
+ - offset
+ - limit
+ """
+ pass
+
+ def addUsersToGroup(self, domainId, userIds, groupId):
+ """
+ <p>API method to add list of users to a group</p>
+
+ Parameters:
+ - domainId
+ - userIds
+ - groupId
+ """
+ pass
+
+ def removeUsersFromGroup(self, domainId, userIds, groupId):
+ """
+ <p>API method to remove users from a group</p>
+
+ Parameters:
+ - domainId
+ - userIds
+ - groupId
+ """
+ pass
+
+ def getGroupMembersOfTypeUser(self, domainId, groupId, offset, limit):
+ """
+ <p>API method to get list of child users in a group. Only the direct members will be returned.</p>
+
+ Parameters:
+ - domainId
+ - groupId
+ - offset
+ - limit
+ """
+ pass
+
+ def getGroupMembersOfTypeGroup(self, domainId, groupId, offset, limit):
+ """
+ <p>API method to get list of child groups in a group. Only the direct members will be returned.</p>
+
+ Parameters:
+ - domainId
+ - groupId
+ - offset
+ - limit
+ """
+ pass
+
+ def addChildGroupsToParentGroup(self, domainId, childIds, groupId):
+ """
+ <p>API method to add a child group to a parent group.</p>
+
+ Parameters:
+ - domainId
+ - childIds
+ - groupId
+ """
+ pass
+
+ def removeChildGroupFromParentGroup(self, domainId, childId, groupId):
+ """
+ <p>API method to remove a child group from parent group.</p>
+
+ Parameters:
+ - domainId
+ - childId
+ - groupId
+ """
+ pass
+
+ def getAllMemberGroupsForUser(self, domainId, userId):
+ """
+ Parameters:
+ - domainId
+ - userId
+ """
+ pass
+
+ def createEntityType(self, entityType):
+ """
+ <p>API method to create a new entity type</p>
+
+ Parameters:
+ - entityType
+ """
+ pass
+
+ def updateEntityType(self, entityType):
+ """
+ <p>API method to update entity type</p>
+
+ Parameters:
+ - entityType
+ """
+ pass
+
+ def isEntityTypeExists(self, domainId, entityTypeId):
+ """
+ <p>API method to check EntityType Exists</p>
+
+ Parameters:
+ - domainId
+ - entityTypeId
+ """
+ pass
+
+ def deleteEntityType(self, domainId, entityTypeId):
+ """
+ <p>API method to delete entity type</p>
+
+ Parameters:
+ - domainId
+ - entityTypeId
+ """
+ pass
+
+ def getEntityType(self, domainId, entityTypeId):
+ """
+ <p>API method to get an entity type</p>
+
+ Parameters:
+ - domainId
+ - entityTypeId
+ """
+ pass
+
+ def getEntityTypes(self, domainId, offset, limit):
+ """
+ <p>API method to get entity types in a domainId.</p>
+
+ Parameters:
+ - domainId
+ - offset
+ - limit
+ """
+ pass
+
+ def createEntity(self, entity):
+ """
+ <p>API method to register new entity</p>
+
+ Parameters:
+ - entity
+ """
+ pass
+
+ def updateEntity(self, entity):
+ """
+ <p>API method to update entity</p>
+
+ Parameters:
+ - entity
+ """
+ pass
+
+ def isEntityExists(self, domainId, entityId):
+ """
+ <p>API method to check Entity Exists</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ """
+ pass
+
+ def deleteEntity(self, domainId, entityId):
+ """
+ <p>API method to delete entity</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ """
+ pass
+
+ def getEntity(self, domainId, entityId):
+ """
+ <p>API method to get entity</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ """
+ pass
+
+ def searchEntities(self, domainId, userId, filters, offset, limit):
+ """
+ <p>API method to search entities</p>
+
+ Parameters:
+ - domainId
+ - userId
+ - filters
+ - offset
+ - limit
+ """
+ pass
+
+ def getListOfSharedUsers(self, domainId, entityId, permissionTypeId):
+ """
+ <p>API method to get a list of shared users given the entity id</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ - permissionTypeId
+ """
+ pass
+
+ def getListOfSharedGroups(self, domainId, entityId, permissionTypeId):
+ """
+ <p>API method to get a list of shared groups given the entity id</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ - permissionTypeId
+ """
+ pass
+
+ def createPermissionType(self, permissionType):
+ """
+ <p>API method to create permission type</p>
+
+ Parameters:
+ - permissionType
+ """
+ pass
+
+ def updatePermissionType(self, permissionType):
+ """
+ <p>API method to update permission type</p>
+
+ Parameters:
+ - permissionType
+ """
+ pass
+
+ def isPermissionExists(self, dimainId, permissionId):
+ """
+ <p>API method to check Permission Exists</p>
+
+ Parameters:
+ - dimainId
+ - permissionId
+ """
+ pass
+
+ def deletePermissionType(self, domainId, permissionTypeId):
+ """
+ <p>API method to delete permission type</p>
+
+ Parameters:
+ - domainId
+ - permissionTypeId
+ """
+ pass
+
+ def getPermissionType(self, domainId, permissionTypeId):
+ """
+ <p>API method to get permission type</p>
+
+ Parameters:
+ - domainId
+ - permissionTypeId
+ """
+ pass
+
+ def getPermissionTypes(self, domainId, offset, limit):
+ """
+ <p>API method to get list of permission types in a given domainId.</p>
+
+ Parameters:
+ - domainId
+ - offset
+ - limit
+ """
+ pass
+
+ def shareEntityWithUsers(self, domainId, entityId, userList, perssionTypeId, cascadePermission):
+ """
+ <p>API method to share an entity with users</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ - userList
+ - perssionTypeId
+ - cascadePermission
+ """
+ pass
+
+ def revokeEntitySharingFromUsers(self, domainId, entityId, userList, perssionTypeId):
+ """
+ <p>API method to revoke sharing from a list of users</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ - userList
+ - perssionTypeId
+ """
+ pass
+
+ def shareEntityWithGroups(self, domainId, entityId, groupList, perssionTypeId, cascadePermission):
+ """
+ <p>API method to share an entity with list of groups</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ - groupList
+ - perssionTypeId
+ - cascadePermission
+ """
+ pass
+
+ def revokeEntitySharingFromGroups(self, domainId, entityId, groupList, perssionTypeId):
+ """
+ <p>API method to revoke sharing from list of users</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ - groupList
+ - perssionTypeId
+ """
+ pass
+
+ def userHasAccess(self, domainId, userId, entityId, permissionTypeId):
+ """
+ <p>API method to check whether a user has access to a specific entity</p>
+
+ Parameters:
+ - domainId
+ - userId
+ - entityId
+ - permissionTypeId
+ """
+ pass
- Parameters:
- - domain
- """
- pass
- def updateDomain(self, domain):
- """
- <p>API method to update a domain</p>
+class Client(Iface):
+ def __init__(self, iprot, oprot=None):
+ self._iprot = self._oprot = iprot
+ if oprot is not None:
+ self._oprot = oprot
+ self._seqid = 0
+
+ def createDomain(self, domain):
+ """
+ <p>API method to create a new domain</p>
+
+ Parameters:
+ - domain
+ """
+ self.send_createDomain(domain)
+ return self.recv_createDomain()
+
+ def send_createDomain(self, domain):
+ self._oprot.writeMessageBegin('createDomain', TMessageType.CALL, self._seqid)
+ args = createDomain_args()
+ args.domain = domain
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_createDomain(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = createDomain_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ if result.dee is not None:
+ raise result.dee
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "createDomain failed: unknown result")
+
+ def updateDomain(self, domain):
+ """
+ <p>API method to update a domain</p>
+
+ Parameters:
+ - domain
+ """
+ self.send_updateDomain(domain)
+ return self.recv_updateDomain()
+
+ def send_updateDomain(self, domain):
+ self._oprot.writeMessageBegin('updateDomain', TMessageType.CALL, self._seqid)
+ args = updateDomain_args()
+ args.domain = domain
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_updateDomain(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = updateDomain_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "updateDomain failed: unknown result")
+
+ def isDomainExists(self, domainId):
+ """
+ <p>API method to check Domain Exists</p>
+
+ Parameters:
+ - domainId
+ """
+ self.send_isDomainExists(domainId)
+ return self.recv_isDomainExists()
+
+ def send_isDomainExists(self, domainId):
+ self._oprot.writeMessageBegin('isDomainExists', TMessageType.CALL, self._seqid)
+ args = isDomainExists_args()
+ args.domainId = domainId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_isDomainExists(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = isDomainExists_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "isDomainExists failed: unknown result")
+
+ def deleteDomain(self, domainId):
+ """
+ <p>API method to delete domain</p>
+
+ Parameters:
+ - domainId
+ """
+ self.send_deleteDomain(domainId)
+ return self.recv_deleteDomain()
+
+ def send_deleteDomain(self, domainId):
+ self._oprot.writeMessageBegin('deleteDomain', TMessageType.CALL, self._seqid)
+ args = deleteDomain_args()
+ args.domainId = domainId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_deleteDomain(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = deleteDomain_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "deleteDomain failed: unknown result")
+
+ def getDomain(self, domainId):
+ """
+ <p>API method to retrieve a domain</p>
+
+ Parameters:
+ - domainId
+ """
+ self.send_getDomain(domainId)
+ return self.recv_getDomain()
+
+ def send_getDomain(self, domainId):
+ self._oprot.writeMessageBegin('getDomain', TMessageType.CALL, self._seqid)
+ args = getDomain_args()
+ args.domainId = domainId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_getDomain(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = getDomain_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "getDomain failed: unknown result")
+
+ def getDomains(self, offset, limit):
+ """
+ <p>API method to get all domain.</p>
+
+ Parameters:
+ - offset
+ - limit
+ """
+ self.send_getDomains(offset, limit)
+ return self.recv_getDomains()
+
+ def send_getDomains(self, offset, limit):
+ self._oprot.writeMessageBegin('getDomains', TMessageType.CALL, self._seqid)
+ args = getDomains_args()
+ args.offset = offset
+ args.limit = limit
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_getDomains(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = getDomains_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "getDomains failed: unknown result")
+
+ def createUser(self, user):
+ """
+ <p>API method to register a user in the system</p>
+
+ Parameters:
+ - user
+ """
+ self.send_createUser(user)
+ return self.recv_createUser()
+
+ def send_createUser(self, user):
+ self._oprot.writeMessageBegin('createUser', TMessageType.CALL, self._seqid)
+ args = createUser_args()
+ args.user = user
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_createUser(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = createUser_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ if result.dee is not None:
+ raise result.dee
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "createUser failed: unknown result")
+
+ def updatedUser(self, user):
+ """
+ <p>API method to update existing user</p>
+
+ Parameters:
+ - user
+ """
+ self.send_updatedUser(user)
+ return self.recv_updatedUser()
+
+ def send_updatedUser(self, user):
+ self._oprot.writeMessageBegin('updatedUser', TMessageType.CALL, self._seqid)
+ args = updatedUser_args()
+ args.user = user
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_updatedUser(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = updatedUser_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "updatedUser failed: unknown result")
+
+ def isUserExists(self, domainId, userId):
+ """
+ <p>API method to check User Exists</p>
+
+ Parameters:
+ - domainId
+ - userId
+ """
+ self.send_isUserExists(domainId, userId)
+ return self.recv_isUserExists()
+
+ def send_isUserExists(self, domainId, userId):
+ self._oprot.writeMessageBegin('isUserExists', TMessageType.CALL, self._seqid)
+ args = isUserExists_args()
+ args.domainId = domainId
+ args.userId = userId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_isUserExists(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = isUserExists_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "isUserExists failed: unknown result")
+
+ def deleteUser(self, domainId, userId):
+ """
+ <p>API method to delete user</p>
+
+ Parameters:
+ - domainId
+ - userId
+ """
+ self.send_deleteUser(domainId, userId)
+ return self.recv_deleteUser()
+
+ def send_deleteUser(self, domainId, userId):
+ self._oprot.writeMessageBegin('deleteUser', TMessageType.CALL, self._seqid)
+ args = deleteUser_args()
+ args.domainId = domainId
+ args.userId = userId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_deleteUser(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = deleteUser_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "deleteUser failed: unknown result")
+
+ def getUser(self, domainId, userId):
+ """
+ <p>API method to get a user</p>
+
+ Parameters:
+ - domainId
+ - userId
+ """
+ self.send_getUser(domainId, userId)
+ return self.recv_getUser()
+
+ def send_getUser(self, domainId, userId):
+ self._oprot.writeMessageBegin('getUser', TMessageType.CALL, self._seqid)
+ args = getUser_args()
+ args.domainId = domainId
+ args.userId = userId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_getUser(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = getUser_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "getUser failed: unknown result")
+
+ def getUsers(self, domainId, offset, limit):
+ """
+ <p>API method to get a list of users in a specific domain.</p>
+ <li>domainId : Domain id</li>
+ <li>offset : Starting result number</li>
+ <li>limit : Number of max results to be sent</li>
+
+ Parameters:
+ - domainId
+ - offset
+ - limit
+ """
+ self.send_getUsers(domainId, offset, limit)
+ return self.recv_getUsers()
+
+ def send_getUsers(self, domainId, offset, limit):
+ self._oprot.writeMessageBegin('getUsers', TMessageType.CALL, self._seqid)
+ args = getUsers_args()
+ args.domainId = domainId
+ args.offset = offset
+ args.limit = limit
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_getUsers(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = getUsers_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "getUsers failed: unknown result")
+
+ def createGroup(self, group):
+ """
+ <p>API method to create a new group</p>
+
+ Parameters:
+ - group
+ """
+ self.send_createGroup(group)
+ return self.recv_createGroup()
+
+ def send_createGroup(self, group):
+ self._oprot.writeMessageBegin('createGroup', TMessageType.CALL, self._seqid)
+ args = createGroup_args()
+ args.group = group
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_createGroup(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = createGroup_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "createGroup failed: unknown result")
+
+ def updateGroup(self, group):
+ """
+ <p>API method to update a group</p>
+
+ Parameters:
+ - group
+ """
+ self.send_updateGroup(group)
+ return self.recv_updateGroup()
+
+ def send_updateGroup(self, group):
+ self._oprot.writeMessageBegin('updateGroup', TMessageType.CALL, self._seqid)
+ args = updateGroup_args()
+ args.group = group
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_updateGroup(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = updateGroup_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "updateGroup failed: unknown result")
+
+ def isGroupExists(self, domainId, groupId):
+ """
+ <p>API method to check Group Exists</p>
+
+ Parameters:
+ - domainId
+ - groupId
+ """
+ self.send_isGroupExists(domainId, groupId)
+ return self.recv_isGroupExists()
+
+ def send_isGroupExists(self, domainId, groupId):
+ self._oprot.writeMessageBegin('isGroupExists', TMessageType.CALL, self._seqid)
+ args = isGroupExists_args()
+ args.domainId = domainId
+ args.groupId = groupId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_isGroupExists(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = isGroupExists_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "isGroupExists failed: unknown result")
+
+ def deleteGroup(self, domainId, groupId):
+ """
+ <p>API method to delete a group</p>
+
+ Parameters:
+ - domainId
+ - groupId
+ """
+ self.send_deleteGroup(domainId, groupId)
+ return self.recv_deleteGroup()
+
+ def send_deleteGroup(self, domainId, groupId):
+ self._oprot.writeMessageBegin('deleteGroup', TMessageType.CALL, self._seqid)
+ args = deleteGroup_args()
+ args.domainId = domainId
+ args.groupId = groupId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_deleteGroup(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = deleteGroup_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "deleteGroup failed: unknown result")
+
+ def getGroup(self, domainId, groupId):
+ """
+ <p>API method to get a group</p>
+
+ Parameters:
+ - domainId
+ - groupId
+ """
+ self.send_getGroup(domainId, groupId)
+ return self.recv_getGroup()
+
+ def send_getGroup(self, domainId, groupId):
+ self._oprot.writeMessageBegin('getGroup', TMessageType.CALL, self._seqid)
+ args = getGroup_args()
+ args.domainId = domainId
+ args.groupId = groupId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_getGroup(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = getGroup_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "getGroup failed: unknown result")
+
+ def getGroups(self, domainId, offset, limit):
+ """
+ <p>API method to get groups in a domainId.</p>
+
+ Parameters:
+ - domainId
+ - offset
+ - limit
+ """
+ self.send_getGroups(domainId, offset, limit)
+ return self.recv_getGroups()
+
+ def send_getGroups(self, domainId, offset, limit):
+ self._oprot.writeMessageBegin('getGroups', TMessageType.CALL, self._seqid)
+ args = getGroups_args()
+ args.domainId = domainId
+ args.offset = offset
+ args.limit = limit
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_getGroups(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = getGroups_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "getGroups failed: unknown result")
+
+ def addUsersToGroup(self, domainId, userIds, groupId):
+ """
+ <p>API method to add list of users to a group</p>
+
+ Parameters:
+ - domainId
+ - userIds
+ - groupId
+ """
+ self.send_addUsersToGroup(domainId, userIds, groupId)
+ return self.recv_addUsersToGroup()
+
+ def send_addUsersToGroup(self, domainId, userIds, groupId):
+ self._oprot.writeMessageBegin('addUsersToGroup', TMessageType.CALL, self._seqid)
+ args = addUsersToGroup_args()
+ args.domainId = domainId
+ args.userIds = userIds
+ args.groupId = groupId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_addUsersToGroup(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = addUsersToGroup_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "addUsersToGroup failed: unknown result")
+
+ def removeUsersFromGroup(self, domainId, userIds, groupId):
+ """
+ <p>API method to remove users from a group</p>
+
+ Parameters:
+ - domainId
+ - userIds
+ - groupId
+ """
+ self.send_removeUsersFromGroup(domainId, userIds, groupId)
+ return self.recv_removeUsersFromGroup()
+
+ def send_removeUsersFromGroup(self, domainId, userIds, groupId):
+ self._oprot.writeMessageBegin('removeUsersFromGroup', TMessageType.CALL, self._seqid)
+ args = removeUsersFromGroup_args()
+ args.domainId = domainId
+ args.userIds = userIds
+ args.groupId = groupId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_removeUsersFromGroup(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = removeUsersFromGroup_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "removeUsersFromGroup failed: unknown result")
+
+ def getGroupMembersOfTypeUser(self, domainId, groupId, offset, limit):
+ """
+ <p>API method to get list of child users in a group. Only the direct members will be returned.</p>
+
+ Parameters:
+ - domainId
+ - groupId
+ - offset
+ - limit
+ """
+ self.send_getGroupMembersOfTypeUser(domainId, groupId, offset, limit)
+ return self.recv_getGroupMembersOfTypeUser()
+
+ def send_getGroupMembersOfTypeUser(self, domainId, groupId, offset, limit):
+ self._oprot.writeMessageBegin('getGroupMembersOfTypeUser', TMessageType.CALL, self._seqid)
+ args = getGroupMembersOfTypeUser_args()
+ args.domainId = domainId
+ args.groupId = groupId
+ args.offset = offset
+ args.limit = limit
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_getGroupMembersOfTypeUser(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = getGroupMembersOfTypeUser_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "getGroupMembersOfTypeUser failed: unknown result")
+
+ def getGroupMembersOfTypeGroup(self, domainId, groupId, offset, limit):
+ """
+ <p>API method to get list of child groups in a group. Only the direct members will be returned.</p>
+
+ Parameters:
+ - domainId
+ - groupId
+ - offset
+ - limit
+ """
+ self.send_getGroupMembersOfTypeGroup(domainId, groupId, offset, limit)
+ return self.recv_getGroupMembersOfTypeGroup()
+
+ def send_getGroupMembersOfTypeGroup(self, domainId, groupId, offset, limit):
+ self._oprot.writeMessageBegin('getGroupMembersOfTypeGroup', TMessageType.CALL, self._seqid)
+ args = getGroupMembersOfTypeGroup_args()
+ args.domainId = domainId
+ args.groupId = groupId
+ args.offset = offset
+ args.limit = limit
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_getGroupMembersOfTypeGroup(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = getGroupMembersOfTypeGroup_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "getGroupMembersOfTypeGroup failed: unknown result")
+
+ def addChildGroupsToParentGroup(self, domainId, childIds, groupId):
+ """
+ <p>API method to add a child group to a parent group.</p>
+
+ Parameters:
+ - domainId
+ - childIds
+ - groupId
+ """
+ self.send_addChildGroupsToParentGroup(domainId, childIds, groupId)
+ return self.recv_addChildGroupsToParentGroup()
+
+ def send_addChildGroupsToParentGroup(self, domainId, childIds, groupId):
+ self._oprot.writeMessageBegin('addChildGroupsToParentGroup', TMessageType.CALL, self._seqid)
+ args = addChildGroupsToParentGroup_args()
+ args.domainId = domainId
+ args.childIds = childIds
+ args.groupId = groupId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_addChildGroupsToParentGroup(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = addChildGroupsToParentGroup_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "addChildGroupsToParentGroup failed: unknown result")
+
+ def removeChildGroupFromParentGroup(self, domainId, childId, groupId):
+ """
+ <p>API method to remove a child group from parent group.</p>
+
+ Parameters:
+ - domainId
+ - childId
+ - groupId
+ """
+ self.send_removeChildGroupFromParentGroup(domainId, childId, groupId)
+ return self.recv_removeChildGroupFromParentGroup()
+
+ def send_removeChildGroupFromParentGroup(self, domainId, childId, groupId):
+ self._oprot.writeMessageBegin('removeChildGroupFromParentGroup', TMessageType.CALL, self._seqid)
+ args = removeChildGroupFromParentGroup_args()
+ args.domainId = domainId
+ args.childId = childId
+ args.groupId = groupId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_removeChildGroupFromParentGroup(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = removeChildGroupFromParentGroup_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "removeChildGroupFromParentGroup failed: unknown result")
+
+ def getAllMemberGroupsForUser(self, domainId, userId):
+ """
+ Parameters:
+ - domainId
+ - userId
+ """
+ self.send_getAllMemberGroupsForUser(domainId, userId)
+ return self.recv_getAllMemberGroupsForUser()
+
+ def send_getAllMemberGroupsForUser(self, domainId, userId):
+ self._oprot.writeMessageBegin('getAllMemberGroupsForUser', TMessageType.CALL, self._seqid)
+ args = getAllMemberGroupsForUser_args()
+ args.domainId = domainId
+ args.userId = userId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_getAllMemberGroupsForUser(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = getAllMemberGroupsForUser_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "getAllMemberGroupsForUser failed: unknown result")
+
+ def createEntityType(self, entityType):
+ """
+ <p>API method to create a new entity type</p>
+
+ Parameters:
+ - entityType
+ """
+ self.send_createEntityType(entityType)
+ return self.recv_createEntityType()
+
+ def send_createEntityType(self, entityType):
+ self._oprot.writeMessageBegin('createEntityType', TMessageType.CALL, self._seqid)
+ args = createEntityType_args()
+ args.entityType = entityType
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_createEntityType(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = createEntityType_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ if result.dee is not None:
+ raise result.dee
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "createEntityType failed: unknown result")
+
+ def updateEntityType(self, entityType):
+ """
+ <p>API method to update entity type</p>
+
+ Parameters:
+ - entityType
+ """
+ self.send_updateEntityType(entityType)
+ return self.recv_updateEntityType()
+
+ def send_updateEntityType(self, entityType):
+ self._oprot.writeMessageBegin('updateEntityType', TMessageType.CALL, self._seqid)
+ args = updateEntityType_args()
+ args.entityType = entityType
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_updateEntityType(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = updateEntityType_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "updateEntityType failed: unknown result")
+
+ def isEntityTypeExists(self, domainId, entityTypeId):
+ """
+ <p>API method to check EntityType Exists</p>
+
+ Parameters:
+ - domainId
+ - entityTypeId
+ """
+ self.send_isEntityTypeExists(domainId, entityTypeId)
+ return self.recv_isEntityTypeExists()
+
+ def send_isEntityTypeExists(self, domainId, entityTypeId):
+ self._oprot.writeMessageBegin('isEntityTypeExists', TMessageType.CALL, self._seqid)
+ args = isEntityTypeExists_args()
+ args.domainId = domainId
+ args.entityTypeId = entityTypeId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_isEntityTypeExists(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = isEntityTypeExists_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "isEntityTypeExists failed: unknown result")
+
+ def deleteEntityType(self, domainId, entityTypeId):
+ """
+ <p>API method to delete entity type</p>
+
+ Parameters:
+ - domainId
+ - entityTypeId
+ """
+ self.send_deleteEntityType(domainId, entityTypeId)
+ return self.recv_deleteEntityType()
+
+ def send_deleteEntityType(self, domainId, entityTypeId):
+ self._oprot.writeMessageBegin('deleteEntityType', TMessageType.CALL, self._seqid)
+ args = deleteEntityType_args()
+ args.domainId = domainId
+ args.entityTypeId = entityTypeId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_deleteEntityType(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = deleteEntityType_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "deleteEntityType failed: unknown result")
+
+ def getEntityType(self, domainId, entityTypeId):
+ """
+ <p>API method to get an entity type</p>
+
+ Parameters:
+ - domainId
+ - entityTypeId
+ """
+ self.send_getEntityType(domainId, entityTypeId)
+ return self.recv_getEntityType()
+
+ def send_getEntityType(self, domainId, entityTypeId):
+ self._oprot.writeMessageBegin('getEntityType', TMessageType.CALL, self._seqid)
+ args = getEntityType_args()
+ args.domainId = domainId
+ args.entityTypeId = entityTypeId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_getEntityType(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = getEntityType_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "getEntityType failed: unknown result")
+
+ def getEntityTypes(self, domainId, offset, limit):
+ """
+ <p>API method to get entity types in a domainId.</p>
+
+ Parameters:
+ - domainId
+ - offset
+ - limit
+ """
+ self.send_getEntityTypes(domainId, offset, limit)
+ return self.recv_getEntityTypes()
+
+ def send_getEntityTypes(self, domainId, offset, limit):
+ self._oprot.writeMessageBegin('getEntityTypes', TMessageType.CALL, self._seqid)
+ args = getEntityTypes_args()
+ args.domainId = domainId
+ args.offset = offset
+ args.limit = limit
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_getEntityTypes(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = getEntityTypes_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "getEntityTypes failed: unknown result")
+
+ def createEntity(self, entity):
+ """
+ <p>API method to register new entity</p>
+
+ Parameters:
+ - entity
+ """
+ self.send_createEntity(entity)
+ return self.recv_createEntity()
+
+ def send_createEntity(self, entity):
+ self._oprot.writeMessageBegin('createEntity', TMessageType.CALL, self._seqid)
+ args = createEntity_args()
+ args.entity = entity
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_createEntity(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = createEntity_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "createEntity failed: unknown result")
+
+ def updateEntity(self, entity):
+ """
+ <p>API method to update entity</p>
+
+ Parameters:
+ - entity
+ """
+ self.send_updateEntity(entity)
+ return self.recv_updateEntity()
+
+ def send_updateEntity(self, entity):
+ self._oprot.writeMessageBegin('updateEntity', TMessageType.CALL, self._seqid)
+ args = updateEntity_args()
+ args.entity = entity
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_updateEntity(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = updateEntity_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "updateEntity failed: unknown result")
+
+ def isEntityExists(self, domainId, entityId):
+ """
+ <p>API method to check Entity Exists</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ """
+ self.send_isEntityExists(domainId, entityId)
+ return self.recv_isEntityExists()
+
+ def send_isEntityExists(self, domainId, entityId):
+ self._oprot.writeMessageBegin('isEntityExists', TMessageType.CALL, self._seqid)
+ args = isEntityExists_args()
+ args.domainId = domainId
+ args.entityId = entityId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_isEntityExists(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = isEntityExists_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "isEntityExists failed: unknown result")
+
+ def deleteEntity(self, domainId, entityId):
+ """
+ <p>API method to delete entity</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ """
+ self.send_deleteEntity(domainId, entityId)
+ return self.recv_deleteEntity()
+
+ def send_deleteEntity(self, domainId, entityId):
+ self._oprot.writeMessageBegin('deleteEntity', TMessageType.CALL, self._seqid)
+ args = deleteEntity_args()
+ args.domainId = domainId
+ args.entityId = entityId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_deleteEntity(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = deleteEntity_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "deleteEntity failed: unknown result")
+
+ def getEntity(self, domainId, entityId):
+ """
+ <p>API method to get entity</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ """
+ self.send_getEntity(domainId, entityId)
+ return self.recv_getEntity()
+
+ def send_getEntity(self, domainId, entityId):
+ self._oprot.writeMessageBegin('getEntity', TMessageType.CALL, self._seqid)
+ args = getEntity_args()
+ args.domainId = domainId
+ args.entityId = entityId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_getEntity(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = getEntity_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "getEntity failed: unknown result")
+
+ def searchEntities(self, domainId, userId, filters, offset, limit):
+ """
+ <p>API method to search entities</p>
+
+ Parameters:
+ - domainId
+ - userId
+ - filters
+ - offset
+ - limit
+ """
+ self.send_searchEntities(domainId, userId, filters, offset, limit)
+ return self.recv_searchEntities()
+
+ def send_searchEntities(self, domainId, userId, filters, offset, limit):
+ self._oprot.writeMessageBegin('searchEntities', TMessageType.CALL, self._seqid)
+ args = searchEntities_args()
+ args.domainId = domainId
+ args.userId = userId
+ args.filters = filters
+ args.offset = offset
+ args.limit = limit
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_searchEntities(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = searchEntities_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "searchEntities failed: unknown result")
+
+ def getListOfSharedUsers(self, domainId, entityId, permissionTypeId):
+ """
+ <p>API method to get a list of shared users given the entity id</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ - permissionTypeId
+ """
+ self.send_getListOfSharedUsers(domainId, entityId, permissionTypeId)
+ return self.recv_getListOfSharedUsers()
+
+ def send_getListOfSharedUsers(self, domainId, entityId, permissionTypeId):
+ self._oprot.writeMessageBegin('getListOfSharedUsers', TMessageType.CALL, self._seqid)
+ args = getListOfSharedUsers_args()
+ args.domainId = domainId
+ args.entityId = entityId
+ args.permissionTypeId = permissionTypeId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_getListOfSharedUsers(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = getListOfSharedUsers_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "getListOfSharedUsers failed: unknown result")
+
+ def getListOfSharedGroups(self, domainId, entityId, permissionTypeId):
+ """
+ <p>API method to get a list of shared groups given the entity id</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ - permissionTypeId
+ """
+ self.send_getListOfSharedGroups(domainId, entityId, permissionTypeId)
+ return self.recv_getListOfSharedGroups()
+
+ def send_getListOfSharedGroups(self, domainId, entityId, permissionTypeId):
+ self._oprot.writeMessageBegin('getListOfSharedGroups', TMessageType.CALL, self._seqid)
+ args = getListOfSharedGroups_args()
+ args.domainId = domainId
+ args.entityId = entityId
+ args.permissionTypeId = permissionTypeId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_getListOfSharedGroups(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = getListOfSharedGroups_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "getListOfSharedGroups failed: unknown result")
+
+ def createPermissionType(self, permissionType):
+ """
+ <p>API method to create permission type</p>
+
+ Parameters:
+ - permissionType
+ """
+ self.send_createPermissionType(permissionType)
+ return self.recv_createPermissionType()
+
+ def send_createPermissionType(self, permissionType):
+ self._oprot.writeMessageBegin('createPermissionType', TMessageType.CALL, self._seqid)
+ args = createPermissionType_args()
+ args.permissionType = permissionType
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_createPermissionType(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = createPermissionType_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ if result.dee is not None:
+ raise result.dee
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "createPermissionType failed: unknown result")
+
+ def updatePermissionType(self, permissionType):
+ """
+ <p>API method to update permission type</p>
+
+ Parameters:
+ - permissionType
+ """
+ self.send_updatePermissionType(permissionType)
+ return self.recv_updatePermissionType()
+
+ def send_updatePermissionType(self, permissionType):
+ self._oprot.writeMessageBegin('updatePermissionType', TMessageType.CALL, self._seqid)
+ args = updatePermissionType_args()
+ args.permissionType = permissionType
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_updatePermissionType(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = updatePermissionType_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "updatePermissionType failed: unknown result")
+
+ def isPermissionExists(self, dimainId, permissionId):
+ """
+ <p>API method to check Permission Exists</p>
+
+ Parameters:
+ - dimainId
+ - permissionId
+ """
+ self.send_isPermissionExists(dimainId, permissionId)
+ return self.recv_isPermissionExists()
+
+ def send_isPermissionExists(self, dimainId, permissionId):
+ self._oprot.writeMessageBegin('isPermissionExists', TMessageType.CALL, self._seqid)
+ args = isPermissionExists_args()
+ args.dimainId = dimainId
+ args.permissionId = permissionId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_isPermissionExists(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = isPermissionExists_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "isPermissionExists failed: unknown result")
+
+ def deletePermissionType(self, domainId, permissionTypeId):
+ """
+ <p>API method to delete permission type</p>
+
+ Parameters:
+ - domainId
+ - permissionTypeId
+ """
+ self.send_deletePermissionType(domainId, permissionTypeId)
+ return self.recv_deletePermissionType()
+
+ def send_deletePermissionType(self, domainId, permissionTypeId):
+ self._oprot.writeMessageBegin('deletePermissionType', TMessageType.CALL, self._seqid)
+ args = deletePermissionType_args()
+ args.domainId = domainId
+ args.permissionTypeId = permissionTypeId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_deletePermissionType(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = deletePermissionType_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "deletePermissionType failed: unknown result")
+
+ def getPermissionType(self, domainId, permissionTypeId):
+ """
+ <p>API method to get permission type</p>
+
+ Parameters:
+ - domainId
+ - permissionTypeId
+ """
+ self.send_getPermissionType(domainId, permissionTypeId)
+ return self.recv_getPermissionType()
+
+ def send_getPermissionType(self, domainId, permissionTypeId):
+ self._oprot.writeMessageBegin('getPermissionType', TMessageType.CALL, self._seqid)
+ args = getPermissionType_args()
+ args.domainId = domainId
+ args.permissionTypeId = permissionTypeId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_getPermissionType(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = getPermissionType_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "getPermissionType failed: unknown result")
+
+ def getPermissionTypes(self, domainId, offset, limit):
+ """
+ <p>API method to get list of permission types in a given domainId.</p>
+
+ Parameters:
+ - domainId
+ - offset
+ - limit
+ """
+ self.send_getPermissionTypes(domainId, offset, limit)
+ return self.recv_getPermissionTypes()
+
+ def send_getPermissionTypes(self, domainId, offset, limit):
+ self._oprot.writeMessageBegin('getPermissionTypes', TMessageType.CALL, self._seqid)
+ args = getPermissionTypes_args()
+ args.domainId = domainId
+ args.offset = offset
+ args.limit = limit
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_getPermissionTypes(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = getPermissionTypes_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "getPermissionTypes failed: unknown result")
+
+ def shareEntityWithUsers(self, domainId, entityId, userList, perssionTypeId, cascadePermission):
+ """
+ <p>API method to share an entity with users</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ - userList
+ - perssionTypeId
+ - cascadePermission
+ """
+ self.send_shareEntityWithUsers(domainId, entityId, userList, perssionTypeId, cascadePermission)
+ return self.recv_shareEntityWithUsers()
+
+ def send_shareEntityWithUsers(self, domainId, entityId, userList, perssionTypeId, cascadePermission):
+ self._oprot.writeMessageBegin('shareEntityWithUsers', TMessageType.CALL, self._seqid)
+ args = shareEntityWithUsers_args()
+ args.domainId = domainId
+ args.entityId = entityId
+ args.userList = userList
+ args.perssionTypeId = perssionTypeId
+ args.cascadePermission = cascadePermission
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_shareEntityWithUsers(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = shareEntityWithUsers_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "shareEntityWithUsers failed: unknown result")
+
+ def revokeEntitySharingFromUsers(self, domainId, entityId, userList, perssionTypeId):
+ """
+ <p>API method to revoke sharing from a list of users</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ - userList
+ - perssionTypeId
+ """
+ self.send_revokeEntitySharingFromUsers(domainId, entityId, userList, perssionTypeId)
+ return self.recv_revokeEntitySharingFromUsers()
+
+ def send_revokeEntitySharingFromUsers(self, domainId, entityId, userList, perssionTypeId):
+ self._oprot.writeMessageBegin('revokeEntitySharingFromUsers', TMessageType.CALL, self._seqid)
+ args = revokeEntitySharingFromUsers_args()
+ args.domainId = domainId
+ args.entityId = entityId
+ args.userList = userList
+ args.perssionTypeId = perssionTypeId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_revokeEntitySharingFromUsers(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = revokeEntitySharingFromUsers_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "revokeEntitySharingFromUsers failed: unknown result")
+
+ def shareEntityWithGroups(self, domainId, entityId, groupList, perssionTypeId, cascadePermission):
+ """
+ <p>API method to share an entity with list of groups</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ - groupList
+ - perssionTypeId
+ - cascadePermission
+ """
+ self.send_shareEntityWithGroups(domainId, entityId, groupList, perssionTypeId, cascadePermission)
+ return self.recv_shareEntityWithGroups()
+
+ def send_shareEntityWithGroups(self, domainId, entityId, groupList, perssionTypeId, cascadePermission):
+ self._oprot.writeMessageBegin('shareEntityWithGroups', TMessageType.CALL, self._seqid)
+ args = shareEntityWithGroups_args()
+ args.domainId = domainId
+ args.entityId = entityId
+ args.groupList = groupList
+ args.perssionTypeId = perssionTypeId
+ args.cascadePermission = cascadePermission
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_shareEntityWithGroups(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = shareEntityWithGroups_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "shareEntityWithGroups failed: unknown result")
+
+ def revokeEntitySharingFromGroups(self, domainId, entityId, groupList, perssionTypeId):
+ """
+ <p>API method to revoke sharing from list of users</p>
+
+ Parameters:
+ - domainId
+ - entityId
+ - groupList
+ - perssionTypeId
+ """
+ self.send_revokeEntitySharingFromGroups(domainId, entityId, groupList, perssionTypeId)
+ return self.recv_revokeEntitySharingFromGroups()
+
+ def send_revokeEntitySharingFromGroups(self, domainId, entityId, groupList, perssionTypeId):
+ self._oprot.writeMessageBegin('revokeEntitySharingFromGroups', TMessageType.CALL, self._seqid)
+ args = revokeEntitySharingFromGroups_args()
+ args.domainId = domainId
+ args.entityId = entityId
+ args.groupList = groupList
+ args.perssionTypeId = perssionTypeId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_revokeEntitySharingFromGroups(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = revokeEntitySharingFromGroups_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "revokeEntitySharingFromGroups failed: unknown result")
+
+ def userHasAccess(self, domainId, userId, entityId, permissionTypeId):
+ """
+ <p>API method to check whether a user has access to a specific entity</p>
+
+ Parameters:
+ - domainId
+ - userId
+ - entityId
+ - permissionTypeId
+ """
+ self.send_userHasAccess(domainId, userId, entityId, permissionTypeId)
+ return self.recv_userHasAccess()
+
+ def send_userHasAccess(self, domainId, userId, entityId, permissionTypeId):
+ self._oprot.writeMessageBegin('userHasAccess', TMessageType.CALL, self._seqid)
+ args = userHasAccess_args()
+ args.domainId = domainId
+ args.userId = userId
+ args.entityId = entityId
+ args.permissionTypeId = permissionTypeId
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_userHasAccess(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = userHasAccess_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ if result.sre is not None:
+ raise result.sre
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "userHasAccess failed: unknown result")
- Parameters:
- - domain
- """
- pass
- def isDomainExists(self, domainId):
- """
- <p>API method to check Domain Exists</p>
+class Processor(Iface, TProcessor):
+ def __init__(self, handler):
+ self._handler = handler
+ self._processMap = {}
+ self._processMap["createDomain"] = Processor.process_createDomain
+ self._processMap["updateDomain"] = Processor.process_updateDomain
+ self._processMap["isDomainExists"] = Processor.process_isDomainExists
+ self._processMap["deleteDomain"] = Processor.process_deleteDomain
+ self._processMap["getDomain"] = Processor.process_getDomain
+ self._processMap["getDomains"] = Processor.process_getDomains
+ self._processMap["createUser"] = Processor.process_createUser
+ self._processMap["updatedUser"] = Processor.process_updatedUser
+ self._processMap["isUserExists"] = Processor.process_isUserExists
+ self._processMap["deleteUser"] = Processor.process_deleteUser
+ self._processMap["getUser"] = Processor.process_getUser
+ self._processMap["getUsers"] = Processor.process_getUsers
+ self._processMap["createGroup"] = Processor.process_createGroup
+ self._processMap["updateGroup"] = Processor.process_updateGroup
+ self._processMap["isGroupExists"] = Processor.process_isGroupExists
+ self._processMap["deleteGroup"] = Processor.process_deleteGroup
+ self._processMap["getGroup"] = Processor.process_getGroup
+ self._processMap["getGroups"] = Processor.process_getGroups
+ self._processMap["addUsersToGroup"] = Processor.process_addUsersToGroup
+ self._processMap["removeUsersFromGroup"] = Processor.process_removeUsersFromGroup
+ self._processMap["getGroupMembersOfTypeUser"] = Processor.process_getGroupMembersOfTypeUser
+ self._processMap["getGroupMembersOfTypeGroup"] = Processor.process_getGroupMembersOfTypeGroup
+ self._processMap["addChildGroupsToParentGroup"] = Processor.process_addChildGroupsToParentGroup
+ self._processMap["removeChildGroupFromParentGroup"] = Processor.process_removeChildGroupFromParentGroup
+ self._processMap["getAllMemberGroupsForUser"] = Processor.process_getAllMemberGroupsForUser
+ self._processMap["createEntityType"] = Processor.process_createEntityType
+ self._processMap["updateEntityType"] = Processor.process_updateEntityType
+ self._processMap["isEntityTypeExists"] = Processor.process_isEntityTypeExists
+ self._processMap["deleteEntityType"] = Processor.process_deleteEntityType
+ self._processMap["getEntityType"] = Processor.process_getEntityType
+ self._processMap["getEntityTypes"] = Processor.process_getEntityTypes
+ self._processMap["createEntity"] = Processor.process_createEntity
+ self._processMap["updateEntity"] = Processor.process_updateEntity
+ self._processMap["isEntityExists"] = Processor.process_isEntityExists
+ self._processMap["deleteEntity"] = Processor.process_deleteEntity
+ self._processMap["getEntity"] = Processor.process_getEntity
+ self._processMap["searchEntities"] = Processor.process_searchEntities
+ self._processMap["getListOfSharedUsers"] = Processor.process_getListOfSharedUsers
+ self._processMap["getListOfSharedGroups"] = Processor.process_getListOfSharedGroups
+ self._processMap["createPermissionType"] = Processor.process_createPermissionType
+ self._processMap["updatePermissionType"] = Processor.process_updatePermissionType
+ self._processMap["isPermissionExists"] = Processor.process_isPermissionExists
+ self._processMap["deletePermissionType"] = Processor.process_deletePermissionType
+ self._processMap["getPermissionType"] = Processor.process_getPermissionType
+ self._processMap["getPermissionTypes"] = Processor.process_getPermissionTypes
+ self._processMap["shareEntityWithUsers"] = Processor.process_shareEntityWithUsers
+ self._processMap["revokeEntitySharingFromUsers"] = Processor.process_revokeEntitySharingFromUsers
+ self._processMap["shareEntityWithGroups"] = Processor.process_shareEntityWithGroups
+ self._processMap["revokeEntitySharingFromGroups"] = Processor.process_revokeEntitySharingFromGroups
+ self._processMap["userHasAccess"] = Processor.process_userHasAccess
+
+ def process(self, iprot, oprot):
+ (name, type, seqid) = iprot.readMessageBegin()
+ if name not in self._processMap:
+ iprot.skip(TType.STRUCT)
+ iprot.readMessageEnd()
+ x = TApplicationException(TApplicationException.UNKNOWN_METHOD, 'Unknown function %s' % (name))
+ oprot.writeMessageBegin(name, TMessageType.EXCEPTION, seqid)
+ x.write(oprot)
+ oprot.writeMessageEnd()
+ oprot.trans.flush()
+ return
+ else:
+ self._processMap[name](self, seqid, iprot, oprot)
+ return True
+
+ def process_createDomain(self, seqid, iprot, oprot):
+ args = createDomain_args()
+ args.read(iprot)
+ iprot.readMessageEnd()
+ result = createDomain_result()
+ try:
+ result.success = self._handler.createDomain(args.domain)
+ msg_type = TMessageType.REPLY
+ except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+ raise
+ except apache.airavata.model.sharing.ttypes.SharingRegistryException as sre:
+ msg_type = TMessageType.REPLY
+ result.sre = sre
+ except apache.airavata.model.sharing.ttypes.DuplicateEntryException as dee:
+ msg_type = TMessageType.REPLY
+ result.dee = dee
+ except Exception as ex:
+ msg_type = TMessageType.EXCEPTION
+ logging.exception(ex)
+ result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+ oprot.writeMessageBegin("createDomain", msg_type, seqid)
+ result.write(oprot)
+ oprot.writeMessageEnd()
+ oprot.trans.flush()
+
+ def process_updateDomain(self, seqid, iprot, oprot):
+ args = updateDomain_args()
+ args.read(iprot)
+ iprot.readMessageEnd()
+ result = updateDomain_result()
+ try:
+ result.success = self._handler.updateDomain(args.domain)
+ msg_type = TMessageType.REPLY
+ except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+ raise
+ except apache.airavata.model.sharing.ttypes.SharingRegistryException as sre:
+ msg_type = TMessageType.REPLY
+ result.sre = sre
+ except Exception as ex:
+ msg_type = TMessageType.EXCEPTION
+ logging.exception(ex)
+ result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+ oprot.writeMessageBegin("updateDomain", msg_type, seqid)
+ result.write(oprot)
+ oprot.writeMessageEnd()
+ oprot.trans.flush()
+
+ def process_isDomainExists(self, seqid, iprot, oprot):
+ args = isDomainExists_args()
+ args.read(iprot)
+ iprot.readMessageEnd()
+ result = isDomainExists_result()
+ try:
+ result.success = self._handler.isDomainExists(args.domainId)
+ msg_type = TMessageType.REPLY
+ except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+ raise
+ except apache.airavata.model.sharing.ttypes.SharingRegistryException as sre:
+ msg_type = TMessageType.REPLY
+ result.sre = sre
+ except Exception as ex:
+ msg_type = TMessageType.EXCEPTION
+ logging.exception(ex)
+ result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+ oprot.writeMessageBegin("isDo
<TRUNCATED>
[51/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
AIRAVATA-2505 Upgrade Airavata to Thrift 0.10.0
Project: http://git-wip-us.apache.org/repos/asf/airavata/repo
Commit: http://git-wip-us.apache.org/repos/asf/airavata/commit/9d165bd8
Tree: http://git-wip-us.apache.org/repos/asf/airavata/tree/9d165bd8
Diff: http://git-wip-us.apache.org/repos/asf/airavata/diff/9d165bd8
Branch: refs/heads/thrift-0.10.0-upgrade
Commit: 9d165bd8773fca924879a0c3398e34d48caed676
Parents: 0f03a85
Author: Marcus Christie <ma...@apache.org>
Authored: Fri Aug 4 16:08:24 2017 -0400
Committer: Marcus Christie <ma...@apache.org>
Committed: Fri Aug 4 16:08:24 2017 -0400
----------------------------------------------------------------------
.../java/org/apache/airavata/api/Airavata.java | 58659 ++++-----
.../airavata/api/airavata_apiConstants.java | 33 +-
.../resources/lib/Airavata/API/Airavata.php | 4 +-
.../resources/lib/Airavata/API/Error/Types.php | 2 +-
.../API/Sharing/SharingRegistryService.php | 4 +-
.../lib/Airavata/API/Sharing/Types.php | 2 +-
.../main/resources/lib/Airavata/API/Types.php | 2 +-
.../Model/AppCatalog/AppDeployment/Types.php | 2 +-
.../Model/AppCatalog/AppInterface/Types.php | 2 +-
.../Model/AppCatalog/ComputeResource/Types.php | 2 +-
.../Model/AppCatalog/GatewayProfile/Types.php | 2 +-
.../Model/AppCatalog/Parallelism/Types.php | 2 +-
.../Model/AppCatalog/StorageResource/Types.php | 2 +-
.../AppCatalog/UserResourceProfile/Types.php | 2 +-
.../lib/Airavata/Model/Application/Io/Types.php | 2 +-
.../lib/Airavata/Model/Commons/Types.php | 2 +-
.../Airavata/Model/Credential/Store/Types.php | 2 +-
.../lib/Airavata/Model/Data/Movement/Types.php | 2 +-
.../lib/Airavata/Model/Data/Replica/Types.php | 2 +-
.../lib/Airavata/Model/Dbevent/Types.php | 2 +-
.../lib/Airavata/Model/Experiment/Types.php | 2 +-
.../lib/Airavata/Model/Group/Types.php | 2 +-
.../Airavata/Model/Messaging/Event/Types.php | 2 +-
.../lib/Airavata/Model/Process/Types.php | 2 +-
.../lib/Airavata/Model/Scheduling/Types.php | 2 +-
.../lib/Airavata/Model/Security/Types.php | 2 +-
.../lib/Airavata/Model/Sharing/Types.php | 2 +-
.../lib/Airavata/Model/Status/Types.php | 2 +-
.../resources/lib/Airavata/Model/Task/Types.php | 2 +-
.../lib/Airavata/Model/Tenant/Types.php | 2 +-
.../main/resources/lib/Airavata/Model/Types.php | 2 +-
.../resources/lib/Airavata/Model/User/Types.php | 2 +-
.../lib/Airavata/Model/Workspace/Types.php | 2 +-
.../resources/lib/Airavata/Model/job/Types.php | 2 +-
.../Iam/Admin/Services/CPI/Error/Types.php | 2 +-
.../Iam/Admin/Services/CPI/IamAdminServices.php | 4 +-
.../Service/Iam/Admin/Services/CPI/Types.php | 2 +-
.../Service/Profile/Tenant/CPI/Error/Types.php | 2 +-
.../Profile/Tenant/CPI/TenantProfileService.php | 4 +-
.../Service/Profile/Tenant/CPI/Types.php | 2 +-
.../lib/Airavata/Service/Profile/Types.php | 2 +-
.../Service/Profile/User/CPI/Error/Types.php | 2 +-
.../Airavata/Service/Profile/User/CPI/Types.php | 2 +-
.../Profile/User/CPI/UserProfileService.php | 4 +-
.../src/main/resources/lib/Types.php | 2 +-
.../lib/apache/airavata/api/Airavata-remote | 1805 +-
.../lib/apache/airavata/api/Airavata.py | 104600 ++++++++--------
.../lib/apache/airavata/api/constants.py | 9 +-
.../lib/apache/airavata/api/error/constants.py | 9 +-
.../lib/apache/airavata/api/error/ttypes.py | 1901 +-
.../api/sharing/SharingRegistryService-remote | 615 +-
.../api/sharing/SharingRegistryService.py | 23009 ++--
.../apache/airavata/api/sharing/constants.py | 9 +-
.../lib/apache/airavata/api/sharing/ttypes.py | 14 +-
.../resources/lib/apache/airavata/api/ttypes.py | 14 +-
.../model/appcatalog/appdeployment/constants.py | 9 +-
.../model/appcatalog/appdeployment/ttypes.py | 1328 +-
.../model/appcatalog/appinterface/constants.py | 9 +-
.../model/appcatalog/appinterface/ttypes.py | 398 +-
.../appcatalog/computeresource/constants.py | 9 +-
.../model/appcatalog/computeresource/ttypes.py | 3447 +-
.../appcatalog/gatewayprofile/constants.py | 9 +-
.../model/appcatalog/gatewayprofile/ttypes.py | 1064 +-
.../model/appcatalog/parallelism/constants.py | 9 +-
.../model/appcatalog/parallelism/ttypes.py | 96 +-
.../appcatalog/storageresource/constants.py | 9 +-
.../model/appcatalog/storageresource/ttypes.py | 297 +-
.../appcatalog/userresourceprofile/constants.py | 9 +-
.../appcatalog/userresourceprofile/ttypes.py | 1012 +-
.../airavata/model/application/io/constants.py | 9 +-
.../airavata/model/application/io/ttypes.py | 989 +-
.../apache/airavata/model/commons/constants.py | 9 +-
.../lib/apache/airavata/model/commons/ttypes.py | 625 +-
.../lib/apache/airavata/model/constants.py | 9 +-
.../airavata/model/data/movement/constants.py | 9 +-
.../airavata/model/data/movement/ttypes.py | 1193 +-
.../airavata/model/data/replica/constants.py | 9 +-
.../airavata/model/data/replica/ttypes.py | 970 +-
.../apache/airavata/model/dbevent/constants.py | 9 +-
.../lib/apache/airavata/model/dbevent/ttypes.py | 938 +-
.../airavata/model/experiment/constants.py | 9 +-
.../apache/airavata/model/experiment/ttypes.py | 2161 +-
.../apache/airavata/model/group/constants.py | 9 +-
.../lib/apache/airavata/model/group/ttypes.py | 331 +-
.../lib/apache/airavata/model/job/constants.py | 9 +-
.../lib/apache/airavata/model/job/ttypes.py | 444 +-
.../airavata/model/messaging/event/constants.py | 9 +-
.../airavata/model/messaging/event/ttypes.py | 2897 +-
.../apache/airavata/model/process/constants.py | 9 +-
.../lib/apache/airavata/model/process/ttypes.py | 818 +-
.../airavata/model/scheduling/constants.py | 9 +-
.../apache/airavata/model/scheduling/ttypes.py | 417 +-
.../apache/airavata/model/security/constants.py | 9 +-
.../apache/airavata/model/security/ttypes.py | 167 +-
.../apache/airavata/model/sharing/constants.py | 9 +-
.../lib/apache/airavata/model/sharing/ttypes.py | 3308 +-
.../apache/airavata/model/status/constants.py | 9 +-
.../lib/apache/airavata/model/status/ttypes.py | 1311 +-
.../lib/apache/airavata/model/task/constants.py | 9 +-
.../lib/apache/airavata/model/task/ttypes.py | 1360 +-
.../apache/airavata/model/tenant/constants.py | 9 +-
.../lib/apache/airavata/model/tenant/ttypes.py | 920 +-
.../lib/apache/airavata/model/ttypes.py | 14 +-
.../lib/apache/airavata/model/user/constants.py | 9 +-
.../lib/apache/airavata/model/user/ttypes.py | 1574 +-
.../apache/airavata/model/workflow/constants.py | 9 +-
.../apache/airavata/model/workflow/ttypes.py | 1564 +-
.../airavata/model/workspace/constants.py | 9 +-
.../apache/airavata/model/workspace/ttypes.py | 1794 +-
.../credential_store_data_models/constants.py | 9 +-
.../lib/credential_store_data_models/ttypes.py | 1497 +-
.../apache/airavata/model/ComponentState.java | 2 +-
.../apache/airavata/model/ComponentStatus.java | 150 +-
.../org/apache/airavata/model/EdgeModel.java | 169 +-
.../org/apache/airavata/model/NodeModel.java | 203 +-
.../org/apache/airavata/model/PortModel.java | 186 +-
.../apache/airavata/model/WorkflowModel.java | 294 +-
.../apache/airavata/model/WorkflowState.java | 2 +-
.../apache/airavata/model/WorkflowStatus.java | 150 +-
.../ApplicationDeploymentDescription.java | 480 +-
.../appdeployment/ApplicationModule.java | 179 +-
.../appcatalog/appdeployment/CommandObject.java | 143 +-
.../appcatalog/appdeployment/SetEnvPaths.java | 162 +-
.../ApplicationInterfaceDescription.java | 283 +-
.../appcatalog/computeresource/BatchQueue.java | 358 +-
.../computeresource/CloudJobSubmission.java | 197 +-
.../ComputeResourceDescription.java | 543 +-
.../appcatalog/computeresource/DMType.java | 2 +-
.../appcatalog/computeresource/FileSystems.java | 2 +-
.../computeresource/GlobusJobSubmission.java | 172 +-
.../computeresource/JobManagerCommand.java | 2 +-
.../computeresource/JobSubmissionInterface.java | 146 +-
.../computeresource/JobSubmissionProtocol.java | 2 +-
.../computeresource/LOCALSubmission.java | 140 +-
.../appcatalog/computeresource/MonitorMode.java | 2 +-
.../computeresource/ProviderName.java | 2 +-
.../computeresource/ResourceJobManager.java | 265 +-
.../computeresource/ResourceJobManagerType.java | 2 +-
.../computeresource/SSHJobSubmission.java | 224 +-
.../computeresource/UnicoreJobSubmission.java | 150 +-
.../ComputeResourcePreference.java | 359 +-
.../gatewayprofile/GatewayResourceProfile.java | 241 +-
.../gatewayprofile/StoragePreference.java | 177 +-
.../StorageResourceDescription.java | 204 +-
.../UserComputeResourcePreference.java | 281 +-
.../UserResourceProfile.java | 263 +-
.../UserStoragePreference.java | 177 +-
.../airavata/model/application/io/DataType.java | 2 +-
.../application/io/InputDataObjectType.java | 350 +-
.../application/io/OutputDataObjectType.java | 312 +-
.../airavata/model/commons/ErrorModel.java | 231 +-
.../model/commons/ValidationResults.java | 145 +-
.../airavata/model/commons/ValidatorResult.java | 139 +-
.../commons/airavata_commonsConstants.java | 33 +-
.../credential/store/CertificateCredential.java | 237 +-
.../model/credential/store/CommunityUser.java | 160 +-
.../credential/store/CredentialOwnerType.java | 2 +-
.../credential/store/CredentialSummary.java | 240 +-
.../credential/store/PasswordCredential.java | 250 +-
.../model/credential/store/SSHCredential.java | 256 +-
.../model/credential/store/SummaryType.java | 2 +-
.../credential_store_data_modelsConstants.java | 33 +-
.../airavata/model/data/movement/DMType.java | 2 +-
.../data/movement/DataMovementInterface.java | 146 +-
.../data/movement/DataMovementProtocol.java | 2 +-
.../data/movement/GridFTPDataMovement.java | 170 +-
.../model/data/movement/LOCALDataMovement.java | 122 +-
.../model/data/movement/SCPDataMovement.java | 169 +-
.../model/data/movement/SecurityProtocol.java | 2 +-
.../data/movement/UnicoreDataMovement.java | 150 +-
.../model/data/replica/DataProductModel.java | 359 +-
.../model/data/replica/DataProductType.java | 2 +-
.../data/replica/DataReplicaLocationModel.java | 343 +-
.../data/replica/ReplicaLocationCategory.java | 2 +-
.../data/replica/ReplicaPersistentType.java | 2 +-
.../apache/airavata/model/dbevent/CrudType.java | 2 +-
.../airavata/model/dbevent/DBEventMessage.java | 140 +-
.../model/dbevent/DBEventMessageContext.java | 97 +-
.../model/dbevent/DBEventPublisher.java | 112 +-
.../model/dbevent/DBEventPublisherContext.java | 146 +-
.../model/dbevent/DBEventSubscriber.java | 122 +-
.../airavata/model/dbevent/DBEventType.java | 2 +-
.../airavata/model/dbevent/EntityType.java | 2 +-
.../model/error/AiravataClientException.java | 135 +-
.../airavata/model/error/AiravataErrorType.java | 2 +-
.../model/error/AiravataSystemException.java | 135 +-
.../model/error/AuthenticationException.java | 124 +-
.../model/error/AuthorizationException.java | 124 +-
.../model/error/DuplicateEntryException.java | 124 +-
.../error/ExperimentNotFoundException.java | 124 +-
.../model/error/InvalidRequestException.java | 124 +-
.../model/error/LaunchValidationException.java | 135 +-
.../model/error/ProjectNotFoundException.java | 124 +-
.../airavata/model/error/TimedOutException.java | 105 +-
.../airavata/model/error/ValidationResults.java | 145 +-
.../airavata/model/error/ValidatorResult.java | 139 +-
.../model/experiment/ExperimentModel.java | 524 +-
.../experiment/ExperimentSearchFields.java | 2 +-
.../model/experiment/ExperimentStatistics.java | 377 +-
.../experiment/ExperimentSummaryModel.java | 328 +-
.../model/experiment/ExperimentType.java | 2 +-
.../model/experiment/ProjectSearchFields.java | 2 +-
.../experiment/UserConfigurationDataModel.java | 265 +-
.../apache/airavata/model/group/GroupModel.java | 212 +-
.../model/group/ResourcePermissionType.java | 2 +-
.../airavata/model/group/ResourceType.java | 2 +-
.../org/apache/airavata/model/job/JobModel.java | 353 +-
.../event/ExperimentStatusChangeEvent.java | 150 +-
.../messaging/event/ExperimentSubmitEvent.java | 141 +-
.../model/messaging/event/JobIdentifier.java | 198 +-
.../messaging/event/JobStatusChangeEvent.java | 121 +-
.../event/JobStatusChangeRequestEvent.java | 121 +-
.../airavata/model/messaging/event/Message.java | 186 +-
.../model/messaging/event/MessageLevel.java | 2 +-
.../model/messaging/event/MessageType.java | 2 +-
.../messaging/event/ProcessIdentifier.java | 160 +-
.../event/ProcessStatusChangeEvent.java | 121 +-
.../event/ProcessStatusChangeRequestEvent.java | 121 +-
.../messaging/event/ProcessSubmitEvent.java | 179 +-
.../messaging/event/ProcessTerminateEvent.java | 160 +-
.../model/messaging/event/TaskIdentifier.java | 179 +-
.../messaging/event/TaskOutputChangeEvent.java | 139 +-
.../messaging/event/TaskStatusChangeEvent.java | 121 +-
.../event/TaskStatusChangeRequestEvent.java | 121 +-
.../parallelism/ApplicationParallelismType.java | 2 +-
.../airavata/model/process/ProcessModel.java | 621 +-
.../ComputationalResourceSchedulingModel.java | 337 +-
.../airavata/model/security/AuthzToken.java | 165 +-
.../airavata/model/status/ExperimentState.java | 2 +-
.../airavata/model/status/ExperimentStatus.java | 150 +-
.../apache/airavata/model/status/JobState.java | 2 +-
.../apache/airavata/model/status/JobStatus.java | 150 +-
.../airavata/model/status/ProcessState.java | 2 +-
.../airavata/model/status/ProcessStatus.java | 150 +-
.../airavata/model/status/QueueStatusModel.java | 201 +-
.../apache/airavata/model/status/TaskState.java | 2 +-
.../airavata/model/status/TaskStatus.java | 150 +-
.../airavata/model/task/DataStageType.java | 2 +-
.../model/task/DataStagingTaskModel.java | 223 +-
.../model/task/EnvironmentSetupTaskModel.java | 131 +-
.../model/task/JobSubmissionTaskModel.java | 142 +-
.../airavata/model/task/MonitorTaskModel.java | 112 +-
.../apache/airavata/model/task/TaskModel.java | 301 +-
.../apache/airavata/model/task/TaskTypes.java | 2 +-
.../apache/airavata/model/tenant/Tenant.java | 331 +-
.../model/tenant/TenantApprovalStatus.java | 2 +-
.../airavata/model/tenant/TenantConfig.java | 175 +-
.../model/tenant/TenantPreferences.java | 158 +-
.../airavata/model/user/NSFDemographics.java | 227 +-
.../org/apache/airavata/model/user/Status.java | 2 +-
.../airavata/model/user/USCitizenship.java | 2 +-
.../apache/airavata/model/user/UserProfile.java | 658 +-
.../apache/airavata/model/user/disability.java | 2 +-
.../apache/airavata/model/user/ethnicity.java | 2 +-
.../org/apache/airavata/model/user/race.java | 2 +-
.../model/user/user_profile_modelConstants.java | 33 +-
.../airavata/model/workspace/Gateway.java | 483 +-
.../model/workspace/GatewayApprovalStatus.java | 2 +-
.../apache/airavata/model/workspace/Group.java | 143 +-
.../airavata/model/workspace/Notification.java | 241 +-
.../model/workspace/NotificationPriority.java | 2 +-
.../airavata/model/workspace/Project.java | 291 +-
.../apache/airavata/model/workspace/User.java | 213 +-
.../admin/services/cpi/IamAdminServices.java | 3083 +-
.../exception/IamAdminServicesException.java | 124 +-
.../cpi/iam_admin_services_cpiConstants.java | 35 +-
.../tenant/cpi/TenantProfileService.java | 2356 +-
.../TenantProfileServiceException.java | 124 +-
.../tenant/cpi/profile_tenant_cpiConstants.java | 35 +-
.../profile/user/cpi/UserProfileService.java | 1870 +-
.../exception/UserProfileServiceException.java | 124 +-
.../user/cpi/profile_user_cpiConstants.java | 35 +-
.../store/cpi/CredentialStoreService.java | 4191 +-
.../cpi/credential_store_cpiConstants.java | 52 +-
.../exception/CredentialStoreException.java | 143 +-
.../apache/airavata/gfac/cpi/GfacService.java | 867 +-
.../airavata/gfac/cpi/gfac_cpiConstants.java | 52 +-
.../orchestrator/cpi/OrchestratorService.java | 1666 +-
.../cpi/orchestrator_cpiConstants.java | 52 +-
.../airavata/registry/api/RegistryService.java | 41472 +++---
.../api/exception/RegistryServiceException.java | 143 +-
.../registry/api/registry_apiConstants.java | 52 +-
.../sharing/registry/models/Domain.java | 192 +-
.../models/DuplicateEntryException.java | 124 +-
.../sharing/registry/models/Entity.java | 364 +-
.../registry/models/EntitySearchField.java | 2 +-
.../sharing/registry/models/EntityType.java | 209 +-
.../registry/models/GroupCardinality.java | 2 +-
.../sharing/registry/models/GroupChildType.java | 6 +-
.../registry/models/GroupMembership.java | 201 +-
.../sharing/registry/models/GroupType.java | 2 +-
.../sharing/registry/models/PermissionType.java | 209 +-
.../registry/models/SearchCondition.java | 2 +-
.../sharing/registry/models/SearchCriteria.java | 142 +-
.../sharing/registry/models/Sharing.java | 235 +-
.../models/SharingRegistryException.java | 124 +-
.../sharing/registry/models/SharingType.java | 2 +-
.../airavata/sharing/registry/models/User.java | 266 +-
.../sharing/registry/models/UserGroup.java | 244 +-
.../models/sharing_modelsConstants.java | 33 +-
.../service/cpi/SharingRegistryService.java | 14572 +--
pom.xml | 2 +-
.../component-cpis/generate-cpi-stubs.sh | 103 +-
.../generate-thrift-stubs.sh | 44 +-
.../service-cpis/generate-service-cpi-stubs.sh | 16 +-
305 files changed, 156366 insertions(+), 163612 deletions(-)
----------------------------------------------------------------------
[15/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/userresourceprofile/UserResourceProfile.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/userresourceprofile/UserResourceProfile.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/userresourceprofile/UserResourceProfile.java
index 5ac614d..d738b5f 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/userresourceprofile/UserResourceProfile.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/userresourceprofile/UserResourceProfile.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.userresourceprofile;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* User Resource Profile
*
@@ -74,7 +47,7 @@ import org.slf4j.LoggerFactory;
* Indicates that this instance is just a container for a null value.
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class UserResourceProfile implements org.apache.thrift.TBase<UserResourceProfile, UserResourceProfile._Fields>, java.io.Serializable, Cloneable, Comparable<UserResourceProfile> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("UserResourceProfile");
@@ -87,19 +60,16 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
private static final org.apache.thrift.protocol.TField IDENTITY_SERVER_PWD_CRED_TOKEN_FIELD_DESC = new org.apache.thrift.protocol.TField("identityServerPwdCredToken", org.apache.thrift.protocol.TType.STRING, (short)7);
private static final org.apache.thrift.protocol.TField IS_NULL_FIELD_DESC = new org.apache.thrift.protocol.TField("isNull", org.apache.thrift.protocol.TType.BOOL, (short)8);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new UserResourceProfileStandardSchemeFactory());
- schemes.put(TupleScheme.class, new UserResourceProfileTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new UserResourceProfileStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new UserResourceProfileTupleSchemeFactory();
- private String userId; // required
- private String gatewayID; // required
- private String credentialStoreToken; // optional
- private List<UserComputeResourcePreference> userComputeResourcePreferences; // optional
- private List<UserStoragePreference> userStoragePreferences; // optional
- private String identityServerTenant; // optional
- private String identityServerPwdCredToken; // optional
+ private java.lang.String userId; // required
+ private java.lang.String gatewayID; // required
+ private java.lang.String credentialStoreToken; // optional
+ private java.util.List<UserComputeResourcePreference> userComputeResourcePreferences; // optional
+ private java.util.List<UserStoragePreference> userStoragePreferences; // optional
+ private java.lang.String identityServerTenant; // optional
+ private java.lang.String identityServerPwdCredToken; // optional
private boolean isNull; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
@@ -113,10 +83,10 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
IDENTITY_SERVER_PWD_CRED_TOKEN((short)7, "identityServerPwdCredToken"),
IS_NULL((short)8, "isNull");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -153,21 +123,21 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -176,7 +146,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -185,9 +155,9 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
private static final int __ISNULL_ISSET_ID = 0;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.CREDENTIAL_STORE_TOKEN,_Fields.USER_COMPUTE_RESOURCE_PREFERENCES,_Fields.USER_STORAGE_PREFERENCES,_Fields.IDENTITY_SERVER_TENANT,_Fields.IDENTITY_SERVER_PWD_CRED_TOKEN,_Fields.IS_NULL};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.USER_ID, new org.apache.thrift.meta_data.FieldMetaData("userId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.GATEWAY_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayID", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -206,7 +176,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.IS_NULL, new org.apache.thrift.meta_data.FieldMetaData("isNull", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(UserResourceProfile.class, metaDataMap);
}
@@ -216,8 +186,8 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
}
public UserResourceProfile(
- String userId,
- String gatewayID)
+ java.lang.String userId,
+ java.lang.String gatewayID)
{
this();
this.userId = userId;
@@ -239,14 +209,14 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
this.credentialStoreToken = other.credentialStoreToken;
}
if (other.isSetUserComputeResourcePreferences()) {
- List<UserComputeResourcePreference> __this__userComputeResourcePreferences = new ArrayList<UserComputeResourcePreference>(other.userComputeResourcePreferences.size());
+ java.util.List<UserComputeResourcePreference> __this__userComputeResourcePreferences = new java.util.ArrayList<UserComputeResourcePreference>(other.userComputeResourcePreferences.size());
for (UserComputeResourcePreference other_element : other.userComputeResourcePreferences) {
__this__userComputeResourcePreferences.add(new UserComputeResourcePreference(other_element));
}
this.userComputeResourcePreferences = __this__userComputeResourcePreferences;
}
if (other.isSetUserStoragePreferences()) {
- List<UserStoragePreference> __this__userStoragePreferences = new ArrayList<UserStoragePreference>(other.userStoragePreferences.size());
+ java.util.List<UserStoragePreference> __this__userStoragePreferences = new java.util.ArrayList<UserStoragePreference>(other.userStoragePreferences.size());
for (UserStoragePreference other_element : other.userStoragePreferences) {
__this__userStoragePreferences.add(new UserStoragePreference(other_element));
}
@@ -278,11 +248,11 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
}
- public String getUserId() {
+ public java.lang.String getUserId() {
return this.userId;
}
- public void setUserId(String userId) {
+ public void setUserId(java.lang.String userId) {
this.userId = userId;
}
@@ -301,11 +271,11 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
}
}
- public String getGatewayID() {
+ public java.lang.String getGatewayID() {
return this.gatewayID;
}
- public void setGatewayID(String gatewayID) {
+ public void setGatewayID(java.lang.String gatewayID) {
this.gatewayID = gatewayID;
}
@@ -324,11 +294,11 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
}
}
- public String getCredentialStoreToken() {
+ public java.lang.String getCredentialStoreToken() {
return this.credentialStoreToken;
}
- public void setCredentialStoreToken(String credentialStoreToken) {
+ public void setCredentialStoreToken(java.lang.String credentialStoreToken) {
this.credentialStoreToken = credentialStoreToken;
}
@@ -357,16 +327,16 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
public void addToUserComputeResourcePreferences(UserComputeResourcePreference elem) {
if (this.userComputeResourcePreferences == null) {
- this.userComputeResourcePreferences = new ArrayList<UserComputeResourcePreference>();
+ this.userComputeResourcePreferences = new java.util.ArrayList<UserComputeResourcePreference>();
}
this.userComputeResourcePreferences.add(elem);
}
- public List<UserComputeResourcePreference> getUserComputeResourcePreferences() {
+ public java.util.List<UserComputeResourcePreference> getUserComputeResourcePreferences() {
return this.userComputeResourcePreferences;
}
- public void setUserComputeResourcePreferences(List<UserComputeResourcePreference> userComputeResourcePreferences) {
+ public void setUserComputeResourcePreferences(java.util.List<UserComputeResourcePreference> userComputeResourcePreferences) {
this.userComputeResourcePreferences = userComputeResourcePreferences;
}
@@ -395,16 +365,16 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
public void addToUserStoragePreferences(UserStoragePreference elem) {
if (this.userStoragePreferences == null) {
- this.userStoragePreferences = new ArrayList<UserStoragePreference>();
+ this.userStoragePreferences = new java.util.ArrayList<UserStoragePreference>();
}
this.userStoragePreferences.add(elem);
}
- public List<UserStoragePreference> getUserStoragePreferences() {
+ public java.util.List<UserStoragePreference> getUserStoragePreferences() {
return this.userStoragePreferences;
}
- public void setUserStoragePreferences(List<UserStoragePreference> userStoragePreferences) {
+ public void setUserStoragePreferences(java.util.List<UserStoragePreference> userStoragePreferences) {
this.userStoragePreferences = userStoragePreferences;
}
@@ -423,11 +393,11 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
}
}
- public String getIdentityServerTenant() {
+ public java.lang.String getIdentityServerTenant() {
return this.identityServerTenant;
}
- public void setIdentityServerTenant(String identityServerTenant) {
+ public void setIdentityServerTenant(java.lang.String identityServerTenant) {
this.identityServerTenant = identityServerTenant;
}
@@ -446,11 +416,11 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
}
}
- public String getIdentityServerPwdCredToken() {
+ public java.lang.String getIdentityServerPwdCredToken() {
return this.identityServerPwdCredToken;
}
- public void setIdentityServerPwdCredToken(String identityServerPwdCredToken) {
+ public void setIdentityServerPwdCredToken(java.lang.String identityServerPwdCredToken) {
this.identityServerPwdCredToken = identityServerPwdCredToken;
}
@@ -479,25 +449,25 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
}
public void unsetIsNull() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ISNULL_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ISNULL_ISSET_ID);
}
/** Returns true if field isNull is set (has been assigned a value) and false otherwise */
public boolean isSetIsNull() {
- return EncodingUtils.testBit(__isset_bitfield, __ISNULL_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ISNULL_ISSET_ID);
}
public void setIsNullIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ISNULL_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ISNULL_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case USER_ID:
if (value == null) {
unsetUserId();
} else {
- setUserId((String)value);
+ setUserId((java.lang.String)value);
}
break;
@@ -505,7 +475,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
if (value == null) {
unsetGatewayID();
} else {
- setGatewayID((String)value);
+ setGatewayID((java.lang.String)value);
}
break;
@@ -513,7 +483,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
if (value == null) {
unsetCredentialStoreToken();
} else {
- setCredentialStoreToken((String)value);
+ setCredentialStoreToken((java.lang.String)value);
}
break;
@@ -521,7 +491,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
if (value == null) {
unsetUserComputeResourcePreferences();
} else {
- setUserComputeResourcePreferences((List<UserComputeResourcePreference>)value);
+ setUserComputeResourcePreferences((java.util.List<UserComputeResourcePreference>)value);
}
break;
@@ -529,7 +499,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
if (value == null) {
unsetUserStoragePreferences();
} else {
- setUserStoragePreferences((List<UserStoragePreference>)value);
+ setUserStoragePreferences((java.util.List<UserStoragePreference>)value);
}
break;
@@ -537,7 +507,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
if (value == null) {
unsetIdentityServerTenant();
} else {
- setIdentityServerTenant((String)value);
+ setIdentityServerTenant((java.lang.String)value);
}
break;
@@ -545,7 +515,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
if (value == null) {
unsetIdentityServerPwdCredToken();
} else {
- setIdentityServerPwdCredToken((String)value);
+ setIdentityServerPwdCredToken((java.lang.String)value);
}
break;
@@ -553,14 +523,14 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
if (value == null) {
unsetIsNull();
} else {
- setIsNull((Boolean)value);
+ setIsNull((java.lang.Boolean)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case USER_ID:
return getUserId();
@@ -587,13 +557,13 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
return isIsNull();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -614,11 +584,11 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
case IS_NULL:
return isSetIsNull();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof UserResourceProfile)
@@ -629,6 +599,8 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
public boolean equals(UserResourceProfile that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_userId = true && this.isSetUserId();
boolean that_present_userId = true && that.isSetUserId();
@@ -707,49 +679,41 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_userId = true && (isSetUserId());
- list.add(present_userId);
- if (present_userId)
- list.add(userId);
+ hashCode = hashCode * 8191 + ((isSetUserId()) ? 131071 : 524287);
+ if (isSetUserId())
+ hashCode = hashCode * 8191 + userId.hashCode();
- boolean present_gatewayID = true && (isSetGatewayID());
- list.add(present_gatewayID);
- if (present_gatewayID)
- list.add(gatewayID);
+ hashCode = hashCode * 8191 + ((isSetGatewayID()) ? 131071 : 524287);
+ if (isSetGatewayID())
+ hashCode = hashCode * 8191 + gatewayID.hashCode();
- boolean present_credentialStoreToken = true && (isSetCredentialStoreToken());
- list.add(present_credentialStoreToken);
- if (present_credentialStoreToken)
- list.add(credentialStoreToken);
+ hashCode = hashCode * 8191 + ((isSetCredentialStoreToken()) ? 131071 : 524287);
+ if (isSetCredentialStoreToken())
+ hashCode = hashCode * 8191 + credentialStoreToken.hashCode();
- boolean present_userComputeResourcePreferences = true && (isSetUserComputeResourcePreferences());
- list.add(present_userComputeResourcePreferences);
- if (present_userComputeResourcePreferences)
- list.add(userComputeResourcePreferences);
+ hashCode = hashCode * 8191 + ((isSetUserComputeResourcePreferences()) ? 131071 : 524287);
+ if (isSetUserComputeResourcePreferences())
+ hashCode = hashCode * 8191 + userComputeResourcePreferences.hashCode();
- boolean present_userStoragePreferences = true && (isSetUserStoragePreferences());
- list.add(present_userStoragePreferences);
- if (present_userStoragePreferences)
- list.add(userStoragePreferences);
+ hashCode = hashCode * 8191 + ((isSetUserStoragePreferences()) ? 131071 : 524287);
+ if (isSetUserStoragePreferences())
+ hashCode = hashCode * 8191 + userStoragePreferences.hashCode();
- boolean present_identityServerTenant = true && (isSetIdentityServerTenant());
- list.add(present_identityServerTenant);
- if (present_identityServerTenant)
- list.add(identityServerTenant);
+ hashCode = hashCode * 8191 + ((isSetIdentityServerTenant()) ? 131071 : 524287);
+ if (isSetIdentityServerTenant())
+ hashCode = hashCode * 8191 + identityServerTenant.hashCode();
- boolean present_identityServerPwdCredToken = true && (isSetIdentityServerPwdCredToken());
- list.add(present_identityServerPwdCredToken);
- if (present_identityServerPwdCredToken)
- list.add(identityServerPwdCredToken);
+ hashCode = hashCode * 8191 + ((isSetIdentityServerPwdCredToken()) ? 131071 : 524287);
+ if (isSetIdentityServerPwdCredToken())
+ hashCode = hashCode * 8191 + identityServerPwdCredToken.hashCode();
- boolean present_isNull = true && (isSetIsNull());
- list.add(present_isNull);
- if (present_isNull)
- list.add(isNull);
+ hashCode = hashCode * 8191 + ((isSetIsNull()) ? 131071 : 524287);
+ if (isSetIsNull())
+ hashCode = hashCode * 8191 + ((isNull) ? 131071 : 524287);
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -760,7 +724,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetUserId()).compareTo(other.isSetUserId());
+ lastComparison = java.lang.Boolean.valueOf(isSetUserId()).compareTo(other.isSetUserId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -770,7 +734,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetGatewayID()).compareTo(other.isSetGatewayID());
+ lastComparison = java.lang.Boolean.valueOf(isSetGatewayID()).compareTo(other.isSetGatewayID());
if (lastComparison != 0) {
return lastComparison;
}
@@ -780,7 +744,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCredentialStoreToken()).compareTo(other.isSetCredentialStoreToken());
+ lastComparison = java.lang.Boolean.valueOf(isSetCredentialStoreToken()).compareTo(other.isSetCredentialStoreToken());
if (lastComparison != 0) {
return lastComparison;
}
@@ -790,7 +754,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUserComputeResourcePreferences()).compareTo(other.isSetUserComputeResourcePreferences());
+ lastComparison = java.lang.Boolean.valueOf(isSetUserComputeResourcePreferences()).compareTo(other.isSetUserComputeResourcePreferences());
if (lastComparison != 0) {
return lastComparison;
}
@@ -800,7 +764,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUserStoragePreferences()).compareTo(other.isSetUserStoragePreferences());
+ lastComparison = java.lang.Boolean.valueOf(isSetUserStoragePreferences()).compareTo(other.isSetUserStoragePreferences());
if (lastComparison != 0) {
return lastComparison;
}
@@ -810,7 +774,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetIdentityServerTenant()).compareTo(other.isSetIdentityServerTenant());
+ lastComparison = java.lang.Boolean.valueOf(isSetIdentityServerTenant()).compareTo(other.isSetIdentityServerTenant());
if (lastComparison != 0) {
return lastComparison;
}
@@ -820,7 +784,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetIdentityServerPwdCredToken()).compareTo(other.isSetIdentityServerPwdCredToken());
+ lastComparison = java.lang.Boolean.valueOf(isSetIdentityServerPwdCredToken()).compareTo(other.isSetIdentityServerPwdCredToken());
if (lastComparison != 0) {
return lastComparison;
}
@@ -830,7 +794,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetIsNull()).compareTo(other.isSetIsNull());
+ lastComparison = java.lang.Boolean.valueOf(isSetIsNull()).compareTo(other.isSetIsNull());
if (lastComparison != 0) {
return lastComparison;
}
@@ -848,16 +812,16 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("UserResourceProfile(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("UserResourceProfile(");
boolean first = true;
sb.append("userId:");
@@ -956,7 +920,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -966,13 +930,13 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
}
}
- private static class UserResourceProfileStandardSchemeFactory implements SchemeFactory {
+ private static class UserResourceProfileStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public UserResourceProfileStandardScheme getScheme() {
return new UserResourceProfileStandardScheme();
}
}
- private static class UserResourceProfileStandardScheme extends StandardScheme<UserResourceProfile> {
+ private static class UserResourceProfileStandardScheme extends org.apache.thrift.scheme.StandardScheme<UserResourceProfile> {
public void read(org.apache.thrift.protocol.TProtocol iprot, UserResourceProfile struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1012,7 +976,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list0 = iprot.readListBegin();
- struct.userComputeResourcePreferences = new ArrayList<UserComputeResourcePreference>(_list0.size);
+ struct.userComputeResourcePreferences = new java.util.ArrayList<UserComputeResourcePreference>(_list0.size);
UserComputeResourcePreference _elem1;
for (int _i2 = 0; _i2 < _list0.size; ++_i2)
{
@@ -1031,7 +995,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list3 = iprot.readListBegin();
- struct.userStoragePreferences = new ArrayList<UserStoragePreference>(_list3.size);
+ struct.userStoragePreferences = new java.util.ArrayList<UserStoragePreference>(_list3.size);
UserStoragePreference _elem4;
for (int _i5 = 0; _i5 < _list3.size; ++_i5)
{
@@ -1153,20 +1117,20 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
}
- private static class UserResourceProfileTupleSchemeFactory implements SchemeFactory {
+ private static class UserResourceProfileTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public UserResourceProfileTupleScheme getScheme() {
return new UserResourceProfileTupleScheme();
}
}
- private static class UserResourceProfileTupleScheme extends TupleScheme<UserResourceProfile> {
+ private static class UserResourceProfileTupleScheme extends org.apache.thrift.scheme.TupleScheme<UserResourceProfile> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, UserResourceProfile struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.userId);
oprot.writeString(struct.gatewayID);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetCredentialStoreToken()) {
optionals.set(0);
}
@@ -1220,12 +1184,12 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, UserResourceProfile struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.userId = iprot.readString();
struct.setUserIdIsSet(true);
struct.gatewayID = iprot.readString();
struct.setGatewayIDIsSet(true);
- BitSet incoming = iprot.readBitSet(6);
+ java.util.BitSet incoming = iprot.readBitSet(6);
if (incoming.get(0)) {
struct.credentialStoreToken = iprot.readString();
struct.setCredentialStoreTokenIsSet(true);
@@ -1233,7 +1197,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
if (incoming.get(1)) {
{
org.apache.thrift.protocol.TList _list10 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.userComputeResourcePreferences = new ArrayList<UserComputeResourcePreference>(_list10.size);
+ struct.userComputeResourcePreferences = new java.util.ArrayList<UserComputeResourcePreference>(_list10.size);
UserComputeResourcePreference _elem11;
for (int _i12 = 0; _i12 < _list10.size; ++_i12)
{
@@ -1247,7 +1211,7 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
if (incoming.get(2)) {
{
org.apache.thrift.protocol.TList _list13 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.userStoragePreferences = new ArrayList<UserStoragePreference>(_list13.size);
+ struct.userStoragePreferences = new java.util.ArrayList<UserStoragePreference>(_list13.size);
UserStoragePreference _elem14;
for (int _i15 = 0; _i15 < _list13.size; ++_i15)
{
@@ -1273,5 +1237,8 @@ public class UserResourceProfile implements org.apache.thrift.TBase<UserResource
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/userresourceprofile/UserStoragePreference.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/userresourceprofile/UserStoragePreference.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/userresourceprofile/UserStoragePreference.java
index daa5df2..44a5fc3 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/userresourceprofile/UserStoragePreference.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/userresourceprofile/UserStoragePreference.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.userresourceprofile;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class UserStoragePreference implements org.apache.thrift.TBase<UserStoragePreference, UserStoragePreference._Fields>, java.io.Serializable, Cloneable, Comparable<UserStoragePreference> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("UserStoragePreference");
@@ -60,16 +33,13 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
private static final org.apache.thrift.protocol.TField FILE_SYSTEM_ROOT_LOCATION_FIELD_DESC = new org.apache.thrift.protocol.TField("fileSystemRootLocation", org.apache.thrift.protocol.TType.STRING, (short)3);
private static final org.apache.thrift.protocol.TField RESOURCE_SPECIFIC_CREDENTIAL_STORE_TOKEN_FIELD_DESC = new org.apache.thrift.protocol.TField("resourceSpecificCredentialStoreToken", 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 UserStoragePreferenceStandardSchemeFactory());
- schemes.put(TupleScheme.class, new UserStoragePreferenceTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new UserStoragePreferenceStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new UserStoragePreferenceTupleSchemeFactory();
- private String storageResourceId; // required
- private String loginUserName; // optional
- private String fileSystemRootLocation; // optional
- private String resourceSpecificCredentialStoreToken; // optional
+ private java.lang.String storageResourceId; // required
+ private java.lang.String loginUserName; // optional
+ private java.lang.String fileSystemRootLocation; // optional
+ private java.lang.String resourceSpecificCredentialStoreToken; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -78,10 +48,10 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
FILE_SYSTEM_ROOT_LOCATION((short)3, "fileSystemRootLocation"),
RESOURCE_SPECIFIC_CREDENTIAL_STORE_TOKEN((short)4, "resourceSpecificCredentialStoreToken");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -110,21 +80,21 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -133,16 +103,16 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
private static final _Fields optionals[] = {_Fields.LOGIN_USER_NAME,_Fields.FILE_SYSTEM_ROOT_LOCATION,_Fields.RESOURCE_SPECIFIC_CREDENTIAL_STORE_TOKEN};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.STORAGE_RESOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("storageResourceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.LOGIN_USER_NAME, new org.apache.thrift.meta_data.FieldMetaData("loginUserName", org.apache.thrift.TFieldRequirementType.OPTIONAL,
@@ -151,7 +121,7 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.RESOURCE_SPECIFIC_CREDENTIAL_STORE_TOKEN, new org.apache.thrift.meta_data.FieldMetaData("resourceSpecificCredentialStoreToken", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(UserStoragePreference.class, metaDataMap);
}
@@ -159,7 +129,7 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
}
public UserStoragePreference(
- String storageResourceId)
+ java.lang.String storageResourceId)
{
this();
this.storageResourceId = storageResourceId;
@@ -195,11 +165,11 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
this.resourceSpecificCredentialStoreToken = null;
}
- public String getStorageResourceId() {
+ public java.lang.String getStorageResourceId() {
return this.storageResourceId;
}
- public void setStorageResourceId(String storageResourceId) {
+ public void setStorageResourceId(java.lang.String storageResourceId) {
this.storageResourceId = storageResourceId;
}
@@ -218,11 +188,11 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
}
}
- public String getLoginUserName() {
+ public java.lang.String getLoginUserName() {
return this.loginUserName;
}
- public void setLoginUserName(String loginUserName) {
+ public void setLoginUserName(java.lang.String loginUserName) {
this.loginUserName = loginUserName;
}
@@ -241,11 +211,11 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
}
}
- public String getFileSystemRootLocation() {
+ public java.lang.String getFileSystemRootLocation() {
return this.fileSystemRootLocation;
}
- public void setFileSystemRootLocation(String fileSystemRootLocation) {
+ public void setFileSystemRootLocation(java.lang.String fileSystemRootLocation) {
this.fileSystemRootLocation = fileSystemRootLocation;
}
@@ -264,11 +234,11 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
}
}
- public String getResourceSpecificCredentialStoreToken() {
+ public java.lang.String getResourceSpecificCredentialStoreToken() {
return this.resourceSpecificCredentialStoreToken;
}
- public void setResourceSpecificCredentialStoreToken(String resourceSpecificCredentialStoreToken) {
+ public void setResourceSpecificCredentialStoreToken(java.lang.String resourceSpecificCredentialStoreToken) {
this.resourceSpecificCredentialStoreToken = resourceSpecificCredentialStoreToken;
}
@@ -287,13 +257,13 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case STORAGE_RESOURCE_ID:
if (value == null) {
unsetStorageResourceId();
} else {
- setStorageResourceId((String)value);
+ setStorageResourceId((java.lang.String)value);
}
break;
@@ -301,7 +271,7 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
if (value == null) {
unsetLoginUserName();
} else {
- setLoginUserName((String)value);
+ setLoginUserName((java.lang.String)value);
}
break;
@@ -309,7 +279,7 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
if (value == null) {
unsetFileSystemRootLocation();
} else {
- setFileSystemRootLocation((String)value);
+ setFileSystemRootLocation((java.lang.String)value);
}
break;
@@ -317,14 +287,14 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
if (value == null) {
unsetResourceSpecificCredentialStoreToken();
} else {
- setResourceSpecificCredentialStoreToken((String)value);
+ setResourceSpecificCredentialStoreToken((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case STORAGE_RESOURCE_ID:
return getStorageResourceId();
@@ -339,13 +309,13 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
return getResourceSpecificCredentialStoreToken();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -358,11 +328,11 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
case RESOURCE_SPECIFIC_CREDENTIAL_STORE_TOKEN:
return isSetResourceSpecificCredentialStoreToken();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof UserStoragePreference)
@@ -373,6 +343,8 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
public boolean equals(UserStoragePreference that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_storageResourceId = true && this.isSetStorageResourceId();
boolean that_present_storageResourceId = true && that.isSetStorageResourceId();
@@ -415,29 +387,25 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_storageResourceId = true && (isSetStorageResourceId());
- list.add(present_storageResourceId);
- if (present_storageResourceId)
- list.add(storageResourceId);
+ hashCode = hashCode * 8191 + ((isSetStorageResourceId()) ? 131071 : 524287);
+ if (isSetStorageResourceId())
+ hashCode = hashCode * 8191 + storageResourceId.hashCode();
- boolean present_loginUserName = true && (isSetLoginUserName());
- list.add(present_loginUserName);
- if (present_loginUserName)
- list.add(loginUserName);
+ hashCode = hashCode * 8191 + ((isSetLoginUserName()) ? 131071 : 524287);
+ if (isSetLoginUserName())
+ hashCode = hashCode * 8191 + loginUserName.hashCode();
- boolean present_fileSystemRootLocation = true && (isSetFileSystemRootLocation());
- list.add(present_fileSystemRootLocation);
- if (present_fileSystemRootLocation)
- list.add(fileSystemRootLocation);
+ hashCode = hashCode * 8191 + ((isSetFileSystemRootLocation()) ? 131071 : 524287);
+ if (isSetFileSystemRootLocation())
+ hashCode = hashCode * 8191 + fileSystemRootLocation.hashCode();
- boolean present_resourceSpecificCredentialStoreToken = true && (isSetResourceSpecificCredentialStoreToken());
- list.add(present_resourceSpecificCredentialStoreToken);
- if (present_resourceSpecificCredentialStoreToken)
- list.add(resourceSpecificCredentialStoreToken);
+ hashCode = hashCode * 8191 + ((isSetResourceSpecificCredentialStoreToken()) ? 131071 : 524287);
+ if (isSetResourceSpecificCredentialStoreToken())
+ hashCode = hashCode * 8191 + resourceSpecificCredentialStoreToken.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -448,7 +416,7 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetStorageResourceId()).compareTo(other.isSetStorageResourceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetStorageResourceId()).compareTo(other.isSetStorageResourceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -458,7 +426,7 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetLoginUserName()).compareTo(other.isSetLoginUserName());
+ lastComparison = java.lang.Boolean.valueOf(isSetLoginUserName()).compareTo(other.isSetLoginUserName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -468,7 +436,7 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetFileSystemRootLocation()).compareTo(other.isSetFileSystemRootLocation());
+ lastComparison = java.lang.Boolean.valueOf(isSetFileSystemRootLocation()).compareTo(other.isSetFileSystemRootLocation());
if (lastComparison != 0) {
return lastComparison;
}
@@ -478,7 +446,7 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetResourceSpecificCredentialStoreToken()).compareTo(other.isSetResourceSpecificCredentialStoreToken());
+ lastComparison = java.lang.Boolean.valueOf(isSetResourceSpecificCredentialStoreToken()).compareTo(other.isSetResourceSpecificCredentialStoreToken());
if (lastComparison != 0) {
return lastComparison;
}
@@ -496,16 +464,16 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("UserStoragePreference(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("UserStoragePreference(");
boolean first = true;
sb.append("storageResourceId:");
@@ -566,7 +534,7 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -574,13 +542,13 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
}
}
- private static class UserStoragePreferenceStandardSchemeFactory implements SchemeFactory {
+ private static class UserStoragePreferenceStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public UserStoragePreferenceStandardScheme getScheme() {
return new UserStoragePreferenceStandardScheme();
}
}
- private static class UserStoragePreferenceStandardScheme extends StandardScheme<UserStoragePreference> {
+ private static class UserStoragePreferenceStandardScheme extends org.apache.thrift.scheme.StandardScheme<UserStoragePreference> {
public void read(org.apache.thrift.protocol.TProtocol iprot, UserStoragePreference struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -669,19 +637,19 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
}
- private static class UserStoragePreferenceTupleSchemeFactory implements SchemeFactory {
+ private static class UserStoragePreferenceTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public UserStoragePreferenceTupleScheme getScheme() {
return new UserStoragePreferenceTupleScheme();
}
}
- private static class UserStoragePreferenceTupleScheme extends TupleScheme<UserStoragePreference> {
+ private static class UserStoragePreferenceTupleScheme extends org.apache.thrift.scheme.TupleScheme<UserStoragePreference> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, UserStoragePreference struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.storageResourceId);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetLoginUserName()) {
optionals.set(0);
}
@@ -705,10 +673,10 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, UserStoragePreference struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.storageResourceId = iprot.readString();
struct.setStorageResourceIdIsSet(true);
- BitSet incoming = iprot.readBitSet(3);
+ java.util.BitSet incoming = iprot.readBitSet(3);
if (incoming.get(0)) {
struct.loginUserName = iprot.readString();
struct.setLoginUserNameIsSet(true);
@@ -724,5 +692,8 @@ public class UserStoragePreference implements org.apache.thrift.TBase<UserStorag
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/application/io/DataType.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/application/io/DataType.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/application/io/DataType.java
index 8bef839..565f03d 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/application/io/DataType.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/application/io/DataType.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
[35/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/messaging/event/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/messaging/event/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/messaging/event/ttypes.py
index 42e9da4..a5224ec 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/messaging/event/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/messaging/event/ttypes.py
@@ -1,1514 +1,1407 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.status.ttypes
import apache.airavata.model.application.io.ttypes
import apache.airavata.model.commons.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class MessageLevel:
- INFO = 0
- DEBUG = 1
- ERROR = 2
- ACK = 3
-
- _VALUES_TO_NAMES = {
- 0: "INFO",
- 1: "DEBUG",
- 2: "ERROR",
- 3: "ACK",
- }
-
- _NAMES_TO_VALUES = {
- "INFO": 0,
- "DEBUG": 1,
- "ERROR": 2,
- "ACK": 3,
- }
-
-class MessageType:
- EXPERIMENT = 0
- EXPERIMENT_CANCEL = 1
- TASK = 2
- PROCESS = 3
- JOB = 4
- LAUNCHPROCESS = 5
- TERMINATEPROCESS = 6
- PROCESSOUTPUT = 7
- DB_EVENT = 8
-
- _VALUES_TO_NAMES = {
- 0: "EXPERIMENT",
- 1: "EXPERIMENT_CANCEL",
- 2: "TASK",
- 3: "PROCESS",
- 4: "JOB",
- 5: "LAUNCHPROCESS",
- 6: "TERMINATEPROCESS",
- 7: "PROCESSOUTPUT",
- 8: "DB_EVENT",
- }
-
- _NAMES_TO_VALUES = {
- "EXPERIMENT": 0,
- "EXPERIMENT_CANCEL": 1,
- "TASK": 2,
- "PROCESS": 3,
- "JOB": 4,
- "LAUNCHPROCESS": 5,
- "TERMINATEPROCESS": 6,
- "PROCESSOUTPUT": 7,
- "DB_EVENT": 8,
- }
-
-
-class ExperimentStatusChangeEvent:
- """
- Attributes:
- - state
- - experimentId
- - gatewayId
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'state', None, None, ), # 1
- (2, TType.STRING, 'experimentId', None, None, ), # 2
- (3, TType.STRING, 'gatewayId', None, None, ), # 3
- )
-
- def __init__(self, state=None, experimentId=None, gatewayId=None,):
- self.state = state
- self.experimentId = experimentId
- self.gatewayId = gatewayId
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.state = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.experimentId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ExperimentStatusChangeEvent')
- if self.state is not None:
- oprot.writeFieldBegin('state', TType.I32, 1)
- oprot.writeI32(self.state)
- oprot.writeFieldEnd()
- if self.experimentId is not None:
- oprot.writeFieldBegin('experimentId', TType.STRING, 2)
- oprot.writeString(self.experimentId)
- oprot.writeFieldEnd()
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 3)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.state is None:
- raise TProtocol.TProtocolException(message='Required field state is unset!')
- if self.experimentId is None:
- raise TProtocol.TProtocolException(message='Required field experimentId is unset!')
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.state)
- value = (value * 31) ^ hash(self.experimentId)
- value = (value * 31) ^ hash(self.gatewayId)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ProcessIdentifier:
- """
- Attributes:
- - processId
- - experimentId
- - gatewayId
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'processId', None, None, ), # 1
- (2, TType.STRING, 'experimentId', None, None, ), # 2
- (3, TType.STRING, 'gatewayId', None, None, ), # 3
- )
-
- def __init__(self, processId=None, experimentId=None, gatewayId=None,):
- self.processId = processId
- self.experimentId = experimentId
- self.gatewayId = gatewayId
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.processId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.experimentId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ProcessIdentifier')
- if self.processId is not None:
- oprot.writeFieldBegin('processId', TType.STRING, 1)
- oprot.writeString(self.processId)
- oprot.writeFieldEnd()
- if self.experimentId is not None:
- oprot.writeFieldBegin('experimentId', TType.STRING, 2)
- oprot.writeString(self.experimentId)
- oprot.writeFieldEnd()
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 3)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.processId is None:
- raise TProtocol.TProtocolException(message='Required field processId is unset!')
- if self.experimentId is None:
- raise TProtocol.TProtocolException(message='Required field experimentId is unset!')
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.processId)
- value = (value * 31) ^ hash(self.experimentId)
- value = (value * 31) ^ hash(self.gatewayId)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class TaskIdentifier:
- """
- Attributes:
- - taskId
- - processId
- - experimentId
- - gatewayId
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'taskId', None, None, ), # 1
- (2, TType.STRING, 'processId', None, None, ), # 2
- (3, TType.STRING, 'experimentId', None, None, ), # 3
- (4, TType.STRING, 'gatewayId', None, None, ), # 4
- )
-
- def __init__(self, taskId=None, processId=None, experimentId=None, gatewayId=None,):
- self.taskId = taskId
- self.processId = processId
- self.experimentId = experimentId
- self.gatewayId = gatewayId
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.taskId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.processId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.experimentId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('TaskIdentifier')
- if self.taskId is not None:
- oprot.writeFieldBegin('taskId', TType.STRING, 1)
- oprot.writeString(self.taskId)
- oprot.writeFieldEnd()
- if self.processId is not None:
- oprot.writeFieldBegin('processId', TType.STRING, 2)
- oprot.writeString(self.processId)
- oprot.writeFieldEnd()
- if self.experimentId is not None:
- oprot.writeFieldBegin('experimentId', TType.STRING, 3)
- oprot.writeString(self.experimentId)
- oprot.writeFieldEnd()
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 4)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.taskId is None:
- raise TProtocol.TProtocolException(message='Required field taskId is unset!')
- if self.processId is None:
- raise TProtocol.TProtocolException(message='Required field processId is unset!')
- if self.experimentId is None:
- raise TProtocol.TProtocolException(message='Required field experimentId is unset!')
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.taskId)
- value = (value * 31) ^ hash(self.processId)
- value = (value * 31) ^ hash(self.experimentId)
- value = (value * 31) ^ hash(self.gatewayId)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class TaskStatusChangeEvent:
- """
- Attributes:
- - state
- - taskIdentity
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'state', None, None, ), # 1
- (2, TType.STRUCT, 'taskIdentity', (TaskIdentifier, TaskIdentifier.thrift_spec), None, ), # 2
- )
-
- def __init__(self, state=None, taskIdentity=None,):
- self.state = state
- self.taskIdentity = taskIdentity
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.state = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRUCT:
- self.taskIdentity = TaskIdentifier()
- self.taskIdentity.read(iprot)
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('TaskStatusChangeEvent')
- if self.state is not None:
- oprot.writeFieldBegin('state', TType.I32, 1)
- oprot.writeI32(self.state)
- oprot.writeFieldEnd()
- if self.taskIdentity is not None:
- oprot.writeFieldBegin('taskIdentity', TType.STRUCT, 2)
- self.taskIdentity.write(oprot)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.state is None:
- raise TProtocol.TProtocolException(message='Required field state is unset!')
- if self.taskIdentity is None:
- raise TProtocol.TProtocolException(message='Required field taskIdentity is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.state)
- value = (value * 31) ^ hash(self.taskIdentity)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class TaskStatusChangeRequestEvent:
- """
- Attributes:
- - state
- - taskIdentity
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'state', None, None, ), # 1
- (2, TType.STRUCT, 'taskIdentity', (TaskIdentifier, TaskIdentifier.thrift_spec), None, ), # 2
- )
-
- def __init__(self, state=None, taskIdentity=None,):
- self.state = state
- self.taskIdentity = taskIdentity
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.state = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRUCT:
- self.taskIdentity = TaskIdentifier()
- self.taskIdentity.read(iprot)
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('TaskStatusChangeRequestEvent')
- if self.state is not None:
- oprot.writeFieldBegin('state', TType.I32, 1)
- oprot.writeI32(self.state)
- oprot.writeFieldEnd()
- if self.taskIdentity is not None:
- oprot.writeFieldBegin('taskIdentity', TType.STRUCT, 2)
- self.taskIdentity.write(oprot)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.state is None:
- raise TProtocol.TProtocolException(message='Required field state is unset!')
- if self.taskIdentity is None:
- raise TProtocol.TProtocolException(message='Required field taskIdentity is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.state)
- value = (value * 31) ^ hash(self.taskIdentity)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ProcessStatusChangeEvent:
- """
- Attributes:
- - state
- - processIdentity
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'state', None, None, ), # 1
- (2, TType.STRUCT, 'processIdentity', (ProcessIdentifier, ProcessIdentifier.thrift_spec), None, ), # 2
- )
-
- def __init__(self, state=None, processIdentity=None,):
- self.state = state
- self.processIdentity = processIdentity
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.state = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRUCT:
- self.processIdentity = ProcessIdentifier()
- self.processIdentity.read(iprot)
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ProcessStatusChangeEvent')
- if self.state is not None:
- oprot.writeFieldBegin('state', TType.I32, 1)
- oprot.writeI32(self.state)
- oprot.writeFieldEnd()
- if self.processIdentity is not None:
- oprot.writeFieldBegin('processIdentity', TType.STRUCT, 2)
- self.processIdentity.write(oprot)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.state is None:
- raise TProtocol.TProtocolException(message='Required field state is unset!')
- if self.processIdentity is None:
- raise TProtocol.TProtocolException(message='Required field processIdentity is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.state)
- value = (value * 31) ^ hash(self.processIdentity)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ProcessStatusChangeRequestEvent:
- """
- Attributes:
- - state
- - processIdentity
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'state', None, None, ), # 1
- (2, TType.STRUCT, 'processIdentity', (ProcessIdentifier, ProcessIdentifier.thrift_spec), None, ), # 2
- )
-
- def __init__(self, state=None, processIdentity=None,):
- self.state = state
- self.processIdentity = processIdentity
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.state = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRUCT:
- self.processIdentity = ProcessIdentifier()
- self.processIdentity.read(iprot)
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ProcessStatusChangeRequestEvent')
- if self.state is not None:
- oprot.writeFieldBegin('state', TType.I32, 1)
- oprot.writeI32(self.state)
- oprot.writeFieldEnd()
- if self.processIdentity is not None:
- oprot.writeFieldBegin('processIdentity', TType.STRUCT, 2)
- self.processIdentity.write(oprot)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.state is None:
- raise TProtocol.TProtocolException(message='Required field state is unset!')
- if self.processIdentity is None:
- raise TProtocol.TProtocolException(message='Required field processIdentity is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.state)
- value = (value * 31) ^ hash(self.processIdentity)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class TaskOutputChangeEvent:
- """
- Attributes:
- - output
- - taskIdentity
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.LIST, 'output', (TType.STRUCT,(apache.airavata.model.application.io.ttypes.OutputDataObjectType, apache.airavata.model.application.io.ttypes.OutputDataObjectType.thrift_spec)), None, ), # 1
- (2, TType.STRUCT, 'taskIdentity', (TaskIdentifier, TaskIdentifier.thrift_spec), None, ), # 2
- )
-
- def __init__(self, output=None, taskIdentity=None,):
- self.output = output
- self.taskIdentity = taskIdentity
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.LIST:
- self.output = []
- (_etype3, _size0) = iprot.readListBegin()
- for _i4 in xrange(_size0):
- _elem5 = apache.airavata.model.application.io.ttypes.OutputDataObjectType()
- _elem5.read(iprot)
- self.output.append(_elem5)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRUCT:
- self.taskIdentity = TaskIdentifier()
- self.taskIdentity.read(iprot)
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('TaskOutputChangeEvent')
- if self.output is not None:
- oprot.writeFieldBegin('output', TType.LIST, 1)
- oprot.writeListBegin(TType.STRUCT, len(self.output))
- for iter6 in self.output:
- iter6.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.taskIdentity is not None:
- oprot.writeFieldBegin('taskIdentity', TType.STRUCT, 2)
- self.taskIdentity.write(oprot)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.output is None:
- raise TProtocol.TProtocolException(message='Required field output is unset!')
- if self.taskIdentity is None:
- raise TProtocol.TProtocolException(message='Required field taskIdentity is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.output)
- value = (value * 31) ^ hash(self.taskIdentity)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class JobIdentifier:
- """
- Attributes:
- - jobId
- - taskId
- - processId
- - experimentId
- - gatewayId
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'jobId', None, None, ), # 1
- (2, TType.STRING, 'taskId', None, None, ), # 2
- (3, TType.STRING, 'processId', None, None, ), # 3
- (4, TType.STRING, 'experimentId', None, None, ), # 4
- (5, TType.STRING, 'gatewayId', None, None, ), # 5
- )
-
- def __init__(self, jobId=None, taskId=None, processId=None, experimentId=None, gatewayId=None,):
- self.jobId = jobId
- self.taskId = taskId
- self.processId = processId
- self.experimentId = experimentId
- self.gatewayId = gatewayId
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.jobId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.taskId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.processId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.experimentId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('JobIdentifier')
- if self.jobId is not None:
- oprot.writeFieldBegin('jobId', TType.STRING, 1)
- oprot.writeString(self.jobId)
- oprot.writeFieldEnd()
- if self.taskId is not None:
- oprot.writeFieldBegin('taskId', TType.STRING, 2)
- oprot.writeString(self.taskId)
- oprot.writeFieldEnd()
- if self.processId is not None:
- oprot.writeFieldBegin('processId', TType.STRING, 3)
- oprot.writeString(self.processId)
- oprot.writeFieldEnd()
- if self.experimentId is not None:
- oprot.writeFieldBegin('experimentId', TType.STRING, 4)
- oprot.writeString(self.experimentId)
- oprot.writeFieldEnd()
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 5)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.jobId is None:
- raise TProtocol.TProtocolException(message='Required field jobId is unset!')
- if self.taskId is None:
- raise TProtocol.TProtocolException(message='Required field taskId is unset!')
- if self.processId is None:
- raise TProtocol.TProtocolException(message='Required field processId is unset!')
- if self.experimentId is None:
- raise TProtocol.TProtocolException(message='Required field experimentId is unset!')
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.jobId)
- value = (value * 31) ^ hash(self.taskId)
- value = (value * 31) ^ hash(self.processId)
- value = (value * 31) ^ hash(self.experimentId)
- value = (value * 31) ^ hash(self.gatewayId)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ExperimentSubmitEvent:
- """
- Attributes:
- - experimentId
- - gatewayId
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'experimentId', None, None, ), # 1
- (2, TType.STRING, 'gatewayId', None, None, ), # 2
- )
-
- def __init__(self, experimentId=None, gatewayId=None,):
- self.experimentId = experimentId
- self.gatewayId = gatewayId
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.experimentId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ExperimentSubmitEvent')
- if self.experimentId is not None:
- oprot.writeFieldBegin('experimentId', TType.STRING, 1)
- oprot.writeString(self.experimentId)
- oprot.writeFieldEnd()
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 2)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.experimentId is None:
- raise TProtocol.TProtocolException(message='Required field experimentId is unset!')
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.experimentId)
- value = (value * 31) ^ hash(self.gatewayId)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ProcessSubmitEvent:
- """
- Attributes:
- - processId
- - gatewayId
- - experimentId
- - tokenId
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'processId', None, None, ), # 1
- (2, TType.STRING, 'gatewayId', None, None, ), # 2
- (3, TType.STRING, 'experimentId', None, None, ), # 3
- (4, TType.STRING, 'tokenId', None, None, ), # 4
- )
-
- def __init__(self, processId=None, gatewayId=None, experimentId=None, tokenId=None,):
- self.processId = processId
- self.gatewayId = gatewayId
- self.experimentId = experimentId
- self.tokenId = tokenId
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.processId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.experimentId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.tokenId = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ProcessSubmitEvent')
- if self.processId is not None:
- oprot.writeFieldBegin('processId', TType.STRING, 1)
- oprot.writeString(self.processId)
- oprot.writeFieldEnd()
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 2)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- if self.experimentId is not None:
- oprot.writeFieldBegin('experimentId', TType.STRING, 3)
- oprot.writeString(self.experimentId)
- oprot.writeFieldEnd()
- if self.tokenId is not None:
- oprot.writeFieldBegin('tokenId', TType.STRING, 4)
- oprot.writeString(self.tokenId)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.processId is None:
- raise TProtocol.TProtocolException(message='Required field processId is unset!')
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- if self.experimentId is None:
- raise TProtocol.TProtocolException(message='Required field experimentId is unset!')
- if self.tokenId is None:
- raise TProtocol.TProtocolException(message='Required field tokenId is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.processId)
- value = (value * 31) ^ hash(self.gatewayId)
- value = (value * 31) ^ hash(self.experimentId)
- value = (value * 31) ^ hash(self.tokenId)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ProcessTerminateEvent:
- """
- Attributes:
- - processId
- - gatewayId
- - tokenId
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'processId', None, None, ), # 1
- (2, TType.STRING, 'gatewayId', None, None, ), # 2
- (3, TType.STRING, 'tokenId', None, None, ), # 3
- )
-
- def __init__(self, processId=None, gatewayId=None, tokenId=None,):
- self.processId = processId
- self.gatewayId = gatewayId
- self.tokenId = tokenId
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.processId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.tokenId = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ProcessTerminateEvent')
- if self.processId is not None:
- oprot.writeFieldBegin('processId', TType.STRING, 1)
- oprot.writeString(self.processId)
- oprot.writeFieldEnd()
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 2)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- if self.tokenId is not None:
- oprot.writeFieldBegin('tokenId', TType.STRING, 3)
- oprot.writeString(self.tokenId)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.processId is None:
- raise TProtocol.TProtocolException(message='Required field processId is unset!')
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- if self.tokenId is None:
- raise TProtocol.TProtocolException(message='Required field tokenId is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.processId)
- value = (value * 31) ^ hash(self.gatewayId)
- value = (value * 31) ^ hash(self.tokenId)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class JobStatusChangeEvent:
- """
- Attributes:
- - state
- - jobIdentity
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'state', None, None, ), # 1
- (2, TType.STRUCT, 'jobIdentity', (JobIdentifier, JobIdentifier.thrift_spec), None, ), # 2
- )
-
- def __init__(self, state=None, jobIdentity=None,):
- self.state = state
- self.jobIdentity = jobIdentity
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.state = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRUCT:
- self.jobIdentity = JobIdentifier()
- self.jobIdentity.read(iprot)
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('JobStatusChangeEvent')
- if self.state is not None:
- oprot.writeFieldBegin('state', TType.I32, 1)
- oprot.writeI32(self.state)
- oprot.writeFieldEnd()
- if self.jobIdentity is not None:
- oprot.writeFieldBegin('jobIdentity', TType.STRUCT, 2)
- self.jobIdentity.write(oprot)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.state is None:
- raise TProtocol.TProtocolException(message='Required field state is unset!')
- if self.jobIdentity is None:
- raise TProtocol.TProtocolException(message='Required field jobIdentity is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.state)
- value = (value * 31) ^ hash(self.jobIdentity)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class JobStatusChangeRequestEvent:
- """
- Attributes:
- - state
- - jobIdentity
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'state', None, None, ), # 1
- (2, TType.STRUCT, 'jobIdentity', (JobIdentifier, JobIdentifier.thrift_spec), None, ), # 2
- )
-
- def __init__(self, state=None, jobIdentity=None,):
- self.state = state
- self.jobIdentity = jobIdentity
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.state = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRUCT:
- self.jobIdentity = JobIdentifier()
- self.jobIdentity.read(iprot)
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('JobStatusChangeRequestEvent')
- if self.state is not None:
- oprot.writeFieldBegin('state', TType.I32, 1)
- oprot.writeI32(self.state)
- oprot.writeFieldEnd()
- if self.jobIdentity is not None:
- oprot.writeFieldBegin('jobIdentity', TType.STRUCT, 2)
- self.jobIdentity.write(oprot)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.state is None:
- raise TProtocol.TProtocolException(message='Required field state is unset!')
- if self.jobIdentity is None:
- raise TProtocol.TProtocolException(message='Required field jobIdentity is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.state)
- value = (value * 31) ^ hash(self.jobIdentity)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class Message:
- """
- Attributes:
- - event
- - messageId
- - messageType
- - updatedTime
- - messageLevel
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'event', None, None, ), # 1
- (2, TType.STRING, 'messageId', None, "DO_NOT_SET_AT_CLIENTS", ), # 2
- (3, TType.I32, 'messageType', None, None, ), # 3
- (4, TType.I64, 'updatedTime', None, None, ), # 4
- (5, TType.I32, 'messageLevel', None, None, ), # 5
- )
-
- def __init__(self, event=None, messageId=thrift_spec[2][4], messageType=None, updatedTime=None, messageLevel=None,):
- self.event = event
- self.messageId = messageId
- self.messageType = messageType
- self.updatedTime = updatedTime
- self.messageLevel = messageLevel
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.event = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.messageId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.I32:
- self.messageType = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.I64:
- self.updatedTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I32:
- self.messageLevel = iprot.readI32()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('Message')
- if self.event is not None:
- oprot.writeFieldBegin('event', TType.STRING, 1)
- oprot.writeString(self.event)
- oprot.writeFieldEnd()
- if self.messageId is not None:
- oprot.writeFieldBegin('messageId', TType.STRING, 2)
- oprot.writeString(self.messageId)
- oprot.writeFieldEnd()
- if self.messageType is not None:
- oprot.writeFieldBegin('messageType', TType.I32, 3)
- oprot.writeI32(self.messageType)
- oprot.writeFieldEnd()
- if self.updatedTime is not None:
- oprot.writeFieldBegin('updatedTime', TType.I64, 4)
- oprot.writeI64(self.updatedTime)
- oprot.writeFieldEnd()
- if self.messageLevel is not None:
- oprot.writeFieldBegin('messageLevel', TType.I32, 5)
- oprot.writeI32(self.messageLevel)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.event is None:
- raise TProtocol.TProtocolException(message='Required field event is unset!')
- if self.messageId is None:
- raise TProtocol.TProtocolException(message='Required field messageId is unset!')
- if self.messageType is None:
- raise TProtocol.TProtocolException(message='Required field messageType is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.event)
- value = (value * 31) ^ hash(self.messageId)
- value = (value * 31) ^ hash(self.messageType)
- value = (value * 31) ^ hash(self.updatedTime)
- value = (value * 31) ^ hash(self.messageLevel)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class MessageLevel(object):
+ INFO = 0
+ DEBUG = 1
+ ERROR = 2
+ ACK = 3
+
+ _VALUES_TO_NAMES = {
+ 0: "INFO",
+ 1: "DEBUG",
+ 2: "ERROR",
+ 3: "ACK",
+ }
+
+ _NAMES_TO_VALUES = {
+ "INFO": 0,
+ "DEBUG": 1,
+ "ERROR": 2,
+ "ACK": 3,
+ }
+
+
+class MessageType(object):
+ EXPERIMENT = 0
+ EXPERIMENT_CANCEL = 1
+ TASK = 2
+ PROCESS = 3
+ JOB = 4
+ LAUNCHPROCESS = 5
+ TERMINATEPROCESS = 6
+ PROCESSOUTPUT = 7
+ DB_EVENT = 8
+
+ _VALUES_TO_NAMES = {
+ 0: "EXPERIMENT",
+ 1: "EXPERIMENT_CANCEL",
+ 2: "TASK",
+ 3: "PROCESS",
+ 4: "JOB",
+ 5: "LAUNCHPROCESS",
+ 6: "TERMINATEPROCESS",
+ 7: "PROCESSOUTPUT",
+ 8: "DB_EVENT",
+ }
+
+ _NAMES_TO_VALUES = {
+ "EXPERIMENT": 0,
+ "EXPERIMENT_CANCEL": 1,
+ "TASK": 2,
+ "PROCESS": 3,
+ "JOB": 4,
+ "LAUNCHPROCESS": 5,
+ "TERMINATEPROCESS": 6,
+ "PROCESSOUTPUT": 7,
+ "DB_EVENT": 8,
+ }
+
+
+class ExperimentStatusChangeEvent(object):
+ """
+ Attributes:
+ - state
+ - experimentId
+ - gatewayId
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'state', None, None, ), # 1
+ (2, TType.STRING, 'experimentId', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'gatewayId', 'UTF8', None, ), # 3
+ )
+
+ def __init__(self, state=None, experimentId=None, gatewayId=None,):
+ self.state = state
+ self.experimentId = experimentId
+ self.gatewayId = gatewayId
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.state = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.experimentId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ExperimentStatusChangeEvent')
+ if self.state is not None:
+ oprot.writeFieldBegin('state', TType.I32, 1)
+ oprot.writeI32(self.state)
+ oprot.writeFieldEnd()
+ if self.experimentId is not None:
+ oprot.writeFieldBegin('experimentId', TType.STRING, 2)
+ oprot.writeString(self.experimentId.encode('utf-8') if sys.version_info[0] == 2 else self.experimentId)
+ oprot.writeFieldEnd()
+ if self.gatewayId is not None:
+ oprot.writeFieldBegin('gatewayId', TType.STRING, 3)
+ oprot.writeString(self.gatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayId)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.state is None:
+ raise TProtocolException(message='Required field state is unset!')
+ if self.experimentId is None:
+ raise TProtocolException(message='Required field experimentId is unset!')
+ if self.gatewayId is None:
+ raise TProtocolException(message='Required field gatewayId is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class ProcessIdentifier(object):
+ """
+ Attributes:
+ - processId
+ - experimentId
+ - gatewayId
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'processId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'experimentId', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'gatewayId', 'UTF8', None, ), # 3
+ )
+
+ def __init__(self, processId=None, experimentId=None, gatewayId=None,):
+ self.processId = processId
+ self.experimentId = experimentId
+ self.gatewayId = gatewayId
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.processId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.experimentId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ProcessIdentifier')
+ if self.processId is not None:
+ oprot.writeFieldBegin('processId', TType.STRING, 1)
+ oprot.writeString(self.processId.encode('utf-8') if sys.version_info[0] == 2 else self.processId)
+ oprot.writeFieldEnd()
+ if self.experimentId is not None:
+ oprot.writeFieldBegin('experimentId', TType.STRING, 2)
+ oprot.writeString(self.experimentId.encode('utf-8') if sys.version_info[0] == 2 else self.experimentId)
+ oprot.writeFieldEnd()
+ if self.gatewayId is not None:
+ oprot.writeFieldBegin('gatewayId', TType.STRING, 3)
+ oprot.writeString(self.gatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayId)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.processId is None:
+ raise TProtocolException(message='Required field processId is unset!')
+ if self.experimentId is None:
+ raise TProtocolException(message='Required field experimentId is unset!')
+ if self.gatewayId is None:
+ raise TProtocolException(message='Required field gatewayId is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class TaskIdentifier(object):
+ """
+ Attributes:
+ - taskId
+ - processId
+ - experimentId
+ - gatewayId
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'taskId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'processId', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'experimentId', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'gatewayId', 'UTF8', None, ), # 4
+ )
+
+ def __init__(self, taskId=None, processId=None, experimentId=None, gatewayId=None,):
+ self.taskId = taskId
+ self.processId = processId
+ self.experimentId = experimentId
+ self.gatewayId = gatewayId
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.taskId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.processId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.experimentId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('TaskIdentifier')
+ if self.taskId is not None:
+ oprot.writeFieldBegin('taskId', TType.STRING, 1)
+ oprot.writeString(self.taskId.encode('utf-8') if sys.version_info[0] == 2 else self.taskId)
+ oprot.writeFieldEnd()
+ if self.processId is not None:
+ oprot.writeFieldBegin('processId', TType.STRING, 2)
+ oprot.writeString(self.processId.encode('utf-8') if sys.version_info[0] == 2 else self.processId)
+ oprot.writeFieldEnd()
+ if self.experimentId is not None:
+ oprot.writeFieldBegin('experimentId', TType.STRING, 3)
+ oprot.writeString(self.experimentId.encode('utf-8') if sys.version_info[0] == 2 else self.experimentId)
+ oprot.writeFieldEnd()
+ if self.gatewayId is not None:
+ oprot.writeFieldBegin('gatewayId', TType.STRING, 4)
+ oprot.writeString(self.gatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayId)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.taskId is None:
+ raise TProtocolException(message='Required field taskId is unset!')
+ if self.processId is None:
+ raise TProtocolException(message='Required field processId is unset!')
+ if self.experimentId is None:
+ raise TProtocolException(message='Required field experimentId is unset!')
+ if self.gatewayId is None:
+ raise TProtocolException(message='Required field gatewayId is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class TaskStatusChangeEvent(object):
+ """
+ Attributes:
+ - state
+ - taskIdentity
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'state', None, None, ), # 1
+ (2, TType.STRUCT, 'taskIdentity', (TaskIdentifier, TaskIdentifier.thrift_spec), None, ), # 2
+ )
+
+ def __init__(self, state=None, taskIdentity=None,):
+ self.state = state
+ self.taskIdentity = taskIdentity
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.state = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRUCT:
+ self.taskIdentity = TaskIdentifier()
+ self.taskIdentity.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('TaskStatusChangeEvent')
+ if self.state is not None:
+ oprot.writeFieldBegin('state', TType.I32, 1)
+ oprot.writeI32(self.state)
+ oprot.writeFieldEnd()
+ if self.taskIdentity is not None:
+ oprot.writeFieldBegin('taskIdentity', TType.STRUCT, 2)
+ self.taskIdentity.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.state is None:
+ raise TProtocolException(message='Required field state is unset!')
+ if self.taskIdentity is None:
+ raise TProtocolException(message='Required field taskIdentity is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class TaskStatusChangeRequestEvent(object):
+ """
+ Attributes:
+ - state
+ - taskIdentity
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'state', None, None, ), # 1
+ (2, TType.STRUCT, 'taskIdentity', (TaskIdentifier, TaskIdentifier.thrift_spec), None, ), # 2
+ )
+
+ def __init__(self, state=None, taskIdentity=None,):
+ self.state = state
+ self.taskIdentity = taskIdentity
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.state = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRUCT:
+ self.taskIdentity = TaskIdentifier()
+ self.taskIdentity.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('TaskStatusChangeRequestEvent')
+ if self.state is not None:
+ oprot.writeFieldBegin('state', TType.I32, 1)
+ oprot.writeI32(self.state)
+ oprot.writeFieldEnd()
+ if self.taskIdentity is not None:
+ oprot.writeFieldBegin('taskIdentity', TType.STRUCT, 2)
+ self.taskIdentity.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.state is None:
+ raise TProtocolException(message='Required field state is unset!')
+ if self.taskIdentity is None:
+ raise TProtocolException(message='Required field taskIdentity is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class ProcessStatusChangeEvent(object):
+ """
+ Attributes:
+ - state
+ - processIdentity
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'state', None, None, ), # 1
+ (2, TType.STRUCT, 'processIdentity', (ProcessIdentifier, ProcessIdentifier.thrift_spec), None, ), # 2
+ )
+
+ def __init__(self, state=None, processIdentity=None,):
+ self.state = state
+ self.processIdentity = processIdentity
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.state = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRUCT:
+ self.processIdentity = ProcessIdentifier()
+ self.processIdentity.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ProcessStatusChangeEvent')
+ if self.state is not None:
+ oprot.writeFieldBegin('state', TType.I32, 1)
+ oprot.writeI32(self.state)
+ oprot.writeFieldEnd()
+ if self.processIdentity is not None:
+ oprot.writeFieldBegin('processIdentity', TType.STRUCT, 2)
+ self.processIdentity.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.state is None:
+ raise TProtocolException(message='Required field state is unset!')
+ if self.processIdentity is None:
+ raise TProtocolException(message='Required field processIdentity is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class ProcessStatusChangeRequestEvent(object):
+ """
+ Attributes:
+ - state
+ - processIdentity
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'state', None, None, ), # 1
+ (2, TType.STRUCT, 'processIdentity', (ProcessIdentifier, ProcessIdentifier.thrift_spec), None, ), # 2
+ )
+
+ def __init__(self, state=None, processIdentity=None,):
+ self.state = state
+ self.processIdentity = processIdentity
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.state = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRUCT:
+ self.processIdentity = ProcessIdentifier()
+ self.processIdentity.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ProcessStatusChangeRequestEvent')
+ if self.state is not None:
+ oprot.writeFieldBegin('state', TType.I32, 1)
+ oprot.writeI32(self.state)
+ oprot.writeFieldEnd()
+ if self.processIdentity is not None:
+ oprot.writeFieldBegin('processIdentity', TType.STRUCT, 2)
+ self.processIdentity.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.state is None:
+ raise TProtocolException(message='Required field state is unset!')
+ if self.processIdentity is None:
+ raise TProtocolException(message='Required field processIdentity is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class TaskOutputChangeEvent(object):
+ """
+ Attributes:
+ - output
+ - taskIdentity
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.LIST, 'output', (TType.STRUCT, (apache.airavata.model.application.io.ttypes.OutputDataObjectType, apache.airavata.model.application.io.ttypes.OutputDataObjectType.thrift_spec), False), None, ), # 1
+ (2, TType.STRUCT, 'taskIdentity', (TaskIdentifier, TaskIdentifier.thrift_spec), None, ), # 2
+ )
+
+ def __init__(self, output=None, taskIdentity=None,):
+ self.output = output
+ self.taskIdentity = taskIdentity
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.LIST:
+ self.output = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in range(_size0):
+ _elem5 = apache.airavata.model.application.io.ttypes.OutputDataObjectType()
+ _elem5.read(iprot)
+ self.output.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRUCT:
+ self.taskIdentity = TaskIdentifier()
+ self.taskIdentity.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('TaskOutputChangeEvent')
+ if self.output is not None:
+ oprot.writeFieldBegin('output', TType.LIST, 1)
+ oprot.writeListBegin(TType.STRUCT, len(self.output))
+ for iter6 in self.output:
+ iter6.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.taskIdentity is not None:
+ oprot.writeFieldBegin('taskIdentity', TType.STRUCT, 2)
+ self.taskIdentity.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.output is None:
+ raise TProtocolException(message='Required field output is unset!')
+ if self.taskIdentity is None:
+ raise TProtocolException(message='Required field taskIdentity is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class JobIdentifier(object):
+ """
+ Attributes:
+ - jobId
+ - taskId
+ - processId
+ - experimentId
+ - gatewayId
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'jobId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'taskId', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'processId', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'experimentId', 'UTF8', None, ), # 4
+ (5, TType.STRING, 'gatewayId', 'UTF8', None, ), # 5
+ )
+
+ def __init__(self, jobId=None, taskId=None, processId=None, experimentId=None, gatewayId=None,):
+ self.jobId = jobId
+ self.taskId = taskId
+ self.processId = processId
+ self.experimentId = experimentId
+ self.gatewayId = gatewayId
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.jobId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.taskId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.processId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.experimentId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('JobIdentifier')
+ if self.jobId is not None:
+ oprot.writeFieldBegin('jobId', TType.STRING, 1)
+ oprot.writeString(self.jobId.encode('utf-8') if sys.version_info[0] == 2 else self.jobId)
+ oprot.writeFieldEnd()
+ if self.taskId is not None:
+ oprot.writeFieldBegin('taskId', TType.STRING, 2)
+ oprot.writeString(self.taskId.encode('utf-8') if sys.version_info[0] == 2 else self.taskId)
+ oprot.writeFieldEnd()
+ if self.processId is not None:
+ oprot.writeFieldBegin('processId', TType.STRING, 3)
+ oprot.writeString(self.processId.encode('utf-8') if sys.version_info[0] == 2 else self.processId)
+ oprot.writeFieldEnd()
+ if self.experimentId is not None:
+ oprot.writeFieldBegin('experimentId', TType.STRING, 4)
+ oprot.writeString(self.experimentId.encode('utf-8') if sys.version_info[0] == 2 else self.experimentId)
+ oprot.writeFieldEnd()
+ if self.gatewayId is not None:
+ oprot.writeFieldBegin('gatewayId', TType.STRING, 5)
+ oprot.writeString(self.gatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayId)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.jobId is None:
+ raise TProtocolException(message='Required field jobId is unset!')
+ if self.taskId is None:
+ raise TProtocolException(message='Required field taskId is unset!')
+ if self.processId is None:
+ raise TProtocolException(message='Required field processId is unset!')
+ if self.experimentId is None:
+ raise TProtocolException(message='Required field experimentId is unset!')
+ if self.gatewayId is None:
+ raise TProtocolException(message='Required field gatewayId is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class ExperimentSubmitEvent(object):
+ """
+ Attributes:
+ - experimentId
+ - gatewayId
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'experimentId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'gatewayId', 'UTF8', None, ), # 2
+ )
+
+ def __init__(self, experimentId=None, gatewayId=None,):
+ self.experimentId = experimentId
+ self.gatewayId = gatewayId
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.experimentId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ExperimentSubmitEvent')
+ if self.experimentId is not None:
+ oprot.writeFieldBegin('experimentId', TType.STRING, 1)
+ oprot.writeString(self.experimentId.encode('utf-8') if sys.version_info[0] == 2 else self.experimentId)
+ oprot.writeFieldEnd()
+ if self.gatewayId is not None:
+ oprot.writeFieldBegin('gatewayId', TType.STRING, 2)
+ oprot.writeString(self.gatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayId)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.experimentId is None:
+ raise TProtocolException(message='Required field experimentId is unset!')
+ if self.gatewayId is None:
+ raise TProtocolException(message='Required field gatewayId is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class ProcessSubmitEvent(object):
+ """
+ Attributes:
+ - processId
+ - gatewayId
+ - experimentId
+ - tokenId
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'processId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'gatewayId', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'experimentId', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'tokenId', 'UTF8', None, ), # 4
+ )
+
+ def __init__(self, processId=None, gatewayId=None, experimentId=None, tokenId=None,):
+ self.processId = processId
+ self.gatewayId = gatewayId
+ self.experimentId = experimentId
+ self.tokenId = tokenId
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.processId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.experimentId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.tokenId = i
<TRUNCATED>
[14/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/application/io/InputDataObjectType.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/application/io/InputDataObjectType.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/application/io/InputDataObjectType.java
index 6308e58..48f45d8 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/application/io/InputDataObjectType.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/application/io/InputDataObjectType.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.application.io;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Application Inputs. The paramters describe how inputs are passed to the application.
*
@@ -77,7 +50,7 @@ import org.slf4j.LoggerFactory;
* Any metadat. This is typically ignore by Airavata and is used by gateways for application configuration.
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObjectType, InputDataObjectType._Fields>, java.io.Serializable, Cloneable, Comparable<InputDataObjectType> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("InputDataObjectType");
@@ -95,24 +68,21 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
private static final org.apache.thrift.protocol.TField STORAGE_RESOURCE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("storageResourceId", org.apache.thrift.protocol.TType.STRING, (short)12);
private static final org.apache.thrift.protocol.TField IS_READ_ONLY_FIELD_DESC = new org.apache.thrift.protocol.TField("isReadOnly", org.apache.thrift.protocol.TType.BOOL, (short)13);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new InputDataObjectTypeStandardSchemeFactory());
- schemes.put(TupleScheme.class, new InputDataObjectTypeTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new InputDataObjectTypeStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new InputDataObjectTypeTupleSchemeFactory();
- private String name; // required
- private String value; // optional
+ private java.lang.String name; // required
+ private java.lang.String value; // optional
private DataType type; // optional
- private String applicationArgument; // optional
+ private java.lang.String applicationArgument; // optional
private boolean standardInput; // optional
- private String userFriendlyDescription; // optional
- private String metaData; // optional
+ private java.lang.String userFriendlyDescription; // optional
+ private java.lang.String metaData; // optional
private int inputOrder; // optional
private boolean isRequired; // optional
private boolean requiredToAddedToCommandLine; // optional
private boolean dataStaged; // optional
- private String storageResourceId; // optional
+ private java.lang.String storageResourceId; // optional
private boolean isReadOnly; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
@@ -135,10 +105,10 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
STORAGE_RESOURCE_ID((short)12, "storageResourceId"),
IS_READ_ONLY((short)13, "isReadOnly");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -185,21 +155,21 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -208,7 +178,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -222,9 +192,9 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
private static final int __ISREADONLY_ISSET_ID = 5;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.VALUE,_Fields.TYPE,_Fields.APPLICATION_ARGUMENT,_Fields.STANDARD_INPUT,_Fields.USER_FRIENDLY_DESCRIPTION,_Fields.META_DATA,_Fields.INPUT_ORDER,_Fields.IS_REQUIRED,_Fields.REQUIRED_TO_ADDED_TO_COMMAND_LINE,_Fields.DATA_STAGED,_Fields.STORAGE_RESOURCE_ID,_Fields.IS_READ_ONLY};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.NAME, new org.apache.thrift.meta_data.FieldMetaData("name", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.VALUE, new org.apache.thrift.meta_data.FieldMetaData("value", org.apache.thrift.TFieldRequirementType.OPTIONAL,
@@ -251,7 +221,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.IS_READ_ONLY, new org.apache.thrift.meta_data.FieldMetaData("isReadOnly", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(InputDataObjectType.class, metaDataMap);
}
@@ -259,7 +229,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
}
public InputDataObjectType(
- String name)
+ java.lang.String name)
{
this();
this.name = name;
@@ -326,11 +296,11 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
this.isReadOnly = false;
}
- public String getName() {
+ public java.lang.String getName() {
return this.name;
}
- public void setName(String name) {
+ public void setName(java.lang.String name) {
this.name = name;
}
@@ -349,11 +319,11 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
}
}
- public String getValue() {
+ public java.lang.String getValue() {
return this.value;
}
- public void setValue(String value) {
+ public void setValue(java.lang.String value) {
this.value = value;
}
@@ -403,11 +373,11 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
}
}
- public String getApplicationArgument() {
+ public java.lang.String getApplicationArgument() {
return this.applicationArgument;
}
- public void setApplicationArgument(String applicationArgument) {
+ public void setApplicationArgument(java.lang.String applicationArgument) {
this.applicationArgument = applicationArgument;
}
@@ -436,23 +406,23 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
}
public void unsetStandardInput() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __STANDARDINPUT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __STANDARDINPUT_ISSET_ID);
}
/** Returns true if field standardInput is set (has been assigned a value) and false otherwise */
public boolean isSetStandardInput() {
- return EncodingUtils.testBit(__isset_bitfield, __STANDARDINPUT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __STANDARDINPUT_ISSET_ID);
}
public void setStandardInputIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __STANDARDINPUT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __STANDARDINPUT_ISSET_ID, value);
}
- public String getUserFriendlyDescription() {
+ public java.lang.String getUserFriendlyDescription() {
return this.userFriendlyDescription;
}
- public void setUserFriendlyDescription(String userFriendlyDescription) {
+ public void setUserFriendlyDescription(java.lang.String userFriendlyDescription) {
this.userFriendlyDescription = userFriendlyDescription;
}
@@ -471,11 +441,11 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
}
}
- public String getMetaData() {
+ public java.lang.String getMetaData() {
return this.metaData;
}
- public void setMetaData(String metaData) {
+ public void setMetaData(java.lang.String metaData) {
this.metaData = metaData;
}
@@ -504,16 +474,16 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
}
public void unsetInputOrder() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __INPUTORDER_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __INPUTORDER_ISSET_ID);
}
/** Returns true if field inputOrder is set (has been assigned a value) and false otherwise */
public boolean isSetInputOrder() {
- return EncodingUtils.testBit(__isset_bitfield, __INPUTORDER_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __INPUTORDER_ISSET_ID);
}
public void setInputOrderIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __INPUTORDER_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __INPUTORDER_ISSET_ID, value);
}
public boolean isIsRequired() {
@@ -526,16 +496,16 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
}
public void unsetIsRequired() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ISREQUIRED_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ISREQUIRED_ISSET_ID);
}
/** Returns true if field isRequired is set (has been assigned a value) and false otherwise */
public boolean isSetIsRequired() {
- return EncodingUtils.testBit(__isset_bitfield, __ISREQUIRED_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ISREQUIRED_ISSET_ID);
}
public void setIsRequiredIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ISREQUIRED_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ISREQUIRED_ISSET_ID, value);
}
public boolean isRequiredToAddedToCommandLine() {
@@ -548,16 +518,16 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
}
public void unsetRequiredToAddedToCommandLine() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __REQUIREDTOADDEDTOCOMMANDLINE_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __REQUIREDTOADDEDTOCOMMANDLINE_ISSET_ID);
}
/** Returns true if field requiredToAddedToCommandLine is set (has been assigned a value) and false otherwise */
public boolean isSetRequiredToAddedToCommandLine() {
- return EncodingUtils.testBit(__isset_bitfield, __REQUIREDTOADDEDTOCOMMANDLINE_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __REQUIREDTOADDEDTOCOMMANDLINE_ISSET_ID);
}
public void setRequiredToAddedToCommandLineIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __REQUIREDTOADDEDTOCOMMANDLINE_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __REQUIREDTOADDEDTOCOMMANDLINE_ISSET_ID, value);
}
public boolean isDataStaged() {
@@ -570,23 +540,23 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
}
public void unsetDataStaged() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __DATASTAGED_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __DATASTAGED_ISSET_ID);
}
/** Returns true if field dataStaged is set (has been assigned a value) and false otherwise */
public boolean isSetDataStaged() {
- return EncodingUtils.testBit(__isset_bitfield, __DATASTAGED_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __DATASTAGED_ISSET_ID);
}
public void setDataStagedIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __DATASTAGED_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __DATASTAGED_ISSET_ID, value);
}
- public String getStorageResourceId() {
+ public java.lang.String getStorageResourceId() {
return this.storageResourceId;
}
- public void setStorageResourceId(String storageResourceId) {
+ public void setStorageResourceId(java.lang.String storageResourceId) {
this.storageResourceId = storageResourceId;
}
@@ -615,25 +585,25 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
}
public void unsetIsReadOnly() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ISREADONLY_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ISREADONLY_ISSET_ID);
}
/** Returns true if field isReadOnly is set (has been assigned a value) and false otherwise */
public boolean isSetIsReadOnly() {
- return EncodingUtils.testBit(__isset_bitfield, __ISREADONLY_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ISREADONLY_ISSET_ID);
}
public void setIsReadOnlyIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ISREADONLY_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ISREADONLY_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case NAME:
if (value == null) {
unsetName();
} else {
- setName((String)value);
+ setName((java.lang.String)value);
}
break;
@@ -641,7 +611,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
if (value == null) {
unsetValue();
} else {
- setValue((String)value);
+ setValue((java.lang.String)value);
}
break;
@@ -657,7 +627,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
if (value == null) {
unsetApplicationArgument();
} else {
- setApplicationArgument((String)value);
+ setApplicationArgument((java.lang.String)value);
}
break;
@@ -665,7 +635,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
if (value == null) {
unsetStandardInput();
} else {
- setStandardInput((Boolean)value);
+ setStandardInput((java.lang.Boolean)value);
}
break;
@@ -673,7 +643,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
if (value == null) {
unsetUserFriendlyDescription();
} else {
- setUserFriendlyDescription((String)value);
+ setUserFriendlyDescription((java.lang.String)value);
}
break;
@@ -681,7 +651,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
if (value == null) {
unsetMetaData();
} else {
- setMetaData((String)value);
+ setMetaData((java.lang.String)value);
}
break;
@@ -689,7 +659,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
if (value == null) {
unsetInputOrder();
} else {
- setInputOrder((Integer)value);
+ setInputOrder((java.lang.Integer)value);
}
break;
@@ -697,7 +667,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
if (value == null) {
unsetIsRequired();
} else {
- setIsRequired((Boolean)value);
+ setIsRequired((java.lang.Boolean)value);
}
break;
@@ -705,7 +675,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
if (value == null) {
unsetRequiredToAddedToCommandLine();
} else {
- setRequiredToAddedToCommandLine((Boolean)value);
+ setRequiredToAddedToCommandLine((java.lang.Boolean)value);
}
break;
@@ -713,7 +683,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
if (value == null) {
unsetDataStaged();
} else {
- setDataStaged((Boolean)value);
+ setDataStaged((java.lang.Boolean)value);
}
break;
@@ -721,7 +691,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
if (value == null) {
unsetStorageResourceId();
} else {
- setStorageResourceId((String)value);
+ setStorageResourceId((java.lang.String)value);
}
break;
@@ -729,14 +699,14 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
if (value == null) {
unsetIsReadOnly();
} else {
- setIsReadOnly((Boolean)value);
+ setIsReadOnly((java.lang.Boolean)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case NAME:
return getName();
@@ -778,13 +748,13 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
return isIsReadOnly();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -815,11 +785,11 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
case IS_READ_ONLY:
return isSetIsReadOnly();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof InputDataObjectType)
@@ -830,6 +800,8 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
public boolean equals(InputDataObjectType that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_name = true && this.isSetName();
boolean that_present_name = true && that.isSetName();
@@ -953,74 +925,61 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_name = true && (isSetName());
- list.add(present_name);
- if (present_name)
- list.add(name);
-
- boolean present_value = true && (isSetValue());
- list.add(present_value);
- if (present_value)
- list.add(value);
-
- boolean present_type = true && (isSetType());
- list.add(present_type);
- if (present_type)
- list.add(type.getValue());
-
- boolean present_applicationArgument = true && (isSetApplicationArgument());
- list.add(present_applicationArgument);
- if (present_applicationArgument)
- list.add(applicationArgument);
-
- boolean present_standardInput = true && (isSetStandardInput());
- list.add(present_standardInput);
- if (present_standardInput)
- list.add(standardInput);
-
- boolean present_userFriendlyDescription = true && (isSetUserFriendlyDescription());
- list.add(present_userFriendlyDescription);
- if (present_userFriendlyDescription)
- list.add(userFriendlyDescription);
-
- boolean present_metaData = true && (isSetMetaData());
- list.add(present_metaData);
- if (present_metaData)
- list.add(metaData);
-
- boolean present_inputOrder = true && (isSetInputOrder());
- list.add(present_inputOrder);
- if (present_inputOrder)
- list.add(inputOrder);
-
- boolean present_isRequired = true && (isSetIsRequired());
- list.add(present_isRequired);
- if (present_isRequired)
- list.add(isRequired);
-
- boolean present_requiredToAddedToCommandLine = true && (isSetRequiredToAddedToCommandLine());
- list.add(present_requiredToAddedToCommandLine);
- if (present_requiredToAddedToCommandLine)
- list.add(requiredToAddedToCommandLine);
-
- boolean present_dataStaged = true && (isSetDataStaged());
- list.add(present_dataStaged);
- if (present_dataStaged)
- list.add(dataStaged);
-
- boolean present_storageResourceId = true && (isSetStorageResourceId());
- list.add(present_storageResourceId);
- if (present_storageResourceId)
- list.add(storageResourceId);
-
- boolean present_isReadOnly = true && (isSetIsReadOnly());
- list.add(present_isReadOnly);
- if (present_isReadOnly)
- list.add(isReadOnly);
-
- return list.hashCode();
+ int hashCode = 1;
+
+ hashCode = hashCode * 8191 + ((isSetName()) ? 131071 : 524287);
+ if (isSetName())
+ hashCode = hashCode * 8191 + name.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetValue()) ? 131071 : 524287);
+ if (isSetValue())
+ hashCode = hashCode * 8191 + value.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetType()) ? 131071 : 524287);
+ if (isSetType())
+ hashCode = hashCode * 8191 + type.getValue();
+
+ hashCode = hashCode * 8191 + ((isSetApplicationArgument()) ? 131071 : 524287);
+ if (isSetApplicationArgument())
+ hashCode = hashCode * 8191 + applicationArgument.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetStandardInput()) ? 131071 : 524287);
+ if (isSetStandardInput())
+ hashCode = hashCode * 8191 + ((standardInput) ? 131071 : 524287);
+
+ hashCode = hashCode * 8191 + ((isSetUserFriendlyDescription()) ? 131071 : 524287);
+ if (isSetUserFriendlyDescription())
+ hashCode = hashCode * 8191 + userFriendlyDescription.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetMetaData()) ? 131071 : 524287);
+ if (isSetMetaData())
+ hashCode = hashCode * 8191 + metaData.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetInputOrder()) ? 131071 : 524287);
+ if (isSetInputOrder())
+ hashCode = hashCode * 8191 + inputOrder;
+
+ hashCode = hashCode * 8191 + ((isSetIsRequired()) ? 131071 : 524287);
+ if (isSetIsRequired())
+ hashCode = hashCode * 8191 + ((isRequired) ? 131071 : 524287);
+
+ hashCode = hashCode * 8191 + ((isSetRequiredToAddedToCommandLine()) ? 131071 : 524287);
+ if (isSetRequiredToAddedToCommandLine())
+ hashCode = hashCode * 8191 + ((requiredToAddedToCommandLine) ? 131071 : 524287);
+
+ hashCode = hashCode * 8191 + ((isSetDataStaged()) ? 131071 : 524287);
+ if (isSetDataStaged())
+ hashCode = hashCode * 8191 + ((dataStaged) ? 131071 : 524287);
+
+ hashCode = hashCode * 8191 + ((isSetStorageResourceId()) ? 131071 : 524287);
+ if (isSetStorageResourceId())
+ hashCode = hashCode * 8191 + storageResourceId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetIsReadOnly()) ? 131071 : 524287);
+ if (isSetIsReadOnly())
+ hashCode = hashCode * 8191 + ((isReadOnly) ? 131071 : 524287);
+
+ return hashCode;
}
@Override
@@ -1031,7 +990,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetName()).compareTo(other.isSetName());
+ lastComparison = java.lang.Boolean.valueOf(isSetName()).compareTo(other.isSetName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1041,7 +1000,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetValue()).compareTo(other.isSetValue());
+ lastComparison = java.lang.Boolean.valueOf(isSetValue()).compareTo(other.isSetValue());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1051,7 +1010,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetType()).compareTo(other.isSetType());
+ lastComparison = java.lang.Boolean.valueOf(isSetType()).compareTo(other.isSetType());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1061,7 +1020,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetApplicationArgument()).compareTo(other.isSetApplicationArgument());
+ lastComparison = java.lang.Boolean.valueOf(isSetApplicationArgument()).compareTo(other.isSetApplicationArgument());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1071,7 +1030,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetStandardInput()).compareTo(other.isSetStandardInput());
+ lastComparison = java.lang.Boolean.valueOf(isSetStandardInput()).compareTo(other.isSetStandardInput());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1081,7 +1040,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUserFriendlyDescription()).compareTo(other.isSetUserFriendlyDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetUserFriendlyDescription()).compareTo(other.isSetUserFriendlyDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1091,7 +1050,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetMetaData()).compareTo(other.isSetMetaData());
+ lastComparison = java.lang.Boolean.valueOf(isSetMetaData()).compareTo(other.isSetMetaData());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1101,7 +1060,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetInputOrder()).compareTo(other.isSetInputOrder());
+ lastComparison = java.lang.Boolean.valueOf(isSetInputOrder()).compareTo(other.isSetInputOrder());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1111,7 +1070,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetIsRequired()).compareTo(other.isSetIsRequired());
+ lastComparison = java.lang.Boolean.valueOf(isSetIsRequired()).compareTo(other.isSetIsRequired());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1121,7 +1080,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetRequiredToAddedToCommandLine()).compareTo(other.isSetRequiredToAddedToCommandLine());
+ lastComparison = java.lang.Boolean.valueOf(isSetRequiredToAddedToCommandLine()).compareTo(other.isSetRequiredToAddedToCommandLine());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1131,7 +1090,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDataStaged()).compareTo(other.isSetDataStaged());
+ lastComparison = java.lang.Boolean.valueOf(isSetDataStaged()).compareTo(other.isSetDataStaged());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1141,7 +1100,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetStorageResourceId()).compareTo(other.isSetStorageResourceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetStorageResourceId()).compareTo(other.isSetStorageResourceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1151,7 +1110,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetIsReadOnly()).compareTo(other.isSetIsReadOnly());
+ lastComparison = java.lang.Boolean.valueOf(isSetIsReadOnly()).compareTo(other.isSetIsReadOnly());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1169,16 +1128,16 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("InputDataObjectType(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("InputDataObjectType(");
boolean first = true;
sb.append("name:");
@@ -1305,7 +1264,7 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -1315,13 +1274,13 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
}
}
- private static class InputDataObjectTypeStandardSchemeFactory implements SchemeFactory {
+ private static class InputDataObjectTypeStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public InputDataObjectTypeStandardScheme getScheme() {
return new InputDataObjectTypeStandardScheme();
}
}
- private static class InputDataObjectTypeStandardScheme extends StandardScheme<InputDataObjectType> {
+ private static class InputDataObjectTypeStandardScheme extends org.apache.thrift.scheme.StandardScheme<InputDataObjectType> {
public void read(org.apache.thrift.protocol.TProtocol iprot, InputDataObjectType struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1533,19 +1492,19 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
}
- private static class InputDataObjectTypeTupleSchemeFactory implements SchemeFactory {
+ private static class InputDataObjectTypeTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public InputDataObjectTypeTupleScheme getScheme() {
return new InputDataObjectTypeTupleScheme();
}
}
- private static class InputDataObjectTypeTupleScheme extends TupleScheme<InputDataObjectType> {
+ private static class InputDataObjectTypeTupleScheme extends org.apache.thrift.scheme.TupleScheme<InputDataObjectType> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, InputDataObjectType struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.name);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetValue()) {
optionals.set(0);
}
@@ -1623,10 +1582,10 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, InputDataObjectType struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.name = iprot.readString();
struct.setNameIsSet(true);
- BitSet incoming = iprot.readBitSet(12);
+ java.util.BitSet incoming = iprot.readBitSet(12);
if (incoming.get(0)) {
struct.value = iprot.readString();
struct.setValueIsSet(true);
@@ -1678,5 +1637,8 @@ public class InputDataObjectType implements org.apache.thrift.TBase<InputDataObj
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/application/io/OutputDataObjectType.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/application/io/OutputDataObjectType.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/application/io/OutputDataObjectType.java
index 19df1e3..1c24ed1 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/application/io/OutputDataObjectType.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/application/io/OutputDataObjectType.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.application.io;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Application Outputs. The paramters describe how outputs generated by the application.
*
@@ -77,7 +50,7 @@ import org.slf4j.LoggerFactory;
* Any metadat. This is typically ignore by Airavata and is used by gateways for application configuration.
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataObjectType, OutputDataObjectType._Fields>, java.io.Serializable, Cloneable, Comparable<OutputDataObjectType> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("OutputDataObjectType");
@@ -93,23 +66,20 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
private static final org.apache.thrift.protocol.TField OUTPUT_STREAMING_FIELD_DESC = new org.apache.thrift.protocol.TField("outputStreaming", org.apache.thrift.protocol.TType.BOOL, (short)10);
private static final org.apache.thrift.protocol.TField STORAGE_RESOURCE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("storageResourceId", org.apache.thrift.protocol.TType.STRING, (short)11);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new OutputDataObjectTypeStandardSchemeFactory());
- schemes.put(TupleScheme.class, new OutputDataObjectTypeTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new OutputDataObjectTypeStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new OutputDataObjectTypeTupleSchemeFactory();
- private String name; // required
- private String value; // optional
+ private java.lang.String name; // required
+ private java.lang.String value; // optional
private DataType type; // optional
- private String applicationArgument; // optional
+ private java.lang.String applicationArgument; // optional
private boolean isRequired; // optional
private boolean requiredToAddedToCommandLine; // optional
private boolean dataMovement; // optional
- private String location; // optional
- private String searchQuery; // optional
+ private java.lang.String location; // optional
+ private java.lang.String searchQuery; // optional
private boolean outputStreaming; // optional
- private String storageResourceId; // optional
+ private java.lang.String storageResourceId; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -129,10 +99,10 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
OUTPUT_STREAMING((short)10, "outputStreaming"),
STORAGE_RESOURCE_ID((short)11, "storageResourceId");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -175,21 +145,21 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -198,7 +168,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -210,9 +180,9 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
private static final int __OUTPUTSTREAMING_ISSET_ID = 3;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.VALUE,_Fields.TYPE,_Fields.APPLICATION_ARGUMENT,_Fields.IS_REQUIRED,_Fields.REQUIRED_TO_ADDED_TO_COMMAND_LINE,_Fields.DATA_MOVEMENT,_Fields.LOCATION,_Fields.SEARCH_QUERY,_Fields.OUTPUT_STREAMING,_Fields.STORAGE_RESOURCE_ID};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.NAME, new org.apache.thrift.meta_data.FieldMetaData("name", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.VALUE, new org.apache.thrift.meta_data.FieldMetaData("value", org.apache.thrift.TFieldRequirementType.OPTIONAL,
@@ -235,7 +205,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
tmpMap.put(_Fields.STORAGE_RESOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("storageResourceId", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(OutputDataObjectType.class, metaDataMap);
}
@@ -243,7 +213,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
}
public OutputDataObjectType(
- String name)
+ java.lang.String name)
{
this();
this.name = name;
@@ -304,11 +274,11 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
this.storageResourceId = null;
}
- public String getName() {
+ public java.lang.String getName() {
return this.name;
}
- public void setName(String name) {
+ public void setName(java.lang.String name) {
this.name = name;
}
@@ -327,11 +297,11 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
}
}
- public String getValue() {
+ public java.lang.String getValue() {
return this.value;
}
- public void setValue(String value) {
+ public void setValue(java.lang.String value) {
this.value = value;
}
@@ -381,11 +351,11 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
}
}
- public String getApplicationArgument() {
+ public java.lang.String getApplicationArgument() {
return this.applicationArgument;
}
- public void setApplicationArgument(String applicationArgument) {
+ public void setApplicationArgument(java.lang.String applicationArgument) {
this.applicationArgument = applicationArgument;
}
@@ -414,16 +384,16 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
}
public void unsetIsRequired() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ISREQUIRED_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ISREQUIRED_ISSET_ID);
}
/** Returns true if field isRequired is set (has been assigned a value) and false otherwise */
public boolean isSetIsRequired() {
- return EncodingUtils.testBit(__isset_bitfield, __ISREQUIRED_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ISREQUIRED_ISSET_ID);
}
public void setIsRequiredIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ISREQUIRED_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ISREQUIRED_ISSET_ID, value);
}
public boolean isRequiredToAddedToCommandLine() {
@@ -436,16 +406,16 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
}
public void unsetRequiredToAddedToCommandLine() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __REQUIREDTOADDEDTOCOMMANDLINE_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __REQUIREDTOADDEDTOCOMMANDLINE_ISSET_ID);
}
/** Returns true if field requiredToAddedToCommandLine is set (has been assigned a value) and false otherwise */
public boolean isSetRequiredToAddedToCommandLine() {
- return EncodingUtils.testBit(__isset_bitfield, __REQUIREDTOADDEDTOCOMMANDLINE_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __REQUIREDTOADDEDTOCOMMANDLINE_ISSET_ID);
}
public void setRequiredToAddedToCommandLineIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __REQUIREDTOADDEDTOCOMMANDLINE_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __REQUIREDTOADDEDTOCOMMANDLINE_ISSET_ID, value);
}
public boolean isDataMovement() {
@@ -458,23 +428,23 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
}
public void unsetDataMovement() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __DATAMOVEMENT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __DATAMOVEMENT_ISSET_ID);
}
/** Returns true if field dataMovement is set (has been assigned a value) and false otherwise */
public boolean isSetDataMovement() {
- return EncodingUtils.testBit(__isset_bitfield, __DATAMOVEMENT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __DATAMOVEMENT_ISSET_ID);
}
public void setDataMovementIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __DATAMOVEMENT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __DATAMOVEMENT_ISSET_ID, value);
}
- public String getLocation() {
+ public java.lang.String getLocation() {
return this.location;
}
- public void setLocation(String location) {
+ public void setLocation(java.lang.String location) {
this.location = location;
}
@@ -493,11 +463,11 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
}
}
- public String getSearchQuery() {
+ public java.lang.String getSearchQuery() {
return this.searchQuery;
}
- public void setSearchQuery(String searchQuery) {
+ public void setSearchQuery(java.lang.String searchQuery) {
this.searchQuery = searchQuery;
}
@@ -526,23 +496,23 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
}
public void unsetOutputStreaming() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __OUTPUTSTREAMING_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __OUTPUTSTREAMING_ISSET_ID);
}
/** Returns true if field outputStreaming is set (has been assigned a value) and false otherwise */
public boolean isSetOutputStreaming() {
- return EncodingUtils.testBit(__isset_bitfield, __OUTPUTSTREAMING_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __OUTPUTSTREAMING_ISSET_ID);
}
public void setOutputStreamingIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __OUTPUTSTREAMING_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __OUTPUTSTREAMING_ISSET_ID, value);
}
- public String getStorageResourceId() {
+ public java.lang.String getStorageResourceId() {
return this.storageResourceId;
}
- public void setStorageResourceId(String storageResourceId) {
+ public void setStorageResourceId(java.lang.String storageResourceId) {
this.storageResourceId = storageResourceId;
}
@@ -561,13 +531,13 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case NAME:
if (value == null) {
unsetName();
} else {
- setName((String)value);
+ setName((java.lang.String)value);
}
break;
@@ -575,7 +545,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
if (value == null) {
unsetValue();
} else {
- setValue((String)value);
+ setValue((java.lang.String)value);
}
break;
@@ -591,7 +561,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
if (value == null) {
unsetApplicationArgument();
} else {
- setApplicationArgument((String)value);
+ setApplicationArgument((java.lang.String)value);
}
break;
@@ -599,7 +569,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
if (value == null) {
unsetIsRequired();
} else {
- setIsRequired((Boolean)value);
+ setIsRequired((java.lang.Boolean)value);
}
break;
@@ -607,7 +577,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
if (value == null) {
unsetRequiredToAddedToCommandLine();
} else {
- setRequiredToAddedToCommandLine((Boolean)value);
+ setRequiredToAddedToCommandLine((java.lang.Boolean)value);
}
break;
@@ -615,7 +585,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
if (value == null) {
unsetDataMovement();
} else {
- setDataMovement((Boolean)value);
+ setDataMovement((java.lang.Boolean)value);
}
break;
@@ -623,7 +593,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
if (value == null) {
unsetLocation();
} else {
- setLocation((String)value);
+ setLocation((java.lang.String)value);
}
break;
@@ -631,7 +601,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
if (value == null) {
unsetSearchQuery();
} else {
- setSearchQuery((String)value);
+ setSearchQuery((java.lang.String)value);
}
break;
@@ -639,7 +609,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
if (value == null) {
unsetOutputStreaming();
} else {
- setOutputStreaming((Boolean)value);
+ setOutputStreaming((java.lang.Boolean)value);
}
break;
@@ -647,14 +617,14 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
if (value == null) {
unsetStorageResourceId();
} else {
- setStorageResourceId((String)value);
+ setStorageResourceId((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case NAME:
return getName();
@@ -690,13 +660,13 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
return getStorageResourceId();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -723,11 +693,11 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
case STORAGE_RESOURCE_ID:
return isSetStorageResourceId();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof OutputDataObjectType)
@@ -738,6 +708,8 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
public boolean equals(OutputDataObjectType that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_name = true && this.isSetName();
boolean that_present_name = true && that.isSetName();
@@ -843,64 +815,53 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_name = true && (isSetName());
- list.add(present_name);
- if (present_name)
- list.add(name);
-
- boolean present_value = true && (isSetValue());
- list.add(present_value);
- if (present_value)
- list.add(value);
-
- boolean present_type = true && (isSetType());
- list.add(present_type);
- if (present_type)
- list.add(type.getValue());
-
- boolean present_applicationArgument = true && (isSetApplicationArgument());
- list.add(present_applicationArgument);
- if (present_applicationArgument)
- list.add(applicationArgument);
-
- boolean present_isRequired = true && (isSetIsRequired());
- list.add(present_isRequired);
- if (present_isRequired)
- list.add(isRequired);
-
- boolean present_requiredToAddedToCommandLine = true && (isSetRequiredToAddedToCommandLine());
- list.add(present_requiredToAddedToCommandLine);
- if (present_requiredToAddedToCommandLine)
- list.add(requiredToAddedToCommandLine);
-
- boolean present_dataMovement = true && (isSetDataMovement());
- list.add(present_dataMovement);
- if (present_dataMovement)
- list.add(dataMovement);
-
- boolean present_location = true && (isSetLocation());
- list.add(present_location);
- if (present_location)
- list.add(location);
-
- boolean present_searchQuery = true && (isSetSearchQuery());
- list.add(present_searchQuery);
- if (present_searchQuery)
- list.add(searchQuery);
-
- boolean present_outputStreaming = true && (isSetOutputStreaming());
- list.add(present_outputStreaming);
- if (present_outputStreaming)
- list.add(outputStreaming);
-
- boolean present_storageResourceId = true && (isSetStorageResourceId());
- list.add(present_storageResourceId);
- if (present_storageResourceId)
- list.add(storageResourceId);
-
- return list.hashCode();
+ int hashCode = 1;
+
+ hashCode = hashCode * 8191 + ((isSetName()) ? 131071 : 524287);
+ if (isSetName())
+ hashCode = hashCode * 8191 + name.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetValue()) ? 131071 : 524287);
+ if (isSetValue())
+ hashCode = hashCode * 8191 + value.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetType()) ? 131071 : 524287);
+ if (isSetType())
+ hashCode = hashCode * 8191 + type.getValue();
+
+ hashCode = hashCode * 8191 + ((isSetApplicationArgument()) ? 131071 : 524287);
+ if (isSetApplicationArgument())
+ hashCode = hashCode * 8191 + applicationArgument.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetIsRequired()) ? 131071 : 524287);
+ if (isSetIsRequired())
+ hashCode = hashCode * 8191 + ((isRequired) ? 131071 : 524287);
+
+ hashCode = hashCode * 8191 + ((isSetRequiredToAddedToCommandLine()) ? 131071 : 524287);
+ if (isSetRequiredToAddedToCommandLine())
+ hashCode = hashCode * 8191 + ((requiredToAddedToCommandLine) ? 131071 : 524287);
+
+ hashCode = hashCode * 8191 + ((isSetDataMovement()) ? 131071 : 524287);
+ if (isSetDataMovement())
+ hashCode = hashCode * 8191 + ((dataMovement) ? 131071 : 524287);
+
+ hashCode = hashCode * 8191 + ((isSetLocation()) ? 131071 : 524287);
+ if (isSetLocation())
+ hashCode = hashCode * 8191 + location.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetSearchQuery()) ? 131071 : 524287);
+ if (isSetSearchQuery())
+ hashCode = hashCode * 8191 + searchQuery.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetOutputStreaming()) ? 131071 : 524287);
+ if (isSetOutputStreaming())
+ hashCode = hashCode * 8191 + ((outputStreaming) ? 131071 : 524287);
+
+ hashCode = hashCode * 8191 + ((isSetStorageResourceId()) ? 131071 : 524287);
+ if (isSetStorageResourceId())
+ hashCode = hashCode * 8191 + storageResourceId.hashCode();
+
+ return hashCode;
}
@Override
@@ -911,7 +872,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetName()).compareTo(other.isSetName());
+ lastComparison = java.lang.Boolean.valueOf(isSetName()).compareTo(other.isSetName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -921,7 +882,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetValue()).compareTo(other.isSetValue());
+ lastComparison = java.lang.Boolean.valueOf(isSetValue()).compareTo(other.isSetValue());
if (lastComparison != 0) {
return lastComparison;
}
@@ -931,7 +892,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetType()).compareTo(other.isSetType());
+ lastComparison = java.lang.Boolean.valueOf(isSetType()).compareTo(other.isSetType());
if (lastComparison != 0) {
return lastComparison;
}
@@ -941,7 +902,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetApplicationArgument()).compareTo(other.isSetApplicationArgument());
+ lastComparison = java.lang.Boolean.valueOf(isSetApplicationArgument()).compareTo(other.isSetApplicationArgument());
if (lastComparison != 0) {
return lastComparison;
}
@@ -951,7 +912,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetIsRequired()).compareTo(other.isSetIsRequired());
+ lastComparison = java.lang.Boolean.valueOf(isSetIsRequired()).compareTo(other.isSetIsRequired());
if (lastComparison != 0) {
return lastComparison;
}
@@ -961,7 +922,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetRequiredToAddedToCommandLine()).compareTo(other.isSetRequiredToAddedToCommandLine());
+ lastComparison = java.lang.Boolean.valueOf(isSetRequiredToAddedToCommandLine()).compareTo(other.isSetRequiredToAddedToCommandLine());
if (lastComparison != 0) {
return lastComparison;
}
@@ -971,7 +932,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDataMovement()).compareTo(other.isSetDataMovement());
+ lastComparison = java.lang.Boolean.valueOf(isSetDataMovement()).compareTo(other.isSetDataMovement());
if (lastComparison != 0) {
return lastComparison;
}
@@ -981,7 +942,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetLocation()).compareTo(other.isSetLocation());
+ lastComparison = java.lang.Boolean.valueOf(isSetLocation()).compareTo(other.isSetLocation());
if (lastComparison != 0) {
return lastComparison;
}
@@ -991,7 +952,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetSearchQuery()).compareTo(other.isSetSearchQuery());
+ lastComparison = java.lang.Boolean.valueOf(isSetSearchQuery()).compareTo(other.isSetSearchQuery());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1001,7 +962,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetOutputStreaming()).compareTo(other.isSetOutputStreaming());
+ lastComparison = java.lang.Boolean.valueOf(isSetOutputStreaming()).compareTo(other.isSetOutputStreaming());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1011,7 +972,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetStorageResourceId()).compareTo(other.isSetStorageResourceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetStorageResourceId()).compareTo(other.isSetStorageResourceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1029,16 +990,16 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("OutputDataObjectType(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("OutputDataObjectType(");
boolean first = true;
sb.append("name:");
@@ -1153,7 +1114,7 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -1163,13 +1124,13 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
}
}
- private static class OutputDataObjectTypeStandardSchemeFactory implements SchemeFactory {
+ private static class OutputDataObjectTypeStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public OutputDataObjectTypeStandardScheme getScheme() {
return new OutputDataObjectTypeStandardScheme();
}
}
- private static class OutputDataObjectTypeStandardScheme extends StandardScheme<OutputDataObjectType> {
+ private static class OutputDataObjectTypeStandardScheme extends org.apache.thrift.scheme.StandardScheme<OutputDataObjectType> {
public void read(org.apache.thrift.protocol.TProtocol iprot, OutputDataObjectType struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1355,19 +1316,19 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
}
- private static class OutputDataObjectTypeTupleSchemeFactory implements SchemeFactory {
+ private static class OutputDataObjectTypeTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public OutputDataObjectTypeTupleScheme getScheme() {
return new OutputDataObjectTypeTupleScheme();
}
}
- private static class OutputDataObjectTypeTupleScheme extends TupleScheme<OutputDataObjectType> {
+ private static class OutputDataObjectTypeTupleScheme extends org.apache.thrift.scheme.TupleScheme<OutputDataObjectType> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, OutputDataObjectType struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.name);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetValue()) {
optionals.set(0);
}
@@ -1433,10 +1394,10 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, OutputDataObjectType struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.name = iprot.readString();
struct.setNameIsSet(true);
- BitSet incoming = iprot.readBitSet(10);
+ java.util.BitSet incoming = iprot.readBitSet(10);
if (incoming.get(0)) {
struct.value = iprot.readString();
struct.setValueIsSet(true);
@@ -1480,5 +1441,8 @@ public class OutputDataObjectType implements org.apache.thrift.TBase<OutputDataO
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
[26/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/credential_store_data_models/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/credential_store_data_models/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/credential_store_data_models/ttypes.py
index be5e93d..7d6cadf 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/credential_store_data_models/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/credential_store_data_models/ttypes.py
@@ -1,786 +1,729 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class CredentialOwnerType:
- GATEWAY = 0
- USER = 1
-
- _VALUES_TO_NAMES = {
- 0: "GATEWAY",
- 1: "USER",
- }
-
- _NAMES_TO_VALUES = {
- "GATEWAY": 0,
- "USER": 1,
- }
-
-class SummaryType:
- """
- Data Types supported in Airavata. The primitive data types
-
- """
- SSH = 0
- PASSWD = 1
- CERT = 2
-
- _VALUES_TO_NAMES = {
- 0: "SSH",
- 1: "PASSWD",
- 2: "CERT",
- }
-
- _NAMES_TO_VALUES = {
- "SSH": 0,
- "PASSWD": 1,
- "CERT": 2,
- }
-
-
-class SSHCredential:
- """
- Attributes:
- - gatewayId
- - username
- - passphrase
- - publicKey
- - privateKey
- - persistedTime
- - token
- - description
- - credentialOwnerType
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'gatewayId', None, None, ), # 1
- (2, TType.STRING, 'username', None, None, ), # 2
- (3, TType.STRING, 'passphrase', None, None, ), # 3
- (4, TType.STRING, 'publicKey', None, None, ), # 4
- (5, TType.STRING, 'privateKey', None, None, ), # 5
- (6, TType.I64, 'persistedTime', None, None, ), # 6
- (7, TType.STRING, 'token', None, None, ), # 7
- (8, TType.STRING, 'description', None, None, ), # 8
- (9, TType.I32, 'credentialOwnerType', None, 0, ), # 9
- )
-
- def __init__(self, gatewayId=None, username=None, passphrase=None, publicKey=None, privateKey=None, persistedTime=None, token=None, description=None, credentialOwnerType=thrift_spec[9][4],):
- self.gatewayId = gatewayId
- self.username = username
- self.passphrase = passphrase
- self.publicKey = publicKey
- self.privateKey = privateKey
- self.persistedTime = persistedTime
- self.token = token
- self.description = description
- self.credentialOwnerType = credentialOwnerType
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.username = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.passphrase = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.publicKey = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.privateKey = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.I64:
- self.persistedTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.STRING:
- self.token = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.STRING:
- self.description = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.I32:
- self.credentialOwnerType = iprot.readI32()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('SSHCredential')
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 1)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- if self.username is not None:
- oprot.writeFieldBegin('username', TType.STRING, 2)
- oprot.writeString(self.username)
- oprot.writeFieldEnd()
- if self.passphrase is not None:
- oprot.writeFieldBegin('passphrase', TType.STRING, 3)
- oprot.writeString(self.passphrase)
- oprot.writeFieldEnd()
- if self.publicKey is not None:
- oprot.writeFieldBegin('publicKey', TType.STRING, 4)
- oprot.writeString(self.publicKey)
- oprot.writeFieldEnd()
- if self.privateKey is not None:
- oprot.writeFieldBegin('privateKey', TType.STRING, 5)
- oprot.writeString(self.privateKey)
- oprot.writeFieldEnd()
- if self.persistedTime is not None:
- oprot.writeFieldBegin('persistedTime', TType.I64, 6)
- oprot.writeI64(self.persistedTime)
- oprot.writeFieldEnd()
- if self.token is not None:
- oprot.writeFieldBegin('token', TType.STRING, 7)
- oprot.writeString(self.token)
- oprot.writeFieldEnd()
- if self.description is not None:
- oprot.writeFieldBegin('description', TType.STRING, 8)
- oprot.writeString(self.description)
- oprot.writeFieldEnd()
- if self.credentialOwnerType is not None:
- oprot.writeFieldBegin('credentialOwnerType', TType.I32, 9)
- oprot.writeI32(self.credentialOwnerType)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- if self.username is None:
- raise TProtocol.TProtocolException(message='Required field username is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.gatewayId)
- value = (value * 31) ^ hash(self.username)
- value = (value * 31) ^ hash(self.passphrase)
- value = (value * 31) ^ hash(self.publicKey)
- value = (value * 31) ^ hash(self.privateKey)
- value = (value * 31) ^ hash(self.persistedTime)
- value = (value * 31) ^ hash(self.token)
- value = (value * 31) ^ hash(self.description)
- value = (value * 31) ^ hash(self.credentialOwnerType)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class CredentialSummary:
- """
- Attributes:
- - type
- - gatewayId
- - username
- - publicKey
- - persistedTime
- - token
- - description
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'type', None, None, ), # 1
- (2, TType.STRING, 'gatewayId', None, None, ), # 2
- (3, TType.STRING, 'username', None, None, ), # 3
- (4, TType.STRING, 'publicKey', None, None, ), # 4
- (5, TType.I64, 'persistedTime', None, None, ), # 5
- (6, TType.STRING, 'token', None, None, ), # 6
- (7, TType.STRING, 'description', None, None, ), # 7
- )
-
- def __init__(self, type=None, gatewayId=None, username=None, publicKey=None, persistedTime=None, token=None, description=None,):
- self.type = type
- self.gatewayId = gatewayId
- self.username = username
- self.publicKey = publicKey
- self.persistedTime = persistedTime
- self.token = token
- self.description = description
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.type = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.username = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.publicKey = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I64:
- self.persistedTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.token = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.STRING:
- self.description = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('CredentialSummary')
- if self.type is not None:
- oprot.writeFieldBegin('type', TType.I32, 1)
- oprot.writeI32(self.type)
- oprot.writeFieldEnd()
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 2)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- if self.username is not None:
- oprot.writeFieldBegin('username', TType.STRING, 3)
- oprot.writeString(self.username)
- oprot.writeFieldEnd()
- if self.publicKey is not None:
- oprot.writeFieldBegin('publicKey', TType.STRING, 4)
- oprot.writeString(self.publicKey)
- oprot.writeFieldEnd()
- if self.persistedTime is not None:
- oprot.writeFieldBegin('persistedTime', TType.I64, 5)
- oprot.writeI64(self.persistedTime)
- oprot.writeFieldEnd()
- if self.token is not None:
- oprot.writeFieldBegin('token', TType.STRING, 6)
- oprot.writeString(self.token)
- oprot.writeFieldEnd()
- if self.description is not None:
- oprot.writeFieldBegin('description', TType.STRING, 7)
- oprot.writeString(self.description)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.type is None:
- raise TProtocol.TProtocolException(message='Required field type is unset!')
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- if self.username is None:
- raise TProtocol.TProtocolException(message='Required field username is unset!')
- if self.token is None:
- raise TProtocol.TProtocolException(message='Required field token is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.type)
- value = (value * 31) ^ hash(self.gatewayId)
- value = (value * 31) ^ hash(self.username)
- value = (value * 31) ^ hash(self.publicKey)
- value = (value * 31) ^ hash(self.persistedTime)
- value = (value * 31) ^ hash(self.token)
- value = (value * 31) ^ hash(self.description)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class CommunityUser:
- """
- Attributes:
- - gatewayName
- - username
- - userEmail
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'gatewayName', None, None, ), # 1
- (2, TType.STRING, 'username', None, None, ), # 2
- (3, TType.STRING, 'userEmail', None, None, ), # 3
- )
-
- def __init__(self, gatewayName=None, username=None, userEmail=None,):
- self.gatewayName = gatewayName
- self.username = username
- self.userEmail = userEmail
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.gatewayName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.username = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.userEmail = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('CommunityUser')
- if self.gatewayName is not None:
- oprot.writeFieldBegin('gatewayName', TType.STRING, 1)
- oprot.writeString(self.gatewayName)
- oprot.writeFieldEnd()
- if self.username is not None:
- oprot.writeFieldBegin('username', TType.STRING, 2)
- oprot.writeString(self.username)
- oprot.writeFieldEnd()
- if self.userEmail is not None:
- oprot.writeFieldBegin('userEmail', TType.STRING, 3)
- oprot.writeString(self.userEmail)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.gatewayName is None:
- raise TProtocol.TProtocolException(message='Required field gatewayName is unset!')
- if self.username is None:
- raise TProtocol.TProtocolException(message='Required field username is unset!')
- if self.userEmail is None:
- raise TProtocol.TProtocolException(message='Required field userEmail is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.gatewayName)
- value = (value * 31) ^ hash(self.username)
- value = (value * 31) ^ hash(self.userEmail)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class CertificateCredential:
- """
- Attributes:
- - communityUser
- - x509Cert
- - notAfter
- - privateKey
- - lifeTime
- - notBefore
- - persistedTime
- - token
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRUCT, 'communityUser', (CommunityUser, CommunityUser.thrift_spec), None, ), # 1
- (2, TType.STRING, 'x509Cert', None, None, ), # 2
- (3, TType.STRING, 'notAfter', None, None, ), # 3
- (4, TType.STRING, 'privateKey', None, None, ), # 4
- (5, TType.I64, 'lifeTime', None, None, ), # 5
- (6, TType.STRING, 'notBefore', None, None, ), # 6
- (7, TType.I64, 'persistedTime', None, None, ), # 7
- (8, TType.STRING, 'token', None, None, ), # 8
- )
-
- def __init__(self, communityUser=None, x509Cert=None, notAfter=None, privateKey=None, lifeTime=None, notBefore=None, persistedTime=None, token=None,):
- self.communityUser = communityUser
- self.x509Cert = x509Cert
- self.notAfter = notAfter
- self.privateKey = privateKey
- self.lifeTime = lifeTime
- self.notBefore = notBefore
- self.persistedTime = persistedTime
- self.token = token
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRUCT:
- self.communityUser = CommunityUser()
- self.communityUser.read(iprot)
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.x509Cert = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.notAfter = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.privateKey = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I64:
- self.lifeTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.notBefore = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.I64:
- self.persistedTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.STRING:
- self.token = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('CertificateCredential')
- if self.communityUser is not None:
- oprot.writeFieldBegin('communityUser', TType.STRUCT, 1)
- self.communityUser.write(oprot)
- oprot.writeFieldEnd()
- if self.x509Cert is not None:
- oprot.writeFieldBegin('x509Cert', TType.STRING, 2)
- oprot.writeString(self.x509Cert)
- oprot.writeFieldEnd()
- if self.notAfter is not None:
- oprot.writeFieldBegin('notAfter', TType.STRING, 3)
- oprot.writeString(self.notAfter)
- oprot.writeFieldEnd()
- if self.privateKey is not None:
- oprot.writeFieldBegin('privateKey', TType.STRING, 4)
- oprot.writeString(self.privateKey)
- oprot.writeFieldEnd()
- if self.lifeTime is not None:
- oprot.writeFieldBegin('lifeTime', TType.I64, 5)
- oprot.writeI64(self.lifeTime)
- oprot.writeFieldEnd()
- if self.notBefore is not None:
- oprot.writeFieldBegin('notBefore', TType.STRING, 6)
- oprot.writeString(self.notBefore)
- oprot.writeFieldEnd()
- if self.persistedTime is not None:
- oprot.writeFieldBegin('persistedTime', TType.I64, 7)
- oprot.writeI64(self.persistedTime)
- oprot.writeFieldEnd()
- if self.token is not None:
- oprot.writeFieldBegin('token', TType.STRING, 8)
- oprot.writeString(self.token)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.communityUser is None:
- raise TProtocol.TProtocolException(message='Required field communityUser is unset!')
- if self.x509Cert is None:
- raise TProtocol.TProtocolException(message='Required field x509Cert is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.communityUser)
- value = (value * 31) ^ hash(self.x509Cert)
- value = (value * 31) ^ hash(self.notAfter)
- value = (value * 31) ^ hash(self.privateKey)
- value = (value * 31) ^ hash(self.lifeTime)
- value = (value * 31) ^ hash(self.notBefore)
- value = (value * 31) ^ hash(self.persistedTime)
- value = (value * 31) ^ hash(self.token)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class PasswordCredential:
- """
- Attributes:
- - gatewayId
- - portalUserName
- - loginUserName
- - password
- - description
- - persistedTime
- - token
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'gatewayId', None, None, ), # 1
- (2, TType.STRING, 'portalUserName', None, None, ), # 2
- (3, TType.STRING, 'loginUserName', None, None, ), # 3
- (4, TType.STRING, 'password', None, None, ), # 4
- (5, TType.STRING, 'description', None, None, ), # 5
- (6, TType.I64, 'persistedTime', None, None, ), # 6
- (7, TType.STRING, 'token', None, None, ), # 7
- )
-
- def __init__(self, gatewayId=None, portalUserName=None, loginUserName=None, password=None, description=None, persistedTime=None, token=None,):
- self.gatewayId = gatewayId
- self.portalUserName = portalUserName
- self.loginUserName = loginUserName
- self.password = password
- self.description = description
- self.persistedTime = persistedTime
- self.token = token
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.portalUserName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.loginUserName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.password = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.description = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.I64:
- self.persistedTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.STRING:
- self.token = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('PasswordCredential')
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 1)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- if self.portalUserName is not None:
- oprot.writeFieldBegin('portalUserName', TType.STRING, 2)
- oprot.writeString(self.portalUserName)
- oprot.writeFieldEnd()
- if self.loginUserName is not None:
- oprot.writeFieldBegin('loginUserName', TType.STRING, 3)
- oprot.writeString(self.loginUserName)
- oprot.writeFieldEnd()
- if self.password is not None:
- oprot.writeFieldBegin('password', TType.STRING, 4)
- oprot.writeString(self.password)
- oprot.writeFieldEnd()
- if self.description is not None:
- oprot.writeFieldBegin('description', TType.STRING, 5)
- oprot.writeString(self.description)
- oprot.writeFieldEnd()
- if self.persistedTime is not None:
- oprot.writeFieldBegin('persistedTime', TType.I64, 6)
- oprot.writeI64(self.persistedTime)
- oprot.writeFieldEnd()
- if self.token is not None:
- oprot.writeFieldBegin('token', TType.STRING, 7)
- oprot.writeString(self.token)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- if self.portalUserName is None:
- raise TProtocol.TProtocolException(message='Required field portalUserName is unset!')
- if self.loginUserName is None:
- raise TProtocol.TProtocolException(message='Required field loginUserName is unset!')
- if self.password is None:
- raise TProtocol.TProtocolException(message='Required field password is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.gatewayId)
- value = (value * 31) ^ hash(self.portalUserName)
- value = (value * 31) ^ hash(self.loginUserName)
- value = (value * 31) ^ hash(self.password)
- value = (value * 31) ^ hash(self.description)
- value = (value * 31) ^ hash(self.persistedTime)
- value = (value * 31) ^ hash(self.token)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class CredentialOwnerType(object):
+ GATEWAY = 0
+ USER = 1
+
+ _VALUES_TO_NAMES = {
+ 0: "GATEWAY",
+ 1: "USER",
+ }
+
+ _NAMES_TO_VALUES = {
+ "GATEWAY": 0,
+ "USER": 1,
+ }
+
+
+class SummaryType(object):
+ """
+ Data Types supported in Airavata. The primitive data types
+
+ """
+ SSH = 0
+ PASSWD = 1
+ CERT = 2
+
+ _VALUES_TO_NAMES = {
+ 0: "SSH",
+ 1: "PASSWD",
+ 2: "CERT",
+ }
+
+ _NAMES_TO_VALUES = {
+ "SSH": 0,
+ "PASSWD": 1,
+ "CERT": 2,
+ }
+
+
+class SSHCredential(object):
+ """
+ Attributes:
+ - gatewayId
+ - username
+ - passphrase
+ - publicKey
+ - privateKey
+ - persistedTime
+ - token
+ - description
+ - credentialOwnerType
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'gatewayId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'username', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'passphrase', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'publicKey', 'UTF8', None, ), # 4
+ (5, TType.STRING, 'privateKey', 'UTF8', None, ), # 5
+ (6, TType.I64, 'persistedTime', None, None, ), # 6
+ (7, TType.STRING, 'token', 'UTF8', None, ), # 7
+ (8, TType.STRING, 'description', 'UTF8', None, ), # 8
+ (9, TType.I32, 'credentialOwnerType', None, 0, ), # 9
+ )
+
+ def __init__(self, gatewayId=None, username=None, passphrase=None, publicKey=None, privateKey=None, persistedTime=None, token=None, description=None, credentialOwnerType=thrift_spec[9][4],):
+ self.gatewayId = gatewayId
+ self.username = username
+ self.passphrase = passphrase
+ self.publicKey = publicKey
+ self.privateKey = privateKey
+ self.persistedTime = persistedTime
+ self.token = token
+ self.description = description
+ self.credentialOwnerType = credentialOwnerType
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.username = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.passphrase = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.publicKey = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRING:
+ self.privateKey = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.I64:
+ self.persistedTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.STRING:
+ self.token = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.STRING:
+ self.description = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.I32:
+ self.credentialOwnerType = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('SSHCredential')
+ if self.gatewayId is not None:
+ oprot.writeFieldBegin('gatewayId', TType.STRING, 1)
+ oprot.writeString(self.gatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayId)
+ oprot.writeFieldEnd()
+ if self.username is not None:
+ oprot.writeFieldBegin('username', TType.STRING, 2)
+ oprot.writeString(self.username.encode('utf-8') if sys.version_info[0] == 2 else self.username)
+ oprot.writeFieldEnd()
+ if self.passphrase is not None:
+ oprot.writeFieldBegin('passphrase', TType.STRING, 3)
+ oprot.writeString(self.passphrase.encode('utf-8') if sys.version_info[0] == 2 else self.passphrase)
+ oprot.writeFieldEnd()
+ if self.publicKey is not None:
+ oprot.writeFieldBegin('publicKey', TType.STRING, 4)
+ oprot.writeString(self.publicKey.encode('utf-8') if sys.version_info[0] == 2 else self.publicKey)
+ oprot.writeFieldEnd()
+ if self.privateKey is not None:
+ oprot.writeFieldBegin('privateKey', TType.STRING, 5)
+ oprot.writeString(self.privateKey.encode('utf-8') if sys.version_info[0] == 2 else self.privateKey)
+ oprot.writeFieldEnd()
+ if self.persistedTime is not None:
+ oprot.writeFieldBegin('persistedTime', TType.I64, 6)
+ oprot.writeI64(self.persistedTime)
+ oprot.writeFieldEnd()
+ if self.token is not None:
+ oprot.writeFieldBegin('token', TType.STRING, 7)
+ oprot.writeString(self.token.encode('utf-8') if sys.version_info[0] == 2 else self.token)
+ oprot.writeFieldEnd()
+ if self.description is not None:
+ oprot.writeFieldBegin('description', TType.STRING, 8)
+ oprot.writeString(self.description.encode('utf-8') if sys.version_info[0] == 2 else self.description)
+ oprot.writeFieldEnd()
+ if self.credentialOwnerType is not None:
+ oprot.writeFieldBegin('credentialOwnerType', TType.I32, 9)
+ oprot.writeI32(self.credentialOwnerType)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.gatewayId is None:
+ raise TProtocolException(message='Required field gatewayId is unset!')
+ if self.username is None:
+ raise TProtocolException(message='Required field username is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class CredentialSummary(object):
+ """
+ Attributes:
+ - type
+ - gatewayId
+ - username
+ - publicKey
+ - persistedTime
+ - token
+ - description
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'type', None, None, ), # 1
+ (2, TType.STRING, 'gatewayId', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'username', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'publicKey', 'UTF8', None, ), # 4
+ (5, TType.I64, 'persistedTime', None, None, ), # 5
+ (6, TType.STRING, 'token', 'UTF8', None, ), # 6
+ (7, TType.STRING, 'description', 'UTF8', None, ), # 7
+ )
+
+ def __init__(self, type=None, gatewayId=None, username=None, publicKey=None, persistedTime=None, token=None, description=None,):
+ self.type = type
+ self.gatewayId = gatewayId
+ self.username = username
+ self.publicKey = publicKey
+ self.persistedTime = persistedTime
+ self.token = token
+ self.description = description
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.type = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.username = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.publicKey = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.I64:
+ self.persistedTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.token = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.STRING:
+ self.description = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('CredentialSummary')
+ if self.type is not None:
+ oprot.writeFieldBegin('type', TType.I32, 1)
+ oprot.writeI32(self.type)
+ oprot.writeFieldEnd()
+ if self.gatewayId is not None:
+ oprot.writeFieldBegin('gatewayId', TType.STRING, 2)
+ oprot.writeString(self.gatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayId)
+ oprot.writeFieldEnd()
+ if self.username is not None:
+ oprot.writeFieldBegin('username', TType.STRING, 3)
+ oprot.writeString(self.username.encode('utf-8') if sys.version_info[0] == 2 else self.username)
+ oprot.writeFieldEnd()
+ if self.publicKey is not None:
+ oprot.writeFieldBegin('publicKey', TType.STRING, 4)
+ oprot.writeString(self.publicKey.encode('utf-8') if sys.version_info[0] == 2 else self.publicKey)
+ oprot.writeFieldEnd()
+ if self.persistedTime is not None:
+ oprot.writeFieldBegin('persistedTime', TType.I64, 5)
+ oprot.writeI64(self.persistedTime)
+ oprot.writeFieldEnd()
+ if self.token is not None:
+ oprot.writeFieldBegin('token', TType.STRING, 6)
+ oprot.writeString(self.token.encode('utf-8') if sys.version_info[0] == 2 else self.token)
+ oprot.writeFieldEnd()
+ if self.description is not None:
+ oprot.writeFieldBegin('description', TType.STRING, 7)
+ oprot.writeString(self.description.encode('utf-8') if sys.version_info[0] == 2 else self.description)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.type is None:
+ raise TProtocolException(message='Required field type is unset!')
+ if self.gatewayId is None:
+ raise TProtocolException(message='Required field gatewayId is unset!')
+ if self.username is None:
+ raise TProtocolException(message='Required field username is unset!')
+ if self.token is None:
+ raise TProtocolException(message='Required field token is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class CommunityUser(object):
+ """
+ Attributes:
+ - gatewayName
+ - username
+ - userEmail
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'gatewayName', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'username', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'userEmail', 'UTF8', None, ), # 3
+ )
+
+ def __init__(self, gatewayName=None, username=None, userEmail=None,):
+ self.gatewayName = gatewayName
+ self.username = username
+ self.userEmail = userEmail
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.gatewayName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.username = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.userEmail = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('CommunityUser')
+ if self.gatewayName is not None:
+ oprot.writeFieldBegin('gatewayName', TType.STRING, 1)
+ oprot.writeString(self.gatewayName.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayName)
+ oprot.writeFieldEnd()
+ if self.username is not None:
+ oprot.writeFieldBegin('username', TType.STRING, 2)
+ oprot.writeString(self.username.encode('utf-8') if sys.version_info[0] == 2 else self.username)
+ oprot.writeFieldEnd()
+ if self.userEmail is not None:
+ oprot.writeFieldBegin('userEmail', TType.STRING, 3)
+ oprot.writeString(self.userEmail.encode('utf-8') if sys.version_info[0] == 2 else self.userEmail)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.gatewayName is None:
+ raise TProtocolException(message='Required field gatewayName is unset!')
+ if self.username is None:
+ raise TProtocolException(message='Required field username is unset!')
+ if self.userEmail is None:
+ raise TProtocolException(message='Required field userEmail is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class CertificateCredential(object):
+ """
+ Attributes:
+ - communityUser
+ - x509Cert
+ - notAfter
+ - privateKey
+ - lifeTime
+ - notBefore
+ - persistedTime
+ - token
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRUCT, 'communityUser', (CommunityUser, CommunityUser.thrift_spec), None, ), # 1
+ (2, TType.STRING, 'x509Cert', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'notAfter', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'privateKey', 'UTF8', None, ), # 4
+ (5, TType.I64, 'lifeTime', None, None, ), # 5
+ (6, TType.STRING, 'notBefore', 'UTF8', None, ), # 6
+ (7, TType.I64, 'persistedTime', None, None, ), # 7
+ (8, TType.STRING, 'token', 'UTF8', None, ), # 8
+ )
+
+ def __init__(self, communityUser=None, x509Cert=None, notAfter=None, privateKey=None, lifeTime=None, notBefore=None, persistedTime=None, token=None,):
+ self.communityUser = communityUser
+ self.x509Cert = x509Cert
+ self.notAfter = notAfter
+ self.privateKey = privateKey
+ self.lifeTime = lifeTime
+ self.notBefore = notBefore
+ self.persistedTime = persistedTime
+ self.token = token
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRUCT:
+ self.communityUser = CommunityUser()
+ self.communityUser.read(iprot)
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.x509Cert = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.notAfter = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.privateKey = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.I64:
+ self.lifeTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.notBefore = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.I64:
+ self.persistedTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.STRING:
+ self.token = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('CertificateCredential')
+ if self.communityUser is not None:
+ oprot.writeFieldBegin('communityUser', TType.STRUCT, 1)
+ self.communityUser.write(oprot)
+ oprot.writeFieldEnd()
+ if self.x509Cert is not None:
+ oprot.writeFieldBegin('x509Cert', TType.STRING, 2)
+ oprot.writeString(self.x509Cert.encode('utf-8') if sys.version_info[0] == 2 else self.x509Cert)
+ oprot.writeFieldEnd()
+ if self.notAfter is not None:
+ oprot.writeFieldBegin('notAfter', TType.STRING, 3)
+ oprot.writeString(self.notAfter.encode('utf-8') if sys.version_info[0] == 2 else self.notAfter)
+ oprot.writeFieldEnd()
+ if self.privateKey is not None:
+ oprot.writeFieldBegin('privateKey', TType.STRING, 4)
+ oprot.writeString(self.privateKey.encode('utf-8') if sys.version_info[0] == 2 else self.privateKey)
+ oprot.writeFieldEnd()
+ if self.lifeTime is not None:
+ oprot.writeFieldBegin('lifeTime', TType.I64, 5)
+ oprot.writeI64(self.lifeTime)
+ oprot.writeFieldEnd()
+ if self.notBefore is not None:
+ oprot.writeFieldBegin('notBefore', TType.STRING, 6)
+ oprot.writeString(self.notBefore.encode('utf-8') if sys.version_info[0] == 2 else self.notBefore)
+ oprot.writeFieldEnd()
+ if self.persistedTime is not None:
+ oprot.writeFieldBegin('persistedTime', TType.I64, 7)
+ oprot.writeI64(self.persistedTime)
+ oprot.writeFieldEnd()
+ if self.token is not None:
+ oprot.writeFieldBegin('token', TType.STRING, 8)
+ oprot.writeString(self.token.encode('utf-8') if sys.version_info[0] == 2 else self.token)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.communityUser is None:
+ raise TProtocolException(message='Required field communityUser is unset!')
+ if self.x509Cert is None:
+ raise TProtocolException(message='Required field x509Cert is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class PasswordCredential(object):
+ """
+ Attributes:
+ - gatewayId
+ - portalUserName
+ - loginUserName
+ - password
+ - description
+ - persistedTime
+ - token
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'gatewayId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'portalUserName', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'loginUserName', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'password', 'UTF8', None, ), # 4
+ (5, TType.STRING, 'description', 'UTF8', None, ), # 5
+ (6, TType.I64, 'persistedTime', None, None, ), # 6
+ (7, TType.STRING, 'token', 'UTF8', None, ), # 7
+ )
+
+ def __init__(self, gatewayId=None, portalUserName=None, loginUserName=None, password=None, description=None, persistedTime=None, token=None,):
+ self.gatewayId = gatewayId
+ self.portalUserName = portalUserName
+ self.loginUserName = loginUserName
+ self.password = password
+ self.description = description
+ self.persistedTime = persistedTime
+ self.token = token
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.portalUserName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.loginUserName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.password = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRING:
+ self.description = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.I64:
+ self.persistedTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.STRING:
+ self.token = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('PasswordCredential')
+ if self.gatewayId is not None:
+ oprot.writeFieldBegin('gatewayId', TType.STRING, 1)
+ oprot.writeString(self.gatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayId)
+ oprot.writeFieldEnd()
+ if self.portalUserName is not None:
+ oprot.writeFieldBegin('portalUserName', TType.STRING, 2)
+ oprot.writeString(self.portalUserName.encode('utf-8') if sys.version_info[0] == 2 else self.portalUserName)
+ oprot.writeFieldEnd()
+ if self.loginUserName is not None:
+ oprot.writeFieldBegin('loginUserName', TType.STRING, 3)
+ oprot.writeString(self.loginUserName.encode('utf-8') if sys.version_info[0] == 2 else self.loginUserName)
+ oprot.writeFieldEnd()
+ if self.password is not None:
+ oprot.writeFieldBegin('password', TType.STRING, 4)
+ oprot.writeString(self.password.encode('utf-8') if sys.version_info[0] == 2 else self.password)
+ oprot.writeFieldEnd()
+ if self.description is not None:
+ oprot.writeFieldBegin('description', TType.STRING, 5)
+ oprot.writeString(self.description.encode('utf-8') if sys.version_info[0] == 2 else self.description)
+ oprot.writeFieldEnd()
+ if self.persistedTime is not None:
+ oprot.writeFieldBegin('persistedTime', TType.I64, 6)
+ oprot.writeI64(self.persistedTime)
+ oprot.writeFieldEnd()
+ if self.token is not None:
+ oprot.writeFieldBegin('token', TType.STRING, 7)
+ oprot.writeString(self.token.encode('utf-8') if sys.version_info[0] == 2 else self.token)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.gatewayId is None:
+ raise TProtocolException(message='Required field gatewayId is unset!')
+ if self.portalUserName is None:
+ raise TProtocolException(message='Required field portalUserName is unset!')
+ if self.loginUserName is None:
+ raise TProtocolException(message='Required field loginUserName is unset!')
+ if self.password is None:
+ raise TProtocolException(message='Required field password is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/ComponentState.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/ComponentState.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/ComponentState.java
index 1e68782..5015794 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/ComponentState.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/ComponentState.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/ComponentStatus.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/ComponentStatus.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/ComponentStatus.java
index 4da27d6..bbe4e6a 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/ComponentStatus.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/ComponentStatus.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus, ComponentStatus._Fields>, java.io.Serializable, Cloneable, Comparable<ComponentStatus> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ComponentStatus");
@@ -59,14 +32,11 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
private static final org.apache.thrift.protocol.TField REASON_FIELD_DESC = new org.apache.thrift.protocol.TField("reason", org.apache.thrift.protocol.TType.STRING, (short)2);
private static final org.apache.thrift.protocol.TField TIMEOF_STATE_CHANGE_FIELD_DESC = new org.apache.thrift.protocol.TField("timeofStateChange", org.apache.thrift.protocol.TType.I64, (short)3);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new ComponentStatusStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ComponentStatusTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ComponentStatusStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ComponentStatusTupleSchemeFactory();
private ComponentState state; // required
- private String reason; // optional
+ private java.lang.String reason; // optional
private long timeofStateChange; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
@@ -79,10 +49,10 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
REASON((short)2, "reason"),
TIMEOF_STATE_CHANGE((short)3, "timeofStateChange");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -109,21 +79,21 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -132,7 +102,7 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -141,16 +111,16 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
private static final int __TIMEOFSTATECHANGE_ISSET_ID = 0;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.REASON,_Fields.TIMEOF_STATE_CHANGE};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.STATE, new org.apache.thrift.meta_data.FieldMetaData("state", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, ComponentState.class)));
tmpMap.put(_Fields.REASON, new org.apache.thrift.meta_data.FieldMetaData("reason", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.TIMEOF_STATE_CHANGE, new org.apache.thrift.meta_data.FieldMetaData("timeofStateChange", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ComponentStatus.class, metaDataMap);
}
@@ -224,11 +194,11 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
}
}
- public String getReason() {
+ public java.lang.String getReason() {
return this.reason;
}
- public void setReason(String reason) {
+ public void setReason(java.lang.String reason) {
this.reason = reason;
}
@@ -257,19 +227,19 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
}
public void unsetTimeofStateChange() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __TIMEOFSTATECHANGE_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __TIMEOFSTATECHANGE_ISSET_ID);
}
/** Returns true if field timeofStateChange is set (has been assigned a value) and false otherwise */
public boolean isSetTimeofStateChange() {
- return EncodingUtils.testBit(__isset_bitfield, __TIMEOFSTATECHANGE_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __TIMEOFSTATECHANGE_ISSET_ID);
}
public void setTimeofStateChangeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __TIMEOFSTATECHANGE_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __TIMEOFSTATECHANGE_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case STATE:
if (value == null) {
@@ -283,7 +253,7 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
if (value == null) {
unsetReason();
} else {
- setReason((String)value);
+ setReason((java.lang.String)value);
}
break;
@@ -291,14 +261,14 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
if (value == null) {
unsetTimeofStateChange();
} else {
- setTimeofStateChange((Long)value);
+ setTimeofStateChange((java.lang.Long)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case STATE:
return getState();
@@ -310,13 +280,13 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
return getTimeofStateChange();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -327,11 +297,11 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
case TIMEOF_STATE_CHANGE:
return isSetTimeofStateChange();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ComponentStatus)
@@ -342,6 +312,8 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
public boolean equals(ComponentStatus that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_state = true && this.isSetState();
boolean that_present_state = true && that.isSetState();
@@ -375,24 +347,21 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_state = true && (isSetState());
- list.add(present_state);
- if (present_state)
- list.add(state.getValue());
+ hashCode = hashCode * 8191 + ((isSetState()) ? 131071 : 524287);
+ if (isSetState())
+ hashCode = hashCode * 8191 + state.getValue();
- boolean present_reason = true && (isSetReason());
- list.add(present_reason);
- if (present_reason)
- list.add(reason);
+ hashCode = hashCode * 8191 + ((isSetReason()) ? 131071 : 524287);
+ if (isSetReason())
+ hashCode = hashCode * 8191 + reason.hashCode();
- boolean present_timeofStateChange = true && (isSetTimeofStateChange());
- list.add(present_timeofStateChange);
- if (present_timeofStateChange)
- list.add(timeofStateChange);
+ hashCode = hashCode * 8191 + ((isSetTimeofStateChange()) ? 131071 : 524287);
+ if (isSetTimeofStateChange())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(timeofStateChange);
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -403,7 +372,7 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetState()).compareTo(other.isSetState());
+ lastComparison = java.lang.Boolean.valueOf(isSetState()).compareTo(other.isSetState());
if (lastComparison != 0) {
return lastComparison;
}
@@ -413,7 +382,7 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetReason()).compareTo(other.isSetReason());
+ lastComparison = java.lang.Boolean.valueOf(isSetReason()).compareTo(other.isSetReason());
if (lastComparison != 0) {
return lastComparison;
}
@@ -423,7 +392,7 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetTimeofStateChange()).compareTo(other.isSetTimeofStateChange());
+ lastComparison = java.lang.Boolean.valueOf(isSetTimeofStateChange()).compareTo(other.isSetTimeofStateChange());
if (lastComparison != 0) {
return lastComparison;
}
@@ -441,16 +410,16 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ComponentStatus(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ComponentStatus(");
boolean first = true;
sb.append("state:");
@@ -497,7 +466,7 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -507,13 +476,13 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
}
}
- private static class ComponentStatusStandardSchemeFactory implements SchemeFactory {
+ private static class ComponentStatusStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ComponentStatusStandardScheme getScheme() {
return new ComponentStatusStandardScheme();
}
}
- private static class ComponentStatusStandardScheme extends StandardScheme<ComponentStatus> {
+ private static class ComponentStatusStandardScheme extends org.apache.thrift.scheme.StandardScheme<ComponentStatus> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ComponentStatus struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -585,19 +554,19 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
}
- private static class ComponentStatusTupleSchemeFactory implements SchemeFactory {
+ private static class ComponentStatusTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ComponentStatusTupleScheme getScheme() {
return new ComponentStatusTupleScheme();
}
}
- private static class ComponentStatusTupleScheme extends TupleScheme<ComponentStatus> {
+ private static class ComponentStatusTupleScheme extends org.apache.thrift.scheme.TupleScheme<ComponentStatus> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ComponentStatus struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeI32(struct.state.getValue());
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetReason()) {
optionals.set(0);
}
@@ -615,10 +584,10 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ComponentStatus struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.state = org.apache.airavata.model.ComponentState.findByValue(iprot.readI32());
struct.setStateIsSet(true);
- BitSet incoming = iprot.readBitSet(2);
+ java.util.BitSet incoming = iprot.readBitSet(2);
if (incoming.get(0)) {
struct.reason = iprot.readString();
struct.setReasonIsSet(true);
@@ -630,5 +599,8 @@ public class ComponentStatus implements org.apache.thrift.TBase<ComponentStatus,
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
[04/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentModel.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentModel.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentModel.java
index 7b01741..7adceff 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentModel.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentModel.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.experiment;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* A structure holding the experiment metadata and its child models.
*
@@ -67,7 +40,7 @@ import org.slf4j.LoggerFactory;
* experimentDescription:
* The verbose description of the experiment. This is an optional parameter.
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel, ExperimentModel._Fields>, java.io.Serializable, Cloneable, Comparable<ExperimentModel> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ExperimentModel");
@@ -91,31 +64,28 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
private static final org.apache.thrift.protocol.TField ERRORS_FIELD_DESC = new org.apache.thrift.protocol.TField("errors", org.apache.thrift.protocol.TType.LIST, (short)18);
private static final org.apache.thrift.protocol.TField PROCESSES_FIELD_DESC = new org.apache.thrift.protocol.TField("processes", org.apache.thrift.protocol.TType.LIST, (short)19);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new ExperimentModelStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ExperimentModelTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ExperimentModelStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ExperimentModelTupleSchemeFactory();
- private String experimentId; // required
- private String projectId; // required
- private String gatewayId; // required
+ private java.lang.String experimentId; // required
+ private java.lang.String projectId; // required
+ private java.lang.String gatewayId; // required
private ExperimentType experimentType; // required
- private String userName; // required
- private String experimentName; // required
+ private java.lang.String userName; // required
+ private java.lang.String experimentName; // required
private long creationTime; // optional
- private String description; // optional
- private String executionId; // optional
- private String gatewayExecutionId; // optional
- private String gatewayInstanceId; // optional
+ private java.lang.String description; // optional
+ private java.lang.String executionId; // optional
+ private java.lang.String gatewayExecutionId; // optional
+ private java.lang.String gatewayInstanceId; // optional
private boolean enableEmailNotification; // optional
- private List<String> emailAddresses; // optional
+ private java.util.List<java.lang.String> emailAddresses; // optional
private UserConfigurationDataModel userConfigurationData; // optional
- private List<org.apache.airavata.model.application.io.InputDataObjectType> experimentInputs; // optional
- private List<org.apache.airavata.model.application.io.OutputDataObjectType> experimentOutputs; // optional
- private List<org.apache.airavata.model.status.ExperimentStatus> experimentStatus; // optional
- private List<org.apache.airavata.model.commons.ErrorModel> errors; // optional
- private List<org.apache.airavata.model.process.ProcessModel> processes; // optional
+ private java.util.List<org.apache.airavata.model.application.io.InputDataObjectType> experimentInputs; // optional
+ private java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType> experimentOutputs; // optional
+ private java.util.List<org.apache.airavata.model.status.ExperimentStatus> experimentStatus; // optional
+ private java.util.List<org.apache.airavata.model.commons.ErrorModel> errors; // optional
+ private java.util.List<org.apache.airavata.model.process.ProcessModel> processes; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -143,10 +113,10 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
ERRORS((short)18, "errors"),
PROCESSES((short)19, "processes");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -205,21 +175,21 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -228,7 +198,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -238,9 +208,9 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
private static final int __ENABLEEMAILNOTIFICATION_ISSET_ID = 1;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.CREATION_TIME,_Fields.DESCRIPTION,_Fields.EXECUTION_ID,_Fields.GATEWAY_EXECUTION_ID,_Fields.GATEWAY_INSTANCE_ID,_Fields.ENABLE_EMAIL_NOTIFICATION,_Fields.EMAIL_ADDRESSES,_Fields.USER_CONFIGURATION_DATA,_Fields.EXPERIMENT_INPUTS,_Fields.EXPERIMENT_OUTPUTS,_Fields.EXPERIMENT_STATUS,_Fields.ERRORS,_Fields.PROCESSES};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.EXPERIMENT_ID, new org.apache.thrift.meta_data.FieldMetaData("experimentId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.PROJECT_ID, new org.apache.thrift.meta_data.FieldMetaData("projectId", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -285,7 +255,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
tmpMap.put(_Fields.PROCESSES, new org.apache.thrift.meta_data.FieldMetaData("processes", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, org.apache.airavata.model.process.ProcessModel.class))));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ExperimentModel.class, metaDataMap);
}
@@ -297,12 +267,12 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
}
public ExperimentModel(
- String experimentId,
- String projectId,
- String gatewayId,
+ java.lang.String experimentId,
+ java.lang.String projectId,
+ java.lang.String gatewayId,
ExperimentType experimentType,
- String userName,
- String experimentName)
+ java.lang.String userName,
+ java.lang.String experimentName)
{
this();
this.experimentId = experimentId;
@@ -351,42 +321,42 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
}
this.enableEmailNotification = other.enableEmailNotification;
if (other.isSetEmailAddresses()) {
- List<String> __this__emailAddresses = new ArrayList<String>(other.emailAddresses);
+ java.util.List<java.lang.String> __this__emailAddresses = new java.util.ArrayList<java.lang.String>(other.emailAddresses);
this.emailAddresses = __this__emailAddresses;
}
if (other.isSetUserConfigurationData()) {
this.userConfigurationData = new UserConfigurationDataModel(other.userConfigurationData);
}
if (other.isSetExperimentInputs()) {
- List<org.apache.airavata.model.application.io.InputDataObjectType> __this__experimentInputs = new ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(other.experimentInputs.size());
+ java.util.List<org.apache.airavata.model.application.io.InputDataObjectType> __this__experimentInputs = new java.util.ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(other.experimentInputs.size());
for (org.apache.airavata.model.application.io.InputDataObjectType other_element : other.experimentInputs) {
__this__experimentInputs.add(new org.apache.airavata.model.application.io.InputDataObjectType(other_element));
}
this.experimentInputs = __this__experimentInputs;
}
if (other.isSetExperimentOutputs()) {
- List<org.apache.airavata.model.application.io.OutputDataObjectType> __this__experimentOutputs = new ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(other.experimentOutputs.size());
+ java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType> __this__experimentOutputs = new java.util.ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(other.experimentOutputs.size());
for (org.apache.airavata.model.application.io.OutputDataObjectType other_element : other.experimentOutputs) {
__this__experimentOutputs.add(new org.apache.airavata.model.application.io.OutputDataObjectType(other_element));
}
this.experimentOutputs = __this__experimentOutputs;
}
if (other.isSetExperimentStatus()) {
- List<org.apache.airavata.model.status.ExperimentStatus> __this__experimentStatus = new ArrayList<org.apache.airavata.model.status.ExperimentStatus>(other.experimentStatus.size());
+ java.util.List<org.apache.airavata.model.status.ExperimentStatus> __this__experimentStatus = new java.util.ArrayList<org.apache.airavata.model.status.ExperimentStatus>(other.experimentStatus.size());
for (org.apache.airavata.model.status.ExperimentStatus other_element : other.experimentStatus) {
__this__experimentStatus.add(new org.apache.airavata.model.status.ExperimentStatus(other_element));
}
this.experimentStatus = __this__experimentStatus;
}
if (other.isSetErrors()) {
- List<org.apache.airavata.model.commons.ErrorModel> __this__errors = new ArrayList<org.apache.airavata.model.commons.ErrorModel>(other.errors.size());
+ java.util.List<org.apache.airavata.model.commons.ErrorModel> __this__errors = new java.util.ArrayList<org.apache.airavata.model.commons.ErrorModel>(other.errors.size());
for (org.apache.airavata.model.commons.ErrorModel other_element : other.errors) {
__this__errors.add(new org.apache.airavata.model.commons.ErrorModel(other_element));
}
this.errors = __this__errors;
}
if (other.isSetProcesses()) {
- List<org.apache.airavata.model.process.ProcessModel> __this__processes = new ArrayList<org.apache.airavata.model.process.ProcessModel>(other.processes.size());
+ java.util.List<org.apache.airavata.model.process.ProcessModel> __this__processes = new java.util.ArrayList<org.apache.airavata.model.process.ProcessModel>(other.processes.size());
for (org.apache.airavata.model.process.ProcessModel other_element : other.processes) {
__this__processes.add(new org.apache.airavata.model.process.ProcessModel(other_element));
}
@@ -425,11 +395,11 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
this.processes = null;
}
- public String getExperimentId() {
+ public java.lang.String getExperimentId() {
return this.experimentId;
}
- public void setExperimentId(String experimentId) {
+ public void setExperimentId(java.lang.String experimentId) {
this.experimentId = experimentId;
}
@@ -448,11 +418,11 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
}
}
- public String getProjectId() {
+ public java.lang.String getProjectId() {
return this.projectId;
}
- public void setProjectId(String projectId) {
+ public void setProjectId(java.lang.String projectId) {
this.projectId = projectId;
}
@@ -471,11 +441,11 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
}
}
- public String getGatewayId() {
+ public java.lang.String getGatewayId() {
return this.gatewayId;
}
- public void setGatewayId(String gatewayId) {
+ public void setGatewayId(java.lang.String gatewayId) {
this.gatewayId = gatewayId;
}
@@ -525,11 +495,11 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
}
}
- public String getUserName() {
+ public java.lang.String getUserName() {
return this.userName;
}
- public void setUserName(String userName) {
+ public void setUserName(java.lang.String userName) {
this.userName = userName;
}
@@ -548,11 +518,11 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
}
}
- public String getExperimentName() {
+ public java.lang.String getExperimentName() {
return this.experimentName;
}
- public void setExperimentName(String experimentName) {
+ public void setExperimentName(java.lang.String experimentName) {
this.experimentName = experimentName;
}
@@ -581,23 +551,23 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
}
public void unsetCreationTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
}
/** Returns true if field creationTime is set (has been assigned a value) and false otherwise */
public boolean isSetCreationTime() {
- return EncodingUtils.testBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
}
public void setCreationTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __CREATIONTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __CREATIONTIME_ISSET_ID, value);
}
- public String getDescription() {
+ public java.lang.String getDescription() {
return this.description;
}
- public void setDescription(String description) {
+ public void setDescription(java.lang.String description) {
this.description = description;
}
@@ -616,11 +586,11 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
}
}
- public String getExecutionId() {
+ public java.lang.String getExecutionId() {
return this.executionId;
}
- public void setExecutionId(String executionId) {
+ public void setExecutionId(java.lang.String executionId) {
this.executionId = executionId;
}
@@ -639,11 +609,11 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
}
}
- public String getGatewayExecutionId() {
+ public java.lang.String getGatewayExecutionId() {
return this.gatewayExecutionId;
}
- public void setGatewayExecutionId(String gatewayExecutionId) {
+ public void setGatewayExecutionId(java.lang.String gatewayExecutionId) {
this.gatewayExecutionId = gatewayExecutionId;
}
@@ -662,11 +632,11 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
}
}
- public String getGatewayInstanceId() {
+ public java.lang.String getGatewayInstanceId() {
return this.gatewayInstanceId;
}
- public void setGatewayInstanceId(String gatewayInstanceId) {
+ public void setGatewayInstanceId(java.lang.String gatewayInstanceId) {
this.gatewayInstanceId = gatewayInstanceId;
}
@@ -695,38 +665,38 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
}
public void unsetEnableEmailNotification() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ENABLEEMAILNOTIFICATION_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ENABLEEMAILNOTIFICATION_ISSET_ID);
}
/** Returns true if field enableEmailNotification is set (has been assigned a value) and false otherwise */
public boolean isSetEnableEmailNotification() {
- return EncodingUtils.testBit(__isset_bitfield, __ENABLEEMAILNOTIFICATION_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ENABLEEMAILNOTIFICATION_ISSET_ID);
}
public void setEnableEmailNotificationIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ENABLEEMAILNOTIFICATION_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ENABLEEMAILNOTIFICATION_ISSET_ID, value);
}
public int getEmailAddressesSize() {
return (this.emailAddresses == null) ? 0 : this.emailAddresses.size();
}
- public java.util.Iterator<String> getEmailAddressesIterator() {
+ public java.util.Iterator<java.lang.String> getEmailAddressesIterator() {
return (this.emailAddresses == null) ? null : this.emailAddresses.iterator();
}
- public void addToEmailAddresses(String elem) {
+ public void addToEmailAddresses(java.lang.String elem) {
if (this.emailAddresses == null) {
- this.emailAddresses = new ArrayList<String>();
+ this.emailAddresses = new java.util.ArrayList<java.lang.String>();
}
this.emailAddresses.add(elem);
}
- public List<String> getEmailAddresses() {
+ public java.util.List<java.lang.String> getEmailAddresses() {
return this.emailAddresses;
}
- public void setEmailAddresses(List<String> emailAddresses) {
+ public void setEmailAddresses(java.util.List<java.lang.String> emailAddresses) {
this.emailAddresses = emailAddresses;
}
@@ -778,16 +748,16 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
public void addToExperimentInputs(org.apache.airavata.model.application.io.InputDataObjectType elem) {
if (this.experimentInputs == null) {
- this.experimentInputs = new ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>();
+ this.experimentInputs = new java.util.ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>();
}
this.experimentInputs.add(elem);
}
- public List<org.apache.airavata.model.application.io.InputDataObjectType> getExperimentInputs() {
+ public java.util.List<org.apache.airavata.model.application.io.InputDataObjectType> getExperimentInputs() {
return this.experimentInputs;
}
- public void setExperimentInputs(List<org.apache.airavata.model.application.io.InputDataObjectType> experimentInputs) {
+ public void setExperimentInputs(java.util.List<org.apache.airavata.model.application.io.InputDataObjectType> experimentInputs) {
this.experimentInputs = experimentInputs;
}
@@ -816,16 +786,16 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
public void addToExperimentOutputs(org.apache.airavata.model.application.io.OutputDataObjectType elem) {
if (this.experimentOutputs == null) {
- this.experimentOutputs = new ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>();
+ this.experimentOutputs = new java.util.ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>();
}
this.experimentOutputs.add(elem);
}
- public List<org.apache.airavata.model.application.io.OutputDataObjectType> getExperimentOutputs() {
+ public java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType> getExperimentOutputs() {
return this.experimentOutputs;
}
- public void setExperimentOutputs(List<org.apache.airavata.model.application.io.OutputDataObjectType> experimentOutputs) {
+ public void setExperimentOutputs(java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType> experimentOutputs) {
this.experimentOutputs = experimentOutputs;
}
@@ -854,16 +824,16 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
public void addToExperimentStatus(org.apache.airavata.model.status.ExperimentStatus elem) {
if (this.experimentStatus == null) {
- this.experimentStatus = new ArrayList<org.apache.airavata.model.status.ExperimentStatus>();
+ this.experimentStatus = new java.util.ArrayList<org.apache.airavata.model.status.ExperimentStatus>();
}
this.experimentStatus.add(elem);
}
- public List<org.apache.airavata.model.status.ExperimentStatus> getExperimentStatus() {
+ public java.util.List<org.apache.airavata.model.status.ExperimentStatus> getExperimentStatus() {
return this.experimentStatus;
}
- public void setExperimentStatus(List<org.apache.airavata.model.status.ExperimentStatus> experimentStatus) {
+ public void setExperimentStatus(java.util.List<org.apache.airavata.model.status.ExperimentStatus> experimentStatus) {
this.experimentStatus = experimentStatus;
}
@@ -892,16 +862,16 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
public void addToErrors(org.apache.airavata.model.commons.ErrorModel elem) {
if (this.errors == null) {
- this.errors = new ArrayList<org.apache.airavata.model.commons.ErrorModel>();
+ this.errors = new java.util.ArrayList<org.apache.airavata.model.commons.ErrorModel>();
}
this.errors.add(elem);
}
- public List<org.apache.airavata.model.commons.ErrorModel> getErrors() {
+ public java.util.List<org.apache.airavata.model.commons.ErrorModel> getErrors() {
return this.errors;
}
- public void setErrors(List<org.apache.airavata.model.commons.ErrorModel> errors) {
+ public void setErrors(java.util.List<org.apache.airavata.model.commons.ErrorModel> errors) {
this.errors = errors;
}
@@ -930,16 +900,16 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
public void addToProcesses(org.apache.airavata.model.process.ProcessModel elem) {
if (this.processes == null) {
- this.processes = new ArrayList<org.apache.airavata.model.process.ProcessModel>();
+ this.processes = new java.util.ArrayList<org.apache.airavata.model.process.ProcessModel>();
}
this.processes.add(elem);
}
- public List<org.apache.airavata.model.process.ProcessModel> getProcesses() {
+ public java.util.List<org.apache.airavata.model.process.ProcessModel> getProcesses() {
return this.processes;
}
- public void setProcesses(List<org.apache.airavata.model.process.ProcessModel> processes) {
+ public void setProcesses(java.util.List<org.apache.airavata.model.process.ProcessModel> processes) {
this.processes = processes;
}
@@ -958,13 +928,13 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case EXPERIMENT_ID:
if (value == null) {
unsetExperimentId();
} else {
- setExperimentId((String)value);
+ setExperimentId((java.lang.String)value);
}
break;
@@ -972,7 +942,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (value == null) {
unsetProjectId();
} else {
- setProjectId((String)value);
+ setProjectId((java.lang.String)value);
}
break;
@@ -980,7 +950,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (value == null) {
unsetGatewayId();
} else {
- setGatewayId((String)value);
+ setGatewayId((java.lang.String)value);
}
break;
@@ -996,7 +966,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (value == null) {
unsetUserName();
} else {
- setUserName((String)value);
+ setUserName((java.lang.String)value);
}
break;
@@ -1004,7 +974,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (value == null) {
unsetExperimentName();
} else {
- setExperimentName((String)value);
+ setExperimentName((java.lang.String)value);
}
break;
@@ -1012,7 +982,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (value == null) {
unsetCreationTime();
} else {
- setCreationTime((Long)value);
+ setCreationTime((java.lang.Long)value);
}
break;
@@ -1020,7 +990,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (value == null) {
unsetDescription();
} else {
- setDescription((String)value);
+ setDescription((java.lang.String)value);
}
break;
@@ -1028,7 +998,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (value == null) {
unsetExecutionId();
} else {
- setExecutionId((String)value);
+ setExecutionId((java.lang.String)value);
}
break;
@@ -1036,7 +1006,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (value == null) {
unsetGatewayExecutionId();
} else {
- setGatewayExecutionId((String)value);
+ setGatewayExecutionId((java.lang.String)value);
}
break;
@@ -1044,7 +1014,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (value == null) {
unsetGatewayInstanceId();
} else {
- setGatewayInstanceId((String)value);
+ setGatewayInstanceId((java.lang.String)value);
}
break;
@@ -1052,7 +1022,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (value == null) {
unsetEnableEmailNotification();
} else {
- setEnableEmailNotification((Boolean)value);
+ setEnableEmailNotification((java.lang.Boolean)value);
}
break;
@@ -1060,7 +1030,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (value == null) {
unsetEmailAddresses();
} else {
- setEmailAddresses((List<String>)value);
+ setEmailAddresses((java.util.List<java.lang.String>)value);
}
break;
@@ -1076,7 +1046,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (value == null) {
unsetExperimentInputs();
} else {
- setExperimentInputs((List<org.apache.airavata.model.application.io.InputDataObjectType>)value);
+ setExperimentInputs((java.util.List<org.apache.airavata.model.application.io.InputDataObjectType>)value);
}
break;
@@ -1084,7 +1054,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (value == null) {
unsetExperimentOutputs();
} else {
- setExperimentOutputs((List<org.apache.airavata.model.application.io.OutputDataObjectType>)value);
+ setExperimentOutputs((java.util.List<org.apache.airavata.model.application.io.OutputDataObjectType>)value);
}
break;
@@ -1092,7 +1062,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (value == null) {
unsetExperimentStatus();
} else {
- setExperimentStatus((List<org.apache.airavata.model.status.ExperimentStatus>)value);
+ setExperimentStatus((java.util.List<org.apache.airavata.model.status.ExperimentStatus>)value);
}
break;
@@ -1100,7 +1070,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (value == null) {
unsetErrors();
} else {
- setErrors((List<org.apache.airavata.model.commons.ErrorModel>)value);
+ setErrors((java.util.List<org.apache.airavata.model.commons.ErrorModel>)value);
}
break;
@@ -1108,14 +1078,14 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (value == null) {
unsetProcesses();
} else {
- setProcesses((List<org.apache.airavata.model.process.ProcessModel>)value);
+ setProcesses((java.util.List<org.apache.airavata.model.process.ProcessModel>)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case EXPERIMENT_ID:
return getExperimentId();
@@ -1175,13 +1145,13 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return getProcesses();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -1224,11 +1194,11 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
case PROCESSES:
return isSetProcesses();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ExperimentModel)
@@ -1239,6 +1209,8 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
public boolean equals(ExperimentModel that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_experimentId = true && this.isSetExperimentId();
boolean that_present_experimentId = true && that.isSetExperimentId();
@@ -1416,104 +1388,85 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_experimentId = true && (isSetExperimentId());
- list.add(present_experimentId);
- if (present_experimentId)
- list.add(experimentId);
-
- boolean present_projectId = true && (isSetProjectId());
- list.add(present_projectId);
- if (present_projectId)
- list.add(projectId);
-
- boolean present_gatewayId = true && (isSetGatewayId());
- list.add(present_gatewayId);
- if (present_gatewayId)
- list.add(gatewayId);
-
- boolean present_experimentType = true && (isSetExperimentType());
- list.add(present_experimentType);
- if (present_experimentType)
- list.add(experimentType.getValue());
-
- boolean present_userName = true && (isSetUserName());
- list.add(present_userName);
- if (present_userName)
- list.add(userName);
-
- boolean present_experimentName = true && (isSetExperimentName());
- list.add(present_experimentName);
- if (present_experimentName)
- list.add(experimentName);
-
- boolean present_creationTime = true && (isSetCreationTime());
- list.add(present_creationTime);
- if (present_creationTime)
- list.add(creationTime);
-
- boolean present_description = true && (isSetDescription());
- list.add(present_description);
- if (present_description)
- list.add(description);
-
- boolean present_executionId = true && (isSetExecutionId());
- list.add(present_executionId);
- if (present_executionId)
- list.add(executionId);
-
- boolean present_gatewayExecutionId = true && (isSetGatewayExecutionId());
- list.add(present_gatewayExecutionId);
- if (present_gatewayExecutionId)
- list.add(gatewayExecutionId);
-
- boolean present_gatewayInstanceId = true && (isSetGatewayInstanceId());
- list.add(present_gatewayInstanceId);
- if (present_gatewayInstanceId)
- list.add(gatewayInstanceId);
-
- boolean present_enableEmailNotification = true && (isSetEnableEmailNotification());
- list.add(present_enableEmailNotification);
- if (present_enableEmailNotification)
- list.add(enableEmailNotification);
-
- boolean present_emailAddresses = true && (isSetEmailAddresses());
- list.add(present_emailAddresses);
- if (present_emailAddresses)
- list.add(emailAddresses);
-
- boolean present_userConfigurationData = true && (isSetUserConfigurationData());
- list.add(present_userConfigurationData);
- if (present_userConfigurationData)
- list.add(userConfigurationData);
-
- boolean present_experimentInputs = true && (isSetExperimentInputs());
- list.add(present_experimentInputs);
- if (present_experimentInputs)
- list.add(experimentInputs);
-
- boolean present_experimentOutputs = true && (isSetExperimentOutputs());
- list.add(present_experimentOutputs);
- if (present_experimentOutputs)
- list.add(experimentOutputs);
-
- boolean present_experimentStatus = true && (isSetExperimentStatus());
- list.add(present_experimentStatus);
- if (present_experimentStatus)
- list.add(experimentStatus);
-
- boolean present_errors = true && (isSetErrors());
- list.add(present_errors);
- if (present_errors)
- list.add(errors);
-
- boolean present_processes = true && (isSetProcesses());
- list.add(present_processes);
- if (present_processes)
- list.add(processes);
-
- return list.hashCode();
+ int hashCode = 1;
+
+ hashCode = hashCode * 8191 + ((isSetExperimentId()) ? 131071 : 524287);
+ if (isSetExperimentId())
+ hashCode = hashCode * 8191 + experimentId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetProjectId()) ? 131071 : 524287);
+ if (isSetProjectId())
+ hashCode = hashCode * 8191 + projectId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetGatewayId()) ? 131071 : 524287);
+ if (isSetGatewayId())
+ hashCode = hashCode * 8191 + gatewayId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetExperimentType()) ? 131071 : 524287);
+ if (isSetExperimentType())
+ hashCode = hashCode * 8191 + experimentType.getValue();
+
+ hashCode = hashCode * 8191 + ((isSetUserName()) ? 131071 : 524287);
+ if (isSetUserName())
+ hashCode = hashCode * 8191 + userName.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetExperimentName()) ? 131071 : 524287);
+ if (isSetExperimentName())
+ hashCode = hashCode * 8191 + experimentName.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetCreationTime()) ? 131071 : 524287);
+ if (isSetCreationTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(creationTime);
+
+ hashCode = hashCode * 8191 + ((isSetDescription()) ? 131071 : 524287);
+ if (isSetDescription())
+ hashCode = hashCode * 8191 + description.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetExecutionId()) ? 131071 : 524287);
+ if (isSetExecutionId())
+ hashCode = hashCode * 8191 + executionId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetGatewayExecutionId()) ? 131071 : 524287);
+ if (isSetGatewayExecutionId())
+ hashCode = hashCode * 8191 + gatewayExecutionId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetGatewayInstanceId()) ? 131071 : 524287);
+ if (isSetGatewayInstanceId())
+ hashCode = hashCode * 8191 + gatewayInstanceId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetEnableEmailNotification()) ? 131071 : 524287);
+ if (isSetEnableEmailNotification())
+ hashCode = hashCode * 8191 + ((enableEmailNotification) ? 131071 : 524287);
+
+ hashCode = hashCode * 8191 + ((isSetEmailAddresses()) ? 131071 : 524287);
+ if (isSetEmailAddresses())
+ hashCode = hashCode * 8191 + emailAddresses.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetUserConfigurationData()) ? 131071 : 524287);
+ if (isSetUserConfigurationData())
+ hashCode = hashCode * 8191 + userConfigurationData.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetExperimentInputs()) ? 131071 : 524287);
+ if (isSetExperimentInputs())
+ hashCode = hashCode * 8191 + experimentInputs.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetExperimentOutputs()) ? 131071 : 524287);
+ if (isSetExperimentOutputs())
+ hashCode = hashCode * 8191 + experimentOutputs.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetExperimentStatus()) ? 131071 : 524287);
+ if (isSetExperimentStatus())
+ hashCode = hashCode * 8191 + experimentStatus.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetErrors()) ? 131071 : 524287);
+ if (isSetErrors())
+ hashCode = hashCode * 8191 + errors.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetProcesses()) ? 131071 : 524287);
+ if (isSetProcesses())
+ hashCode = hashCode * 8191 + processes.hashCode();
+
+ return hashCode;
}
@Override
@@ -1524,7 +1477,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetExperimentId()).compareTo(other.isSetExperimentId());
+ lastComparison = java.lang.Boolean.valueOf(isSetExperimentId()).compareTo(other.isSetExperimentId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1534,7 +1487,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetProjectId()).compareTo(other.isSetProjectId());
+ lastComparison = java.lang.Boolean.valueOf(isSetProjectId()).compareTo(other.isSetProjectId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1544,7 +1497,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(other.isSetGatewayId());
+ lastComparison = java.lang.Boolean.valueOf(isSetGatewayId()).compareTo(other.isSetGatewayId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1554,7 +1507,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetExperimentType()).compareTo(other.isSetExperimentType());
+ lastComparison = java.lang.Boolean.valueOf(isSetExperimentType()).compareTo(other.isSetExperimentType());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1564,7 +1517,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUserName()).compareTo(other.isSetUserName());
+ lastComparison = java.lang.Boolean.valueOf(isSetUserName()).compareTo(other.isSetUserName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1574,7 +1527,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetExperimentName()).compareTo(other.isSetExperimentName());
+ lastComparison = java.lang.Boolean.valueOf(isSetExperimentName()).compareTo(other.isSetExperimentName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1584,7 +1537,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCreationTime()).compareTo(other.isSetCreationTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetCreationTime()).compareTo(other.isSetCreationTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1594,7 +1547,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1604,7 +1557,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetExecutionId()).compareTo(other.isSetExecutionId());
+ lastComparison = java.lang.Boolean.valueOf(isSetExecutionId()).compareTo(other.isSetExecutionId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1614,7 +1567,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetGatewayExecutionId()).compareTo(other.isSetGatewayExecutionId());
+ lastComparison = java.lang.Boolean.valueOf(isSetGatewayExecutionId()).compareTo(other.isSetGatewayExecutionId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1624,7 +1577,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetGatewayInstanceId()).compareTo(other.isSetGatewayInstanceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetGatewayInstanceId()).compareTo(other.isSetGatewayInstanceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1634,7 +1587,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetEnableEmailNotification()).compareTo(other.isSetEnableEmailNotification());
+ lastComparison = java.lang.Boolean.valueOf(isSetEnableEmailNotification()).compareTo(other.isSetEnableEmailNotification());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1644,7 +1597,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetEmailAddresses()).compareTo(other.isSetEmailAddresses());
+ lastComparison = java.lang.Boolean.valueOf(isSetEmailAddresses()).compareTo(other.isSetEmailAddresses());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1654,7 +1607,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUserConfigurationData()).compareTo(other.isSetUserConfigurationData());
+ lastComparison = java.lang.Boolean.valueOf(isSetUserConfigurationData()).compareTo(other.isSetUserConfigurationData());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1664,7 +1617,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetExperimentInputs()).compareTo(other.isSetExperimentInputs());
+ lastComparison = java.lang.Boolean.valueOf(isSetExperimentInputs()).compareTo(other.isSetExperimentInputs());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1674,7 +1627,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetExperimentOutputs()).compareTo(other.isSetExperimentOutputs());
+ lastComparison = java.lang.Boolean.valueOf(isSetExperimentOutputs()).compareTo(other.isSetExperimentOutputs());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1684,7 +1637,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetExperimentStatus()).compareTo(other.isSetExperimentStatus());
+ lastComparison = java.lang.Boolean.valueOf(isSetExperimentStatus()).compareTo(other.isSetExperimentStatus());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1694,7 +1647,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetErrors()).compareTo(other.isSetErrors());
+ lastComparison = java.lang.Boolean.valueOf(isSetErrors()).compareTo(other.isSetErrors());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1704,7 +1657,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetProcesses()).compareTo(other.isSetProcesses());
+ lastComparison = java.lang.Boolean.valueOf(isSetProcesses()).compareTo(other.isSetProcesses());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1722,16 +1675,16 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ExperimentModel(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ExperimentModel(");
boolean first = true;
sb.append("experimentId:");
@@ -1947,7 +1900,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -1957,13 +1910,13 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
}
}
- private static class ExperimentModelStandardSchemeFactory implements SchemeFactory {
+ private static class ExperimentModelStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ExperimentModelStandardScheme getScheme() {
return new ExperimentModelStandardScheme();
}
}
- private static class ExperimentModelStandardScheme extends StandardScheme<ExperimentModel> {
+ private static class ExperimentModelStandardScheme extends org.apache.thrift.scheme.StandardScheme<ExperimentModel> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ExperimentModel struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -2075,8 +2028,8 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list0 = iprot.readListBegin();
- struct.emailAddresses = new ArrayList<String>(_list0.size);
- String _elem1;
+ struct.emailAddresses = new java.util.ArrayList<java.lang.String>(_list0.size);
+ java.lang.String _elem1;
for (int _i2 = 0; _i2 < _list0.size; ++_i2)
{
_elem1 = iprot.readString();
@@ -2102,7 +2055,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list3 = iprot.readListBegin();
- struct.experimentInputs = new ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(_list3.size);
+ struct.experimentInputs = new java.util.ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(_list3.size);
org.apache.airavata.model.application.io.InputDataObjectType _elem4;
for (int _i5 = 0; _i5 < _list3.size; ++_i5)
{
@@ -2121,7 +2074,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list6 = iprot.readListBegin();
- struct.experimentOutputs = new ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(_list6.size);
+ struct.experimentOutputs = new java.util.ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(_list6.size);
org.apache.airavata.model.application.io.OutputDataObjectType _elem7;
for (int _i8 = 0; _i8 < _list6.size; ++_i8)
{
@@ -2140,7 +2093,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list9 = iprot.readListBegin();
- struct.experimentStatus = new ArrayList<org.apache.airavata.model.status.ExperimentStatus>(_list9.size);
+ struct.experimentStatus = new java.util.ArrayList<org.apache.airavata.model.status.ExperimentStatus>(_list9.size);
org.apache.airavata.model.status.ExperimentStatus _elem10;
for (int _i11 = 0; _i11 < _list9.size; ++_i11)
{
@@ -2159,7 +2112,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list12 = iprot.readListBegin();
- struct.errors = new ArrayList<org.apache.airavata.model.commons.ErrorModel>(_list12.size);
+ struct.errors = new java.util.ArrayList<org.apache.airavata.model.commons.ErrorModel>(_list12.size);
org.apache.airavata.model.commons.ErrorModel _elem13;
for (int _i14 = 0; _i14 < _list12.size; ++_i14)
{
@@ -2178,7 +2131,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list15 = iprot.readListBegin();
- struct.processes = new ArrayList<org.apache.airavata.model.process.ProcessModel>(_list15.size);
+ struct.processes = new java.util.ArrayList<org.apache.airavata.model.process.ProcessModel>(_list15.size);
org.apache.airavata.model.process.ProcessModel _elem16;
for (int _i17 = 0; _i17 < _list15.size; ++_i17)
{
@@ -2279,7 +2232,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
oprot.writeFieldBegin(EMAIL_ADDRESSES_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.emailAddresses.size()));
- for (String _iter18 : struct.emailAddresses)
+ for (java.lang.String _iter18 : struct.emailAddresses)
{
oprot.writeString(_iter18);
}
@@ -2371,24 +2324,24 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
}
- private static class ExperimentModelTupleSchemeFactory implements SchemeFactory {
+ private static class ExperimentModelTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ExperimentModelTupleScheme getScheme() {
return new ExperimentModelTupleScheme();
}
}
- private static class ExperimentModelTupleScheme extends TupleScheme<ExperimentModel> {
+ private static class ExperimentModelTupleScheme extends org.apache.thrift.scheme.TupleScheme<ExperimentModel> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ExperimentModel struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.experimentId);
oprot.writeString(struct.projectId);
oprot.writeString(struct.gatewayId);
oprot.writeI32(struct.experimentType.getValue());
oprot.writeString(struct.userName);
oprot.writeString(struct.experimentName);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetCreationTime()) {
optionals.set(0);
}
@@ -2450,7 +2403,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (struct.isSetEmailAddresses()) {
{
oprot.writeI32(struct.emailAddresses.size());
- for (String _iter24 : struct.emailAddresses)
+ for (java.lang.String _iter24 : struct.emailAddresses)
{
oprot.writeString(_iter24);
}
@@ -2508,7 +2461,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ExperimentModel struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.experimentId = iprot.readString();
struct.setExperimentIdIsSet(true);
struct.projectId = iprot.readString();
@@ -2521,7 +2474,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
struct.setUserNameIsSet(true);
struct.experimentName = iprot.readString();
struct.setExperimentNameIsSet(true);
- BitSet incoming = iprot.readBitSet(13);
+ java.util.BitSet incoming = iprot.readBitSet(13);
if (incoming.get(0)) {
struct.creationTime = iprot.readI64();
struct.setCreationTimeIsSet(true);
@@ -2549,8 +2502,8 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (incoming.get(6)) {
{
org.apache.thrift.protocol.TList _list30 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.emailAddresses = new ArrayList<String>(_list30.size);
- String _elem31;
+ struct.emailAddresses = new java.util.ArrayList<java.lang.String>(_list30.size);
+ java.lang.String _elem31;
for (int _i32 = 0; _i32 < _list30.size; ++_i32)
{
_elem31 = iprot.readString();
@@ -2567,7 +2520,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (incoming.get(8)) {
{
org.apache.thrift.protocol.TList _list33 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.experimentInputs = new ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(_list33.size);
+ struct.experimentInputs = new java.util.ArrayList<org.apache.airavata.model.application.io.InputDataObjectType>(_list33.size);
org.apache.airavata.model.application.io.InputDataObjectType _elem34;
for (int _i35 = 0; _i35 < _list33.size; ++_i35)
{
@@ -2581,7 +2534,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (incoming.get(9)) {
{
org.apache.thrift.protocol.TList _list36 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.experimentOutputs = new ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(_list36.size);
+ struct.experimentOutputs = new java.util.ArrayList<org.apache.airavata.model.application.io.OutputDataObjectType>(_list36.size);
org.apache.airavata.model.application.io.OutputDataObjectType _elem37;
for (int _i38 = 0; _i38 < _list36.size; ++_i38)
{
@@ -2595,7 +2548,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (incoming.get(10)) {
{
org.apache.thrift.protocol.TList _list39 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.experimentStatus = new ArrayList<org.apache.airavata.model.status.ExperimentStatus>(_list39.size);
+ struct.experimentStatus = new java.util.ArrayList<org.apache.airavata.model.status.ExperimentStatus>(_list39.size);
org.apache.airavata.model.status.ExperimentStatus _elem40;
for (int _i41 = 0; _i41 < _list39.size; ++_i41)
{
@@ -2609,7 +2562,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (incoming.get(11)) {
{
org.apache.thrift.protocol.TList _list42 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.errors = new ArrayList<org.apache.airavata.model.commons.ErrorModel>(_list42.size);
+ struct.errors = new java.util.ArrayList<org.apache.airavata.model.commons.ErrorModel>(_list42.size);
org.apache.airavata.model.commons.ErrorModel _elem43;
for (int _i44 = 0; _i44 < _list42.size; ++_i44)
{
@@ -2623,7 +2576,7 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
if (incoming.get(12)) {
{
org.apache.thrift.protocol.TList _list45 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.processes = new ArrayList<org.apache.airavata.model.process.ProcessModel>(_list45.size);
+ struct.processes = new java.util.ArrayList<org.apache.airavata.model.process.ProcessModel>(_list45.size);
org.apache.airavata.model.process.ProcessModel _elem46;
for (int _i47 = 0; _i47 < _list45.size; ++_i47)
{
@@ -2637,5 +2590,8 @@ public class ExperimentModel implements org.apache.thrift.TBase<ExperimentModel,
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentSearchFields.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentSearchFields.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentSearchFields.java
index 84a0a6b..efe72e3 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentSearchFields.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/experiment/ExperimentSearchFields.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
[18/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ResourceJobManager.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ResourceJobManager.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ResourceJobManager.java
index bca1b6f..0293141 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ResourceJobManager.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ResourceJobManager.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.computeresource;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Resource Job Manager Information
*
@@ -68,7 +41,7 @@ import org.slf4j.LoggerFactory;
* An enumeration of commonly used manager commands.
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobManager, ResourceJobManager._Fields>, java.io.Serializable, Cloneable, Comparable<ResourceJobManager> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ResourceJobManager");
@@ -79,18 +52,15 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
private static final org.apache.thrift.protocol.TField JOB_MANAGER_COMMANDS_FIELD_DESC = new org.apache.thrift.protocol.TField("jobManagerCommands", org.apache.thrift.protocol.TType.MAP, (short)5);
private static final org.apache.thrift.protocol.TField PARALLELISM_PREFIX_FIELD_DESC = new org.apache.thrift.protocol.TField("parallelismPrefix", org.apache.thrift.protocol.TType.MAP, (short)6);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new ResourceJobManagerStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ResourceJobManagerTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ResourceJobManagerStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ResourceJobManagerTupleSchemeFactory();
- private String resourceJobManagerId; // required
+ private java.lang.String resourceJobManagerId; // required
private ResourceJobManagerType resourceJobManagerType; // required
- private String pushMonitoringEndpoint; // optional
- private String jobManagerBinPath; // optional
- private Map<JobManagerCommand,String> jobManagerCommands; // optional
- private Map<org.apache.airavata.model.parallelism.ApplicationParallelismType,String> parallelismPrefix; // optional
+ private java.lang.String pushMonitoringEndpoint; // optional
+ private java.lang.String jobManagerBinPath; // optional
+ private java.util.Map<JobManagerCommand,java.lang.String> jobManagerCommands; // optional
+ private java.util.Map<org.apache.airavata.model.parallelism.ApplicationParallelismType,java.lang.String> parallelismPrefix; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -105,10 +75,10 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
JOB_MANAGER_COMMANDS((short)5, "jobManagerCommands"),
PARALLELISM_PREFIX((short)6, "parallelismPrefix");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -141,21 +111,21 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -164,16 +134,16 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
private static final _Fields optionals[] = {_Fields.PUSH_MONITORING_ENDPOINT,_Fields.JOB_MANAGER_BIN_PATH,_Fields.JOB_MANAGER_COMMANDS,_Fields.PARALLELISM_PREFIX};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.RESOURCE_JOB_MANAGER_ID, new org.apache.thrift.meta_data.FieldMetaData("resourceJobManagerId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.RESOURCE_JOB_MANAGER_TYPE, new org.apache.thrift.meta_data.FieldMetaData("resourceJobManagerType", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -190,7 +160,7 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, org.apache.airavata.model.parallelism.ApplicationParallelismType.class),
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ResourceJobManager.class, metaDataMap);
}
@@ -200,7 +170,7 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
}
public ResourceJobManager(
- String resourceJobManagerId,
+ java.lang.String resourceJobManagerId,
ResourceJobManagerType resourceJobManagerType)
{
this();
@@ -225,30 +195,30 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
this.jobManagerBinPath = other.jobManagerBinPath;
}
if (other.isSetJobManagerCommands()) {
- Map<JobManagerCommand,String> __this__jobManagerCommands = new HashMap<JobManagerCommand,String>(other.jobManagerCommands.size());
- for (Map.Entry<JobManagerCommand, String> other_element : other.jobManagerCommands.entrySet()) {
+ java.util.Map<JobManagerCommand,java.lang.String> __this__jobManagerCommands = new java.util.HashMap<JobManagerCommand,java.lang.String>(other.jobManagerCommands.size());
+ for (java.util.Map.Entry<JobManagerCommand, java.lang.String> other_element : other.jobManagerCommands.entrySet()) {
JobManagerCommand other_element_key = other_element.getKey();
- String other_element_value = other_element.getValue();
+ java.lang.String other_element_value = other_element.getValue();
JobManagerCommand __this__jobManagerCommands_copy_key = other_element_key;
- String __this__jobManagerCommands_copy_value = other_element_value;
+ java.lang.String __this__jobManagerCommands_copy_value = other_element_value;
__this__jobManagerCommands.put(__this__jobManagerCommands_copy_key, __this__jobManagerCommands_copy_value);
}
this.jobManagerCommands = __this__jobManagerCommands;
}
if (other.isSetParallelismPrefix()) {
- Map<org.apache.airavata.model.parallelism.ApplicationParallelismType,String> __this__parallelismPrefix = new HashMap<org.apache.airavata.model.parallelism.ApplicationParallelismType,String>(other.parallelismPrefix.size());
- for (Map.Entry<org.apache.airavata.model.parallelism.ApplicationParallelismType, String> other_element : other.parallelismPrefix.entrySet()) {
+ java.util.Map<org.apache.airavata.model.parallelism.ApplicationParallelismType,java.lang.String> __this__parallelismPrefix = new java.util.HashMap<org.apache.airavata.model.parallelism.ApplicationParallelismType,java.lang.String>(other.parallelismPrefix.size());
+ for (java.util.Map.Entry<org.apache.airavata.model.parallelism.ApplicationParallelismType, java.lang.String> other_element : other.parallelismPrefix.entrySet()) {
org.apache.airavata.model.parallelism.ApplicationParallelismType other_element_key = other_element.getKey();
- String other_element_value = other_element.getValue();
+ java.lang.String other_element_value = other_element.getValue();
org.apache.airavata.model.parallelism.ApplicationParallelismType __this__parallelismPrefix_copy_key = other_element_key;
- String __this__parallelismPrefix_copy_value = other_element_value;
+ java.lang.String __this__parallelismPrefix_copy_value = other_element_value;
__this__parallelismPrefix.put(__this__parallelismPrefix_copy_key, __this__parallelismPrefix_copy_value);
}
@@ -271,11 +241,11 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
this.parallelismPrefix = null;
}
- public String getResourceJobManagerId() {
+ public java.lang.String getResourceJobManagerId() {
return this.resourceJobManagerId;
}
- public void setResourceJobManagerId(String resourceJobManagerId) {
+ public void setResourceJobManagerId(java.lang.String resourceJobManagerId) {
this.resourceJobManagerId = resourceJobManagerId;
}
@@ -325,11 +295,11 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
}
}
- public String getPushMonitoringEndpoint() {
+ public java.lang.String getPushMonitoringEndpoint() {
return this.pushMonitoringEndpoint;
}
- public void setPushMonitoringEndpoint(String pushMonitoringEndpoint) {
+ public void setPushMonitoringEndpoint(java.lang.String pushMonitoringEndpoint) {
this.pushMonitoringEndpoint = pushMonitoringEndpoint;
}
@@ -348,11 +318,11 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
}
}
- public String getJobManagerBinPath() {
+ public java.lang.String getJobManagerBinPath() {
return this.jobManagerBinPath;
}
- public void setJobManagerBinPath(String jobManagerBinPath) {
+ public void setJobManagerBinPath(java.lang.String jobManagerBinPath) {
this.jobManagerBinPath = jobManagerBinPath;
}
@@ -375,18 +345,18 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
return (this.jobManagerCommands == null) ? 0 : this.jobManagerCommands.size();
}
- public void putToJobManagerCommands(JobManagerCommand key, String val) {
+ public void putToJobManagerCommands(JobManagerCommand key, java.lang.String val) {
if (this.jobManagerCommands == null) {
- this.jobManagerCommands = new HashMap<JobManagerCommand,String>();
+ this.jobManagerCommands = new java.util.HashMap<JobManagerCommand,java.lang.String>();
}
this.jobManagerCommands.put(key, val);
}
- public Map<JobManagerCommand,String> getJobManagerCommands() {
+ public java.util.Map<JobManagerCommand,java.lang.String> getJobManagerCommands() {
return this.jobManagerCommands;
}
- public void setJobManagerCommands(Map<JobManagerCommand,String> jobManagerCommands) {
+ public void setJobManagerCommands(java.util.Map<JobManagerCommand,java.lang.String> jobManagerCommands) {
this.jobManagerCommands = jobManagerCommands;
}
@@ -409,18 +379,18 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
return (this.parallelismPrefix == null) ? 0 : this.parallelismPrefix.size();
}
- public void putToParallelismPrefix(org.apache.airavata.model.parallelism.ApplicationParallelismType key, String val) {
+ public void putToParallelismPrefix(org.apache.airavata.model.parallelism.ApplicationParallelismType key, java.lang.String val) {
if (this.parallelismPrefix == null) {
- this.parallelismPrefix = new HashMap<org.apache.airavata.model.parallelism.ApplicationParallelismType,String>();
+ this.parallelismPrefix = new java.util.HashMap<org.apache.airavata.model.parallelism.ApplicationParallelismType,java.lang.String>();
}
this.parallelismPrefix.put(key, val);
}
- public Map<org.apache.airavata.model.parallelism.ApplicationParallelismType,String> getParallelismPrefix() {
+ public java.util.Map<org.apache.airavata.model.parallelism.ApplicationParallelismType,java.lang.String> getParallelismPrefix() {
return this.parallelismPrefix;
}
- public void setParallelismPrefix(Map<org.apache.airavata.model.parallelism.ApplicationParallelismType,String> parallelismPrefix) {
+ public void setParallelismPrefix(java.util.Map<org.apache.airavata.model.parallelism.ApplicationParallelismType,java.lang.String> parallelismPrefix) {
this.parallelismPrefix = parallelismPrefix;
}
@@ -439,13 +409,13 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case RESOURCE_JOB_MANAGER_ID:
if (value == null) {
unsetResourceJobManagerId();
} else {
- setResourceJobManagerId((String)value);
+ setResourceJobManagerId((java.lang.String)value);
}
break;
@@ -461,7 +431,7 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
if (value == null) {
unsetPushMonitoringEndpoint();
} else {
- setPushMonitoringEndpoint((String)value);
+ setPushMonitoringEndpoint((java.lang.String)value);
}
break;
@@ -469,7 +439,7 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
if (value == null) {
unsetJobManagerBinPath();
} else {
- setJobManagerBinPath((String)value);
+ setJobManagerBinPath((java.lang.String)value);
}
break;
@@ -477,7 +447,7 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
if (value == null) {
unsetJobManagerCommands();
} else {
- setJobManagerCommands((Map<JobManagerCommand,String>)value);
+ setJobManagerCommands((java.util.Map<JobManagerCommand,java.lang.String>)value);
}
break;
@@ -485,14 +455,14 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
if (value == null) {
unsetParallelismPrefix();
} else {
- setParallelismPrefix((Map<org.apache.airavata.model.parallelism.ApplicationParallelismType,String>)value);
+ setParallelismPrefix((java.util.Map<org.apache.airavata.model.parallelism.ApplicationParallelismType,java.lang.String>)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case RESOURCE_JOB_MANAGER_ID:
return getResourceJobManagerId();
@@ -513,13 +483,13 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
return getParallelismPrefix();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -536,11 +506,11 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
case PARALLELISM_PREFIX:
return isSetParallelismPrefix();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ResourceJobManager)
@@ -551,6 +521,8 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
public boolean equals(ResourceJobManager that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_resourceJobManagerId = true && this.isSetResourceJobManagerId();
boolean that_present_resourceJobManagerId = true && that.isSetResourceJobManagerId();
@@ -611,39 +583,33 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_resourceJobManagerId = true && (isSetResourceJobManagerId());
- list.add(present_resourceJobManagerId);
- if (present_resourceJobManagerId)
- list.add(resourceJobManagerId);
-
- boolean present_resourceJobManagerType = true && (isSetResourceJobManagerType());
- list.add(present_resourceJobManagerType);
- if (present_resourceJobManagerType)
- list.add(resourceJobManagerType.getValue());
-
- boolean present_pushMonitoringEndpoint = true && (isSetPushMonitoringEndpoint());
- list.add(present_pushMonitoringEndpoint);
- if (present_pushMonitoringEndpoint)
- list.add(pushMonitoringEndpoint);
-
- boolean present_jobManagerBinPath = true && (isSetJobManagerBinPath());
- list.add(present_jobManagerBinPath);
- if (present_jobManagerBinPath)
- list.add(jobManagerBinPath);
-
- boolean present_jobManagerCommands = true && (isSetJobManagerCommands());
- list.add(present_jobManagerCommands);
- if (present_jobManagerCommands)
- list.add(jobManagerCommands);
-
- boolean present_parallelismPrefix = true && (isSetParallelismPrefix());
- list.add(present_parallelismPrefix);
- if (present_parallelismPrefix)
- list.add(parallelismPrefix);
-
- return list.hashCode();
+ int hashCode = 1;
+
+ hashCode = hashCode * 8191 + ((isSetResourceJobManagerId()) ? 131071 : 524287);
+ if (isSetResourceJobManagerId())
+ hashCode = hashCode * 8191 + resourceJobManagerId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetResourceJobManagerType()) ? 131071 : 524287);
+ if (isSetResourceJobManagerType())
+ hashCode = hashCode * 8191 + resourceJobManagerType.getValue();
+
+ hashCode = hashCode * 8191 + ((isSetPushMonitoringEndpoint()) ? 131071 : 524287);
+ if (isSetPushMonitoringEndpoint())
+ hashCode = hashCode * 8191 + pushMonitoringEndpoint.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetJobManagerBinPath()) ? 131071 : 524287);
+ if (isSetJobManagerBinPath())
+ hashCode = hashCode * 8191 + jobManagerBinPath.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetJobManagerCommands()) ? 131071 : 524287);
+ if (isSetJobManagerCommands())
+ hashCode = hashCode * 8191 + jobManagerCommands.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetParallelismPrefix()) ? 131071 : 524287);
+ if (isSetParallelismPrefix())
+ hashCode = hashCode * 8191 + parallelismPrefix.hashCode();
+
+ return hashCode;
}
@Override
@@ -654,7 +620,7 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetResourceJobManagerId()).compareTo(other.isSetResourceJobManagerId());
+ lastComparison = java.lang.Boolean.valueOf(isSetResourceJobManagerId()).compareTo(other.isSetResourceJobManagerId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -664,7 +630,7 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetResourceJobManagerType()).compareTo(other.isSetResourceJobManagerType());
+ lastComparison = java.lang.Boolean.valueOf(isSetResourceJobManagerType()).compareTo(other.isSetResourceJobManagerType());
if (lastComparison != 0) {
return lastComparison;
}
@@ -674,7 +640,7 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPushMonitoringEndpoint()).compareTo(other.isSetPushMonitoringEndpoint());
+ lastComparison = java.lang.Boolean.valueOf(isSetPushMonitoringEndpoint()).compareTo(other.isSetPushMonitoringEndpoint());
if (lastComparison != 0) {
return lastComparison;
}
@@ -684,7 +650,7 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetJobManagerBinPath()).compareTo(other.isSetJobManagerBinPath());
+ lastComparison = java.lang.Boolean.valueOf(isSetJobManagerBinPath()).compareTo(other.isSetJobManagerBinPath());
if (lastComparison != 0) {
return lastComparison;
}
@@ -694,7 +660,7 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetJobManagerCommands()).compareTo(other.isSetJobManagerCommands());
+ lastComparison = java.lang.Boolean.valueOf(isSetJobManagerCommands()).compareTo(other.isSetJobManagerCommands());
if (lastComparison != 0) {
return lastComparison;
}
@@ -704,7 +670,7 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetParallelismPrefix()).compareTo(other.isSetParallelismPrefix());
+ lastComparison = java.lang.Boolean.valueOf(isSetParallelismPrefix()).compareTo(other.isSetParallelismPrefix());
if (lastComparison != 0) {
return lastComparison;
}
@@ -722,16 +688,16 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ResourceJobManager(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ResourceJobManager(");
boolean first = true;
sb.append("resourceJobManagerId:");
@@ -814,7 +780,7 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -822,13 +788,13 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
}
}
- private static class ResourceJobManagerStandardSchemeFactory implements SchemeFactory {
+ private static class ResourceJobManagerStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ResourceJobManagerStandardScheme getScheme() {
return new ResourceJobManagerStandardScheme();
}
}
- private static class ResourceJobManagerStandardScheme extends StandardScheme<ResourceJobManager> {
+ private static class ResourceJobManagerStandardScheme extends org.apache.thrift.scheme.StandardScheme<ResourceJobManager> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ResourceJobManager struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -876,9 +842,9 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
if (schemeField.type == org.apache.thrift.protocol.TType.MAP) {
{
org.apache.thrift.protocol.TMap _map0 = iprot.readMapBegin();
- struct.jobManagerCommands = new HashMap<JobManagerCommand,String>(2*_map0.size);
+ struct.jobManagerCommands = new java.util.HashMap<JobManagerCommand,java.lang.String>(2*_map0.size);
JobManagerCommand _key1;
- String _val2;
+ java.lang.String _val2;
for (int _i3 = 0; _i3 < _map0.size; ++_i3)
{
_key1 = org.apache.airavata.model.appcatalog.computeresource.JobManagerCommand.findByValue(iprot.readI32());
@@ -896,9 +862,9 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
if (schemeField.type == org.apache.thrift.protocol.TType.MAP) {
{
org.apache.thrift.protocol.TMap _map4 = iprot.readMapBegin();
- struct.parallelismPrefix = new HashMap<org.apache.airavata.model.parallelism.ApplicationParallelismType,String>(2*_map4.size);
+ struct.parallelismPrefix = new java.util.HashMap<org.apache.airavata.model.parallelism.ApplicationParallelismType,java.lang.String>(2*_map4.size);
org.apache.airavata.model.parallelism.ApplicationParallelismType _key5;
- String _val6;
+ java.lang.String _val6;
for (int _i7 = 0; _i7 < _map4.size; ++_i7)
{
_key5 = org.apache.airavata.model.parallelism.ApplicationParallelismType.findByValue(iprot.readI32());
@@ -954,7 +920,7 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
oprot.writeFieldBegin(JOB_MANAGER_COMMANDS_FIELD_DESC);
{
oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.I32, org.apache.thrift.protocol.TType.STRING, struct.jobManagerCommands.size()));
- for (Map.Entry<JobManagerCommand, String> _iter8 : struct.jobManagerCommands.entrySet())
+ for (java.util.Map.Entry<JobManagerCommand, java.lang.String> _iter8 : struct.jobManagerCommands.entrySet())
{
oprot.writeI32(_iter8.getKey().getValue());
oprot.writeString(_iter8.getValue());
@@ -969,7 +935,7 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
oprot.writeFieldBegin(PARALLELISM_PREFIX_FIELD_DESC);
{
oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.I32, org.apache.thrift.protocol.TType.STRING, struct.parallelismPrefix.size()));
- for (Map.Entry<org.apache.airavata.model.parallelism.ApplicationParallelismType, String> _iter9 : struct.parallelismPrefix.entrySet())
+ for (java.util.Map.Entry<org.apache.airavata.model.parallelism.ApplicationParallelismType, java.lang.String> _iter9 : struct.parallelismPrefix.entrySet())
{
oprot.writeI32(_iter9.getKey().getValue());
oprot.writeString(_iter9.getValue());
@@ -985,20 +951,20 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
}
- private static class ResourceJobManagerTupleSchemeFactory implements SchemeFactory {
+ private static class ResourceJobManagerTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ResourceJobManagerTupleScheme getScheme() {
return new ResourceJobManagerTupleScheme();
}
}
- private static class ResourceJobManagerTupleScheme extends TupleScheme<ResourceJobManager> {
+ private static class ResourceJobManagerTupleScheme extends org.apache.thrift.scheme.TupleScheme<ResourceJobManager> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ResourceJobManager struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.resourceJobManagerId);
oprot.writeI32(struct.resourceJobManagerType.getValue());
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetPushMonitoringEndpoint()) {
optionals.set(0);
}
@@ -1021,7 +987,7 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
if (struct.isSetJobManagerCommands()) {
{
oprot.writeI32(struct.jobManagerCommands.size());
- for (Map.Entry<JobManagerCommand, String> _iter10 : struct.jobManagerCommands.entrySet())
+ for (java.util.Map.Entry<JobManagerCommand, java.lang.String> _iter10 : struct.jobManagerCommands.entrySet())
{
oprot.writeI32(_iter10.getKey().getValue());
oprot.writeString(_iter10.getValue());
@@ -1031,7 +997,7 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
if (struct.isSetParallelismPrefix()) {
{
oprot.writeI32(struct.parallelismPrefix.size());
- for (Map.Entry<org.apache.airavata.model.parallelism.ApplicationParallelismType, String> _iter11 : struct.parallelismPrefix.entrySet())
+ for (java.util.Map.Entry<org.apache.airavata.model.parallelism.ApplicationParallelismType, java.lang.String> _iter11 : struct.parallelismPrefix.entrySet())
{
oprot.writeI32(_iter11.getKey().getValue());
oprot.writeString(_iter11.getValue());
@@ -1042,12 +1008,12 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ResourceJobManager struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.resourceJobManagerId = iprot.readString();
struct.setResourceJobManagerIdIsSet(true);
struct.resourceJobManagerType = org.apache.airavata.model.appcatalog.computeresource.ResourceJobManagerType.findByValue(iprot.readI32());
struct.setResourceJobManagerTypeIsSet(true);
- BitSet incoming = iprot.readBitSet(4);
+ java.util.BitSet incoming = iprot.readBitSet(4);
if (incoming.get(0)) {
struct.pushMonitoringEndpoint = iprot.readString();
struct.setPushMonitoringEndpointIsSet(true);
@@ -1059,9 +1025,9 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
if (incoming.get(2)) {
{
org.apache.thrift.protocol.TMap _map12 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.I32, org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.jobManagerCommands = new HashMap<JobManagerCommand,String>(2*_map12.size);
+ struct.jobManagerCommands = new java.util.HashMap<JobManagerCommand,java.lang.String>(2*_map12.size);
JobManagerCommand _key13;
- String _val14;
+ java.lang.String _val14;
for (int _i15 = 0; _i15 < _map12.size; ++_i15)
{
_key13 = org.apache.airavata.model.appcatalog.computeresource.JobManagerCommand.findByValue(iprot.readI32());
@@ -1074,9 +1040,9 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
if (incoming.get(3)) {
{
org.apache.thrift.protocol.TMap _map16 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.I32, org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.parallelismPrefix = new HashMap<org.apache.airavata.model.parallelism.ApplicationParallelismType,String>(2*_map16.size);
+ struct.parallelismPrefix = new java.util.HashMap<org.apache.airavata.model.parallelism.ApplicationParallelismType,java.lang.String>(2*_map16.size);
org.apache.airavata.model.parallelism.ApplicationParallelismType _key17;
- String _val18;
+ java.lang.String _val18;
for (int _i19 = 0; _i19 < _map16.size; ++_i19)
{
_key17 = org.apache.airavata.model.parallelism.ApplicationParallelismType.findByValue(iprot.readI32());
@@ -1089,5 +1055,8 @@ public class ResourceJobManager implements org.apache.thrift.TBase<ResourceJobMa
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ResourceJobManagerType.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ResourceJobManagerType.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ResourceJobManagerType.java
index 04dfb74..e1a336c 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ResourceJobManagerType.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ResourceJobManagerType.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/SSHJobSubmission.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/SSHJobSubmission.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/SSHJobSubmission.java
index 8a9007a..7d6aecf 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/SSHJobSubmission.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/SSHJobSubmission.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.computeresource;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Authenticate using Secured Shell
*
@@ -67,7 +40,7 @@ import org.slf4j.LoggerFactory;
* the same. Example: *@*.example.com or *@example.com
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmission, SSHJobSubmission._Fields>, java.io.Serializable, Cloneable, Comparable<SSHJobSubmission> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("SSHJobSubmission");
@@ -79,19 +52,16 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
private static final org.apache.thrift.protocol.TField MONITOR_MODE_FIELD_DESC = new org.apache.thrift.protocol.TField("monitorMode", org.apache.thrift.protocol.TType.I32, (short)6);
private static final org.apache.thrift.protocol.TField BATCH_QUEUE_EMAIL_SENDERS_FIELD_DESC = new org.apache.thrift.protocol.TField("batchQueueEmailSenders", org.apache.thrift.protocol.TType.LIST, (short)7);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new SSHJobSubmissionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new SSHJobSubmissionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new SSHJobSubmissionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new SSHJobSubmissionTupleSchemeFactory();
- private String jobSubmissionInterfaceId; // required
+ private java.lang.String jobSubmissionInterfaceId; // required
private org.apache.airavata.model.data.movement.SecurityProtocol securityProtocol; // required
private ResourceJobManager resourceJobManager; // required
- private String alternativeSSHHostName; // optional
+ private java.lang.String alternativeSSHHostName; // optional
private int sshPort; // optional
private MonitorMode monitorMode; // optional
- private List<String> batchQueueEmailSenders; // optional
+ private java.util.List<java.lang.String> batchQueueEmailSenders; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -111,10 +81,10 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
MONITOR_MODE((short)6, "monitorMode"),
BATCH_QUEUE_EMAIL_SENDERS((short)7, "batchQueueEmailSenders");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -149,21 +119,21 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -172,7 +142,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -181,9 +151,9 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
private static final int __SSHPORT_ISSET_ID = 0;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.ALTERNATIVE_SSHHOST_NAME,_Fields.SSH_PORT,_Fields.MONITOR_MODE,_Fields.BATCH_QUEUE_EMAIL_SENDERS};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.JOB_SUBMISSION_INTERFACE_ID, new org.apache.thrift.meta_data.FieldMetaData("jobSubmissionInterfaceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.SECURITY_PROTOCOL, new org.apache.thrift.meta_data.FieldMetaData("securityProtocol", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -199,7 +169,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
tmpMap.put(_Fields.BATCH_QUEUE_EMAIL_SENDERS, new org.apache.thrift.meta_data.FieldMetaData("batchQueueEmailSenders", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(SSHJobSubmission.class, metaDataMap);
}
@@ -211,7 +181,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
}
public SSHJobSubmission(
- String jobSubmissionInterfaceId,
+ java.lang.String jobSubmissionInterfaceId,
org.apache.airavata.model.data.movement.SecurityProtocol securityProtocol,
ResourceJobManager resourceJobManager)
{
@@ -243,7 +213,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
this.monitorMode = other.monitorMode;
}
if (other.isSetBatchQueueEmailSenders()) {
- List<String> __this__batchQueueEmailSenders = new ArrayList<String>(other.batchQueueEmailSenders);
+ java.util.List<java.lang.String> __this__batchQueueEmailSenders = new java.util.ArrayList<java.lang.String>(other.batchQueueEmailSenders);
this.batchQueueEmailSenders = __this__batchQueueEmailSenders;
}
}
@@ -265,11 +235,11 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
this.batchQueueEmailSenders = null;
}
- public String getJobSubmissionInterfaceId() {
+ public java.lang.String getJobSubmissionInterfaceId() {
return this.jobSubmissionInterfaceId;
}
- public void setJobSubmissionInterfaceId(String jobSubmissionInterfaceId) {
+ public void setJobSubmissionInterfaceId(java.lang.String jobSubmissionInterfaceId) {
this.jobSubmissionInterfaceId = jobSubmissionInterfaceId;
}
@@ -342,11 +312,11 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
}
}
- public String getAlternativeSSHHostName() {
+ public java.lang.String getAlternativeSSHHostName() {
return this.alternativeSSHHostName;
}
- public void setAlternativeSSHHostName(String alternativeSSHHostName) {
+ public void setAlternativeSSHHostName(java.lang.String alternativeSSHHostName) {
this.alternativeSSHHostName = alternativeSSHHostName;
}
@@ -375,16 +345,16 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
}
public void unsetSshPort() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __SSHPORT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __SSHPORT_ISSET_ID);
}
/** Returns true if field sshPort is set (has been assigned a value) and false otherwise */
public boolean isSetSshPort() {
- return EncodingUtils.testBit(__isset_bitfield, __SSHPORT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __SSHPORT_ISSET_ID);
}
public void setSshPortIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SSHPORT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __SSHPORT_ISSET_ID, value);
}
/**
@@ -422,22 +392,22 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
return (this.batchQueueEmailSenders == null) ? 0 : this.batchQueueEmailSenders.size();
}
- public java.util.Iterator<String> getBatchQueueEmailSendersIterator() {
+ public java.util.Iterator<java.lang.String> getBatchQueueEmailSendersIterator() {
return (this.batchQueueEmailSenders == null) ? null : this.batchQueueEmailSenders.iterator();
}
- public void addToBatchQueueEmailSenders(String elem) {
+ public void addToBatchQueueEmailSenders(java.lang.String elem) {
if (this.batchQueueEmailSenders == null) {
- this.batchQueueEmailSenders = new ArrayList<String>();
+ this.batchQueueEmailSenders = new java.util.ArrayList<java.lang.String>();
}
this.batchQueueEmailSenders.add(elem);
}
- public List<String> getBatchQueueEmailSenders() {
+ public java.util.List<java.lang.String> getBatchQueueEmailSenders() {
return this.batchQueueEmailSenders;
}
- public void setBatchQueueEmailSenders(List<String> batchQueueEmailSenders) {
+ public void setBatchQueueEmailSenders(java.util.List<java.lang.String> batchQueueEmailSenders) {
this.batchQueueEmailSenders = batchQueueEmailSenders;
}
@@ -456,13 +426,13 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case JOB_SUBMISSION_INTERFACE_ID:
if (value == null) {
unsetJobSubmissionInterfaceId();
} else {
- setJobSubmissionInterfaceId((String)value);
+ setJobSubmissionInterfaceId((java.lang.String)value);
}
break;
@@ -486,7 +456,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
if (value == null) {
unsetAlternativeSSHHostName();
} else {
- setAlternativeSSHHostName((String)value);
+ setAlternativeSSHHostName((java.lang.String)value);
}
break;
@@ -494,7 +464,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
if (value == null) {
unsetSshPort();
} else {
- setSshPort((Integer)value);
+ setSshPort((java.lang.Integer)value);
}
break;
@@ -510,14 +480,14 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
if (value == null) {
unsetBatchQueueEmailSenders();
} else {
- setBatchQueueEmailSenders((List<String>)value);
+ setBatchQueueEmailSenders((java.util.List<java.lang.String>)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case JOB_SUBMISSION_INTERFACE_ID:
return getJobSubmissionInterfaceId();
@@ -541,13 +511,13 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
return getBatchQueueEmailSenders();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -566,11 +536,11 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
case BATCH_QUEUE_EMAIL_SENDERS:
return isSetBatchQueueEmailSenders();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof SSHJobSubmission)
@@ -581,6 +551,8 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
public boolean equals(SSHJobSubmission that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_jobSubmissionInterfaceId = true && this.isSetJobSubmissionInterfaceId();
boolean that_present_jobSubmissionInterfaceId = true && that.isSetJobSubmissionInterfaceId();
@@ -650,44 +622,37 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_jobSubmissionInterfaceId = true && (isSetJobSubmissionInterfaceId());
- list.add(present_jobSubmissionInterfaceId);
- if (present_jobSubmissionInterfaceId)
- list.add(jobSubmissionInterfaceId);
+ hashCode = hashCode * 8191 + ((isSetJobSubmissionInterfaceId()) ? 131071 : 524287);
+ if (isSetJobSubmissionInterfaceId())
+ hashCode = hashCode * 8191 + jobSubmissionInterfaceId.hashCode();
- boolean present_securityProtocol = true && (isSetSecurityProtocol());
- list.add(present_securityProtocol);
- if (present_securityProtocol)
- list.add(securityProtocol.getValue());
+ hashCode = hashCode * 8191 + ((isSetSecurityProtocol()) ? 131071 : 524287);
+ if (isSetSecurityProtocol())
+ hashCode = hashCode * 8191 + securityProtocol.getValue();
- boolean present_resourceJobManager = true && (isSetResourceJobManager());
- list.add(present_resourceJobManager);
- if (present_resourceJobManager)
- list.add(resourceJobManager);
+ hashCode = hashCode * 8191 + ((isSetResourceJobManager()) ? 131071 : 524287);
+ if (isSetResourceJobManager())
+ hashCode = hashCode * 8191 + resourceJobManager.hashCode();
- boolean present_alternativeSSHHostName = true && (isSetAlternativeSSHHostName());
- list.add(present_alternativeSSHHostName);
- if (present_alternativeSSHHostName)
- list.add(alternativeSSHHostName);
+ hashCode = hashCode * 8191 + ((isSetAlternativeSSHHostName()) ? 131071 : 524287);
+ if (isSetAlternativeSSHHostName())
+ hashCode = hashCode * 8191 + alternativeSSHHostName.hashCode();
- boolean present_sshPort = true && (isSetSshPort());
- list.add(present_sshPort);
- if (present_sshPort)
- list.add(sshPort);
+ hashCode = hashCode * 8191 + ((isSetSshPort()) ? 131071 : 524287);
+ if (isSetSshPort())
+ hashCode = hashCode * 8191 + sshPort;
- boolean present_monitorMode = true && (isSetMonitorMode());
- list.add(present_monitorMode);
- if (present_monitorMode)
- list.add(monitorMode.getValue());
+ hashCode = hashCode * 8191 + ((isSetMonitorMode()) ? 131071 : 524287);
+ if (isSetMonitorMode())
+ hashCode = hashCode * 8191 + monitorMode.getValue();
- boolean present_batchQueueEmailSenders = true && (isSetBatchQueueEmailSenders());
- list.add(present_batchQueueEmailSenders);
- if (present_batchQueueEmailSenders)
- list.add(batchQueueEmailSenders);
+ hashCode = hashCode * 8191 + ((isSetBatchQueueEmailSenders()) ? 131071 : 524287);
+ if (isSetBatchQueueEmailSenders())
+ hashCode = hashCode * 8191 + batchQueueEmailSenders.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -698,7 +663,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetJobSubmissionInterfaceId()).compareTo(other.isSetJobSubmissionInterfaceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetJobSubmissionInterfaceId()).compareTo(other.isSetJobSubmissionInterfaceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -708,7 +673,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetSecurityProtocol()).compareTo(other.isSetSecurityProtocol());
+ lastComparison = java.lang.Boolean.valueOf(isSetSecurityProtocol()).compareTo(other.isSetSecurityProtocol());
if (lastComparison != 0) {
return lastComparison;
}
@@ -718,7 +683,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetResourceJobManager()).compareTo(other.isSetResourceJobManager());
+ lastComparison = java.lang.Boolean.valueOf(isSetResourceJobManager()).compareTo(other.isSetResourceJobManager());
if (lastComparison != 0) {
return lastComparison;
}
@@ -728,7 +693,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAlternativeSSHHostName()).compareTo(other.isSetAlternativeSSHHostName());
+ lastComparison = java.lang.Boolean.valueOf(isSetAlternativeSSHHostName()).compareTo(other.isSetAlternativeSSHHostName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -738,7 +703,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetSshPort()).compareTo(other.isSetSshPort());
+ lastComparison = java.lang.Boolean.valueOf(isSetSshPort()).compareTo(other.isSetSshPort());
if (lastComparison != 0) {
return lastComparison;
}
@@ -748,7 +713,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetMonitorMode()).compareTo(other.isSetMonitorMode());
+ lastComparison = java.lang.Boolean.valueOf(isSetMonitorMode()).compareTo(other.isSetMonitorMode());
if (lastComparison != 0) {
return lastComparison;
}
@@ -758,7 +723,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetBatchQueueEmailSenders()).compareTo(other.isSetBatchQueueEmailSenders());
+ lastComparison = java.lang.Boolean.valueOf(isSetBatchQueueEmailSenders()).compareTo(other.isSetBatchQueueEmailSenders());
if (lastComparison != 0) {
return lastComparison;
}
@@ -776,16 +741,16 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("SSHJobSubmission(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("SSHJobSubmission(");
boolean first = true;
sb.append("jobSubmissionInterfaceId:");
@@ -879,7 +844,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -889,13 +854,13 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
}
}
- private static class SSHJobSubmissionStandardSchemeFactory implements SchemeFactory {
+ private static class SSHJobSubmissionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public SSHJobSubmissionStandardScheme getScheme() {
return new SSHJobSubmissionStandardScheme();
}
}
- private static class SSHJobSubmissionStandardScheme extends StandardScheme<SSHJobSubmission> {
+ private static class SSHJobSubmissionStandardScheme extends org.apache.thrift.scheme.StandardScheme<SSHJobSubmission> {
public void read(org.apache.thrift.protocol.TProtocol iprot, SSHJobSubmission struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -960,8 +925,8 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list20 = iprot.readListBegin();
- struct.batchQueueEmailSenders = new ArrayList<String>(_list20.size);
- String _elem21;
+ struct.batchQueueEmailSenders = new java.util.ArrayList<java.lang.String>(_list20.size);
+ java.lang.String _elem21;
for (int _i22 = 0; _i22 < _list20.size; ++_i22)
{
_elem21 = iprot.readString();
@@ -1026,7 +991,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
oprot.writeFieldBegin(BATCH_QUEUE_EMAIL_SENDERS_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.batchQueueEmailSenders.size()));
- for (String _iter23 : struct.batchQueueEmailSenders)
+ for (java.lang.String _iter23 : struct.batchQueueEmailSenders)
{
oprot.writeString(_iter23);
}
@@ -1041,21 +1006,21 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
}
- private static class SSHJobSubmissionTupleSchemeFactory implements SchemeFactory {
+ private static class SSHJobSubmissionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public SSHJobSubmissionTupleScheme getScheme() {
return new SSHJobSubmissionTupleScheme();
}
}
- private static class SSHJobSubmissionTupleScheme extends TupleScheme<SSHJobSubmission> {
+ private static class SSHJobSubmissionTupleScheme extends org.apache.thrift.scheme.TupleScheme<SSHJobSubmission> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, SSHJobSubmission struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.jobSubmissionInterfaceId);
oprot.writeI32(struct.securityProtocol.getValue());
struct.resourceJobManager.write(oprot);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetAlternativeSSHHostName()) {
optionals.set(0);
}
@@ -1081,7 +1046,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
if (struct.isSetBatchQueueEmailSenders()) {
{
oprot.writeI32(struct.batchQueueEmailSenders.size());
- for (String _iter24 : struct.batchQueueEmailSenders)
+ for (java.lang.String _iter24 : struct.batchQueueEmailSenders)
{
oprot.writeString(_iter24);
}
@@ -1091,7 +1056,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, SSHJobSubmission struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.jobSubmissionInterfaceId = iprot.readString();
struct.setJobSubmissionInterfaceIdIsSet(true);
struct.securityProtocol = org.apache.airavata.model.data.movement.SecurityProtocol.findByValue(iprot.readI32());
@@ -1099,7 +1064,7 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
struct.resourceJobManager = new ResourceJobManager();
struct.resourceJobManager.read(iprot);
struct.setResourceJobManagerIsSet(true);
- BitSet incoming = iprot.readBitSet(4);
+ java.util.BitSet incoming = iprot.readBitSet(4);
if (incoming.get(0)) {
struct.alternativeSSHHostName = iprot.readString();
struct.setAlternativeSSHHostNameIsSet(true);
@@ -1115,8 +1080,8 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
if (incoming.get(3)) {
{
org.apache.thrift.protocol.TList _list25 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.batchQueueEmailSenders = new ArrayList<String>(_list25.size);
- String _elem26;
+ struct.batchQueueEmailSenders = new java.util.ArrayList<java.lang.String>(_list25.size);
+ java.lang.String _elem26;
for (int _i27 = 0; _i27 < _list25.size; ++_i27)
{
_elem26 = iprot.readString();
@@ -1128,5 +1093,8 @@ public class SSHJobSubmission implements org.apache.thrift.TBase<SSHJobSubmissio
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/UnicoreJobSubmission.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/UnicoreJobSubmission.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/UnicoreJobSubmission.java
index 1d367fb..54fc0ae 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/UnicoreJobSubmission.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/UnicoreJobSubmission.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.computeresource;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Unicore Job Submission
*
@@ -59,7 +32,7 @@ import org.slf4j.LoggerFactory;
* authenticationMode
* The authenticationMode defines the way certificate is fetched.
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobSubmission, UnicoreJobSubmission._Fields>, java.io.Serializable, Cloneable, Comparable<UnicoreJobSubmission> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("UnicoreJobSubmission");
@@ -67,15 +40,12 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
private static final org.apache.thrift.protocol.TField SECURITY_PROTOCOL_FIELD_DESC = new org.apache.thrift.protocol.TField("securityProtocol", org.apache.thrift.protocol.TType.I32, (short)2);
private static final org.apache.thrift.protocol.TField UNICORE_END_POINT_URL_FIELD_DESC = new org.apache.thrift.protocol.TField("unicoreEndPointURL", 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 UnicoreJobSubmissionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new UnicoreJobSubmissionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new UnicoreJobSubmissionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new UnicoreJobSubmissionTupleSchemeFactory();
- private String jobSubmissionInterfaceId; // required
+ private java.lang.String jobSubmissionInterfaceId; // required
private org.apache.airavata.model.data.movement.SecurityProtocol securityProtocol; // required
- private String unicoreEndPointURL; // required
+ private java.lang.String unicoreEndPointURL; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -87,10 +57,10 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
SECURITY_PROTOCOL((short)2, "securityProtocol"),
UNICORE_END_POINT_URL((short)3, "unicoreEndPointURL");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -117,21 +87,21 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -140,22 +110,22 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.JOB_SUBMISSION_INTERFACE_ID, new org.apache.thrift.meta_data.FieldMetaData("jobSubmissionInterfaceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.SECURITY_PROTOCOL, new org.apache.thrift.meta_data.FieldMetaData("securityProtocol", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, org.apache.airavata.model.data.movement.SecurityProtocol.class)));
tmpMap.put(_Fields.UNICORE_END_POINT_URL, new org.apache.thrift.meta_data.FieldMetaData("unicoreEndPointURL", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(UnicoreJobSubmission.class, metaDataMap);
}
@@ -165,9 +135,9 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
}
public UnicoreJobSubmission(
- String jobSubmissionInterfaceId,
+ java.lang.String jobSubmissionInterfaceId,
org.apache.airavata.model.data.movement.SecurityProtocol securityProtocol,
- String unicoreEndPointURL)
+ java.lang.String unicoreEndPointURL)
{
this();
this.jobSubmissionInterfaceId = jobSubmissionInterfaceId;
@@ -202,11 +172,11 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
this.unicoreEndPointURL = null;
}
- public String getJobSubmissionInterfaceId() {
+ public java.lang.String getJobSubmissionInterfaceId() {
return this.jobSubmissionInterfaceId;
}
- public void setJobSubmissionInterfaceId(String jobSubmissionInterfaceId) {
+ public void setJobSubmissionInterfaceId(java.lang.String jobSubmissionInterfaceId) {
this.jobSubmissionInterfaceId = jobSubmissionInterfaceId;
}
@@ -256,11 +226,11 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
}
}
- public String getUnicoreEndPointURL() {
+ public java.lang.String getUnicoreEndPointURL() {
return this.unicoreEndPointURL;
}
- public void setUnicoreEndPointURL(String unicoreEndPointURL) {
+ public void setUnicoreEndPointURL(java.lang.String unicoreEndPointURL) {
this.unicoreEndPointURL = unicoreEndPointURL;
}
@@ -279,13 +249,13 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case JOB_SUBMISSION_INTERFACE_ID:
if (value == null) {
unsetJobSubmissionInterfaceId();
} else {
- setJobSubmissionInterfaceId((String)value);
+ setJobSubmissionInterfaceId((java.lang.String)value);
}
break;
@@ -301,14 +271,14 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
if (value == null) {
unsetUnicoreEndPointURL();
} else {
- setUnicoreEndPointURL((String)value);
+ setUnicoreEndPointURL((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case JOB_SUBMISSION_INTERFACE_ID:
return getJobSubmissionInterfaceId();
@@ -320,13 +290,13 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
return getUnicoreEndPointURL();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -337,11 +307,11 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
case UNICORE_END_POINT_URL:
return isSetUnicoreEndPointURL();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof UnicoreJobSubmission)
@@ -352,6 +322,8 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
public boolean equals(UnicoreJobSubmission that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_jobSubmissionInterfaceId = true && this.isSetJobSubmissionInterfaceId();
boolean that_present_jobSubmissionInterfaceId = true && that.isSetJobSubmissionInterfaceId();
@@ -385,24 +357,21 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_jobSubmissionInterfaceId = true && (isSetJobSubmissionInterfaceId());
- list.add(present_jobSubmissionInterfaceId);
- if (present_jobSubmissionInterfaceId)
- list.add(jobSubmissionInterfaceId);
+ hashCode = hashCode * 8191 + ((isSetJobSubmissionInterfaceId()) ? 131071 : 524287);
+ if (isSetJobSubmissionInterfaceId())
+ hashCode = hashCode * 8191 + jobSubmissionInterfaceId.hashCode();
- boolean present_securityProtocol = true && (isSetSecurityProtocol());
- list.add(present_securityProtocol);
- if (present_securityProtocol)
- list.add(securityProtocol.getValue());
+ hashCode = hashCode * 8191 + ((isSetSecurityProtocol()) ? 131071 : 524287);
+ if (isSetSecurityProtocol())
+ hashCode = hashCode * 8191 + securityProtocol.getValue();
- boolean present_unicoreEndPointURL = true && (isSetUnicoreEndPointURL());
- list.add(present_unicoreEndPointURL);
- if (present_unicoreEndPointURL)
- list.add(unicoreEndPointURL);
+ hashCode = hashCode * 8191 + ((isSetUnicoreEndPointURL()) ? 131071 : 524287);
+ if (isSetUnicoreEndPointURL())
+ hashCode = hashCode * 8191 + unicoreEndPointURL.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -413,7 +382,7 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetJobSubmissionInterfaceId()).compareTo(other.isSetJobSubmissionInterfaceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetJobSubmissionInterfaceId()).compareTo(other.isSetJobSubmissionInterfaceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -423,7 +392,7 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetSecurityProtocol()).compareTo(other.isSetSecurityProtocol());
+ lastComparison = java.lang.Boolean.valueOf(isSetSecurityProtocol()).compareTo(other.isSetSecurityProtocol());
if (lastComparison != 0) {
return lastComparison;
}
@@ -433,7 +402,7 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUnicoreEndPointURL()).compareTo(other.isSetUnicoreEndPointURL());
+ lastComparison = java.lang.Boolean.valueOf(isSetUnicoreEndPointURL()).compareTo(other.isSetUnicoreEndPointURL());
if (lastComparison != 0) {
return lastComparison;
}
@@ -451,16 +420,16 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("UnicoreJobSubmission(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("UnicoreJobSubmission(");
boolean first = true;
sb.append("jobSubmissionInterfaceId:");
@@ -515,7 +484,7 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -523,13 +492,13 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
}
}
- private static class UnicoreJobSubmissionStandardSchemeFactory implements SchemeFactory {
+ private static class UnicoreJobSubmissionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public UnicoreJobSubmissionStandardScheme getScheme() {
return new UnicoreJobSubmissionStandardScheme();
}
}
- private static class UnicoreJobSubmissionStandardScheme extends StandardScheme<UnicoreJobSubmission> {
+ private static class UnicoreJobSubmissionStandardScheme extends org.apache.thrift.scheme.StandardScheme<UnicoreJobSubmission> {
public void read(org.apache.thrift.protocol.TProtocol iprot, UnicoreJobSubmission struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -599,17 +568,17 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
}
- private static class UnicoreJobSubmissionTupleSchemeFactory implements SchemeFactory {
+ private static class UnicoreJobSubmissionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public UnicoreJobSubmissionTupleScheme getScheme() {
return new UnicoreJobSubmissionTupleScheme();
}
}
- private static class UnicoreJobSubmissionTupleScheme extends TupleScheme<UnicoreJobSubmission> {
+ private static class UnicoreJobSubmissionTupleScheme extends org.apache.thrift.scheme.TupleScheme<UnicoreJobSubmission> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, UnicoreJobSubmission struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.jobSubmissionInterfaceId);
oprot.writeI32(struct.securityProtocol.getValue());
oprot.writeString(struct.unicoreEndPointURL);
@@ -617,7 +586,7 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, UnicoreJobSubmission struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.jobSubmissionInterfaceId = iprot.readString();
struct.setJobSubmissionInterfaceIdIsSet(true);
struct.securityProtocol = org.apache.airavata.model.data.movement.SecurityProtocol.findByValue(iprot.readI32());
@@ -627,5 +596,8 @@ public class UnicoreJobSubmission implements org.apache.thrift.TBase<UnicoreJobS
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
[39/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/commons/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/commons/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/commons/ttypes.py
index 21ec7e0..3e081fd 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/commons/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/commons/ttypes.py
@@ -1,335 +1,308 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-
-class ErrorModel:
- """
- Attributes:
- - errorId
- - creationTime
- - actualErrorMessage
- - userFriendlyMessage
- - transientOrPersistent
- - rootCauseErrorIdList
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'errorId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.I64, 'creationTime', None, None, ), # 2
- (3, TType.STRING, 'actualErrorMessage', None, None, ), # 3
- (4, TType.STRING, 'userFriendlyMessage', None, None, ), # 4
- (5, TType.BOOL, 'transientOrPersistent', None, False, ), # 5
- (6, TType.LIST, 'rootCauseErrorIdList', (TType.STRING,None), None, ), # 6
- )
-
- def __init__(self, errorId=thrift_spec[1][4], creationTime=None, actualErrorMessage=None, userFriendlyMessage=None, transientOrPersistent=thrift_spec[5][4], rootCauseErrorIdList=None,):
- self.errorId = errorId
- self.creationTime = creationTime
- self.actualErrorMessage = actualErrorMessage
- self.userFriendlyMessage = userFriendlyMessage
- self.transientOrPersistent = transientOrPersistent
- self.rootCauseErrorIdList = rootCauseErrorIdList
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.errorId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I64:
- self.creationTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.actualErrorMessage = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.userFriendlyMessage = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.BOOL:
- self.transientOrPersistent = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.LIST:
- self.rootCauseErrorIdList = []
- (_etype3, _size0) = iprot.readListBegin()
- for _i4 in xrange(_size0):
- _elem5 = iprot.readString()
- self.rootCauseErrorIdList.append(_elem5)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ErrorModel')
- if self.errorId is not None:
- oprot.writeFieldBegin('errorId', TType.STRING, 1)
- oprot.writeString(self.errorId)
- oprot.writeFieldEnd()
- if self.creationTime is not None:
- oprot.writeFieldBegin('creationTime', TType.I64, 2)
- oprot.writeI64(self.creationTime)
- oprot.writeFieldEnd()
- if self.actualErrorMessage is not None:
- oprot.writeFieldBegin('actualErrorMessage', TType.STRING, 3)
- oprot.writeString(self.actualErrorMessage)
- oprot.writeFieldEnd()
- if self.userFriendlyMessage is not None:
- oprot.writeFieldBegin('userFriendlyMessage', TType.STRING, 4)
- oprot.writeString(self.userFriendlyMessage)
- oprot.writeFieldEnd()
- if self.transientOrPersistent is not None:
- oprot.writeFieldBegin('transientOrPersistent', TType.BOOL, 5)
- oprot.writeBool(self.transientOrPersistent)
- oprot.writeFieldEnd()
- if self.rootCauseErrorIdList is not None:
- oprot.writeFieldBegin('rootCauseErrorIdList', TType.LIST, 6)
- oprot.writeListBegin(TType.STRING, len(self.rootCauseErrorIdList))
- for iter6 in self.rootCauseErrorIdList:
- oprot.writeString(iter6)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.errorId is None:
- raise TProtocol.TProtocolException(message='Required field errorId is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.errorId)
- value = (value * 31) ^ hash(self.creationTime)
- value = (value * 31) ^ hash(self.actualErrorMessage)
- value = (value * 31) ^ hash(self.userFriendlyMessage)
- value = (value * 31) ^ hash(self.transientOrPersistent)
- value = (value * 31) ^ hash(self.rootCauseErrorIdList)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ValidatorResult:
- """
- This data structure can be used to store the validation results
- captured during validation step and during the launchExperiment
- operation it can be easilly checked to see the errors occured
- during the experiment launch operation
-
-
- Attributes:
- - result
- - errorDetails
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.BOOL, 'result', None, None, ), # 1
- (2, TType.STRING, 'errorDetails', None, None, ), # 2
- )
-
- def __init__(self, result=None, errorDetails=None,):
- self.result = result
- self.errorDetails = errorDetails
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.BOOL:
- self.result = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.errorDetails = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ValidatorResult')
- if self.result is not None:
- oprot.writeFieldBegin('result', TType.BOOL, 1)
- oprot.writeBool(self.result)
- oprot.writeFieldEnd()
- if self.errorDetails is not None:
- oprot.writeFieldBegin('errorDetails', TType.STRING, 2)
- oprot.writeString(self.errorDetails)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.result is None:
- raise TProtocol.TProtocolException(message='Required field result is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.result)
- value = (value * 31) ^ hash(self.errorDetails)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ValidationResults:
- """
- Attributes:
- - validationState
- - validationResultList
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.BOOL, 'validationState', None, None, ), # 1
- (2, TType.LIST, 'validationResultList', (TType.STRUCT,(ValidatorResult, ValidatorResult.thrift_spec)), None, ), # 2
- )
-
- def __init__(self, validationState=None, validationResultList=None,):
- self.validationState = validationState
- self.validationResultList = validationResultList
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.BOOL:
- self.validationState = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.LIST:
- self.validationResultList = []
- (_etype10, _size7) = iprot.readListBegin()
- for _i11 in xrange(_size7):
- _elem12 = ValidatorResult()
- _elem12.read(iprot)
- self.validationResultList.append(_elem12)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ValidationResults')
- if self.validationState is not None:
- oprot.writeFieldBegin('validationState', TType.BOOL, 1)
- oprot.writeBool(self.validationState)
- oprot.writeFieldEnd()
- if self.validationResultList is not None:
- oprot.writeFieldBegin('validationResultList', TType.LIST, 2)
- oprot.writeListBegin(TType.STRUCT, len(self.validationResultList))
- for iter13 in self.validationResultList:
- iter13.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.validationState is None:
- raise TProtocol.TProtocolException(message='Required field validationState is unset!')
- if self.validationResultList is None:
- raise TProtocol.TProtocolException(message='Required field validationResultList is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.validationState)
- value = (value * 31) ^ hash(self.validationResultList)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class ErrorModel(object):
+ """
+ Attributes:
+ - errorId
+ - creationTime
+ - actualErrorMessage
+ - userFriendlyMessage
+ - transientOrPersistent
+ - rootCauseErrorIdList
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'errorId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.I64, 'creationTime', None, None, ), # 2
+ (3, TType.STRING, 'actualErrorMessage', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'userFriendlyMessage', 'UTF8', None, ), # 4
+ (5, TType.BOOL, 'transientOrPersistent', None, False, ), # 5
+ (6, TType.LIST, 'rootCauseErrorIdList', (TType.STRING, 'UTF8', False), None, ), # 6
+ )
+
+ def __init__(self, errorId=thrift_spec[1][4], creationTime=None, actualErrorMessage=None, userFriendlyMessage=None, transientOrPersistent=thrift_spec[5][4], rootCauseErrorIdList=None,):
+ self.errorId = errorId
+ self.creationTime = creationTime
+ self.actualErrorMessage = actualErrorMessage
+ self.userFriendlyMessage = userFriendlyMessage
+ self.transientOrPersistent = transientOrPersistent
+ self.rootCauseErrorIdList = rootCauseErrorIdList
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.errorId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I64:
+ self.creationTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.actualErrorMessage = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.userFriendlyMessage = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.BOOL:
+ self.transientOrPersistent = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.LIST:
+ self.rootCauseErrorIdList = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in range(_size0):
+ _elem5 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ self.rootCauseErrorIdList.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ErrorModel')
+ if self.errorId is not None:
+ oprot.writeFieldBegin('errorId', TType.STRING, 1)
+ oprot.writeString(self.errorId.encode('utf-8') if sys.version_info[0] == 2 else self.errorId)
+ oprot.writeFieldEnd()
+ if self.creationTime is not None:
+ oprot.writeFieldBegin('creationTime', TType.I64, 2)
+ oprot.writeI64(self.creationTime)
+ oprot.writeFieldEnd()
+ if self.actualErrorMessage is not None:
+ oprot.writeFieldBegin('actualErrorMessage', TType.STRING, 3)
+ oprot.writeString(self.actualErrorMessage.encode('utf-8') if sys.version_info[0] == 2 else self.actualErrorMessage)
+ oprot.writeFieldEnd()
+ if self.userFriendlyMessage is not None:
+ oprot.writeFieldBegin('userFriendlyMessage', TType.STRING, 4)
+ oprot.writeString(self.userFriendlyMessage.encode('utf-8') if sys.version_info[0] == 2 else self.userFriendlyMessage)
+ oprot.writeFieldEnd()
+ if self.transientOrPersistent is not None:
+ oprot.writeFieldBegin('transientOrPersistent', TType.BOOL, 5)
+ oprot.writeBool(self.transientOrPersistent)
+ oprot.writeFieldEnd()
+ if self.rootCauseErrorIdList is not None:
+ oprot.writeFieldBegin('rootCauseErrorIdList', TType.LIST, 6)
+ oprot.writeListBegin(TType.STRING, len(self.rootCauseErrorIdList))
+ for iter6 in self.rootCauseErrorIdList:
+ oprot.writeString(iter6.encode('utf-8') if sys.version_info[0] == 2 else iter6)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.errorId is None:
+ raise TProtocolException(message='Required field errorId is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class ValidatorResult(object):
+ """
+ This data structure can be used to store the validation results
+ captured during validation step and during the launchExperiment
+ operation it can be easilly checked to see the errors occured
+ during the experiment launch operation
+
+
+ Attributes:
+ - result
+ - errorDetails
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.BOOL, 'result', None, None, ), # 1
+ (2, TType.STRING, 'errorDetails', 'UTF8', None, ), # 2
+ )
+
+ def __init__(self, result=None, errorDetails=None,):
+ self.result = result
+ self.errorDetails = errorDetails
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.BOOL:
+ self.result = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.errorDetails = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ValidatorResult')
+ if self.result is not None:
+ oprot.writeFieldBegin('result', TType.BOOL, 1)
+ oprot.writeBool(self.result)
+ oprot.writeFieldEnd()
+ if self.errorDetails is not None:
+ oprot.writeFieldBegin('errorDetails', TType.STRING, 2)
+ oprot.writeString(self.errorDetails.encode('utf-8') if sys.version_info[0] == 2 else self.errorDetails)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.result is None:
+ raise TProtocolException(message='Required field result is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class ValidationResults(object):
+ """
+ Attributes:
+ - validationState
+ - validationResultList
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.BOOL, 'validationState', None, None, ), # 1
+ (2, TType.LIST, 'validationResultList', (TType.STRUCT, (ValidatorResult, ValidatorResult.thrift_spec), False), None, ), # 2
+ )
+
+ def __init__(self, validationState=None, validationResultList=None,):
+ self.validationState = validationState
+ self.validationResultList = validationResultList
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.BOOL:
+ self.validationState = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.LIST:
+ self.validationResultList = []
+ (_etype10, _size7) = iprot.readListBegin()
+ for _i11 in range(_size7):
+ _elem12 = ValidatorResult()
+ _elem12.read(iprot)
+ self.validationResultList.append(_elem12)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ValidationResults')
+ if self.validationState is not None:
+ oprot.writeFieldBegin('validationState', TType.BOOL, 1)
+ oprot.writeBool(self.validationState)
+ oprot.writeFieldEnd()
+ if self.validationResultList is not None:
+ oprot.writeFieldBegin('validationResultList', TType.LIST, 2)
+ oprot.writeListBegin(TType.STRUCT, len(self.validationResultList))
+ for iter13 in self.validationResultList:
+ iter13.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.validationState is None:
+ raise TProtocolException(message='Required field validationState is unset!')
+ if self.validationResultList is None:
+ raise TProtocolException(message='Required field validationResultList is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/movement/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/movement/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/movement/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/movement/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/movement/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/movement/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/movement/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/movement/ttypes.py
index 01e5c45..ff74381 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/movement/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/movement/ttypes.py
@@ -1,625 +1,588 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.commons.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class DMType:
- COMPUTE_RESOURCE = 0
- STORAGE_RESOURCE = 1
-
- _VALUES_TO_NAMES = {
- 0: "COMPUTE_RESOURCE",
- 1: "STORAGE_RESOURCE",
- }
-
- _NAMES_TO_VALUES = {
- "COMPUTE_RESOURCE": 0,
- "STORAGE_RESOURCE": 1,
- }
-
-class SecurityProtocol:
- """
- Enumeration of security sshKeyAuthentication and authorization mechanisms supported by Airavata. This enumeration just
- describes the supported mechanism. The corresponding security credentials are registered with Airavata Credential
- store.
-
- USERNAME_PASSWORD:
- A User Name.
-
- SSH_KEYS:
- SSH Keys
-
- FIXME: Change GSI to a more precise generic security protocol - X509
-
- """
- USERNAME_PASSWORD = 0
- SSH_KEYS = 1
- GSI = 2
- KERBEROS = 3
- OAUTH = 4
- LOCAL = 5
-
- _VALUES_TO_NAMES = {
- 0: "USERNAME_PASSWORD",
- 1: "SSH_KEYS",
- 2: "GSI",
- 3: "KERBEROS",
- 4: "OAUTH",
- 5: "LOCAL",
- }
-
- _NAMES_TO_VALUES = {
- "USERNAME_PASSWORD": 0,
- "SSH_KEYS": 1,
- "GSI": 2,
- "KERBEROS": 3,
- "OAUTH": 4,
- "LOCAL": 5,
- }
-
-class DataMovementProtocol:
- """
- Enumeration of data movement supported by Airavata
-
- SCP:
- Job manager supporting the Portal Batch System (PBS) protocol. Some examples include TORQUE, PBSPro, Grid Engine.
-
- SFTP:
- The Simple Linux Utility for Resource Management is a open source workload manager.
-
- GridFTP:
- Globus File Transfer Protocol
-
- UNICORE_STORAGE_SERVICE:
- Storage Service Provided by Unicore
-
- """
- LOCAL = 0
- SCP = 1
- SFTP = 2
- GridFTP = 3
- UNICORE_STORAGE_SERVICE = 4
-
- _VALUES_TO_NAMES = {
- 0: "LOCAL",
- 1: "SCP",
- 2: "SFTP",
- 3: "GridFTP",
- 4: "UNICORE_STORAGE_SERVICE",
- }
-
- _NAMES_TO_VALUES = {
- "LOCAL": 0,
- "SCP": 1,
- "SFTP": 2,
- "GridFTP": 3,
- "UNICORE_STORAGE_SERVICE": 4,
- }
-
-
-class SCPDataMovement:
- """
- Data Movement through Secured Copy
-
- alternativeSCPHostName:
- If the login to scp is different than the hostname itself, specify it here
-
- sshPort:
- If a non-default port needs to used, specify it.
-
- Attributes:
- - dataMovementInterfaceId
- - securityProtocol
- - alternativeSCPHostName
- - sshPort
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'dataMovementInterfaceId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.I32, 'securityProtocol', None, None, ), # 2
- (3, TType.STRING, 'alternativeSCPHostName', None, None, ), # 3
- (4, TType.I32, 'sshPort', None, 22, ), # 4
- )
-
- def __init__(self, dataMovementInterfaceId=thrift_spec[1][4], securityProtocol=None, alternativeSCPHostName=None, sshPort=thrift_spec[4][4],):
- self.dataMovementInterfaceId = dataMovementInterfaceId
- self.securityProtocol = securityProtocol
- self.alternativeSCPHostName = alternativeSCPHostName
- self.sshPort = sshPort
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.dataMovementInterfaceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.securityProtocol = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.alternativeSCPHostName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.I32:
- self.sshPort = iprot.readI32()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('SCPDataMovement')
- if self.dataMovementInterfaceId is not None:
- oprot.writeFieldBegin('dataMovementInterfaceId', TType.STRING, 1)
- oprot.writeString(self.dataMovementInterfaceId)
- oprot.writeFieldEnd()
- if self.securityProtocol is not None:
- oprot.writeFieldBegin('securityProtocol', TType.I32, 2)
- oprot.writeI32(self.securityProtocol)
- oprot.writeFieldEnd()
- if self.alternativeSCPHostName is not None:
- oprot.writeFieldBegin('alternativeSCPHostName', TType.STRING, 3)
- oprot.writeString(self.alternativeSCPHostName)
- oprot.writeFieldEnd()
- if self.sshPort is not None:
- oprot.writeFieldBegin('sshPort', TType.I32, 4)
- oprot.writeI32(self.sshPort)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.dataMovementInterfaceId is None:
- raise TProtocol.TProtocolException(message='Required field dataMovementInterfaceId is unset!')
- if self.securityProtocol is None:
- raise TProtocol.TProtocolException(message='Required field securityProtocol is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.dataMovementInterfaceId)
- value = (value * 31) ^ hash(self.securityProtocol)
- value = (value * 31) ^ hash(self.alternativeSCPHostName)
- value = (value * 31) ^ hash(self.sshPort)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class GridFTPDataMovement:
- """
- Data Movement through GridFTP
-
- alternativeSCPHostName:
- If the login to scp is different than the hostname itself, specify it here
-
- sshPort:
- If a non-default port needs to used, specify it.
-
- Attributes:
- - dataMovementInterfaceId
- - securityProtocol
- - gridFTPEndPoints
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'dataMovementInterfaceId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.I32, 'securityProtocol', None, None, ), # 2
- (3, TType.LIST, 'gridFTPEndPoints', (TType.STRING,None), None, ), # 3
- )
-
- def __init__(self, dataMovementInterfaceId=thrift_spec[1][4], securityProtocol=None, gridFTPEndPoints=None,):
- self.dataMovementInterfaceId = dataMovementInterfaceId
- self.securityProtocol = securityProtocol
- self.gridFTPEndPoints = gridFTPEndPoints
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.dataMovementInterfaceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.securityProtocol = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.LIST:
- self.gridFTPEndPoints = []
- (_etype3, _size0) = iprot.readListBegin()
- for _i4 in xrange(_size0):
- _elem5 = iprot.readString()
- self.gridFTPEndPoints.append(_elem5)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('GridFTPDataMovement')
- if self.dataMovementInterfaceId is not None:
- oprot.writeFieldBegin('dataMovementInterfaceId', TType.STRING, 1)
- oprot.writeString(self.dataMovementInterfaceId)
- oprot.writeFieldEnd()
- if self.securityProtocol is not None:
- oprot.writeFieldBegin('securityProtocol', TType.I32, 2)
- oprot.writeI32(self.securityProtocol)
- oprot.writeFieldEnd()
- if self.gridFTPEndPoints is not None:
- oprot.writeFieldBegin('gridFTPEndPoints', TType.LIST, 3)
- oprot.writeListBegin(TType.STRING, len(self.gridFTPEndPoints))
- for iter6 in self.gridFTPEndPoints:
- oprot.writeString(iter6)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.dataMovementInterfaceId is None:
- raise TProtocol.TProtocolException(message='Required field dataMovementInterfaceId is unset!')
- if self.securityProtocol is None:
- raise TProtocol.TProtocolException(message='Required field securityProtocol is unset!')
- if self.gridFTPEndPoints is None:
- raise TProtocol.TProtocolException(message='Required field gridFTPEndPoints is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.dataMovementInterfaceId)
- value = (value * 31) ^ hash(self.securityProtocol)
- value = (value * 31) ^ hash(self.gridFTPEndPoints)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class UnicoreDataMovement:
- """
- Data Movement through UnicoreStorage
-
- unicoreEndPointURL:
- unicoreGateway End Point. The provider will query this service to fetch required service end points.
-
- Attributes:
- - dataMovementInterfaceId
- - securityProtocol
- - unicoreEndPointURL
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'dataMovementInterfaceId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.I32, 'securityProtocol', None, None, ), # 2
- (3, TType.STRING, 'unicoreEndPointURL', None, None, ), # 3
- )
-
- def __init__(self, dataMovementInterfaceId=thrift_spec[1][4], securityProtocol=None, unicoreEndPointURL=None,):
- self.dataMovementInterfaceId = dataMovementInterfaceId
- self.securityProtocol = securityProtocol
- self.unicoreEndPointURL = unicoreEndPointURL
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.dataMovementInterfaceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.securityProtocol = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.unicoreEndPointURL = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('UnicoreDataMovement')
- if self.dataMovementInterfaceId is not None:
- oprot.writeFieldBegin('dataMovementInterfaceId', TType.STRING, 1)
- oprot.writeString(self.dataMovementInterfaceId)
- oprot.writeFieldEnd()
- if self.securityProtocol is not None:
- oprot.writeFieldBegin('securityProtocol', TType.I32, 2)
- oprot.writeI32(self.securityProtocol)
- oprot.writeFieldEnd()
- if self.unicoreEndPointURL is not None:
- oprot.writeFieldBegin('unicoreEndPointURL', TType.STRING, 3)
- oprot.writeString(self.unicoreEndPointURL)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.dataMovementInterfaceId is None:
- raise TProtocol.TProtocolException(message='Required field dataMovementInterfaceId is unset!')
- if self.securityProtocol is None:
- raise TProtocol.TProtocolException(message='Required field securityProtocol is unset!')
- if self.unicoreEndPointURL is None:
- raise TProtocol.TProtocolException(message='Required field unicoreEndPointURL is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.dataMovementInterfaceId)
- value = (value * 31) ^ hash(self.securityProtocol)
- value = (value * 31) ^ hash(self.unicoreEndPointURL)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class LOCALDataMovement:
- """
- LOCAL
-
- alternativeSCPHostName:
- If the login to scp is different than the hostname itself, specify it here
-
- sshPort:
- If a non-defualt port needs to used, specify it.
-
- Attributes:
- - dataMovementInterfaceId
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'dataMovementInterfaceId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- )
-
- def __init__(self, dataMovementInterfaceId=thrift_spec[1][4],):
- self.dataMovementInterfaceId = dataMovementInterfaceId
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.dataMovementInterfaceId = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('LOCALDataMovement')
- if self.dataMovementInterfaceId is not None:
- oprot.writeFieldBegin('dataMovementInterfaceId', TType.STRING, 1)
- oprot.writeString(self.dataMovementInterfaceId)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.dataMovementInterfaceId is None:
- raise TProtocol.TProtocolException(message='Required field dataMovementInterfaceId is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.dataMovementInterfaceId)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class DataMovementInterface:
- """
- Data Movement Interfaces
-
- dataMovementInterfaceId: The Data Movement Interface has to be previously registered and referenced here.
-
- priorityOrder:
- For resources with multiple interfaces, the priority order should be selected.
- Lower the numerical number, higher the priority
-
-
- Attributes:
- - dataMovementInterfaceId
- - dataMovementProtocol
- - priorityOrder
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'dataMovementInterfaceId', None, None, ), # 1
- (2, TType.I32, 'dataMovementProtocol', None, None, ), # 2
- (3, TType.I32, 'priorityOrder', None, 0, ), # 3
- )
-
- def __init__(self, dataMovementInterfaceId=None, dataMovementProtocol=None, priorityOrder=thrift_spec[3][4],):
- self.dataMovementInterfaceId = dataMovementInterfaceId
- self.dataMovementProtocol = dataMovementProtocol
- self.priorityOrder = priorityOrder
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.dataMovementInterfaceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.dataMovementProtocol = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.I32:
- self.priorityOrder = iprot.readI32()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('DataMovementInterface')
- if self.dataMovementInterfaceId is not None:
- oprot.writeFieldBegin('dataMovementInterfaceId', TType.STRING, 1)
- oprot.writeString(self.dataMovementInterfaceId)
- oprot.writeFieldEnd()
- if self.dataMovementProtocol is not None:
- oprot.writeFieldBegin('dataMovementProtocol', TType.I32, 2)
- oprot.writeI32(self.dataMovementProtocol)
- oprot.writeFieldEnd()
- if self.priorityOrder is not None:
- oprot.writeFieldBegin('priorityOrder', TType.I32, 3)
- oprot.writeI32(self.priorityOrder)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.dataMovementInterfaceId is None:
- raise TProtocol.TProtocolException(message='Required field dataMovementInterfaceId is unset!')
- if self.dataMovementProtocol is None:
- raise TProtocol.TProtocolException(message='Required field dataMovementProtocol is unset!')
- if self.priorityOrder is None:
- raise TProtocol.TProtocolException(message='Required field priorityOrder is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.dataMovementInterfaceId)
- value = (value * 31) ^ hash(self.dataMovementProtocol)
- value = (value * 31) ^ hash(self.priorityOrder)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class DMType(object):
+ COMPUTE_RESOURCE = 0
+ STORAGE_RESOURCE = 1
+
+ _VALUES_TO_NAMES = {
+ 0: "COMPUTE_RESOURCE",
+ 1: "STORAGE_RESOURCE",
+ }
+
+ _NAMES_TO_VALUES = {
+ "COMPUTE_RESOURCE": 0,
+ "STORAGE_RESOURCE": 1,
+ }
+
+
+class SecurityProtocol(object):
+ """
+ Enumeration of security sshKeyAuthentication and authorization mechanisms supported by Airavata. This enumeration just
+ describes the supported mechanism. The corresponding security credentials are registered with Airavata Credential
+ store.
+
+ USERNAME_PASSWORD:
+ A User Name.
+
+ SSH_KEYS:
+ SSH Keys
+
+ FIXME: Change GSI to a more precise generic security protocol - X509
+
+ """
+ USERNAME_PASSWORD = 0
+ SSH_KEYS = 1
+ GSI = 2
+ KERBEROS = 3
+ OAUTH = 4
+ LOCAL = 5
+
+ _VALUES_TO_NAMES = {
+ 0: "USERNAME_PASSWORD",
+ 1: "SSH_KEYS",
+ 2: "GSI",
+ 3: "KERBEROS",
+ 4: "OAUTH",
+ 5: "LOCAL",
+ }
+
+ _NAMES_TO_VALUES = {
+ "USERNAME_PASSWORD": 0,
+ "SSH_KEYS": 1,
+ "GSI": 2,
+ "KERBEROS": 3,
+ "OAUTH": 4,
+ "LOCAL": 5,
+ }
+
+
+class DataMovementProtocol(object):
+ """
+ Enumeration of data movement supported by Airavata
+
+ SCP:
+ Job manager supporting the Portal Batch System (PBS) protocol. Some examples include TORQUE, PBSPro, Grid Engine.
+
+ SFTP:
+ The Simple Linux Utility for Resource Management is a open source workload manager.
+
+ GridFTP:
+ Globus File Transfer Protocol
+
+ UNICORE_STORAGE_SERVICE:
+ Storage Service Provided by Unicore
+
+ """
+ LOCAL = 0
+ SCP = 1
+ SFTP = 2
+ GridFTP = 3
+ UNICORE_STORAGE_SERVICE = 4
+
+ _VALUES_TO_NAMES = {
+ 0: "LOCAL",
+ 1: "SCP",
+ 2: "SFTP",
+ 3: "GridFTP",
+ 4: "UNICORE_STORAGE_SERVICE",
+ }
+
+ _NAMES_TO_VALUES = {
+ "LOCAL": 0,
+ "SCP": 1,
+ "SFTP": 2,
+ "GridFTP": 3,
+ "UNICORE_STORAGE_SERVICE": 4,
+ }
+
+
+class SCPDataMovement(object):
+ """
+ Data Movement through Secured Copy
+
+ alternativeSCPHostName:
+ If the login to scp is different than the hostname itself, specify it here
+
+ sshPort:
+ If a non-default port needs to used, specify it.
+
+ Attributes:
+ - dataMovementInterfaceId
+ - securityProtocol
+ - alternativeSCPHostName
+ - sshPort
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'dataMovementInterfaceId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.I32, 'securityProtocol', None, None, ), # 2
+ (3, TType.STRING, 'alternativeSCPHostName', 'UTF8', None, ), # 3
+ (4, TType.I32, 'sshPort', None, 22, ), # 4
+ )
+
+ def __init__(self, dataMovementInterfaceId=thrift_spec[1][4], securityProtocol=None, alternativeSCPHostName=None, sshPort=thrift_spec[4][4],):
+ self.dataMovementInterfaceId = dataMovementInterfaceId
+ self.securityProtocol = securityProtocol
+ self.alternativeSCPHostName = alternativeSCPHostName
+ self.sshPort = sshPort
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.dataMovementInterfaceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I32:
+ self.securityProtocol = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.alternativeSCPHostName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.I32:
+ self.sshPort = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('SCPDataMovement')
+ if self.dataMovementInterfaceId is not None:
+ oprot.writeFieldBegin('dataMovementInterfaceId', TType.STRING, 1)
+ oprot.writeString(self.dataMovementInterfaceId.encode('utf-8') if sys.version_info[0] == 2 else self.dataMovementInterfaceId)
+ oprot.writeFieldEnd()
+ if self.securityProtocol is not None:
+ oprot.writeFieldBegin('securityProtocol', TType.I32, 2)
+ oprot.writeI32(self.securityProtocol)
+ oprot.writeFieldEnd()
+ if self.alternativeSCPHostName is not None:
+ oprot.writeFieldBegin('alternativeSCPHostName', TType.STRING, 3)
+ oprot.writeString(self.alternativeSCPHostName.encode('utf-8') if sys.version_info[0] == 2 else self.alternativeSCPHostName)
+ oprot.writeFieldEnd()
+ if self.sshPort is not None:
+ oprot.writeFieldBegin('sshPort', TType.I32, 4)
+ oprot.writeI32(self.sshPort)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.dataMovementInterfaceId is None:
+ raise TProtocolException(message='Required field dataMovementInterfaceId is unset!')
+ if self.securityProtocol is None:
+ raise TProtocolException(message='Required field securityProtocol is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class GridFTPDataMovement(object):
+ """
+ Data Movement through GridFTP
+
+ alternativeSCPHostName:
+ If the login to scp is different than the hostname itself, specify it here
+
+ sshPort:
+ If a non-default port needs to used, specify it.
+
+ Attributes:
+ - dataMovementInterfaceId
+ - securityProtocol
+ - gridFTPEndPoints
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'dataMovementInterfaceId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.I32, 'securityProtocol', None, None, ), # 2
+ (3, TType.LIST, 'gridFTPEndPoints', (TType.STRING, 'UTF8', False), None, ), # 3
+ )
+
+ def __init__(self, dataMovementInterfaceId=thrift_spec[1][4], securityProtocol=None, gridFTPEndPoints=None,):
+ self.dataMovementInterfaceId = dataMovementInterfaceId
+ self.securityProtocol = securityProtocol
+ self.gridFTPEndPoints = gridFTPEndPoints
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.dataMovementInterfaceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I32:
+ self.securityProtocol = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.LIST:
+ self.gridFTPEndPoints = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in range(_size0):
+ _elem5 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ self.gridFTPEndPoints.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('GridFTPDataMovement')
+ if self.dataMovementInterfaceId is not None:
+ oprot.writeFieldBegin('dataMovementInterfaceId', TType.STRING, 1)
+ oprot.writeString(self.dataMovementInterfaceId.encode('utf-8') if sys.version_info[0] == 2 else self.dataMovementInterfaceId)
+ oprot.writeFieldEnd()
+ if self.securityProtocol is not None:
+ oprot.writeFieldBegin('securityProtocol', TType.I32, 2)
+ oprot.writeI32(self.securityProtocol)
+ oprot.writeFieldEnd()
+ if self.gridFTPEndPoints is not None:
+ oprot.writeFieldBegin('gridFTPEndPoints', TType.LIST, 3)
+ oprot.writeListBegin(TType.STRING, len(self.gridFTPEndPoints))
+ for iter6 in self.gridFTPEndPoints:
+ oprot.writeString(iter6.encode('utf-8') if sys.version_info[0] == 2 else iter6)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.dataMovementInterfaceId is None:
+ raise TProtocolException(message='Required field dataMovementInterfaceId is unset!')
+ if self.securityProtocol is None:
+ raise TProtocolException(message='Required field securityProtocol is unset!')
+ if self.gridFTPEndPoints is None:
+ raise TProtocolException(message='Required field gridFTPEndPoints is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class UnicoreDataMovement(object):
+ """
+ Data Movement through UnicoreStorage
+
+ unicoreEndPointURL:
+ unicoreGateway End Point. The provider will query this service to fetch required service end points.
+
+ Attributes:
+ - dataMovementInterfaceId
+ - securityProtocol
+ - unicoreEndPointURL
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'dataMovementInterfaceId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.I32, 'securityProtocol', None, None, ), # 2
+ (3, TType.STRING, 'unicoreEndPointURL', 'UTF8', None, ), # 3
+ )
+
+ def __init__(self, dataMovementInterfaceId=thrift_spec[1][4], securityProtocol=None, unicoreEndPointURL=None,):
+ self.dataMovementInterfaceId = dataMovementInterfaceId
+ self.securityProtocol = securityProtocol
+ self.unicoreEndPointURL = unicoreEndPointURL
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.dataMovementInterfaceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I32:
+ self.securityProtocol = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.unicoreEndPointURL = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('UnicoreDataMovement')
+ if self.dataMovementInterfaceId is not None:
+ oprot.writeFieldBegin('dataMovementInterfaceId', TType.STRING, 1)
+ oprot.writeString(self.dataMovementInterfaceId.encode('utf-8') if sys.version_info[0] == 2 else self.dataMovementInterfaceId)
+ oprot.writeFieldEnd()
+ if self.securityProtocol is not None:
+ oprot.writeFieldBegin('securityProtocol', TType.I32, 2)
+ oprot.writeI32(self.securityProtocol)
+ oprot.writeFieldEnd()
+ if self.unicoreEndPointURL is not None:
+ oprot.writeFieldBegin('unicoreEndPointURL', TType.STRING, 3)
+ oprot.writeString(self.unicoreEndPointURL.encode('utf-8') if sys.version_info[0] == 2 else self.unicoreEndPointURL)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.dataMovementInterfaceId is None:
+ raise TProtocolException(message='Required field dataMovementInterfaceId is unset!')
+ if self.securityProtocol is None:
+ raise TProtocolException(message='Required field securityProtocol is unset!')
+ if self.unicoreEndPointURL is None:
+ raise TProtocolException(message='Required field unicoreEndPointURL is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class LOCALDataMovement(object):
+ """
+ LOCAL
+
+ alternativeSCPHostName:
+ If the login to scp is different than the hostname itself, specify it here
+
+ sshPort:
+ If a non-defualt port needs to used, specify it.
+
+ Attributes:
+ - dataMovementInterfaceId
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'dataMovementInterfaceId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ )
+
+ def __init__(self, dataMovementInterfaceId=thrift_spec[1][4],):
+ self.dataMovementInterfaceId = dataMovementInterfaceId
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.dataMovementInterfaceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('LOCALDataMovement')
+ if self.dataMovementInterfaceId is not None:
+ oprot.writeFieldBegin('dataMovementInterfaceId', TType.STRING, 1)
+ oprot.writeString(self.dataMovementInterfaceId.encode('utf-8') if sys.version_info[0] == 2 else self.dataMovementInterfaceId)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.dataMovementInterfaceId is None:
+ raise TProtocolException(message='Required field dataMovementInterfaceId is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class DataMovementInterface(object):
+ """
+ Data Movement Interfaces
+
+ dataMovementInterfaceId: The Data Movement Interface has to be previously registered and referenced here.
+
+ priorityOrder:
+ For resources with multiple interfaces, the priority order should be selected.
+ Lower the numerical number, higher the priority
+
+
+ Attributes:
+ - dataMovementInterfaceId
+ - dataMovementProtocol
+ - priorityOrder
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'dataMovementInterfaceId', 'UTF8', None, ), # 1
+ (2, TType.I32, 'dataMovementProtocol', None, None, ), # 2
+ (3, TType.I32, 'priorityOrder', None, 0, ), # 3
+ )
+
+ def __init__(self, dataMovementInterfaceId=None, dataMovementProtocol=None, priorityOrder=thrift_spec[3][4],):
+ self.dataMovementInterfaceId = dataMovementInterfaceId
+ self.dataMovementProtocol = dataMovementProtocol
+ self.priorityOrder = priorityOrder
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.dataMovementInterfaceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I32:
+ self.dataMovementProtocol = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I32:
+ self.priorityOrder = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('DataMovementInterface')
+ if self.dataMovementInterfaceId is not None:
+ oprot.writeFieldBegin('dataMovementInterfaceId', TType.STRING, 1)
+ oprot.writeString(self.dataMovementInterfaceId.encode('utf-8') if sys.version_info[0] == 2 else self.dataMovementInterfaceId)
+ oprot.writeFieldEnd()
+ if self.dataMovementProtocol is not None:
+ oprot.writeFieldBegin('dataMovementProtocol', TType.I32, 2)
+ oprot.writeI32(self.dataMovementProtocol)
+ oprot.writeFieldEnd()
+ if self.priorityOrder is not None:
+ oprot.writeFieldBegin('priorityOrder', TType.I32, 3)
+ oprot.writeI32(self.priorityOrder)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.dataMovementInterfaceId is None:
+ raise TProtocolException(message='Required field dataMovementInterfaceId is unset!')
+ if self.dataMovementProtocol is None:
+ raise TProtocolException(message='Required field dataMovementProtocol is unset!')
+ if self.priorityOrder is None:
+ raise TProtocolException(message='Required field priorityOrder is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/replica/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/replica/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/replica/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/replica/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/replica/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
[20/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ComputeResourceDescription.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ComputeResourceDescription.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ComputeResourceDescription.java
index 65ad6ad..9b804da 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ComputeResourceDescription.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/ComputeResourceDescription.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.computeresource;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Computational Resource Description
*
@@ -80,7 +53,7 @@ import org.slf4j.LoggerFactory;
* Map of file systems type and the path.
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class ComputeResourceDescription implements org.apache.thrift.TBase<ComputeResourceDescription, ComputeResourceDescription._Fields>, java.io.Serializable, Cloneable, Comparable<ComputeResourceDescription> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ComputeResourceDescription");
@@ -103,26 +76,23 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
private static final org.apache.thrift.protocol.TField DEFAULT_CPUCOUNT_FIELD_DESC = new org.apache.thrift.protocol.TField("defaultCPUCount", org.apache.thrift.protocol.TType.I32, (short)17);
private static final org.apache.thrift.protocol.TField DEFAULT_WALLTIME_FIELD_DESC = new org.apache.thrift.protocol.TField("defaultWalltime", org.apache.thrift.protocol.TType.I32, (short)18);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new ComputeResourceDescriptionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ComputeResourceDescriptionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ComputeResourceDescriptionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ComputeResourceDescriptionTupleSchemeFactory();
- private String computeResourceId; // required
- private String hostName; // required
- private List<String> hostAliases; // optional
- private List<String> ipAddresses; // optional
- private String resourceDescription; // optional
+ private java.lang.String computeResourceId; // required
+ private java.lang.String hostName; // required
+ private java.util.List<java.lang.String> hostAliases; // optional
+ private java.util.List<java.lang.String> ipAddresses; // optional
+ private java.lang.String resourceDescription; // optional
private boolean enabled; // optional
- private List<BatchQueue> batchQueues; // optional
- private Map<FileSystems,String> fileSystems; // optional
- private List<JobSubmissionInterface> jobSubmissionInterfaces; // optional
- private List<org.apache.airavata.model.data.movement.DataMovementInterface> dataMovementInterfaces; // optional
+ private java.util.List<BatchQueue> batchQueues; // optional
+ private java.util.Map<FileSystems,java.lang.String> fileSystems; // optional
+ private java.util.List<JobSubmissionInterface> jobSubmissionInterfaces; // optional
+ private java.util.List<org.apache.airavata.model.data.movement.DataMovementInterface> dataMovementInterfaces; // optional
private int maxMemoryPerNode; // optional
private boolean gatewayUsageReporting; // optional
- private String gatewayUsageModuleLoadCommand; // optional
- private String gatewayUsageExecutable; // optional
+ private java.lang.String gatewayUsageModuleLoadCommand; // optional
+ private java.lang.String gatewayUsageExecutable; // optional
private int cpusPerNode; // optional
private int defaultNodeCount; // optional
private int defaultCPUCount; // optional
@@ -149,10 +119,10 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
DEFAULT_CPUCOUNT((short)17, "defaultCPUCount"),
DEFAULT_WALLTIME((short)18, "defaultWalltime");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -209,21 +179,21 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -232,7 +202,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -247,9 +217,9 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
private static final int __DEFAULTWALLTIME_ISSET_ID = 6;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.HOST_ALIASES,_Fields.IP_ADDRESSES,_Fields.RESOURCE_DESCRIPTION,_Fields.ENABLED,_Fields.BATCH_QUEUES,_Fields.FILE_SYSTEMS,_Fields.JOB_SUBMISSION_INTERFACES,_Fields.DATA_MOVEMENT_INTERFACES,_Fields.MAX_MEMORY_PER_NODE,_Fields.GATEWAY_USAGE_REPORTING,_Fields.GATEWAY_USAGE_MODULE_LOAD_COMMAND,_Fields.GATEWAY_USAGE_EXECUTABLE,_Fields.CPUS_PER_NODE,_Fields.DEFAULT_NODE_COUNT,_Fields.DEFAULT_CPUCOUNT,_Fields.DEFAULT_WALLTIME};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.COMPUTE_RESOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("computeResourceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.HOST_NAME, new org.apache.thrift.meta_data.FieldMetaData("hostName", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -293,7 +263,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
tmpMap.put(_Fields.DEFAULT_WALLTIME, new org.apache.thrift.meta_data.FieldMetaData("defaultWalltime", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ComputeResourceDescription.class, metaDataMap);
}
@@ -303,8 +273,8 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
}
public ComputeResourceDescription(
- String computeResourceId,
- String hostName)
+ java.lang.String computeResourceId,
+ java.lang.String hostName)
{
this();
this.computeResourceId = computeResourceId;
@@ -323,11 +293,11 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
this.hostName = other.hostName;
}
if (other.isSetHostAliases()) {
- List<String> __this__hostAliases = new ArrayList<String>(other.hostAliases);
+ java.util.List<java.lang.String> __this__hostAliases = new java.util.ArrayList<java.lang.String>(other.hostAliases);
this.hostAliases = __this__hostAliases;
}
if (other.isSetIpAddresses()) {
- List<String> __this__ipAddresses = new ArrayList<String>(other.ipAddresses);
+ java.util.List<java.lang.String> __this__ipAddresses = new java.util.ArrayList<java.lang.String>(other.ipAddresses);
this.ipAddresses = __this__ipAddresses;
}
if (other.isSetResourceDescription()) {
@@ -335,36 +305,36 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
}
this.enabled = other.enabled;
if (other.isSetBatchQueues()) {
- List<BatchQueue> __this__batchQueues = new ArrayList<BatchQueue>(other.batchQueues.size());
+ java.util.List<BatchQueue> __this__batchQueues = new java.util.ArrayList<BatchQueue>(other.batchQueues.size());
for (BatchQueue other_element : other.batchQueues) {
__this__batchQueues.add(new BatchQueue(other_element));
}
this.batchQueues = __this__batchQueues;
}
if (other.isSetFileSystems()) {
- Map<FileSystems,String> __this__fileSystems = new HashMap<FileSystems,String>(other.fileSystems.size());
- for (Map.Entry<FileSystems, String> other_element : other.fileSystems.entrySet()) {
+ java.util.Map<FileSystems,java.lang.String> __this__fileSystems = new java.util.HashMap<FileSystems,java.lang.String>(other.fileSystems.size());
+ for (java.util.Map.Entry<FileSystems, java.lang.String> other_element : other.fileSystems.entrySet()) {
FileSystems other_element_key = other_element.getKey();
- String other_element_value = other_element.getValue();
+ java.lang.String other_element_value = other_element.getValue();
FileSystems __this__fileSystems_copy_key = other_element_key;
- String __this__fileSystems_copy_value = other_element_value;
+ java.lang.String __this__fileSystems_copy_value = other_element_value;
__this__fileSystems.put(__this__fileSystems_copy_key, __this__fileSystems_copy_value);
}
this.fileSystems = __this__fileSystems;
}
if (other.isSetJobSubmissionInterfaces()) {
- List<JobSubmissionInterface> __this__jobSubmissionInterfaces = new ArrayList<JobSubmissionInterface>(other.jobSubmissionInterfaces.size());
+ java.util.List<JobSubmissionInterface> __this__jobSubmissionInterfaces = new java.util.ArrayList<JobSubmissionInterface>(other.jobSubmissionInterfaces.size());
for (JobSubmissionInterface other_element : other.jobSubmissionInterfaces) {
__this__jobSubmissionInterfaces.add(new JobSubmissionInterface(other_element));
}
this.jobSubmissionInterfaces = __this__jobSubmissionInterfaces;
}
if (other.isSetDataMovementInterfaces()) {
- List<org.apache.airavata.model.data.movement.DataMovementInterface> __this__dataMovementInterfaces = new ArrayList<org.apache.airavata.model.data.movement.DataMovementInterface>(other.dataMovementInterfaces.size());
+ java.util.List<org.apache.airavata.model.data.movement.DataMovementInterface> __this__dataMovementInterfaces = new java.util.ArrayList<org.apache.airavata.model.data.movement.DataMovementInterface>(other.dataMovementInterfaces.size());
for (org.apache.airavata.model.data.movement.DataMovementInterface other_element : other.dataMovementInterfaces) {
__this__dataMovementInterfaces.add(new org.apache.airavata.model.data.movement.DataMovementInterface(other_element));
}
@@ -418,11 +388,11 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
this.defaultWalltime = 0;
}
- public String getComputeResourceId() {
+ public java.lang.String getComputeResourceId() {
return this.computeResourceId;
}
- public void setComputeResourceId(String computeResourceId) {
+ public void setComputeResourceId(java.lang.String computeResourceId) {
this.computeResourceId = computeResourceId;
}
@@ -441,11 +411,11 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
}
}
- public String getHostName() {
+ public java.lang.String getHostName() {
return this.hostName;
}
- public void setHostName(String hostName) {
+ public void setHostName(java.lang.String hostName) {
this.hostName = hostName;
}
@@ -468,22 +438,22 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return (this.hostAliases == null) ? 0 : this.hostAliases.size();
}
- public java.util.Iterator<String> getHostAliasesIterator() {
+ public java.util.Iterator<java.lang.String> getHostAliasesIterator() {
return (this.hostAliases == null) ? null : this.hostAliases.iterator();
}
- public void addToHostAliases(String elem) {
+ public void addToHostAliases(java.lang.String elem) {
if (this.hostAliases == null) {
- this.hostAliases = new ArrayList<String>();
+ this.hostAliases = new java.util.ArrayList<java.lang.String>();
}
this.hostAliases.add(elem);
}
- public List<String> getHostAliases() {
+ public java.util.List<java.lang.String> getHostAliases() {
return this.hostAliases;
}
- public void setHostAliases(List<String> hostAliases) {
+ public void setHostAliases(java.util.List<java.lang.String> hostAliases) {
this.hostAliases = hostAliases;
}
@@ -506,22 +476,22 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return (this.ipAddresses == null) ? 0 : this.ipAddresses.size();
}
- public java.util.Iterator<String> getIpAddressesIterator() {
+ public java.util.Iterator<java.lang.String> getIpAddressesIterator() {
return (this.ipAddresses == null) ? null : this.ipAddresses.iterator();
}
- public void addToIpAddresses(String elem) {
+ public void addToIpAddresses(java.lang.String elem) {
if (this.ipAddresses == null) {
- this.ipAddresses = new ArrayList<String>();
+ this.ipAddresses = new java.util.ArrayList<java.lang.String>();
}
this.ipAddresses.add(elem);
}
- public List<String> getIpAddresses() {
+ public java.util.List<java.lang.String> getIpAddresses() {
return this.ipAddresses;
}
- public void setIpAddresses(List<String> ipAddresses) {
+ public void setIpAddresses(java.util.List<java.lang.String> ipAddresses) {
this.ipAddresses = ipAddresses;
}
@@ -540,11 +510,11 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
}
}
- public String getResourceDescription() {
+ public java.lang.String getResourceDescription() {
return this.resourceDescription;
}
- public void setResourceDescription(String resourceDescription) {
+ public void setResourceDescription(java.lang.String resourceDescription) {
this.resourceDescription = resourceDescription;
}
@@ -573,16 +543,16 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
}
public void unsetEnabled() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ENABLED_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ENABLED_ISSET_ID);
}
/** Returns true if field enabled is set (has been assigned a value) and false otherwise */
public boolean isSetEnabled() {
- return EncodingUtils.testBit(__isset_bitfield, __ENABLED_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ENABLED_ISSET_ID);
}
public void setEnabledIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ENABLED_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ENABLED_ISSET_ID, value);
}
public int getBatchQueuesSize() {
@@ -595,16 +565,16 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
public void addToBatchQueues(BatchQueue elem) {
if (this.batchQueues == null) {
- this.batchQueues = new ArrayList<BatchQueue>();
+ this.batchQueues = new java.util.ArrayList<BatchQueue>();
}
this.batchQueues.add(elem);
}
- public List<BatchQueue> getBatchQueues() {
+ public java.util.List<BatchQueue> getBatchQueues() {
return this.batchQueues;
}
- public void setBatchQueues(List<BatchQueue> batchQueues) {
+ public void setBatchQueues(java.util.List<BatchQueue> batchQueues) {
this.batchQueues = batchQueues;
}
@@ -627,18 +597,18 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return (this.fileSystems == null) ? 0 : this.fileSystems.size();
}
- public void putToFileSystems(FileSystems key, String val) {
+ public void putToFileSystems(FileSystems key, java.lang.String val) {
if (this.fileSystems == null) {
- this.fileSystems = new HashMap<FileSystems,String>();
+ this.fileSystems = new java.util.HashMap<FileSystems,java.lang.String>();
}
this.fileSystems.put(key, val);
}
- public Map<FileSystems,String> getFileSystems() {
+ public java.util.Map<FileSystems,java.lang.String> getFileSystems() {
return this.fileSystems;
}
- public void setFileSystems(Map<FileSystems,String> fileSystems) {
+ public void setFileSystems(java.util.Map<FileSystems,java.lang.String> fileSystems) {
this.fileSystems = fileSystems;
}
@@ -667,16 +637,16 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
public void addToJobSubmissionInterfaces(JobSubmissionInterface elem) {
if (this.jobSubmissionInterfaces == null) {
- this.jobSubmissionInterfaces = new ArrayList<JobSubmissionInterface>();
+ this.jobSubmissionInterfaces = new java.util.ArrayList<JobSubmissionInterface>();
}
this.jobSubmissionInterfaces.add(elem);
}
- public List<JobSubmissionInterface> getJobSubmissionInterfaces() {
+ public java.util.List<JobSubmissionInterface> getJobSubmissionInterfaces() {
return this.jobSubmissionInterfaces;
}
- public void setJobSubmissionInterfaces(List<JobSubmissionInterface> jobSubmissionInterfaces) {
+ public void setJobSubmissionInterfaces(java.util.List<JobSubmissionInterface> jobSubmissionInterfaces) {
this.jobSubmissionInterfaces = jobSubmissionInterfaces;
}
@@ -705,16 +675,16 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
public void addToDataMovementInterfaces(org.apache.airavata.model.data.movement.DataMovementInterface elem) {
if (this.dataMovementInterfaces == null) {
- this.dataMovementInterfaces = new ArrayList<org.apache.airavata.model.data.movement.DataMovementInterface>();
+ this.dataMovementInterfaces = new java.util.ArrayList<org.apache.airavata.model.data.movement.DataMovementInterface>();
}
this.dataMovementInterfaces.add(elem);
}
- public List<org.apache.airavata.model.data.movement.DataMovementInterface> getDataMovementInterfaces() {
+ public java.util.List<org.apache.airavata.model.data.movement.DataMovementInterface> getDataMovementInterfaces() {
return this.dataMovementInterfaces;
}
- public void setDataMovementInterfaces(List<org.apache.airavata.model.data.movement.DataMovementInterface> dataMovementInterfaces) {
+ public void setDataMovementInterfaces(java.util.List<org.apache.airavata.model.data.movement.DataMovementInterface> dataMovementInterfaces) {
this.dataMovementInterfaces = dataMovementInterfaces;
}
@@ -743,16 +713,16 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
}
public void unsetMaxMemoryPerNode() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __MAXMEMORYPERNODE_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __MAXMEMORYPERNODE_ISSET_ID);
}
/** Returns true if field maxMemoryPerNode is set (has been assigned a value) and false otherwise */
public boolean isSetMaxMemoryPerNode() {
- return EncodingUtils.testBit(__isset_bitfield, __MAXMEMORYPERNODE_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __MAXMEMORYPERNODE_ISSET_ID);
}
public void setMaxMemoryPerNodeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __MAXMEMORYPERNODE_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __MAXMEMORYPERNODE_ISSET_ID, value);
}
public boolean isGatewayUsageReporting() {
@@ -765,23 +735,23 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
}
public void unsetGatewayUsageReporting() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __GATEWAYUSAGEREPORTING_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __GATEWAYUSAGEREPORTING_ISSET_ID);
}
/** Returns true if field gatewayUsageReporting is set (has been assigned a value) and false otherwise */
public boolean isSetGatewayUsageReporting() {
- return EncodingUtils.testBit(__isset_bitfield, __GATEWAYUSAGEREPORTING_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __GATEWAYUSAGEREPORTING_ISSET_ID);
}
public void setGatewayUsageReportingIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __GATEWAYUSAGEREPORTING_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __GATEWAYUSAGEREPORTING_ISSET_ID, value);
}
- public String getGatewayUsageModuleLoadCommand() {
+ public java.lang.String getGatewayUsageModuleLoadCommand() {
return this.gatewayUsageModuleLoadCommand;
}
- public void setGatewayUsageModuleLoadCommand(String gatewayUsageModuleLoadCommand) {
+ public void setGatewayUsageModuleLoadCommand(java.lang.String gatewayUsageModuleLoadCommand) {
this.gatewayUsageModuleLoadCommand = gatewayUsageModuleLoadCommand;
}
@@ -800,11 +770,11 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
}
}
- public String getGatewayUsageExecutable() {
+ public java.lang.String getGatewayUsageExecutable() {
return this.gatewayUsageExecutable;
}
- public void setGatewayUsageExecutable(String gatewayUsageExecutable) {
+ public void setGatewayUsageExecutable(java.lang.String gatewayUsageExecutable) {
this.gatewayUsageExecutable = gatewayUsageExecutable;
}
@@ -833,16 +803,16 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
}
public void unsetCpusPerNode() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __CPUSPERNODE_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __CPUSPERNODE_ISSET_ID);
}
/** Returns true if field cpusPerNode is set (has been assigned a value) and false otherwise */
public boolean isSetCpusPerNode() {
- return EncodingUtils.testBit(__isset_bitfield, __CPUSPERNODE_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __CPUSPERNODE_ISSET_ID);
}
public void setCpusPerNodeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __CPUSPERNODE_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __CPUSPERNODE_ISSET_ID, value);
}
public int getDefaultNodeCount() {
@@ -855,16 +825,16 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
}
public void unsetDefaultNodeCount() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID);
}
/** Returns true if field defaultNodeCount is set (has been assigned a value) and false otherwise */
public boolean isSetDefaultNodeCount() {
- return EncodingUtils.testBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID);
}
public void setDefaultNodeCountIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID, value);
}
public int getDefaultCPUCount() {
@@ -877,16 +847,16 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
}
public void unsetDefaultCPUCount() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID);
}
/** Returns true if field defaultCPUCount is set (has been assigned a value) and false otherwise */
public boolean isSetDefaultCPUCount() {
- return EncodingUtils.testBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID);
}
public void setDefaultCPUCountIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID, value);
}
public int getDefaultWalltime() {
@@ -899,25 +869,25 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
}
public void unsetDefaultWalltime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID);
}
/** Returns true if field defaultWalltime is set (has been assigned a value) and false otherwise */
public boolean isSetDefaultWalltime() {
- return EncodingUtils.testBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID);
}
public void setDefaultWalltimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case COMPUTE_RESOURCE_ID:
if (value == null) {
unsetComputeResourceId();
} else {
- setComputeResourceId((String)value);
+ setComputeResourceId((java.lang.String)value);
}
break;
@@ -925,7 +895,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (value == null) {
unsetHostName();
} else {
- setHostName((String)value);
+ setHostName((java.lang.String)value);
}
break;
@@ -933,7 +903,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (value == null) {
unsetHostAliases();
} else {
- setHostAliases((List<String>)value);
+ setHostAliases((java.util.List<java.lang.String>)value);
}
break;
@@ -941,7 +911,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (value == null) {
unsetIpAddresses();
} else {
- setIpAddresses((List<String>)value);
+ setIpAddresses((java.util.List<java.lang.String>)value);
}
break;
@@ -949,7 +919,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (value == null) {
unsetResourceDescription();
} else {
- setResourceDescription((String)value);
+ setResourceDescription((java.lang.String)value);
}
break;
@@ -957,7 +927,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (value == null) {
unsetEnabled();
} else {
- setEnabled((Boolean)value);
+ setEnabled((java.lang.Boolean)value);
}
break;
@@ -965,7 +935,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (value == null) {
unsetBatchQueues();
} else {
- setBatchQueues((List<BatchQueue>)value);
+ setBatchQueues((java.util.List<BatchQueue>)value);
}
break;
@@ -973,7 +943,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (value == null) {
unsetFileSystems();
} else {
- setFileSystems((Map<FileSystems,String>)value);
+ setFileSystems((java.util.Map<FileSystems,java.lang.String>)value);
}
break;
@@ -981,7 +951,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (value == null) {
unsetJobSubmissionInterfaces();
} else {
- setJobSubmissionInterfaces((List<JobSubmissionInterface>)value);
+ setJobSubmissionInterfaces((java.util.List<JobSubmissionInterface>)value);
}
break;
@@ -989,7 +959,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (value == null) {
unsetDataMovementInterfaces();
} else {
- setDataMovementInterfaces((List<org.apache.airavata.model.data.movement.DataMovementInterface>)value);
+ setDataMovementInterfaces((java.util.List<org.apache.airavata.model.data.movement.DataMovementInterface>)value);
}
break;
@@ -997,7 +967,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (value == null) {
unsetMaxMemoryPerNode();
} else {
- setMaxMemoryPerNode((Integer)value);
+ setMaxMemoryPerNode((java.lang.Integer)value);
}
break;
@@ -1005,7 +975,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (value == null) {
unsetGatewayUsageReporting();
} else {
- setGatewayUsageReporting((Boolean)value);
+ setGatewayUsageReporting((java.lang.Boolean)value);
}
break;
@@ -1013,7 +983,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (value == null) {
unsetGatewayUsageModuleLoadCommand();
} else {
- setGatewayUsageModuleLoadCommand((String)value);
+ setGatewayUsageModuleLoadCommand((java.lang.String)value);
}
break;
@@ -1021,7 +991,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (value == null) {
unsetGatewayUsageExecutable();
} else {
- setGatewayUsageExecutable((String)value);
+ setGatewayUsageExecutable((java.lang.String)value);
}
break;
@@ -1029,7 +999,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (value == null) {
unsetCpusPerNode();
} else {
- setCpusPerNode((Integer)value);
+ setCpusPerNode((java.lang.Integer)value);
}
break;
@@ -1037,7 +1007,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (value == null) {
unsetDefaultNodeCount();
} else {
- setDefaultNodeCount((Integer)value);
+ setDefaultNodeCount((java.lang.Integer)value);
}
break;
@@ -1045,7 +1015,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (value == null) {
unsetDefaultCPUCount();
} else {
- setDefaultCPUCount((Integer)value);
+ setDefaultCPUCount((java.lang.Integer)value);
}
break;
@@ -1053,14 +1023,14 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (value == null) {
unsetDefaultWalltime();
} else {
- setDefaultWalltime((Integer)value);
+ setDefaultWalltime((java.lang.Integer)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case COMPUTE_RESOURCE_ID:
return getComputeResourceId();
@@ -1117,13 +1087,13 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return getDefaultWalltime();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -1164,11 +1134,11 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
case DEFAULT_WALLTIME:
return isSetDefaultWalltime();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ComputeResourceDescription)
@@ -1179,6 +1149,8 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
public boolean equals(ComputeResourceDescription that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_computeResourceId = true && this.isSetComputeResourceId();
boolean that_present_computeResourceId = true && that.isSetComputeResourceId();
@@ -1347,99 +1319,81 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_computeResourceId = true && (isSetComputeResourceId());
- list.add(present_computeResourceId);
- if (present_computeResourceId)
- list.add(computeResourceId);
-
- boolean present_hostName = true && (isSetHostName());
- list.add(present_hostName);
- if (present_hostName)
- list.add(hostName);
-
- boolean present_hostAliases = true && (isSetHostAliases());
- list.add(present_hostAliases);
- if (present_hostAliases)
- list.add(hostAliases);
-
- boolean present_ipAddresses = true && (isSetIpAddresses());
- list.add(present_ipAddresses);
- if (present_ipAddresses)
- list.add(ipAddresses);
-
- boolean present_resourceDescription = true && (isSetResourceDescription());
- list.add(present_resourceDescription);
- if (present_resourceDescription)
- list.add(resourceDescription);
-
- boolean present_enabled = true && (isSetEnabled());
- list.add(present_enabled);
- if (present_enabled)
- list.add(enabled);
-
- boolean present_batchQueues = true && (isSetBatchQueues());
- list.add(present_batchQueues);
- if (present_batchQueues)
- list.add(batchQueues);
-
- boolean present_fileSystems = true && (isSetFileSystems());
- list.add(present_fileSystems);
- if (present_fileSystems)
- list.add(fileSystems);
-
- boolean present_jobSubmissionInterfaces = true && (isSetJobSubmissionInterfaces());
- list.add(present_jobSubmissionInterfaces);
- if (present_jobSubmissionInterfaces)
- list.add(jobSubmissionInterfaces);
-
- boolean present_dataMovementInterfaces = true && (isSetDataMovementInterfaces());
- list.add(present_dataMovementInterfaces);
- if (present_dataMovementInterfaces)
- list.add(dataMovementInterfaces);
-
- boolean present_maxMemoryPerNode = true && (isSetMaxMemoryPerNode());
- list.add(present_maxMemoryPerNode);
- if (present_maxMemoryPerNode)
- list.add(maxMemoryPerNode);
-
- boolean present_gatewayUsageReporting = true && (isSetGatewayUsageReporting());
- list.add(present_gatewayUsageReporting);
- if (present_gatewayUsageReporting)
- list.add(gatewayUsageReporting);
-
- boolean present_gatewayUsageModuleLoadCommand = true && (isSetGatewayUsageModuleLoadCommand());
- list.add(present_gatewayUsageModuleLoadCommand);
- if (present_gatewayUsageModuleLoadCommand)
- list.add(gatewayUsageModuleLoadCommand);
-
- boolean present_gatewayUsageExecutable = true && (isSetGatewayUsageExecutable());
- list.add(present_gatewayUsageExecutable);
- if (present_gatewayUsageExecutable)
- list.add(gatewayUsageExecutable);
-
- boolean present_cpusPerNode = true && (isSetCpusPerNode());
- list.add(present_cpusPerNode);
- if (present_cpusPerNode)
- list.add(cpusPerNode);
-
- boolean present_defaultNodeCount = true && (isSetDefaultNodeCount());
- list.add(present_defaultNodeCount);
- if (present_defaultNodeCount)
- list.add(defaultNodeCount);
-
- boolean present_defaultCPUCount = true && (isSetDefaultCPUCount());
- list.add(present_defaultCPUCount);
- if (present_defaultCPUCount)
- list.add(defaultCPUCount);
-
- boolean present_defaultWalltime = true && (isSetDefaultWalltime());
- list.add(present_defaultWalltime);
- if (present_defaultWalltime)
- list.add(defaultWalltime);
-
- return list.hashCode();
+ int hashCode = 1;
+
+ hashCode = hashCode * 8191 + ((isSetComputeResourceId()) ? 131071 : 524287);
+ if (isSetComputeResourceId())
+ hashCode = hashCode * 8191 + computeResourceId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetHostName()) ? 131071 : 524287);
+ if (isSetHostName())
+ hashCode = hashCode * 8191 + hostName.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetHostAliases()) ? 131071 : 524287);
+ if (isSetHostAliases())
+ hashCode = hashCode * 8191 + hostAliases.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetIpAddresses()) ? 131071 : 524287);
+ if (isSetIpAddresses())
+ hashCode = hashCode * 8191 + ipAddresses.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetResourceDescription()) ? 131071 : 524287);
+ if (isSetResourceDescription())
+ hashCode = hashCode * 8191 + resourceDescription.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetEnabled()) ? 131071 : 524287);
+ if (isSetEnabled())
+ hashCode = hashCode * 8191 + ((enabled) ? 131071 : 524287);
+
+ hashCode = hashCode * 8191 + ((isSetBatchQueues()) ? 131071 : 524287);
+ if (isSetBatchQueues())
+ hashCode = hashCode * 8191 + batchQueues.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetFileSystems()) ? 131071 : 524287);
+ if (isSetFileSystems())
+ hashCode = hashCode * 8191 + fileSystems.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetJobSubmissionInterfaces()) ? 131071 : 524287);
+ if (isSetJobSubmissionInterfaces())
+ hashCode = hashCode * 8191 + jobSubmissionInterfaces.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetDataMovementInterfaces()) ? 131071 : 524287);
+ if (isSetDataMovementInterfaces())
+ hashCode = hashCode * 8191 + dataMovementInterfaces.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetMaxMemoryPerNode()) ? 131071 : 524287);
+ if (isSetMaxMemoryPerNode())
+ hashCode = hashCode * 8191 + maxMemoryPerNode;
+
+ hashCode = hashCode * 8191 + ((isSetGatewayUsageReporting()) ? 131071 : 524287);
+ if (isSetGatewayUsageReporting())
+ hashCode = hashCode * 8191 + ((gatewayUsageReporting) ? 131071 : 524287);
+
+ hashCode = hashCode * 8191 + ((isSetGatewayUsageModuleLoadCommand()) ? 131071 : 524287);
+ if (isSetGatewayUsageModuleLoadCommand())
+ hashCode = hashCode * 8191 + gatewayUsageModuleLoadCommand.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetGatewayUsageExecutable()) ? 131071 : 524287);
+ if (isSetGatewayUsageExecutable())
+ hashCode = hashCode * 8191 + gatewayUsageExecutable.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetCpusPerNode()) ? 131071 : 524287);
+ if (isSetCpusPerNode())
+ hashCode = hashCode * 8191 + cpusPerNode;
+
+ hashCode = hashCode * 8191 + ((isSetDefaultNodeCount()) ? 131071 : 524287);
+ if (isSetDefaultNodeCount())
+ hashCode = hashCode * 8191 + defaultNodeCount;
+
+ hashCode = hashCode * 8191 + ((isSetDefaultCPUCount()) ? 131071 : 524287);
+ if (isSetDefaultCPUCount())
+ hashCode = hashCode * 8191 + defaultCPUCount;
+
+ hashCode = hashCode * 8191 + ((isSetDefaultWalltime()) ? 131071 : 524287);
+ if (isSetDefaultWalltime())
+ hashCode = hashCode * 8191 + defaultWalltime;
+
+ return hashCode;
}
@Override
@@ -1450,7 +1404,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetComputeResourceId()).compareTo(other.isSetComputeResourceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetComputeResourceId()).compareTo(other.isSetComputeResourceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1460,7 +1414,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetHostName()).compareTo(other.isSetHostName());
+ lastComparison = java.lang.Boolean.valueOf(isSetHostName()).compareTo(other.isSetHostName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1470,7 +1424,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetHostAliases()).compareTo(other.isSetHostAliases());
+ lastComparison = java.lang.Boolean.valueOf(isSetHostAliases()).compareTo(other.isSetHostAliases());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1480,7 +1434,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetIpAddresses()).compareTo(other.isSetIpAddresses());
+ lastComparison = java.lang.Boolean.valueOf(isSetIpAddresses()).compareTo(other.isSetIpAddresses());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1490,7 +1444,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetResourceDescription()).compareTo(other.isSetResourceDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetResourceDescription()).compareTo(other.isSetResourceDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1500,7 +1454,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetEnabled()).compareTo(other.isSetEnabled());
+ lastComparison = java.lang.Boolean.valueOf(isSetEnabled()).compareTo(other.isSetEnabled());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1510,7 +1464,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetBatchQueues()).compareTo(other.isSetBatchQueues());
+ lastComparison = java.lang.Boolean.valueOf(isSetBatchQueues()).compareTo(other.isSetBatchQueues());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1520,7 +1474,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetFileSystems()).compareTo(other.isSetFileSystems());
+ lastComparison = java.lang.Boolean.valueOf(isSetFileSystems()).compareTo(other.isSetFileSystems());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1530,7 +1484,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetJobSubmissionInterfaces()).compareTo(other.isSetJobSubmissionInterfaces());
+ lastComparison = java.lang.Boolean.valueOf(isSetJobSubmissionInterfaces()).compareTo(other.isSetJobSubmissionInterfaces());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1540,7 +1494,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDataMovementInterfaces()).compareTo(other.isSetDataMovementInterfaces());
+ lastComparison = java.lang.Boolean.valueOf(isSetDataMovementInterfaces()).compareTo(other.isSetDataMovementInterfaces());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1550,7 +1504,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetMaxMemoryPerNode()).compareTo(other.isSetMaxMemoryPerNode());
+ lastComparison = java.lang.Boolean.valueOf(isSetMaxMemoryPerNode()).compareTo(other.isSetMaxMemoryPerNode());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1560,7 +1514,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetGatewayUsageReporting()).compareTo(other.isSetGatewayUsageReporting());
+ lastComparison = java.lang.Boolean.valueOf(isSetGatewayUsageReporting()).compareTo(other.isSetGatewayUsageReporting());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1570,7 +1524,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetGatewayUsageModuleLoadCommand()).compareTo(other.isSetGatewayUsageModuleLoadCommand());
+ lastComparison = java.lang.Boolean.valueOf(isSetGatewayUsageModuleLoadCommand()).compareTo(other.isSetGatewayUsageModuleLoadCommand());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1580,7 +1534,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetGatewayUsageExecutable()).compareTo(other.isSetGatewayUsageExecutable());
+ lastComparison = java.lang.Boolean.valueOf(isSetGatewayUsageExecutable()).compareTo(other.isSetGatewayUsageExecutable());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1590,7 +1544,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCpusPerNode()).compareTo(other.isSetCpusPerNode());
+ lastComparison = java.lang.Boolean.valueOf(isSetCpusPerNode()).compareTo(other.isSetCpusPerNode());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1600,7 +1554,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDefaultNodeCount()).compareTo(other.isSetDefaultNodeCount());
+ lastComparison = java.lang.Boolean.valueOf(isSetDefaultNodeCount()).compareTo(other.isSetDefaultNodeCount());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1610,7 +1564,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDefaultCPUCount()).compareTo(other.isSetDefaultCPUCount());
+ lastComparison = java.lang.Boolean.valueOf(isSetDefaultCPUCount()).compareTo(other.isSetDefaultCPUCount());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1620,7 +1574,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDefaultWalltime()).compareTo(other.isSetDefaultWalltime());
+ lastComparison = java.lang.Boolean.valueOf(isSetDefaultWalltime()).compareTo(other.isSetDefaultWalltime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1638,16 +1592,16 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ComputeResourceDescription(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ComputeResourceDescription(");
boolean first = true;
sb.append("computeResourceId:");
@@ -1822,7 +1776,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -1832,13 +1786,13 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
}
}
- private static class ComputeResourceDescriptionStandardSchemeFactory implements SchemeFactory {
+ private static class ComputeResourceDescriptionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ComputeResourceDescriptionStandardScheme getScheme() {
return new ComputeResourceDescriptionStandardScheme();
}
}
- private static class ComputeResourceDescriptionStandardScheme extends StandardScheme<ComputeResourceDescription> {
+ private static class ComputeResourceDescriptionStandardScheme extends org.apache.thrift.scheme.StandardScheme<ComputeResourceDescription> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ComputeResourceDescription struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1870,8 +1824,8 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list36 = iprot.readListBegin();
- struct.hostAliases = new ArrayList<String>(_list36.size);
- String _elem37;
+ struct.hostAliases = new java.util.ArrayList<java.lang.String>(_list36.size);
+ java.lang.String _elem37;
for (int _i38 = 0; _i38 < _list36.size; ++_i38)
{
_elem37 = iprot.readString();
@@ -1888,8 +1842,8 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list39 = iprot.readListBegin();
- struct.ipAddresses = new ArrayList<String>(_list39.size);
- String _elem40;
+ struct.ipAddresses = new java.util.ArrayList<java.lang.String>(_list39.size);
+ java.lang.String _elem40;
for (int _i41 = 0; _i41 < _list39.size; ++_i41)
{
_elem40 = iprot.readString();
@@ -1922,7 +1876,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list42 = iprot.readListBegin();
- struct.batchQueues = new ArrayList<BatchQueue>(_list42.size);
+ struct.batchQueues = new java.util.ArrayList<BatchQueue>(_list42.size);
BatchQueue _elem43;
for (int _i44 = 0; _i44 < _list42.size; ++_i44)
{
@@ -1941,9 +1895,9 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (schemeField.type == org.apache.thrift.protocol.TType.MAP) {
{
org.apache.thrift.protocol.TMap _map45 = iprot.readMapBegin();
- struct.fileSystems = new HashMap<FileSystems,String>(2*_map45.size);
+ struct.fileSystems = new java.util.HashMap<FileSystems,java.lang.String>(2*_map45.size);
FileSystems _key46;
- String _val47;
+ java.lang.String _val47;
for (int _i48 = 0; _i48 < _map45.size; ++_i48)
{
_key46 = org.apache.airavata.model.appcatalog.computeresource.FileSystems.findByValue(iprot.readI32());
@@ -1961,7 +1915,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list49 = iprot.readListBegin();
- struct.jobSubmissionInterfaces = new ArrayList<JobSubmissionInterface>(_list49.size);
+ struct.jobSubmissionInterfaces = new java.util.ArrayList<JobSubmissionInterface>(_list49.size);
JobSubmissionInterface _elem50;
for (int _i51 = 0; _i51 < _list49.size; ++_i51)
{
@@ -1980,7 +1934,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list52 = iprot.readListBegin();
- struct.dataMovementInterfaces = new ArrayList<org.apache.airavata.model.data.movement.DataMovementInterface>(_list52.size);
+ struct.dataMovementInterfaces = new java.util.ArrayList<org.apache.airavata.model.data.movement.DataMovementInterface>(_list52.size);
org.apache.airavata.model.data.movement.DataMovementInterface _elem53;
for (int _i54 = 0; _i54 < _list52.size; ++_i54)
{
@@ -2087,7 +2041,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
oprot.writeFieldBegin(HOST_ALIASES_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.hostAliases.size()));
- for (String _iter55 : struct.hostAliases)
+ for (java.lang.String _iter55 : struct.hostAliases)
{
oprot.writeString(_iter55);
}
@@ -2101,7 +2055,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
oprot.writeFieldBegin(IP_ADDRESSES_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.ipAddresses.size()));
- for (String _iter56 : struct.ipAddresses)
+ for (java.lang.String _iter56 : struct.ipAddresses)
{
oprot.writeString(_iter56);
}
@@ -2141,7 +2095,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
oprot.writeFieldBegin(FILE_SYSTEMS_FIELD_DESC);
{
oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.I32, org.apache.thrift.protocol.TType.STRING, struct.fileSystems.size()));
- for (Map.Entry<FileSystems, String> _iter58 : struct.fileSystems.entrySet())
+ for (java.util.Map.Entry<FileSystems, java.lang.String> _iter58 : struct.fileSystems.entrySet())
{
oprot.writeI32(_iter58.getKey().getValue());
oprot.writeString(_iter58.getValue());
@@ -2229,20 +2183,20 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
}
- private static class ComputeResourceDescriptionTupleSchemeFactory implements SchemeFactory {
+ private static class ComputeResourceDescriptionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ComputeResourceDescriptionTupleScheme getScheme() {
return new ComputeResourceDescriptionTupleScheme();
}
}
- private static class ComputeResourceDescriptionTupleScheme extends TupleScheme<ComputeResourceDescription> {
+ private static class ComputeResourceDescriptionTupleScheme extends org.apache.thrift.scheme.TupleScheme<ComputeResourceDescription> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ComputeResourceDescription struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.computeResourceId);
oprot.writeString(struct.hostName);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetHostAliases()) {
optionals.set(0);
}
@@ -2295,7 +2249,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (struct.isSetHostAliases()) {
{
oprot.writeI32(struct.hostAliases.size());
- for (String _iter61 : struct.hostAliases)
+ for (java.lang.String _iter61 : struct.hostAliases)
{
oprot.writeString(_iter61);
}
@@ -2304,7 +2258,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (struct.isSetIpAddresses()) {
{
oprot.writeI32(struct.ipAddresses.size());
- for (String _iter62 : struct.ipAddresses)
+ for (java.lang.String _iter62 : struct.ipAddresses)
{
oprot.writeString(_iter62);
}
@@ -2328,7 +2282,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (struct.isSetFileSystems()) {
{
oprot.writeI32(struct.fileSystems.size());
- for (Map.Entry<FileSystems, String> _iter64 : struct.fileSystems.entrySet())
+ for (java.util.Map.Entry<FileSystems, java.lang.String> _iter64 : struct.fileSystems.entrySet())
{
oprot.writeI32(_iter64.getKey().getValue());
oprot.writeString(_iter64.getValue());
@@ -2381,17 +2335,17 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ComputeResourceDescription struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.computeResourceId = iprot.readString();
struct.setComputeResourceIdIsSet(true);
struct.hostName = iprot.readString();
struct.setHostNameIsSet(true);
- BitSet incoming = iprot.readBitSet(16);
+ java.util.BitSet incoming = iprot.readBitSet(16);
if (incoming.get(0)) {
{
org.apache.thrift.protocol.TList _list67 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.hostAliases = new ArrayList<String>(_list67.size);
- String _elem68;
+ struct.hostAliases = new java.util.ArrayList<java.lang.String>(_list67.size);
+ java.lang.String _elem68;
for (int _i69 = 0; _i69 < _list67.size; ++_i69)
{
_elem68 = iprot.readString();
@@ -2403,8 +2357,8 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (incoming.get(1)) {
{
org.apache.thrift.protocol.TList _list70 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.ipAddresses = new ArrayList<String>(_list70.size);
- String _elem71;
+ struct.ipAddresses = new java.util.ArrayList<java.lang.String>(_list70.size);
+ java.lang.String _elem71;
for (int _i72 = 0; _i72 < _list70.size; ++_i72)
{
_elem71 = iprot.readString();
@@ -2424,7 +2378,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (incoming.get(4)) {
{
org.apache.thrift.protocol.TList _list73 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.batchQueues = new ArrayList<BatchQueue>(_list73.size);
+ struct.batchQueues = new java.util.ArrayList<BatchQueue>(_list73.size);
BatchQueue _elem74;
for (int _i75 = 0; _i75 < _list73.size; ++_i75)
{
@@ -2438,9 +2392,9 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (incoming.get(5)) {
{
org.apache.thrift.protocol.TMap _map76 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.I32, org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.fileSystems = new HashMap<FileSystems,String>(2*_map76.size);
+ struct.fileSystems = new java.util.HashMap<FileSystems,java.lang.String>(2*_map76.size);
FileSystems _key77;
- String _val78;
+ java.lang.String _val78;
for (int _i79 = 0; _i79 < _map76.size; ++_i79)
{
_key77 = org.apache.airavata.model.appcatalog.computeresource.FileSystems.findByValue(iprot.readI32());
@@ -2453,7 +2407,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (incoming.get(6)) {
{
org.apache.thrift.protocol.TList _list80 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.jobSubmissionInterfaces = new ArrayList<JobSubmissionInterface>(_list80.size);
+ struct.jobSubmissionInterfaces = new java.util.ArrayList<JobSubmissionInterface>(_list80.size);
JobSubmissionInterface _elem81;
for (int _i82 = 0; _i82 < _list80.size; ++_i82)
{
@@ -2467,7 +2421,7 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
if (incoming.get(7)) {
{
org.apache.thrift.protocol.TList _list83 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.dataMovementInterfaces = new ArrayList<org.apache.airavata.model.data.movement.DataMovementInterface>(_list83.size);
+ struct.dataMovementInterfaces = new java.util.ArrayList<org.apache.airavata.model.data.movement.DataMovementInterface>(_list83.size);
org.apache.airavata.model.data.movement.DataMovementInterface _elem84;
for (int _i85 = 0; _i85 < _list83.size; ++_i85)
{
@@ -2513,5 +2467,8 @@ public class ComputeResourceDescription implements org.apache.thrift.TBase<Compu
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/DMType.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/DMType.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/DMType.java
index a434764..6f35b01 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/DMType.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/DMType.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/FileSystems.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/FileSystems.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/FileSystems.java
index ad1d6e4..7be1718 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/FileSystems.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/FileSystems.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
[10/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/GridFTPDataMovement.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/GridFTPDataMovement.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/GridFTPDataMovement.java
index 9e586ce..0a536c6 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/GridFTPDataMovement.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/GridFTPDataMovement.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.data.movement;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Data Movement through GridFTP
*
@@ -60,7 +33,7 @@ import org.slf4j.LoggerFactory;
* sshPort:
* If a non-default port needs to used, specify it.
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataMovement, GridFTPDataMovement._Fields>, java.io.Serializable, Cloneable, Comparable<GridFTPDataMovement> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("GridFTPDataMovement");
@@ -68,15 +41,12 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
private static final org.apache.thrift.protocol.TField SECURITY_PROTOCOL_FIELD_DESC = new org.apache.thrift.protocol.TField("securityProtocol", org.apache.thrift.protocol.TType.I32, (short)2);
private static final org.apache.thrift.protocol.TField GRID_FTPEND_POINTS_FIELD_DESC = new org.apache.thrift.protocol.TField("gridFTPEndPoints", org.apache.thrift.protocol.TType.LIST, (short)3);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new GridFTPDataMovementStandardSchemeFactory());
- schemes.put(TupleScheme.class, new GridFTPDataMovementTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new GridFTPDataMovementStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new GridFTPDataMovementTupleSchemeFactory();
- private String dataMovementInterfaceId; // required
+ private java.lang.String dataMovementInterfaceId; // required
private SecurityProtocol securityProtocol; // required
- private List<String> gridFTPEndPoints; // required
+ private java.util.List<java.lang.String> gridFTPEndPoints; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -88,10 +58,10 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
SECURITY_PROTOCOL((short)2, "securityProtocol"),
GRID_FTPEND_POINTS((short)3, "gridFTPEndPoints");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -118,21 +88,21 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -141,15 +111,15 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.DATA_MOVEMENT_INTERFACE_ID, new org.apache.thrift.meta_data.FieldMetaData("dataMovementInterfaceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.SECURITY_PROTOCOL, new org.apache.thrift.meta_data.FieldMetaData("securityProtocol", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -157,7 +127,7 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
tmpMap.put(_Fields.GRID_FTPEND_POINTS, new org.apache.thrift.meta_data.FieldMetaData("gridFTPEndPoints", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(GridFTPDataMovement.class, metaDataMap);
}
@@ -167,9 +137,9 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
}
public GridFTPDataMovement(
- String dataMovementInterfaceId,
+ java.lang.String dataMovementInterfaceId,
SecurityProtocol securityProtocol,
- List<String> gridFTPEndPoints)
+ java.util.List<java.lang.String> gridFTPEndPoints)
{
this();
this.dataMovementInterfaceId = dataMovementInterfaceId;
@@ -188,7 +158,7 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
this.securityProtocol = other.securityProtocol;
}
if (other.isSetGridFTPEndPoints()) {
- List<String> __this__gridFTPEndPoints = new ArrayList<String>(other.gridFTPEndPoints);
+ java.util.List<java.lang.String> __this__gridFTPEndPoints = new java.util.ArrayList<java.lang.String>(other.gridFTPEndPoints);
this.gridFTPEndPoints = __this__gridFTPEndPoints;
}
}
@@ -205,11 +175,11 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
this.gridFTPEndPoints = null;
}
- public String getDataMovementInterfaceId() {
+ public java.lang.String getDataMovementInterfaceId() {
return this.dataMovementInterfaceId;
}
- public void setDataMovementInterfaceId(String dataMovementInterfaceId) {
+ public void setDataMovementInterfaceId(java.lang.String dataMovementInterfaceId) {
this.dataMovementInterfaceId = dataMovementInterfaceId;
}
@@ -263,22 +233,22 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
return (this.gridFTPEndPoints == null) ? 0 : this.gridFTPEndPoints.size();
}
- public java.util.Iterator<String> getGridFTPEndPointsIterator() {
+ public java.util.Iterator<java.lang.String> getGridFTPEndPointsIterator() {
return (this.gridFTPEndPoints == null) ? null : this.gridFTPEndPoints.iterator();
}
- public void addToGridFTPEndPoints(String elem) {
+ public void addToGridFTPEndPoints(java.lang.String elem) {
if (this.gridFTPEndPoints == null) {
- this.gridFTPEndPoints = new ArrayList<String>();
+ this.gridFTPEndPoints = new java.util.ArrayList<java.lang.String>();
}
this.gridFTPEndPoints.add(elem);
}
- public List<String> getGridFTPEndPoints() {
+ public java.util.List<java.lang.String> getGridFTPEndPoints() {
return this.gridFTPEndPoints;
}
- public void setGridFTPEndPoints(List<String> gridFTPEndPoints) {
+ public void setGridFTPEndPoints(java.util.List<java.lang.String> gridFTPEndPoints) {
this.gridFTPEndPoints = gridFTPEndPoints;
}
@@ -297,13 +267,13 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case DATA_MOVEMENT_INTERFACE_ID:
if (value == null) {
unsetDataMovementInterfaceId();
} else {
- setDataMovementInterfaceId((String)value);
+ setDataMovementInterfaceId((java.lang.String)value);
}
break;
@@ -319,14 +289,14 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
if (value == null) {
unsetGridFTPEndPoints();
} else {
- setGridFTPEndPoints((List<String>)value);
+ setGridFTPEndPoints((java.util.List<java.lang.String>)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case DATA_MOVEMENT_INTERFACE_ID:
return getDataMovementInterfaceId();
@@ -338,13 +308,13 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
return getGridFTPEndPoints();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -355,11 +325,11 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
case GRID_FTPEND_POINTS:
return isSetGridFTPEndPoints();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof GridFTPDataMovement)
@@ -370,6 +340,8 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
public boolean equals(GridFTPDataMovement that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_dataMovementInterfaceId = true && this.isSetDataMovementInterfaceId();
boolean that_present_dataMovementInterfaceId = true && that.isSetDataMovementInterfaceId();
@@ -403,24 +375,21 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_dataMovementInterfaceId = true && (isSetDataMovementInterfaceId());
- list.add(present_dataMovementInterfaceId);
- if (present_dataMovementInterfaceId)
- list.add(dataMovementInterfaceId);
+ hashCode = hashCode * 8191 + ((isSetDataMovementInterfaceId()) ? 131071 : 524287);
+ if (isSetDataMovementInterfaceId())
+ hashCode = hashCode * 8191 + dataMovementInterfaceId.hashCode();
- boolean present_securityProtocol = true && (isSetSecurityProtocol());
- list.add(present_securityProtocol);
- if (present_securityProtocol)
- list.add(securityProtocol.getValue());
+ hashCode = hashCode * 8191 + ((isSetSecurityProtocol()) ? 131071 : 524287);
+ if (isSetSecurityProtocol())
+ hashCode = hashCode * 8191 + securityProtocol.getValue();
- boolean present_gridFTPEndPoints = true && (isSetGridFTPEndPoints());
- list.add(present_gridFTPEndPoints);
- if (present_gridFTPEndPoints)
- list.add(gridFTPEndPoints);
+ hashCode = hashCode * 8191 + ((isSetGridFTPEndPoints()) ? 131071 : 524287);
+ if (isSetGridFTPEndPoints())
+ hashCode = hashCode * 8191 + gridFTPEndPoints.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -431,7 +400,7 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetDataMovementInterfaceId()).compareTo(other.isSetDataMovementInterfaceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetDataMovementInterfaceId()).compareTo(other.isSetDataMovementInterfaceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -441,7 +410,7 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetSecurityProtocol()).compareTo(other.isSetSecurityProtocol());
+ lastComparison = java.lang.Boolean.valueOf(isSetSecurityProtocol()).compareTo(other.isSetSecurityProtocol());
if (lastComparison != 0) {
return lastComparison;
}
@@ -451,7 +420,7 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetGridFTPEndPoints()).compareTo(other.isSetGridFTPEndPoints());
+ lastComparison = java.lang.Boolean.valueOf(isSetGridFTPEndPoints()).compareTo(other.isSetGridFTPEndPoints());
if (lastComparison != 0) {
return lastComparison;
}
@@ -469,16 +438,16 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("GridFTPDataMovement(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("GridFTPDataMovement(");
boolean first = true;
sb.append("dataMovementInterfaceId:");
@@ -533,7 +502,7 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -541,13 +510,13 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
}
}
- private static class GridFTPDataMovementStandardSchemeFactory implements SchemeFactory {
+ private static class GridFTPDataMovementStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public GridFTPDataMovementStandardScheme getScheme() {
return new GridFTPDataMovementStandardScheme();
}
}
- private static class GridFTPDataMovementStandardScheme extends StandardScheme<GridFTPDataMovement> {
+ private static class GridFTPDataMovementStandardScheme extends org.apache.thrift.scheme.StandardScheme<GridFTPDataMovement> {
public void read(org.apache.thrift.protocol.TProtocol iprot, GridFTPDataMovement struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -579,8 +548,8 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list0 = iprot.readListBegin();
- struct.gridFTPEndPoints = new ArrayList<String>(_list0.size);
- String _elem1;
+ struct.gridFTPEndPoints = new java.util.ArrayList<java.lang.String>(_list0.size);
+ java.lang.String _elem1;
for (int _i2 = 0; _i2 < _list0.size; ++_i2)
{
_elem1 = iprot.readString();
@@ -620,7 +589,7 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
oprot.writeFieldBegin(GRID_FTPEND_POINTS_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.gridFTPEndPoints.size()));
- for (String _iter3 : struct.gridFTPEndPoints)
+ for (java.lang.String _iter3 : struct.gridFTPEndPoints)
{
oprot.writeString(_iter3);
}
@@ -634,22 +603,22 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
}
- private static class GridFTPDataMovementTupleSchemeFactory implements SchemeFactory {
+ private static class GridFTPDataMovementTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public GridFTPDataMovementTupleScheme getScheme() {
return new GridFTPDataMovementTupleScheme();
}
}
- private static class GridFTPDataMovementTupleScheme extends TupleScheme<GridFTPDataMovement> {
+ private static class GridFTPDataMovementTupleScheme extends org.apache.thrift.scheme.TupleScheme<GridFTPDataMovement> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, GridFTPDataMovement struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.dataMovementInterfaceId);
oprot.writeI32(struct.securityProtocol.getValue());
{
oprot.writeI32(struct.gridFTPEndPoints.size());
- for (String _iter4 : struct.gridFTPEndPoints)
+ for (java.lang.String _iter4 : struct.gridFTPEndPoints)
{
oprot.writeString(_iter4);
}
@@ -658,15 +627,15 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, GridFTPDataMovement struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.dataMovementInterfaceId = iprot.readString();
struct.setDataMovementInterfaceIdIsSet(true);
struct.securityProtocol = org.apache.airavata.model.data.movement.SecurityProtocol.findByValue(iprot.readI32());
struct.setSecurityProtocolIsSet(true);
{
org.apache.thrift.protocol.TList _list5 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.gridFTPEndPoints = new ArrayList<String>(_list5.size);
- String _elem6;
+ struct.gridFTPEndPoints = new java.util.ArrayList<java.lang.String>(_list5.size);
+ java.lang.String _elem6;
for (int _i7 = 0; _i7 < _list5.size; ++_i7)
{
_elem6 = iprot.readString();
@@ -677,5 +646,8 @@ public class GridFTPDataMovement implements org.apache.thrift.TBase<GridFTPDataM
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/LOCALDataMovement.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/LOCALDataMovement.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/LOCALDataMovement.java
index 3db57a7..c3dcbbe 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/LOCALDataMovement.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/LOCALDataMovement.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.data.movement;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* LOCAL
*
@@ -60,28 +33,25 @@ import org.slf4j.LoggerFactory;
* sshPort:
* If a non-defualt port needs to used, specify it.
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class LOCALDataMovement implements org.apache.thrift.TBase<LOCALDataMovement, LOCALDataMovement._Fields>, java.io.Serializable, Cloneable, Comparable<LOCALDataMovement> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("LOCALDataMovement");
private static final org.apache.thrift.protocol.TField DATA_MOVEMENT_INTERFACE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("dataMovementInterfaceId", 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 LOCALDataMovementStandardSchemeFactory());
- schemes.put(TupleScheme.class, new LOCALDataMovementTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new LOCALDataMovementStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new LOCALDataMovementTupleSchemeFactory();
- private String dataMovementInterfaceId; // required
+ private java.lang.String dataMovementInterfaceId; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
DATA_MOVEMENT_INTERFACE_ID((short)1, "dataMovementInterfaceId");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -104,21 +74,21 @@ public class LOCALDataMovement implements org.apache.thrift.TBase<LOCALDataMovem
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -127,18 +97,18 @@ public class LOCALDataMovement implements org.apache.thrift.TBase<LOCALDataMovem
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.DATA_MOVEMENT_INTERFACE_ID, new org.apache.thrift.meta_data.FieldMetaData("dataMovementInterfaceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(LOCALDataMovement.class, metaDataMap);
}
@@ -148,7 +118,7 @@ public class LOCALDataMovement implements org.apache.thrift.TBase<LOCALDataMovem
}
public LOCALDataMovement(
- String dataMovementInterfaceId)
+ java.lang.String dataMovementInterfaceId)
{
this();
this.dataMovementInterfaceId = dataMovementInterfaceId;
@@ -173,11 +143,11 @@ public class LOCALDataMovement implements org.apache.thrift.TBase<LOCALDataMovem
}
- public String getDataMovementInterfaceId() {
+ public java.lang.String getDataMovementInterfaceId() {
return this.dataMovementInterfaceId;
}
- public void setDataMovementInterfaceId(String dataMovementInterfaceId) {
+ public void setDataMovementInterfaceId(java.lang.String dataMovementInterfaceId) {
this.dataMovementInterfaceId = dataMovementInterfaceId;
}
@@ -196,43 +166,43 @@ public class LOCALDataMovement implements org.apache.thrift.TBase<LOCALDataMovem
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case DATA_MOVEMENT_INTERFACE_ID:
if (value == null) {
unsetDataMovementInterfaceId();
} else {
- setDataMovementInterfaceId((String)value);
+ setDataMovementInterfaceId((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case DATA_MOVEMENT_INTERFACE_ID:
return getDataMovementInterfaceId();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
case DATA_MOVEMENT_INTERFACE_ID:
return isSetDataMovementInterfaceId();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof LOCALDataMovement)
@@ -243,6 +213,8 @@ public class LOCALDataMovement implements org.apache.thrift.TBase<LOCALDataMovem
public boolean equals(LOCALDataMovement that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_dataMovementInterfaceId = true && this.isSetDataMovementInterfaceId();
boolean that_present_dataMovementInterfaceId = true && that.isSetDataMovementInterfaceId();
@@ -258,14 +230,13 @@ public class LOCALDataMovement implements org.apache.thrift.TBase<LOCALDataMovem
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_dataMovementInterfaceId = true && (isSetDataMovementInterfaceId());
- list.add(present_dataMovementInterfaceId);
- if (present_dataMovementInterfaceId)
- list.add(dataMovementInterfaceId);
+ hashCode = hashCode * 8191 + ((isSetDataMovementInterfaceId()) ? 131071 : 524287);
+ if (isSetDataMovementInterfaceId())
+ hashCode = hashCode * 8191 + dataMovementInterfaceId.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -276,7 +247,7 @@ public class LOCALDataMovement implements org.apache.thrift.TBase<LOCALDataMovem
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetDataMovementInterfaceId()).compareTo(other.isSetDataMovementInterfaceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetDataMovementInterfaceId()).compareTo(other.isSetDataMovementInterfaceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -294,16 +265,16 @@ public class LOCALDataMovement implements org.apache.thrift.TBase<LOCALDataMovem
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("LOCALDataMovement(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("LOCALDataMovement(");
boolean first = true;
sb.append("dataMovementInterfaceId:");
@@ -334,7 +305,7 @@ public class LOCALDataMovement implements org.apache.thrift.TBase<LOCALDataMovem
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -342,13 +313,13 @@ public class LOCALDataMovement implements org.apache.thrift.TBase<LOCALDataMovem
}
}
- private static class LOCALDataMovementStandardSchemeFactory implements SchemeFactory {
+ private static class LOCALDataMovementStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public LOCALDataMovementStandardScheme getScheme() {
return new LOCALDataMovementStandardScheme();
}
}
- private static class LOCALDataMovementStandardScheme extends StandardScheme<LOCALDataMovement> {
+ private static class LOCALDataMovementStandardScheme extends org.apache.thrift.scheme.StandardScheme<LOCALDataMovement> {
public void read(org.apache.thrift.protocol.TProtocol iprot, LOCALDataMovement struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -392,27 +363,30 @@ public class LOCALDataMovement implements org.apache.thrift.TBase<LOCALDataMovem
}
- private static class LOCALDataMovementTupleSchemeFactory implements SchemeFactory {
+ private static class LOCALDataMovementTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public LOCALDataMovementTupleScheme getScheme() {
return new LOCALDataMovementTupleScheme();
}
}
- private static class LOCALDataMovementTupleScheme extends TupleScheme<LOCALDataMovement> {
+ private static class LOCALDataMovementTupleScheme extends org.apache.thrift.scheme.TupleScheme<LOCALDataMovement> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, LOCALDataMovement struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.dataMovementInterfaceId);
}
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, LOCALDataMovement struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.dataMovementInterfaceId = iprot.readString();
struct.setDataMovementInterfaceIdIsSet(true);
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/SCPDataMovement.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/SCPDataMovement.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/SCPDataMovement.java
index 31c4ddb..c1784c4 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/SCPDataMovement.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/SCPDataMovement.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.data.movement;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Data Movement through Secured Copy
*
@@ -60,7 +33,7 @@ import org.slf4j.LoggerFactory;
* sshPort:
* If a non-default port needs to used, specify it.
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement, SCPDataMovement._Fields>, java.io.Serializable, Cloneable, Comparable<SCPDataMovement> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("SCPDataMovement");
@@ -69,15 +42,12 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
private static final org.apache.thrift.protocol.TField ALTERNATIVE_SCPHOST_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("alternativeSCPHostName", org.apache.thrift.protocol.TType.STRING, (short)3);
private static final org.apache.thrift.protocol.TField SSH_PORT_FIELD_DESC = new org.apache.thrift.protocol.TField("sshPort", org.apache.thrift.protocol.TType.I32, (short)4);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new SCPDataMovementStandardSchemeFactory());
- schemes.put(TupleScheme.class, new SCPDataMovementTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new SCPDataMovementStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new SCPDataMovementTupleSchemeFactory();
- private String dataMovementInterfaceId; // required
+ private java.lang.String dataMovementInterfaceId; // required
private SecurityProtocol securityProtocol; // required
- private String alternativeSCPHostName; // optional
+ private java.lang.String alternativeSCPHostName; // optional
private int sshPort; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
@@ -91,10 +61,10 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
ALTERNATIVE_SCPHOST_NAME((short)3, "alternativeSCPHostName"),
SSH_PORT((short)4, "sshPort");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -123,21 +93,21 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -146,7 +116,7 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -155,9 +125,9 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
private static final int __SSHPORT_ISSET_ID = 0;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.ALTERNATIVE_SCPHOST_NAME,_Fields.SSH_PORT};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.DATA_MOVEMENT_INTERFACE_ID, new org.apache.thrift.meta_data.FieldMetaData("dataMovementInterfaceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.SECURITY_PROTOCOL, new org.apache.thrift.meta_data.FieldMetaData("securityProtocol", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -166,7 +136,7 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.SSH_PORT, new org.apache.thrift.meta_data.FieldMetaData("sshPort", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(SCPDataMovement.class, metaDataMap);
}
@@ -178,7 +148,7 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
}
public SCPDataMovement(
- String dataMovementInterfaceId,
+ java.lang.String dataMovementInterfaceId,
SecurityProtocol securityProtocol)
{
this();
@@ -217,11 +187,11 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
}
- public String getDataMovementInterfaceId() {
+ public java.lang.String getDataMovementInterfaceId() {
return this.dataMovementInterfaceId;
}
- public void setDataMovementInterfaceId(String dataMovementInterfaceId) {
+ public void setDataMovementInterfaceId(java.lang.String dataMovementInterfaceId) {
this.dataMovementInterfaceId = dataMovementInterfaceId;
}
@@ -271,11 +241,11 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
}
}
- public String getAlternativeSCPHostName() {
+ public java.lang.String getAlternativeSCPHostName() {
return this.alternativeSCPHostName;
}
- public void setAlternativeSCPHostName(String alternativeSCPHostName) {
+ public void setAlternativeSCPHostName(java.lang.String alternativeSCPHostName) {
this.alternativeSCPHostName = alternativeSCPHostName;
}
@@ -304,25 +274,25 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
}
public void unsetSshPort() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __SSHPORT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __SSHPORT_ISSET_ID);
}
/** Returns true if field sshPort is set (has been assigned a value) and false otherwise */
public boolean isSetSshPort() {
- return EncodingUtils.testBit(__isset_bitfield, __SSHPORT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __SSHPORT_ISSET_ID);
}
public void setSshPortIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SSHPORT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __SSHPORT_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case DATA_MOVEMENT_INTERFACE_ID:
if (value == null) {
unsetDataMovementInterfaceId();
} else {
- setDataMovementInterfaceId((String)value);
+ setDataMovementInterfaceId((java.lang.String)value);
}
break;
@@ -338,7 +308,7 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
if (value == null) {
unsetAlternativeSCPHostName();
} else {
- setAlternativeSCPHostName((String)value);
+ setAlternativeSCPHostName((java.lang.String)value);
}
break;
@@ -346,14 +316,14 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
if (value == null) {
unsetSshPort();
} else {
- setSshPort((Integer)value);
+ setSshPort((java.lang.Integer)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case DATA_MOVEMENT_INTERFACE_ID:
return getDataMovementInterfaceId();
@@ -368,13 +338,13 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
return getSshPort();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -387,11 +357,11 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
case SSH_PORT:
return isSetSshPort();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof SCPDataMovement)
@@ -402,6 +372,8 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
public boolean equals(SCPDataMovement that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_dataMovementInterfaceId = true && this.isSetDataMovementInterfaceId();
boolean that_present_dataMovementInterfaceId = true && that.isSetDataMovementInterfaceId();
@@ -444,29 +416,25 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_dataMovementInterfaceId = true && (isSetDataMovementInterfaceId());
- list.add(present_dataMovementInterfaceId);
- if (present_dataMovementInterfaceId)
- list.add(dataMovementInterfaceId);
+ hashCode = hashCode * 8191 + ((isSetDataMovementInterfaceId()) ? 131071 : 524287);
+ if (isSetDataMovementInterfaceId())
+ hashCode = hashCode * 8191 + dataMovementInterfaceId.hashCode();
- boolean present_securityProtocol = true && (isSetSecurityProtocol());
- list.add(present_securityProtocol);
- if (present_securityProtocol)
- list.add(securityProtocol.getValue());
+ hashCode = hashCode * 8191 + ((isSetSecurityProtocol()) ? 131071 : 524287);
+ if (isSetSecurityProtocol())
+ hashCode = hashCode * 8191 + securityProtocol.getValue();
- boolean present_alternativeSCPHostName = true && (isSetAlternativeSCPHostName());
- list.add(present_alternativeSCPHostName);
- if (present_alternativeSCPHostName)
- list.add(alternativeSCPHostName);
+ hashCode = hashCode * 8191 + ((isSetAlternativeSCPHostName()) ? 131071 : 524287);
+ if (isSetAlternativeSCPHostName())
+ hashCode = hashCode * 8191 + alternativeSCPHostName.hashCode();
- boolean present_sshPort = true && (isSetSshPort());
- list.add(present_sshPort);
- if (present_sshPort)
- list.add(sshPort);
+ hashCode = hashCode * 8191 + ((isSetSshPort()) ? 131071 : 524287);
+ if (isSetSshPort())
+ hashCode = hashCode * 8191 + sshPort;
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -477,7 +445,7 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetDataMovementInterfaceId()).compareTo(other.isSetDataMovementInterfaceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetDataMovementInterfaceId()).compareTo(other.isSetDataMovementInterfaceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -487,7 +455,7 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetSecurityProtocol()).compareTo(other.isSetSecurityProtocol());
+ lastComparison = java.lang.Boolean.valueOf(isSetSecurityProtocol()).compareTo(other.isSetSecurityProtocol());
if (lastComparison != 0) {
return lastComparison;
}
@@ -497,7 +465,7 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAlternativeSCPHostName()).compareTo(other.isSetAlternativeSCPHostName());
+ lastComparison = java.lang.Boolean.valueOf(isSetAlternativeSCPHostName()).compareTo(other.isSetAlternativeSCPHostName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -507,7 +475,7 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetSshPort()).compareTo(other.isSetSshPort());
+ lastComparison = java.lang.Boolean.valueOf(isSetSshPort()).compareTo(other.isSetSshPort());
if (lastComparison != 0) {
return lastComparison;
}
@@ -525,16 +493,16 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("SCPDataMovement(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("SCPDataMovement(");
boolean first = true;
sb.append("dataMovementInterfaceId:");
@@ -593,7 +561,7 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -603,13 +571,13 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
}
}
- private static class SCPDataMovementStandardSchemeFactory implements SchemeFactory {
+ private static class SCPDataMovementStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public SCPDataMovementStandardScheme getScheme() {
return new SCPDataMovementStandardScheme();
}
}
- private static class SCPDataMovementStandardScheme extends StandardScheme<SCPDataMovement> {
+ private static class SCPDataMovementStandardScheme extends org.apache.thrift.scheme.StandardScheme<SCPDataMovement> {
public void read(org.apache.thrift.protocol.TProtocol iprot, SCPDataMovement struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -694,20 +662,20 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
}
- private static class SCPDataMovementTupleSchemeFactory implements SchemeFactory {
+ private static class SCPDataMovementTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public SCPDataMovementTupleScheme getScheme() {
return new SCPDataMovementTupleScheme();
}
}
- private static class SCPDataMovementTupleScheme extends TupleScheme<SCPDataMovement> {
+ private static class SCPDataMovementTupleScheme extends org.apache.thrift.scheme.TupleScheme<SCPDataMovement> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, SCPDataMovement struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.dataMovementInterfaceId);
oprot.writeI32(struct.securityProtocol.getValue());
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetAlternativeSCPHostName()) {
optionals.set(0);
}
@@ -725,12 +693,12 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, SCPDataMovement struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.dataMovementInterfaceId = iprot.readString();
struct.setDataMovementInterfaceIdIsSet(true);
struct.securityProtocol = org.apache.airavata.model.data.movement.SecurityProtocol.findByValue(iprot.readI32());
struct.setSecurityProtocolIsSet(true);
- BitSet incoming = iprot.readBitSet(2);
+ java.util.BitSet incoming = iprot.readBitSet(2);
if (incoming.get(0)) {
struct.alternativeSCPHostName = iprot.readString();
struct.setAlternativeSCPHostNameIsSet(true);
@@ -742,5 +710,8 @@ public class SCPDataMovement implements org.apache.thrift.TBase<SCPDataMovement,
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/SecurityProtocol.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/SecurityProtocol.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/SecurityProtocol.java
index 359930a..49d8322 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/SecurityProtocol.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/SecurityProtocol.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/UnicoreDataMovement.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/UnicoreDataMovement.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/UnicoreDataMovement.java
index 8d54c40..feaeb9b 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/UnicoreDataMovement.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/UnicoreDataMovement.java
@@ -16,48 +16,21 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.data.movement;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Data Movement through UnicoreStorage
*
* unicoreEndPointURL:
* unicoreGateway End Point. The provider will query this service to fetch required service end points.
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataMovement, UnicoreDataMovement._Fields>, java.io.Serializable, Cloneable, Comparable<UnicoreDataMovement> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("UnicoreDataMovement");
@@ -65,15 +38,12 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
private static final org.apache.thrift.protocol.TField SECURITY_PROTOCOL_FIELD_DESC = new org.apache.thrift.protocol.TField("securityProtocol", org.apache.thrift.protocol.TType.I32, (short)2);
private static final org.apache.thrift.protocol.TField UNICORE_END_POINT_URL_FIELD_DESC = new org.apache.thrift.protocol.TField("unicoreEndPointURL", 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 UnicoreDataMovementStandardSchemeFactory());
- schemes.put(TupleScheme.class, new UnicoreDataMovementTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new UnicoreDataMovementStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new UnicoreDataMovementTupleSchemeFactory();
- private String dataMovementInterfaceId; // required
+ private java.lang.String dataMovementInterfaceId; // required
private SecurityProtocol securityProtocol; // required
- private String unicoreEndPointURL; // required
+ private java.lang.String unicoreEndPointURL; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -85,10 +55,10 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
SECURITY_PROTOCOL((short)2, "securityProtocol"),
UNICORE_END_POINT_URL((short)3, "unicoreEndPointURL");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -115,21 +85,21 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -138,22 +108,22 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.DATA_MOVEMENT_INTERFACE_ID, new org.apache.thrift.meta_data.FieldMetaData("dataMovementInterfaceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.SECURITY_PROTOCOL, new org.apache.thrift.meta_data.FieldMetaData("securityProtocol", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, SecurityProtocol.class)));
tmpMap.put(_Fields.UNICORE_END_POINT_URL, new org.apache.thrift.meta_data.FieldMetaData("unicoreEndPointURL", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(UnicoreDataMovement.class, metaDataMap);
}
@@ -163,9 +133,9 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
}
public UnicoreDataMovement(
- String dataMovementInterfaceId,
+ java.lang.String dataMovementInterfaceId,
SecurityProtocol securityProtocol,
- String unicoreEndPointURL)
+ java.lang.String unicoreEndPointURL)
{
this();
this.dataMovementInterfaceId = dataMovementInterfaceId;
@@ -200,11 +170,11 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
this.unicoreEndPointURL = null;
}
- public String getDataMovementInterfaceId() {
+ public java.lang.String getDataMovementInterfaceId() {
return this.dataMovementInterfaceId;
}
- public void setDataMovementInterfaceId(String dataMovementInterfaceId) {
+ public void setDataMovementInterfaceId(java.lang.String dataMovementInterfaceId) {
this.dataMovementInterfaceId = dataMovementInterfaceId;
}
@@ -254,11 +224,11 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
}
}
- public String getUnicoreEndPointURL() {
+ public java.lang.String getUnicoreEndPointURL() {
return this.unicoreEndPointURL;
}
- public void setUnicoreEndPointURL(String unicoreEndPointURL) {
+ public void setUnicoreEndPointURL(java.lang.String unicoreEndPointURL) {
this.unicoreEndPointURL = unicoreEndPointURL;
}
@@ -277,13 +247,13 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case DATA_MOVEMENT_INTERFACE_ID:
if (value == null) {
unsetDataMovementInterfaceId();
} else {
- setDataMovementInterfaceId((String)value);
+ setDataMovementInterfaceId((java.lang.String)value);
}
break;
@@ -299,14 +269,14 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
if (value == null) {
unsetUnicoreEndPointURL();
} else {
- setUnicoreEndPointURL((String)value);
+ setUnicoreEndPointURL((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case DATA_MOVEMENT_INTERFACE_ID:
return getDataMovementInterfaceId();
@@ -318,13 +288,13 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
return getUnicoreEndPointURL();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -335,11 +305,11 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
case UNICORE_END_POINT_URL:
return isSetUnicoreEndPointURL();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof UnicoreDataMovement)
@@ -350,6 +320,8 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
public boolean equals(UnicoreDataMovement that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_dataMovementInterfaceId = true && this.isSetDataMovementInterfaceId();
boolean that_present_dataMovementInterfaceId = true && that.isSetDataMovementInterfaceId();
@@ -383,24 +355,21 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_dataMovementInterfaceId = true && (isSetDataMovementInterfaceId());
- list.add(present_dataMovementInterfaceId);
- if (present_dataMovementInterfaceId)
- list.add(dataMovementInterfaceId);
+ hashCode = hashCode * 8191 + ((isSetDataMovementInterfaceId()) ? 131071 : 524287);
+ if (isSetDataMovementInterfaceId())
+ hashCode = hashCode * 8191 + dataMovementInterfaceId.hashCode();
- boolean present_securityProtocol = true && (isSetSecurityProtocol());
- list.add(present_securityProtocol);
- if (present_securityProtocol)
- list.add(securityProtocol.getValue());
+ hashCode = hashCode * 8191 + ((isSetSecurityProtocol()) ? 131071 : 524287);
+ if (isSetSecurityProtocol())
+ hashCode = hashCode * 8191 + securityProtocol.getValue();
- boolean present_unicoreEndPointURL = true && (isSetUnicoreEndPointURL());
- list.add(present_unicoreEndPointURL);
- if (present_unicoreEndPointURL)
- list.add(unicoreEndPointURL);
+ hashCode = hashCode * 8191 + ((isSetUnicoreEndPointURL()) ? 131071 : 524287);
+ if (isSetUnicoreEndPointURL())
+ hashCode = hashCode * 8191 + unicoreEndPointURL.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -411,7 +380,7 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetDataMovementInterfaceId()).compareTo(other.isSetDataMovementInterfaceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetDataMovementInterfaceId()).compareTo(other.isSetDataMovementInterfaceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -421,7 +390,7 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetSecurityProtocol()).compareTo(other.isSetSecurityProtocol());
+ lastComparison = java.lang.Boolean.valueOf(isSetSecurityProtocol()).compareTo(other.isSetSecurityProtocol());
if (lastComparison != 0) {
return lastComparison;
}
@@ -431,7 +400,7 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUnicoreEndPointURL()).compareTo(other.isSetUnicoreEndPointURL());
+ lastComparison = java.lang.Boolean.valueOf(isSetUnicoreEndPointURL()).compareTo(other.isSetUnicoreEndPointURL());
if (lastComparison != 0) {
return lastComparison;
}
@@ -449,16 +418,16 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("UnicoreDataMovement(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("UnicoreDataMovement(");
boolean first = true;
sb.append("dataMovementInterfaceId:");
@@ -513,7 +482,7 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -521,13 +490,13 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
}
}
- private static class UnicoreDataMovementStandardSchemeFactory implements SchemeFactory {
+ private static class UnicoreDataMovementStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public UnicoreDataMovementStandardScheme getScheme() {
return new UnicoreDataMovementStandardScheme();
}
}
- private static class UnicoreDataMovementStandardScheme extends StandardScheme<UnicoreDataMovement> {
+ private static class UnicoreDataMovementStandardScheme extends org.apache.thrift.scheme.StandardScheme<UnicoreDataMovement> {
public void read(org.apache.thrift.protocol.TProtocol iprot, UnicoreDataMovement struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -597,17 +566,17 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
}
- private static class UnicoreDataMovementTupleSchemeFactory implements SchemeFactory {
+ private static class UnicoreDataMovementTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public UnicoreDataMovementTupleScheme getScheme() {
return new UnicoreDataMovementTupleScheme();
}
}
- private static class UnicoreDataMovementTupleScheme extends TupleScheme<UnicoreDataMovement> {
+ private static class UnicoreDataMovementTupleScheme extends org.apache.thrift.scheme.TupleScheme<UnicoreDataMovement> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, UnicoreDataMovement struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.dataMovementInterfaceId);
oprot.writeI32(struct.securityProtocol.getValue());
oprot.writeString(struct.unicoreEndPointURL);
@@ -615,7 +584,7 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, UnicoreDataMovement struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.dataMovementInterfaceId = iprot.readString();
struct.setDataMovementInterfaceIdIsSet(true);
struct.securityProtocol = org.apache.airavata.model.data.movement.SecurityProtocol.findByValue(iprot.readI32());
@@ -625,5 +594,8 @@ public class UnicoreDataMovement implements org.apache.thrift.TBase<UnicoreDataM
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
[27/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workspace/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workspace/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workspace/ttypes.py
index 707c995..c37b7b7 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workspace/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workspace/ttypes.py
@@ -1,941 +1,873 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.commons.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class GatewayApprovalStatus:
- REQUESTED = 0
- APPROVED = 1
- ACTIVE = 2
- DEACTIVATED = 3
- CANCELLED = 4
- DENIED = 5
- CREATED = 6
- DEPLOYED = 7
-
- _VALUES_TO_NAMES = {
- 0: "REQUESTED",
- 1: "APPROVED",
- 2: "ACTIVE",
- 3: "DEACTIVATED",
- 4: "CANCELLED",
- 5: "DENIED",
- 6: "CREATED",
- 7: "DEPLOYED",
- }
-
- _NAMES_TO_VALUES = {
- "REQUESTED": 0,
- "APPROVED": 1,
- "ACTIVE": 2,
- "DEACTIVATED": 3,
- "CANCELLED": 4,
- "DENIED": 5,
- "CREATED": 6,
- "DEPLOYED": 7,
- }
-
-class NotificationPriority:
- LOW = 0
- NORMAL = 1
- HIGH = 2
-
- _VALUES_TO_NAMES = {
- 0: "LOW",
- 1: "NORMAL",
- 2: "HIGH",
- }
-
- _NAMES_TO_VALUES = {
- "LOW": 0,
- "NORMAL": 1,
- "HIGH": 2,
- }
-
-
-class Group:
- """
- Attributes:
- - groupName
- - description
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'groupName', None, None, ), # 1
- (2, TType.STRING, 'description', None, None, ), # 2
- )
-
- def __init__(self, groupName=None, description=None,):
- self.groupName = groupName
- self.description = description
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.groupName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.description = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('Group')
- if self.groupName is not None:
- oprot.writeFieldBegin('groupName', TType.STRING, 1)
- oprot.writeString(self.groupName)
- oprot.writeFieldEnd()
- if self.description is not None:
- oprot.writeFieldBegin('description', TType.STRING, 2)
- oprot.writeString(self.description)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.groupName is None:
- raise TProtocol.TProtocolException(message='Required field groupName is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.groupName)
- value = (value * 31) ^ hash(self.description)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class Project:
- """
- Attributes:
- - projectID
- - owner
- - gatewayId
- - name
- - description
- - creationTime
- - sharedUsers
- - sharedGroups
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'projectID', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.STRING, 'owner', None, None, ), # 2
- (3, TType.STRING, 'gatewayId', None, None, ), # 3
- (4, TType.STRING, 'name', None, None, ), # 4
- (5, TType.STRING, 'description', None, None, ), # 5
- (6, TType.I64, 'creationTime', None, None, ), # 6
- (7, TType.LIST, 'sharedUsers', (TType.STRING,None), None, ), # 7
- (8, TType.LIST, 'sharedGroups', (TType.STRING,None), None, ), # 8
- )
-
- def __init__(self, projectID=thrift_spec[1][4], owner=None, gatewayId=None, name=None, description=None, creationTime=None, sharedUsers=None, sharedGroups=None,):
- self.projectID = projectID
- self.owner = owner
- self.gatewayId = gatewayId
- self.name = name
- self.description = description
- self.creationTime = creationTime
- self.sharedUsers = sharedUsers
- self.sharedGroups = sharedGroups
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.projectID = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.owner = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.name = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.description = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.I64:
- self.creationTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.LIST:
- self.sharedUsers = []
- (_etype3, _size0) = iprot.readListBegin()
- for _i4 in xrange(_size0):
- _elem5 = iprot.readString()
- self.sharedUsers.append(_elem5)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.LIST:
- self.sharedGroups = []
- (_etype9, _size6) = iprot.readListBegin()
- for _i10 in xrange(_size6):
- _elem11 = iprot.readString()
- self.sharedGroups.append(_elem11)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('Project')
- if self.projectID is not None:
- oprot.writeFieldBegin('projectID', TType.STRING, 1)
- oprot.writeString(self.projectID)
- oprot.writeFieldEnd()
- if self.owner is not None:
- oprot.writeFieldBegin('owner', TType.STRING, 2)
- oprot.writeString(self.owner)
- oprot.writeFieldEnd()
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 3)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- if self.name is not None:
- oprot.writeFieldBegin('name', TType.STRING, 4)
- oprot.writeString(self.name)
- oprot.writeFieldEnd()
- if self.description is not None:
- oprot.writeFieldBegin('description', TType.STRING, 5)
- oprot.writeString(self.description)
- oprot.writeFieldEnd()
- if self.creationTime is not None:
- oprot.writeFieldBegin('creationTime', TType.I64, 6)
- oprot.writeI64(self.creationTime)
- oprot.writeFieldEnd()
- if self.sharedUsers is not None:
- oprot.writeFieldBegin('sharedUsers', TType.LIST, 7)
- oprot.writeListBegin(TType.STRING, len(self.sharedUsers))
- for iter12 in self.sharedUsers:
- oprot.writeString(iter12)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.sharedGroups is not None:
- oprot.writeFieldBegin('sharedGroups', TType.LIST, 8)
- oprot.writeListBegin(TType.STRING, len(self.sharedGroups))
- for iter13 in self.sharedGroups:
- oprot.writeString(iter13)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.projectID is None:
- raise TProtocol.TProtocolException(message='Required field projectID is unset!')
- if self.owner is None:
- raise TProtocol.TProtocolException(message='Required field owner is unset!')
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- if self.name is None:
- raise TProtocol.TProtocolException(message='Required field name is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.projectID)
- value = (value * 31) ^ hash(self.owner)
- value = (value * 31) ^ hash(self.gatewayId)
- value = (value * 31) ^ hash(self.name)
- value = (value * 31) ^ hash(self.description)
- value = (value * 31) ^ hash(self.creationTime)
- value = (value * 31) ^ hash(self.sharedUsers)
- value = (value * 31) ^ hash(self.sharedGroups)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class User:
- """
- Attributes:
- - airavataInternalUserId
- - userName
- - gatewayId
- - firstName
- - lastName
- - email
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'airavataInternalUserId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.STRING, 'userName', None, None, ), # 2
- (3, TType.STRING, 'gatewayId', None, None, ), # 3
- (4, TType.STRING, 'firstName', None, None, ), # 4
- (5, TType.STRING, 'lastName', None, None, ), # 5
- (6, TType.STRING, 'email', None, None, ), # 6
- )
-
- def __init__(self, airavataInternalUserId=thrift_spec[1][4], userName=None, gatewayId=None, firstName=None, lastName=None, email=None,):
- self.airavataInternalUserId = airavataInternalUserId
- self.userName = userName
- self.gatewayId = gatewayId
- self.firstName = firstName
- self.lastName = lastName
- self.email = email
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.airavataInternalUserId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.userName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.firstName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.lastName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.email = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('User')
- if self.airavataInternalUserId is not None:
- oprot.writeFieldBegin('airavataInternalUserId', TType.STRING, 1)
- oprot.writeString(self.airavataInternalUserId)
- oprot.writeFieldEnd()
- if self.userName is not None:
- oprot.writeFieldBegin('userName', TType.STRING, 2)
- oprot.writeString(self.userName)
- oprot.writeFieldEnd()
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 3)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- if self.firstName is not None:
- oprot.writeFieldBegin('firstName', TType.STRING, 4)
- oprot.writeString(self.firstName)
- oprot.writeFieldEnd()
- if self.lastName is not None:
- oprot.writeFieldBegin('lastName', TType.STRING, 5)
- oprot.writeString(self.lastName)
- oprot.writeFieldEnd()
- if self.email is not None:
- oprot.writeFieldBegin('email', TType.STRING, 6)
- oprot.writeString(self.email)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.airavataInternalUserId is None:
- raise TProtocol.TProtocolException(message='Required field airavataInternalUserId is unset!')
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.airavataInternalUserId)
- value = (value * 31) ^ hash(self.userName)
- value = (value * 31) ^ hash(self.gatewayId)
- value = (value * 31) ^ hash(self.firstName)
- value = (value * 31) ^ hash(self.lastName)
- value = (value * 31) ^ hash(self.email)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class Gateway:
- """
- Attributes:
- - airavataInternalGatewayId
- - gatewayId
- - gatewayApprovalStatus
- - gatewayName
- - domain
- - emailAddress
- - gatewayAcronym
- - gatewayURL
- - gatewayPublicAbstract
- - reviewProposalDescription
- - gatewayAdminFirstName
- - gatewayAdminLastName
- - gatewayAdminEmail
- - identityServerUserName
- - identityServerPasswordToken
- - declinedReason
- - oauthClientId
- - oauthClientSecret
- - requestCreationTime
- - requesterUsername
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'airavataInternalGatewayId', None, None, ), # 1
- (2, TType.STRING, 'gatewayId', None, None, ), # 2
- (3, TType.I32, 'gatewayApprovalStatus', None, None, ), # 3
- (4, TType.STRING, 'gatewayName', None, None, ), # 4
- (5, TType.STRING, 'domain', None, None, ), # 5
- (6, TType.STRING, 'emailAddress', None, None, ), # 6
- (7, TType.STRING, 'gatewayAcronym', None, None, ), # 7
- (8, TType.STRING, 'gatewayURL', None, None, ), # 8
- (9, TType.STRING, 'gatewayPublicAbstract', None, None, ), # 9
- (10, TType.STRING, 'reviewProposalDescription', None, None, ), # 10
- (11, TType.STRING, 'gatewayAdminFirstName', None, None, ), # 11
- (12, TType.STRING, 'gatewayAdminLastName', None, None, ), # 12
- (13, TType.STRING, 'gatewayAdminEmail', None, None, ), # 13
- (14, TType.STRING, 'identityServerUserName', None, None, ), # 14
- (15, TType.STRING, 'identityServerPasswordToken', None, None, ), # 15
- (16, TType.STRING, 'declinedReason', None, None, ), # 16
- (17, TType.STRING, 'oauthClientId', None, None, ), # 17
- (18, TType.STRING, 'oauthClientSecret', None, None, ), # 18
- (19, TType.I64, 'requestCreationTime', None, None, ), # 19
- (20, TType.STRING, 'requesterUsername', None, None, ), # 20
- )
-
- def __init__(self, airavataInternalGatewayId=None, gatewayId=None, gatewayApprovalStatus=None, gatewayName=None, domain=None, emailAddress=None, gatewayAcronym=None, gatewayURL=None, gatewayPublicAbstract=None, reviewProposalDescription=None, gatewayAdminFirstName=None, gatewayAdminLastName=None, gatewayAdminEmail=None, identityServerUserName=None, identityServerPasswordToken=None, declinedReason=None, oauthClientId=None, oauthClientSecret=None, requestCreationTime=None, requesterUsername=None,):
- self.airavataInternalGatewayId = airavataInternalGatewayId
- self.gatewayId = gatewayId
- self.gatewayApprovalStatus = gatewayApprovalStatus
- self.gatewayName = gatewayName
- self.domain = domain
- self.emailAddress = emailAddress
- self.gatewayAcronym = gatewayAcronym
- self.gatewayURL = gatewayURL
- self.gatewayPublicAbstract = gatewayPublicAbstract
- self.reviewProposalDescription = reviewProposalDescription
- self.gatewayAdminFirstName = gatewayAdminFirstName
- self.gatewayAdminLastName = gatewayAdminLastName
- self.gatewayAdminEmail = gatewayAdminEmail
- self.identityServerUserName = identityServerUserName
- self.identityServerPasswordToken = identityServerPasswordToken
- self.declinedReason = declinedReason
- self.oauthClientId = oauthClientId
- self.oauthClientSecret = oauthClientSecret
- self.requestCreationTime = requestCreationTime
- self.requesterUsername = requesterUsername
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.airavataInternalGatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.I32:
- self.gatewayApprovalStatus = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.gatewayName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.domain = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.emailAddress = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.STRING:
- self.gatewayAcronym = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.STRING:
- self.gatewayURL = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.STRING:
- self.gatewayPublicAbstract = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.STRING:
- self.reviewProposalDescription = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 11:
- if ftype == TType.STRING:
- self.gatewayAdminFirstName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 12:
- if ftype == TType.STRING:
- self.gatewayAdminLastName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 13:
- if ftype == TType.STRING:
- self.gatewayAdminEmail = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 14:
- if ftype == TType.STRING:
- self.identityServerUserName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 15:
- if ftype == TType.STRING:
- self.identityServerPasswordToken = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 16:
- if ftype == TType.STRING:
- self.declinedReason = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 17:
- if ftype == TType.STRING:
- self.oauthClientId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 18:
- if ftype == TType.STRING:
- self.oauthClientSecret = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 19:
- if ftype == TType.I64:
- self.requestCreationTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 20:
- if ftype == TType.STRING:
- self.requesterUsername = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('Gateway')
- if self.airavataInternalGatewayId is not None:
- oprot.writeFieldBegin('airavataInternalGatewayId', TType.STRING, 1)
- oprot.writeString(self.airavataInternalGatewayId)
- oprot.writeFieldEnd()
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 2)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- if self.gatewayApprovalStatus is not None:
- oprot.writeFieldBegin('gatewayApprovalStatus', TType.I32, 3)
- oprot.writeI32(self.gatewayApprovalStatus)
- oprot.writeFieldEnd()
- if self.gatewayName is not None:
- oprot.writeFieldBegin('gatewayName', TType.STRING, 4)
- oprot.writeString(self.gatewayName)
- oprot.writeFieldEnd()
- if self.domain is not None:
- oprot.writeFieldBegin('domain', TType.STRING, 5)
- oprot.writeString(self.domain)
- oprot.writeFieldEnd()
- if self.emailAddress is not None:
- oprot.writeFieldBegin('emailAddress', TType.STRING, 6)
- oprot.writeString(self.emailAddress)
- oprot.writeFieldEnd()
- if self.gatewayAcronym is not None:
- oprot.writeFieldBegin('gatewayAcronym', TType.STRING, 7)
- oprot.writeString(self.gatewayAcronym)
- oprot.writeFieldEnd()
- if self.gatewayURL is not None:
- oprot.writeFieldBegin('gatewayURL', TType.STRING, 8)
- oprot.writeString(self.gatewayURL)
- oprot.writeFieldEnd()
- if self.gatewayPublicAbstract is not None:
- oprot.writeFieldBegin('gatewayPublicAbstract', TType.STRING, 9)
- oprot.writeString(self.gatewayPublicAbstract)
- oprot.writeFieldEnd()
- if self.reviewProposalDescription is not None:
- oprot.writeFieldBegin('reviewProposalDescription', TType.STRING, 10)
- oprot.writeString(self.reviewProposalDescription)
- oprot.writeFieldEnd()
- if self.gatewayAdminFirstName is not None:
- oprot.writeFieldBegin('gatewayAdminFirstName', TType.STRING, 11)
- oprot.writeString(self.gatewayAdminFirstName)
- oprot.writeFieldEnd()
- if self.gatewayAdminLastName is not None:
- oprot.writeFieldBegin('gatewayAdminLastName', TType.STRING, 12)
- oprot.writeString(self.gatewayAdminLastName)
- oprot.writeFieldEnd()
- if self.gatewayAdminEmail is not None:
- oprot.writeFieldBegin('gatewayAdminEmail', TType.STRING, 13)
- oprot.writeString(self.gatewayAdminEmail)
- oprot.writeFieldEnd()
- if self.identityServerUserName is not None:
- oprot.writeFieldBegin('identityServerUserName', TType.STRING, 14)
- oprot.writeString(self.identityServerUserName)
- oprot.writeFieldEnd()
- if self.identityServerPasswordToken is not None:
- oprot.writeFieldBegin('identityServerPasswordToken', TType.STRING, 15)
- oprot.writeString(self.identityServerPasswordToken)
- oprot.writeFieldEnd()
- if self.declinedReason is not None:
- oprot.writeFieldBegin('declinedReason', TType.STRING, 16)
- oprot.writeString(self.declinedReason)
- oprot.writeFieldEnd()
- if self.oauthClientId is not None:
- oprot.writeFieldBegin('oauthClientId', TType.STRING, 17)
- oprot.writeString(self.oauthClientId)
- oprot.writeFieldEnd()
- if self.oauthClientSecret is not None:
- oprot.writeFieldBegin('oauthClientSecret', TType.STRING, 18)
- oprot.writeString(self.oauthClientSecret)
- oprot.writeFieldEnd()
- if self.requestCreationTime is not None:
- oprot.writeFieldBegin('requestCreationTime', TType.I64, 19)
- oprot.writeI64(self.requestCreationTime)
- oprot.writeFieldEnd()
- if self.requesterUsername is not None:
- oprot.writeFieldBegin('requesterUsername', TType.STRING, 20)
- oprot.writeString(self.requesterUsername)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- if self.gatewayApprovalStatus is None:
- raise TProtocol.TProtocolException(message='Required field gatewayApprovalStatus is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.airavataInternalGatewayId)
- value = (value * 31) ^ hash(self.gatewayId)
- value = (value * 31) ^ hash(self.gatewayApprovalStatus)
- value = (value * 31) ^ hash(self.gatewayName)
- value = (value * 31) ^ hash(self.domain)
- value = (value * 31) ^ hash(self.emailAddress)
- value = (value * 31) ^ hash(self.gatewayAcronym)
- value = (value * 31) ^ hash(self.gatewayURL)
- value = (value * 31) ^ hash(self.gatewayPublicAbstract)
- value = (value * 31) ^ hash(self.reviewProposalDescription)
- value = (value * 31) ^ hash(self.gatewayAdminFirstName)
- value = (value * 31) ^ hash(self.gatewayAdminLastName)
- value = (value * 31) ^ hash(self.gatewayAdminEmail)
- value = (value * 31) ^ hash(self.identityServerUserName)
- value = (value * 31) ^ hash(self.identityServerPasswordToken)
- value = (value * 31) ^ hash(self.declinedReason)
- value = (value * 31) ^ hash(self.oauthClientId)
- value = (value * 31) ^ hash(self.oauthClientSecret)
- value = (value * 31) ^ hash(self.requestCreationTime)
- value = (value * 31) ^ hash(self.requesterUsername)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class Notification:
- """
- Attributes:
- - notificationId
- - gatewayId
- - title
- - notificationMessage
- - creationTime
- - publishedTime
- - expirationTime
- - priority
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'notificationId', None, None, ), # 1
- (2, TType.STRING, 'gatewayId', None, None, ), # 2
- (3, TType.STRING, 'title', None, None, ), # 3
- (4, TType.STRING, 'notificationMessage', None, None, ), # 4
- (5, TType.I64, 'creationTime', None, None, ), # 5
- (6, TType.I64, 'publishedTime', None, None, ), # 6
- (7, TType.I64, 'expirationTime', None, None, ), # 7
- (8, TType.I32, 'priority', None, None, ), # 8
- )
-
- def __init__(self, notificationId=None, gatewayId=None, title=None, notificationMessage=None, creationTime=None, publishedTime=None, expirationTime=None, priority=None,):
- self.notificationId = notificationId
- self.gatewayId = gatewayId
- self.title = title
- self.notificationMessage = notificationMessage
- self.creationTime = creationTime
- self.publishedTime = publishedTime
- self.expirationTime = expirationTime
- self.priority = priority
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.notificationId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.title = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.notificationMessage = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I64:
- self.creationTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.I64:
- self.publishedTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.I64:
- self.expirationTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.I32:
- self.priority = iprot.readI32()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('Notification')
- if self.notificationId is not None:
- oprot.writeFieldBegin('notificationId', TType.STRING, 1)
- oprot.writeString(self.notificationId)
- oprot.writeFieldEnd()
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 2)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- if self.title is not None:
- oprot.writeFieldBegin('title', TType.STRING, 3)
- oprot.writeString(self.title)
- oprot.writeFieldEnd()
- if self.notificationMessage is not None:
- oprot.writeFieldBegin('notificationMessage', TType.STRING, 4)
- oprot.writeString(self.notificationMessage)
- oprot.writeFieldEnd()
- if self.creationTime is not None:
- oprot.writeFieldBegin('creationTime', TType.I64, 5)
- oprot.writeI64(self.creationTime)
- oprot.writeFieldEnd()
- if self.publishedTime is not None:
- oprot.writeFieldBegin('publishedTime', TType.I64, 6)
- oprot.writeI64(self.publishedTime)
- oprot.writeFieldEnd()
- if self.expirationTime is not None:
- oprot.writeFieldBegin('expirationTime', TType.I64, 7)
- oprot.writeI64(self.expirationTime)
- oprot.writeFieldEnd()
- if self.priority is not None:
- oprot.writeFieldBegin('priority', TType.I32, 8)
- oprot.writeI32(self.priority)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- if self.title is None:
- raise TProtocol.TProtocolException(message='Required field title is unset!')
- if self.notificationMessage is None:
- raise TProtocol.TProtocolException(message='Required field notificationMessage is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.notificationId)
- value = (value * 31) ^ hash(self.gatewayId)
- value = (value * 31) ^ hash(self.title)
- value = (value * 31) ^ hash(self.notificationMessage)
- value = (value * 31) ^ hash(self.creationTime)
- value = (value * 31) ^ hash(self.publishedTime)
- value = (value * 31) ^ hash(self.expirationTime)
- value = (value * 31) ^ hash(self.priority)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class GatewayApprovalStatus(object):
+ REQUESTED = 0
+ APPROVED = 1
+ ACTIVE = 2
+ DEACTIVATED = 3
+ CANCELLED = 4
+ DENIED = 5
+ CREATED = 6
+ DEPLOYED = 7
+
+ _VALUES_TO_NAMES = {
+ 0: "REQUESTED",
+ 1: "APPROVED",
+ 2: "ACTIVE",
+ 3: "DEACTIVATED",
+ 4: "CANCELLED",
+ 5: "DENIED",
+ 6: "CREATED",
+ 7: "DEPLOYED",
+ }
+
+ _NAMES_TO_VALUES = {
+ "REQUESTED": 0,
+ "APPROVED": 1,
+ "ACTIVE": 2,
+ "DEACTIVATED": 3,
+ "CANCELLED": 4,
+ "DENIED": 5,
+ "CREATED": 6,
+ "DEPLOYED": 7,
+ }
+
+
+class NotificationPriority(object):
+ LOW = 0
+ NORMAL = 1
+ HIGH = 2
+
+ _VALUES_TO_NAMES = {
+ 0: "LOW",
+ 1: "NORMAL",
+ 2: "HIGH",
+ }
+
+ _NAMES_TO_VALUES = {
+ "LOW": 0,
+ "NORMAL": 1,
+ "HIGH": 2,
+ }
+
+
+class Group(object):
+ """
+ Attributes:
+ - groupName
+ - description
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'groupName', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'description', 'UTF8', None, ), # 2
+ )
+
+ def __init__(self, groupName=None, description=None,):
+ self.groupName = groupName
+ self.description = description
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.groupName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.description = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('Group')
+ if self.groupName is not None:
+ oprot.writeFieldBegin('groupName', TType.STRING, 1)
+ oprot.writeString(self.groupName.encode('utf-8') if sys.version_info[0] == 2 else self.groupName)
+ oprot.writeFieldEnd()
+ if self.description is not None:
+ oprot.writeFieldBegin('description', TType.STRING, 2)
+ oprot.writeString(self.description.encode('utf-8') if sys.version_info[0] == 2 else self.description)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.groupName is None:
+ raise TProtocolException(message='Required field groupName is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class Project(object):
+ """
+ Attributes:
+ - projectID
+ - owner
+ - gatewayId
+ - name
+ - description
+ - creationTime
+ - sharedUsers
+ - sharedGroups
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'projectID', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.STRING, 'owner', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'gatewayId', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'name', 'UTF8', None, ), # 4
+ (5, TType.STRING, 'description', 'UTF8', None, ), # 5
+ (6, TType.I64, 'creationTime', None, None, ), # 6
+ (7, TType.LIST, 'sharedUsers', (TType.STRING, 'UTF8', False), None, ), # 7
+ (8, TType.LIST, 'sharedGroups', (TType.STRING, 'UTF8', False), None, ), # 8
+ )
+
+ def __init__(self, projectID=thrift_spec[1][4], owner=None, gatewayId=None, name=None, description=None, creationTime=None, sharedUsers=None, sharedGroups=None,):
+ self.projectID = projectID
+ self.owner = owner
+ self.gatewayId = gatewayId
+ self.name = name
+ self.description = description
+ self.creationTime = creationTime
+ self.sharedUsers = sharedUsers
+ self.sharedGroups = sharedGroups
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.projectID = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.owner = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.name = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRING:
+ self.description = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.I64:
+ self.creationTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.LIST:
+ self.sharedUsers = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in range(_size0):
+ _elem5 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ self.sharedUsers.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.LIST:
+ self.sharedGroups = []
+ (_etype9, _size6) = iprot.readListBegin()
+ for _i10 in range(_size6):
+ _elem11 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ self.sharedGroups.append(_elem11)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('Project')
+ if self.projectID is not None:
+ oprot.writeFieldBegin('projectID', TType.STRING, 1)
+ oprot.writeString(self.projectID.encode('utf-8') if sys.version_info[0] == 2 else self.projectID)
+ oprot.writeFieldEnd()
+ if self.owner is not None:
+ oprot.writeFieldBegin('owner', TType.STRING, 2)
+ oprot.writeString(self.owner.encode('utf-8') if sys.version_info[0] == 2 else self.owner)
+ oprot.writeFieldEnd()
+ if self.gatewayId is not None:
+ oprot.writeFieldBegin('gatewayId', TType.STRING, 3)
+ oprot.writeString(self.gatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayId)
+ oprot.writeFieldEnd()
+ if self.name is not None:
+ oprot.writeFieldBegin('name', TType.STRING, 4)
+ oprot.writeString(self.name.encode('utf-8') if sys.version_info[0] == 2 else self.name)
+ oprot.writeFieldEnd()
+ if self.description is not None:
+ oprot.writeFieldBegin('description', TType.STRING, 5)
+ oprot.writeString(self.description.encode('utf-8') if sys.version_info[0] == 2 else self.description)
+ oprot.writeFieldEnd()
+ if self.creationTime is not None:
+ oprot.writeFieldBegin('creationTime', TType.I64, 6)
+ oprot.writeI64(self.creationTime)
+ oprot.writeFieldEnd()
+ if self.sharedUsers is not None:
+ oprot.writeFieldBegin('sharedUsers', TType.LIST, 7)
+ oprot.writeListBegin(TType.STRING, len(self.sharedUsers))
+ for iter12 in self.sharedUsers:
+ oprot.writeString(iter12.encode('utf-8') if sys.version_info[0] == 2 else iter12)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.sharedGroups is not None:
+ oprot.writeFieldBegin('sharedGroups', TType.LIST, 8)
+ oprot.writeListBegin(TType.STRING, len(self.sharedGroups))
+ for iter13 in self.sharedGroups:
+ oprot.writeString(iter13.encode('utf-8') if sys.version_info[0] == 2 else iter13)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.projectID is None:
+ raise TProtocolException(message='Required field projectID is unset!')
+ if self.owner is None:
+ raise TProtocolException(message='Required field owner is unset!')
+ if self.gatewayId is None:
+ raise TProtocolException(message='Required field gatewayId is unset!')
+ if self.name is None:
+ raise TProtocolException(message='Required field name is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class User(object):
+ """
+ Attributes:
+ - airavataInternalUserId
+ - userName
+ - gatewayId
+ - firstName
+ - lastName
+ - email
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'airavataInternalUserId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.STRING, 'userName', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'gatewayId', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'firstName', 'UTF8', None, ), # 4
+ (5, TType.STRING, 'lastName', 'UTF8', None, ), # 5
+ (6, TType.STRING, 'email', 'UTF8', None, ), # 6
+ )
+
+ def __init__(self, airavataInternalUserId=thrift_spec[1][4], userName=None, gatewayId=None, firstName=None, lastName=None, email=None,):
+ self.airavataInternalUserId = airavataInternalUserId
+ self.userName = userName
+ self.gatewayId = gatewayId
+ self.firstName = firstName
+ self.lastName = lastName
+ self.email = email
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.airavataInternalUserId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.userName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.firstName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRING:
+ self.lastName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.email = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('User')
+ if self.airavataInternalUserId is not None:
+ oprot.writeFieldBegin('airavataInternalUserId', TType.STRING, 1)
+ oprot.writeString(self.airavataInternalUserId.encode('utf-8') if sys.version_info[0] == 2 else self.airavataInternalUserId)
+ oprot.writeFieldEnd()
+ if self.userName is not None:
+ oprot.writeFieldBegin('userName', TType.STRING, 2)
+ oprot.writeString(self.userName.encode('utf-8') if sys.version_info[0] == 2 else self.userName)
+ oprot.writeFieldEnd()
+ if self.gatewayId is not None:
+ oprot.writeFieldBegin('gatewayId', TType.STRING, 3)
+ oprot.writeString(self.gatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayId)
+ oprot.writeFieldEnd()
+ if self.firstName is not None:
+ oprot.writeFieldBegin('firstName', TType.STRING, 4)
+ oprot.writeString(self.firstName.encode('utf-8') if sys.version_info[0] == 2 else self.firstName)
+ oprot.writeFieldEnd()
+ if self.lastName is not None:
+ oprot.writeFieldBegin('lastName', TType.STRING, 5)
+ oprot.writeString(self.lastName.encode('utf-8') if sys.version_info[0] == 2 else self.lastName)
+ oprot.writeFieldEnd()
+ if self.email is not None:
+ oprot.writeFieldBegin('email', TType.STRING, 6)
+ oprot.writeString(self.email.encode('utf-8') if sys.version_info[0] == 2 else self.email)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.airavataInternalUserId is None:
+ raise TProtocolException(message='Required field airavataInternalUserId is unset!')
+ if self.gatewayId is None:
+ raise TProtocolException(message='Required field gatewayId is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class Gateway(object):
+ """
+ Attributes:
+ - airavataInternalGatewayId
+ - gatewayId
+ - gatewayApprovalStatus
+ - gatewayName
+ - domain
+ - emailAddress
+ - gatewayAcronym
+ - gatewayURL
+ - gatewayPublicAbstract
+ - reviewProposalDescription
+ - gatewayAdminFirstName
+ - gatewayAdminLastName
+ - gatewayAdminEmail
+ - identityServerUserName
+ - identityServerPasswordToken
+ - declinedReason
+ - oauthClientId
+ - oauthClientSecret
+ - requestCreationTime
+ - requesterUsername
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'airavataInternalGatewayId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'gatewayId', 'UTF8', None, ), # 2
+ (3, TType.I32, 'gatewayApprovalStatus', None, None, ), # 3
+ (4, TType.STRING, 'gatewayName', 'UTF8', None, ), # 4
+ (5, TType.STRING, 'domain', 'UTF8', None, ), # 5
+ (6, TType.STRING, 'emailAddress', 'UTF8', None, ), # 6
+ (7, TType.STRING, 'gatewayAcronym', 'UTF8', None, ), # 7
+ (8, TType.STRING, 'gatewayURL', 'UTF8', None, ), # 8
+ (9, TType.STRING, 'gatewayPublicAbstract', 'UTF8', None, ), # 9
+ (10, TType.STRING, 'reviewProposalDescription', 'UTF8', None, ), # 10
+ (11, TType.STRING, 'gatewayAdminFirstName', 'UTF8', None, ), # 11
+ (12, TType.STRING, 'gatewayAdminLastName', 'UTF8', None, ), # 12
+ (13, TType.STRING, 'gatewayAdminEmail', 'UTF8', None, ), # 13
+ (14, TType.STRING, 'identityServerUserName', 'UTF8', None, ), # 14
+ (15, TType.STRING, 'identityServerPasswordToken', 'UTF8', None, ), # 15
+ (16, TType.STRING, 'declinedReason', 'UTF8', None, ), # 16
+ (17, TType.STRING, 'oauthClientId', 'UTF8', None, ), # 17
+ (18, TType.STRING, 'oauthClientSecret', 'UTF8', None, ), # 18
+ (19, TType.I64, 'requestCreationTime', None, None, ), # 19
+ (20, TType.STRING, 'requesterUsername', 'UTF8', None, ), # 20
+ )
+
+ def __init__(self, airavataInternalGatewayId=None, gatewayId=None, gatewayApprovalStatus=None, gatewayName=None, domain=None, emailAddress=None, gatewayAcronym=None, gatewayURL=None, gatewayPublicAbstract=None, reviewProposalDescription=None, gatewayAdminFirstName=None, gatewayAdminLastName=None, gatewayAdminEmail=None, identityServerUserName=None, identityServerPasswordToken=None, declinedReason=None, oauthClientId=None, oauthClientSecret=None, requestCreationTime=None, requesterUsername=None,):
+ self.airavataInternalGatewayId = airavataInternalGatewayId
+ self.gatewayId = gatewayId
+ self.gatewayApprovalStatus = gatewayApprovalStatus
+ self.gatewayName = gatewayName
+ self.domain = domain
+ self.emailAddress = emailAddress
+ self.gatewayAcronym = gatewayAcronym
+ self.gatewayURL = gatewayURL
+ self.gatewayPublicAbstract = gatewayPublicAbstract
+ self.reviewProposalDescription = reviewProposalDescription
+ self.gatewayAdminFirstName = gatewayAdminFirstName
+ self.gatewayAdminLastName = gatewayAdminLastName
+ self.gatewayAdminEmail = gatewayAdminEmail
+ self.identityServerUserName = identityServerUserName
+ self.identityServerPasswordToken = identityServerPasswordToken
+ self.declinedReason = declinedReason
+ self.oauthClientId = oauthClientId
+ self.oauthClientSecret = oauthClientSecret
+ self.requestCreationTime = requestCreationTime
+ self.requesterUsername = requesterUsername
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.airavataInternalGatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I32:
+ self.gatewayApprovalStatus = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.gatewayName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRING:
+ self.domain = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.emailAddress = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.STRING:
+ self.gatewayAcronym = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.STRING:
+ self.gatewayURL = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.STRING:
+ self.gatewayPublicAbstract = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.STRING:
+ self.reviewProposalDescription = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 11:
+ if ftype == TType.STRING:
+ self.gatewayAdminFirstName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 12:
+ if ftype == TType.STRING:
+ self.gatewayAdminLastName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 13:
+ if ftype == TType.STRING:
+ self.gatewayAdminEmail = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 14:
+ if ftype == TType.STRING:
+ self.identityServerUserName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 15:
+ if ftype == TType.STRING:
+ self.identityServerPasswordToken = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 16:
+ if ftype == TType.STRING:
+ self.declinedReason = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 17:
+ if ftype == TType.STRING:
+ self.oauthClientId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 18:
+ if ftype == TType.STRING:
+ self.oauthClientSecret = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 19:
+ if ftype == TType.I64:
+ self.requestCreationTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 20:
+ if ftype == TType.STRING:
+ self.requesterUsername = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('Gateway')
+ if self.airavataInternalGatewayId is not None:
+ oprot.writeFieldBegin('airavataInternalGatewayId', TType.STRING, 1)
+ oprot.writeString(self.airavataInternalGatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.airavataInternalGatewayId)
+ oprot.writeFieldEnd()
+ if self.gatewayId is not None:
+ oprot.writeFieldBegin('gatewayId', TType.STRING, 2)
+ oprot.writeString(self.gatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayId)
+ oprot.writeFieldEnd()
+ if self.gatewayApprovalStatus is not None:
+ oprot.writeFieldBegin('gatewayApprovalStatus', TType.I32, 3)
+ oprot.writeI32(self.gatewayApprovalStatus)
+ oprot.writeFieldEnd()
+ if self.gatewayName is not None:
+ oprot.writeFieldBegin('gatewayName', TType.STRING, 4)
+ oprot.writeString(self.gatewayName.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayName)
+ oprot.writeFieldEnd()
+ if self.domain is not None:
+ oprot.writeFieldBegin('domain', TType.STRING, 5)
+ oprot.writeString(self.domain.encode('utf-8') if sys.version_info[0] == 2 else self.domain)
+ oprot.writeFieldEnd()
+ if self.emailAddress is not None:
+ oprot.writeFieldBegin('emailAddress', TType.STRING, 6)
+ oprot.writeString(self.emailAddress.encode('utf-8') if sys.version_info[0] == 2 else self.emailAddress)
+ oprot.writeFieldEnd()
+ if self.gatewayAcronym is not None:
+ oprot.writeFieldBegin('gatewayAcronym', TType.STRING, 7)
+ oprot.writeString(self.gatewayAcronym.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayAcronym)
+ oprot.writeFieldEnd()
+ if self.gatewayURL is not None:
+ oprot.writeFieldBegin('gatewayURL', TType.STRING, 8)
+ oprot.writeString(self.gatewayURL.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayURL)
+ oprot.writeFieldEnd()
+ if self.gatewayPublicAbstract is not None:
+ oprot.writeFieldBegin('gatewayPublicAbstract', TType.STRING, 9)
+ oprot.writeString(self.gatewayPublicAbstract.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayPublicAbstract)
+ oprot.writeFieldEnd()
+ if self.reviewProposalDescription is not None:
+ oprot.writeFieldBegin('reviewProposalDescription', TType.STRING, 10)
+ oprot.writeString(self.reviewProposalDescription.encode('utf-8') if sys.version_info[0] == 2 else self.reviewProposalDescription)
+ oprot.writeFieldEnd()
+ if self.gatewayAdminFirstName is not None:
+ oprot.writeFieldBegin('gatewayAdminFirstName', TType.STRING, 11)
+ oprot.writeString(self.gatewayAdminFirstName.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayAdminFirstName)
+ oprot.writeFieldEnd()
+ if self.gatewayAdminLastName is not None:
+ oprot.writeFieldBegin('gatewayAdminLastName', TType.STRING, 12)
+ oprot.writeString(self.gatewayAdminLastName.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayAdminLastName)
+ oprot.writeFieldEnd()
+ if self.gatewayAdminEmail is not None:
+ oprot.writeFieldBegin('gatewayAdminEmail', TType.STRING, 13)
+ oprot.writeString(self.gatewayAdminEmail.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayAdminEmail)
+ oprot.writeFieldEnd()
+ if self.identityServerUserName is not None:
+ oprot.writeFieldBegin('identityServerUserName', TType.STRING, 14)
+ oprot.writeString(self.identityServerUserName.encode('utf-8') if sys.version_info[0] == 2 else self.identityServerUserName)
+ oprot.writeFieldEnd()
+ if self.identityServerPasswordToken is not None:
+ oprot.writeFieldBegin('identityServerPasswordToken', TType.STRING, 15)
+ oprot.writeString(self.identityServerPasswordToken.encode('utf-8') if sys.version_info[0] == 2 else self.identityServerPasswordToken)
+ oprot.writeFieldEnd()
+ if self.declinedReason is not None:
+ oprot.writeFieldBegin('declinedReason', TType.STRING, 16)
+ oprot.writeString(self.declinedReason.encode('utf-8') if sys.version_info[0] == 2 else self.declinedReason)
+ oprot.writeFieldEnd()
+ if self.oauthClientId is not None:
+ oprot.writeFieldBegin('oauthClientId', TType.STRING, 17)
+ oprot.writeString(self.oauthClientId.encode('utf-8') if sys.version_info[0] == 2 else self.oauthClientId)
+ oprot.writeFieldEnd()
+ if self.oauthClientSecret is not None:
+ oprot.writeFieldBegin('oauthClientSecret', TType.STRING, 18)
+ oprot.writeString(self.oauthClientSecret.encode('utf-8') if sys.version_info[0] == 2 else self.oauthClientSecret)
+ oprot.writeFieldEnd()
+ if self.requestCreationTime is not None:
+ oprot.writeFieldBegin('requestCreationTime', TType.I64, 19)
+ oprot.writeI64(self.requestCreationTime)
+ oprot.writeFieldEnd()
+ if self.requesterUsername is not None:
+ oprot.writeFieldBegin('requesterUsername', TType.STRING, 20)
+ oprot.writeString(self.requesterUsername.encode('utf-8') if sys.version_info[0] == 2 else self.requesterUsername)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.gatewayId is None:
+ raise TProtocolException(message='Required field gatewayId is unset!')
+ if self.gatewayApprovalStatus is None:
+ raise TProtocolException(message='Required field gatewayApprovalStatus is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class Notification(object):
+ """
+ Attributes:
+ - notificationId
+ - gatewayId
+ - title
+ - notificationMessage
+ - creationTime
+ - publishedTime
+ - expirationTime
+ - priority
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'notificationId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'gatewayId', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'title', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'notificationMessage', 'UTF8', None, ), # 4
+ (5, TType.I64, 'creationTime', None, None, ), # 5
+ (6, TType.I64, 'publishedTime', None, None, ), # 6
+ (7, TType.I64, 'expirationTime', None, None, ), # 7
+ (8, TType.I32, 'priority', None, None, ), # 8
+ )
+
+ def __init__(self, notificationId=None, gatewayId=None, title=None, notificationMessage=None, creationTime=None, publishedTime=None, expirationTime=None, priority=None,):
+ self.notificationId = notificationId
+ self.gatewayId = gatewayId
+ self.title = title
+ self.notificationMessage = notificationMessage
+ self.creationTime = creationTime
+ self.publishedTime = publishedTime
+ self.expirationTime = expirationTime
+ self.priority = priority
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.notificationId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.title = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.notificationMessage = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.I64:
+ self.creationTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.I64:
+ self.publishedTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.I64:
+ self.expirationTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.I32:
+ self.priority = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('Notification')
+ if self.notificationId is not None:
+ oprot.writeFieldBegin('notificationId', TType.STRING, 1)
+ oprot.writeString(self.notificationId.encode('utf-8') if sys.version_info[0] == 2 else self.notificationId)
+ oprot.writeFieldEnd()
+ if self.gatewayId is not None:
+ oprot.writeFieldBegin('gatewayId', TType.STRING, 2)
+ oprot.writeString(self.gatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayId)
+ oprot.writeFieldEnd()
+ if self.title is not None:
+ oprot.writeFieldBegin('title', TType.STRING, 3)
+ oprot.writeString(self.title.encode('utf-8') if sys.version_info[0] == 2 else self.title)
+ oprot.writeFieldEnd()
+ if self.notificationMessage is not None:
+ oprot.writeFieldBegin('notificationMessage', TType.STRING, 4)
+ oprot.writeString(self.notificationMessage.encode('utf-8') if sys.version_info[0] == 2 else self.notificationMessage)
+ oprot.writeFieldEnd()
+ if self.creationTime is not None:
+ oprot.writeFieldBegin('creationTime', TType.I64, 5)
+ oprot.writeI64(self.creationTime)
+ oprot.writeFieldEnd()
+ if self.publishedTime is not None:
+ oprot.writeFieldBegin('publishedTime', TType.I64, 6)
+ oprot.writeI64(self.publishedTime)
+ oprot.writeFieldEnd()
+ if self.expirationTime is not None:
+ oprot.writeFieldBegin('expirationTime', TType.I64, 7)
+ oprot.writeI64(self.expirationTime)
+ oprot.writeFieldEnd()
+ if self.priority is not None:
+ oprot.writeFieldBegin('priority', TType.I32, 8)
+ oprot.writeI32(self.priority)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.gatewayId is None:
+ raise TProtocolException(message='Required field gatewayId is unset!')
+ if self.title is None:
+ raise TProtocolException(message='Required field title is unset!')
+ if self.notificationMessage is None:
+ raise TProtocolException(message='Required field notificationMessage is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/credential_store_data_models/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/credential_store_data_models/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/credential_store_data_models/constants.py
index abf8bc6..2b09fa9 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/credential_store_data_models/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/credential_store_data_models/constants.py
@@ -1,12 +1,13 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
DEFAULT_ID = "DO_NOT_SET_AT_CLIENTS"
[12/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CertificateCredential.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CertificateCredential.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CertificateCredential.java
index c1d959c..bd08eed 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CertificateCredential.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CertificateCredential.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.credential.store;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
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");
@@ -64,20 +37,17 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
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());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new CertificateCredentialStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new CertificateCredentialTupleSchemeFactory();
private CommunityUser communityUser; // required
- private String x509Cert; // required
- private String notAfter; // optional
- private String privateKey; // optional
+ private java.lang.String x509Cert; // required
+ private java.lang.String notAfter; // optional
+ private java.lang.String privateKey; // optional
private long lifeTime; // optional
- private String notBefore; // optional
+ private java.lang.String notBefore; // optional
private long persistedTime; // optional
- private String token; // optional
+ private java.lang.String token; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -90,10 +60,10 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
PERSISTED_TIME((short)7, "persistedTime"),
TOKEN((short)8, "token");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -130,21 +100,21 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -153,7 +123,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -163,9 +133,9 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
private static final int __PERSISTEDTIME_ISSET_ID = 1;
private byte __isset_bitfield = 0;
private static final _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;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.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,
@@ -182,7 +152,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
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);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(CertificateCredential.class, metaDataMap);
}
@@ -191,7 +161,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
public CertificateCredential(
CommunityUser communityUser,
- String x509Cert)
+ java.lang.String x509Cert)
{
this();
this.communityUser = communityUser;
@@ -266,11 +236,11 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
}
}
- public String getX509Cert() {
+ public java.lang.String getX509Cert() {
return this.x509Cert;
}
- public void setX509Cert(String x509Cert) {
+ public void setX509Cert(java.lang.String x509Cert) {
this.x509Cert = x509Cert;
}
@@ -289,11 +259,11 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
}
}
- public String getNotAfter() {
+ public java.lang.String getNotAfter() {
return this.notAfter;
}
- public void setNotAfter(String notAfter) {
+ public void setNotAfter(java.lang.String notAfter) {
this.notAfter = notAfter;
}
@@ -312,11 +282,11 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
}
}
- public String getPrivateKey() {
+ public java.lang.String getPrivateKey() {
return this.privateKey;
}
- public void setPrivateKey(String privateKey) {
+ public void setPrivateKey(java.lang.String privateKey) {
this.privateKey = privateKey;
}
@@ -345,23 +315,23 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
}
public void unsetLifeTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __LIFETIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.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);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __LIFETIME_ISSET_ID);
}
public void setLifeTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __LIFETIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __LIFETIME_ISSET_ID, value);
}
- public String getNotBefore() {
+ public java.lang.String getNotBefore() {
return this.notBefore;
}
- public void setNotBefore(String notBefore) {
+ public void setNotBefore(java.lang.String notBefore) {
this.notBefore = notBefore;
}
@@ -390,23 +360,23 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
}
public void unsetPersistedTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.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);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID);
}
public void setPersistedTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID, value);
}
- public String getToken() {
+ public java.lang.String getToken() {
return this.token;
}
- public void setToken(String token) {
+ public void setToken(java.lang.String token) {
this.token = token;
}
@@ -425,7 +395,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case COMMUNITY_USER:
if (value == null) {
@@ -439,7 +409,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
if (value == null) {
unsetX509Cert();
} else {
- setX509Cert((String)value);
+ setX509Cert((java.lang.String)value);
}
break;
@@ -447,7 +417,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
if (value == null) {
unsetNotAfter();
} else {
- setNotAfter((String)value);
+ setNotAfter((java.lang.String)value);
}
break;
@@ -455,7 +425,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
if (value == null) {
unsetPrivateKey();
} else {
- setPrivateKey((String)value);
+ setPrivateKey((java.lang.String)value);
}
break;
@@ -463,7 +433,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
if (value == null) {
unsetLifeTime();
} else {
- setLifeTime((Long)value);
+ setLifeTime((java.lang.Long)value);
}
break;
@@ -471,7 +441,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
if (value == null) {
unsetNotBefore();
} else {
- setNotBefore((String)value);
+ setNotBefore((java.lang.String)value);
}
break;
@@ -479,7 +449,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
if (value == null) {
unsetPersistedTime();
} else {
- setPersistedTime((Long)value);
+ setPersistedTime((java.lang.Long)value);
}
break;
@@ -487,14 +457,14 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
if (value == null) {
unsetToken();
} else {
- setToken((String)value);
+ setToken((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case COMMUNITY_USER:
return getCommunityUser();
@@ -521,13 +491,13 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
return getToken();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -548,11 +518,11 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
case TOKEN:
return isSetToken();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof CertificateCredential)
@@ -563,6 +533,8 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
public boolean equals(CertificateCredential that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_communityUser = true && this.isSetCommunityUser();
boolean that_present_communityUser = true && that.isSetCommunityUser();
@@ -641,49 +613,41 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_communityUser = true && (isSetCommunityUser());
- list.add(present_communityUser);
- if (present_communityUser)
- list.add(communityUser);
+ hashCode = hashCode * 8191 + ((isSetCommunityUser()) ? 131071 : 524287);
+ if (isSetCommunityUser())
+ hashCode = hashCode * 8191 + communityUser.hashCode();
- boolean present_x509Cert = true && (isSetX509Cert());
- list.add(present_x509Cert);
- if (present_x509Cert)
- list.add(x509Cert);
+ hashCode = hashCode * 8191 + ((isSetX509Cert()) ? 131071 : 524287);
+ if (isSetX509Cert())
+ hashCode = hashCode * 8191 + x509Cert.hashCode();
- boolean present_notAfter = true && (isSetNotAfter());
- list.add(present_notAfter);
- if (present_notAfter)
- list.add(notAfter);
+ hashCode = hashCode * 8191 + ((isSetNotAfter()) ? 131071 : 524287);
+ if (isSetNotAfter())
+ hashCode = hashCode * 8191 + notAfter.hashCode();
- boolean present_privateKey = true && (isSetPrivateKey());
- list.add(present_privateKey);
- if (present_privateKey)
- list.add(privateKey);
+ hashCode = hashCode * 8191 + ((isSetPrivateKey()) ? 131071 : 524287);
+ if (isSetPrivateKey())
+ hashCode = hashCode * 8191 + privateKey.hashCode();
- boolean present_lifeTime = true && (isSetLifeTime());
- list.add(present_lifeTime);
- if (present_lifeTime)
- list.add(lifeTime);
+ hashCode = hashCode * 8191 + ((isSetLifeTime()) ? 131071 : 524287);
+ if (isSetLifeTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(lifeTime);
- boolean present_notBefore = true && (isSetNotBefore());
- list.add(present_notBefore);
- if (present_notBefore)
- list.add(notBefore);
+ hashCode = hashCode * 8191 + ((isSetNotBefore()) ? 131071 : 524287);
+ if (isSetNotBefore())
+ hashCode = hashCode * 8191 + notBefore.hashCode();
- boolean present_persistedTime = true && (isSetPersistedTime());
- list.add(present_persistedTime);
- if (present_persistedTime)
- list.add(persistedTime);
+ hashCode = hashCode * 8191 + ((isSetPersistedTime()) ? 131071 : 524287);
+ if (isSetPersistedTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(persistedTime);
- boolean present_token = true && (isSetToken());
- list.add(present_token);
- if (present_token)
- list.add(token);
+ hashCode = hashCode * 8191 + ((isSetToken()) ? 131071 : 524287);
+ if (isSetToken())
+ hashCode = hashCode * 8191 + token.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -694,7 +658,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetCommunityUser()).compareTo(other.isSetCommunityUser());
+ lastComparison = java.lang.Boolean.valueOf(isSetCommunityUser()).compareTo(other.isSetCommunityUser());
if (lastComparison != 0) {
return lastComparison;
}
@@ -704,7 +668,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetX509Cert()).compareTo(other.isSetX509Cert());
+ lastComparison = java.lang.Boolean.valueOf(isSetX509Cert()).compareTo(other.isSetX509Cert());
if (lastComparison != 0) {
return lastComparison;
}
@@ -714,7 +678,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetNotAfter()).compareTo(other.isSetNotAfter());
+ lastComparison = java.lang.Boolean.valueOf(isSetNotAfter()).compareTo(other.isSetNotAfter());
if (lastComparison != 0) {
return lastComparison;
}
@@ -724,7 +688,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPrivateKey()).compareTo(other.isSetPrivateKey());
+ lastComparison = java.lang.Boolean.valueOf(isSetPrivateKey()).compareTo(other.isSetPrivateKey());
if (lastComparison != 0) {
return lastComparison;
}
@@ -734,7 +698,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetLifeTime()).compareTo(other.isSetLifeTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetLifeTime()).compareTo(other.isSetLifeTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -744,7 +708,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetNotBefore()).compareTo(other.isSetNotBefore());
+ lastComparison = java.lang.Boolean.valueOf(isSetNotBefore()).compareTo(other.isSetNotBefore());
if (lastComparison != 0) {
return lastComparison;
}
@@ -754,7 +718,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPersistedTime()).compareTo(other.isSetPersistedTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetPersistedTime()).compareTo(other.isSetPersistedTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -764,7 +728,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetToken()).compareTo(other.isSetToken());
+ lastComparison = java.lang.Boolean.valueOf(isSetToken()).compareTo(other.isSetToken());
if (lastComparison != 0) {
return lastComparison;
}
@@ -782,16 +746,16 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("CertificateCredential(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("CertificateCredential(");
boolean first = true;
sb.append("communityUser:");
@@ -889,7 +853,7 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -899,13 +863,13 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
}
}
- private static class CertificateCredentialStandardSchemeFactory implements SchemeFactory {
+ private static class CertificateCredentialStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public CertificateCredentialStandardScheme getScheme() {
return new CertificateCredentialStandardScheme();
}
}
- private static class CertificateCredentialStandardScheme extends StandardScheme<CertificateCredential> {
+ private static class CertificateCredentialStandardScheme extends org.apache.thrift.scheme.StandardScheme<CertificateCredential> {
public void read(org.apache.thrift.protocol.TProtocol iprot, CertificateCredential struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1049,20 +1013,20 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
}
- private static class CertificateCredentialTupleSchemeFactory implements SchemeFactory {
+ private static class CertificateCredentialTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public CertificateCredentialTupleScheme getScheme() {
return new CertificateCredentialTupleScheme();
}
}
- private static class CertificateCredentialTupleScheme extends TupleScheme<CertificateCredential> {
+ private static class CertificateCredentialTupleScheme extends org.apache.thrift.scheme.TupleScheme<CertificateCredential> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, CertificateCredential struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.communityUser.write(oprot);
oprot.writeString(struct.x509Cert);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetNotAfter()) {
optionals.set(0);
}
@@ -1104,13 +1068,13 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, CertificateCredential struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.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);
+ java.util.BitSet incoming = iprot.readBitSet(6);
if (incoming.get(0)) {
struct.notAfter = iprot.readString();
struct.setNotAfterIsSet(true);
@@ -1138,5 +1102,8 @@ public class CertificateCredential implements org.apache.thrift.TBase<Certificat
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CommunityUser.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CommunityUser.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CommunityUser.java
index 199fee6..333cd11 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CommunityUser.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CommunityUser.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.credential.store;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
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");
@@ -59,15 +32,12 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
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());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new CommunityUserStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new CommunityUserTupleSchemeFactory();
- private String gatewayName; // required
- private String username; // required
- private String userEmail; // required
+ private java.lang.String gatewayName; // required
+ private java.lang.String username; // required
+ private java.lang.String userEmail; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -75,10 +45,10 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
USERNAME((short)2, "username"),
USER_EMAIL((short)3, "userEmail");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -105,21 +75,21 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -128,22 +98,22 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.GATEWAY_NAME, new org.apache.thrift.meta_data.FieldMetaData("gatewayName", 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);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(CommunityUser.class, metaDataMap);
}
@@ -151,9 +121,9 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
}
public CommunityUser(
- String gatewayName,
- String username,
- String userEmail)
+ java.lang.String gatewayName,
+ java.lang.String username,
+ java.lang.String userEmail)
{
this();
this.gatewayName = gatewayName;
@@ -187,11 +157,11 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
this.userEmail = null;
}
- public String getGatewayName() {
+ public java.lang.String getGatewayName() {
return this.gatewayName;
}
- public void setGatewayName(String gatewayName) {
+ public void setGatewayName(java.lang.String gatewayName) {
this.gatewayName = gatewayName;
}
@@ -210,11 +180,11 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
}
}
- public String getUsername() {
+ public java.lang.String getUsername() {
return this.username;
}
- public void setUsername(String username) {
+ public void setUsername(java.lang.String username) {
this.username = username;
}
@@ -233,11 +203,11 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
}
}
- public String getUserEmail() {
+ public java.lang.String getUserEmail() {
return this.userEmail;
}
- public void setUserEmail(String userEmail) {
+ public void setUserEmail(java.lang.String userEmail) {
this.userEmail = userEmail;
}
@@ -256,13 +226,13 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case GATEWAY_NAME:
if (value == null) {
unsetGatewayName();
} else {
- setGatewayName((String)value);
+ setGatewayName((java.lang.String)value);
}
break;
@@ -270,7 +240,7 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
if (value == null) {
unsetUsername();
} else {
- setUsername((String)value);
+ setUsername((java.lang.String)value);
}
break;
@@ -278,14 +248,14 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
if (value == null) {
unsetUserEmail();
} else {
- setUserEmail((String)value);
+ setUserEmail((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case GATEWAY_NAME:
return getGatewayName();
@@ -297,13 +267,13 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
return getUserEmail();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -314,11 +284,11 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
case USER_EMAIL:
return isSetUserEmail();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof CommunityUser)
@@ -329,6 +299,8 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
public boolean equals(CommunityUser that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_gatewayName = true && this.isSetGatewayName();
boolean that_present_gatewayName = true && that.isSetGatewayName();
@@ -362,24 +334,21 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_gatewayName = true && (isSetGatewayName());
- list.add(present_gatewayName);
- if (present_gatewayName)
- list.add(gatewayName);
+ hashCode = hashCode * 8191 + ((isSetGatewayName()) ? 131071 : 524287);
+ if (isSetGatewayName())
+ hashCode = hashCode * 8191 + gatewayName.hashCode();
- boolean present_username = true && (isSetUsername());
- list.add(present_username);
- if (present_username)
- list.add(username);
+ hashCode = hashCode * 8191 + ((isSetUsername()) ? 131071 : 524287);
+ if (isSetUsername())
+ hashCode = hashCode * 8191 + username.hashCode();
- boolean present_userEmail = true && (isSetUserEmail());
- list.add(present_userEmail);
- if (present_userEmail)
- list.add(userEmail);
+ hashCode = hashCode * 8191 + ((isSetUserEmail()) ? 131071 : 524287);
+ if (isSetUserEmail())
+ hashCode = hashCode * 8191 + userEmail.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -390,7 +359,7 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetGatewayName()).compareTo(other.isSetGatewayName());
+ lastComparison = java.lang.Boolean.valueOf(isSetGatewayName()).compareTo(other.isSetGatewayName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -400,7 +369,7 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUsername()).compareTo(other.isSetUsername());
+ lastComparison = java.lang.Boolean.valueOf(isSetUsername()).compareTo(other.isSetUsername());
if (lastComparison != 0) {
return lastComparison;
}
@@ -410,7 +379,7 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUserEmail()).compareTo(other.isSetUserEmail());
+ lastComparison = java.lang.Boolean.valueOf(isSetUserEmail()).compareTo(other.isSetUserEmail());
if (lastComparison != 0) {
return lastComparison;
}
@@ -428,16 +397,16 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("CommunityUser(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("CommunityUser(");
boolean first = true;
sb.append("gatewayName:");
@@ -492,7 +461,7 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -500,13 +469,13 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
}
}
- private static class CommunityUserStandardSchemeFactory implements SchemeFactory {
+ private static class CommunityUserStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public CommunityUserStandardScheme getScheme() {
return new CommunityUserStandardScheme();
}
}
- private static class CommunityUserStandardScheme extends StandardScheme<CommunityUser> {
+ private static class CommunityUserStandardScheme extends org.apache.thrift.scheme.StandardScheme<CommunityUser> {
public void read(org.apache.thrift.protocol.TProtocol iprot, CommunityUser struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -576,17 +545,17 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
}
- private static class CommunityUserTupleSchemeFactory implements SchemeFactory {
+ private static class CommunityUserTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public CommunityUserTupleScheme getScheme() {
return new CommunityUserTupleScheme();
}
}
- private static class CommunityUserTupleScheme extends TupleScheme<CommunityUser> {
+ private static class CommunityUserTupleScheme extends org.apache.thrift.scheme.TupleScheme<CommunityUser> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, CommunityUser struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.gatewayName);
oprot.writeString(struct.username);
oprot.writeString(struct.userEmail);
@@ -594,7 +563,7 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, CommunityUser struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.gatewayName = iprot.readString();
struct.setGatewayNameIsSet(true);
struct.username = iprot.readString();
@@ -604,5 +573,8 @@ public class CommunityUser implements org.apache.thrift.TBase<CommunityUser, Com
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CredentialOwnerType.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CredentialOwnerType.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CredentialOwnerType.java
index 01b3c90..70f846e 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CredentialOwnerType.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CredentialOwnerType.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CredentialSummary.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CredentialSummary.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CredentialSummary.java
index c31a1b1..9c65c15 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CredentialSummary.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/CredentialSummary.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.credential.store;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class CredentialSummary implements org.apache.thrift.TBase<CredentialSummary, CredentialSummary._Fields>, java.io.Serializable, Cloneable, Comparable<CredentialSummary> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("CredentialSummary");
@@ -63,19 +36,16 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
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)6);
private static final org.apache.thrift.protocol.TField DESCRIPTION_FIELD_DESC = new org.apache.thrift.protocol.TField("description", 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 CredentialSummaryStandardSchemeFactory());
- schemes.put(TupleScheme.class, new CredentialSummaryTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new CredentialSummaryStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new CredentialSummaryTupleSchemeFactory();
private SummaryType type; // required
- private String gatewayId; // required
- private String username; // required
- private String publicKey; // optional
+ private java.lang.String gatewayId; // required
+ private java.lang.String username; // required
+ private java.lang.String publicKey; // optional
private long persistedTime; // optional
- private String token; // required
- private String description; // optional
+ private java.lang.String token; // required
+ private java.lang.String description; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -91,10 +61,10 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
TOKEN((short)6, "token"),
DESCRIPTION((short)7, "description");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -129,21 +99,21 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -152,7 +122,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -161,9 +131,9 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
private static final int __PERSISTEDTIME_ISSET_ID = 0;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.PUBLIC_KEY,_Fields.PERSISTED_TIME,_Fields.DESCRIPTION};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.TYPE, new org.apache.thrift.meta_data.FieldMetaData("type", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, SummaryType.class)));
tmpMap.put(_Fields.GATEWAY_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayId", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -178,7 +148,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.DESCRIPTION, new org.apache.thrift.meta_data.FieldMetaData("description", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(CredentialSummary.class, metaDataMap);
}
@@ -187,9 +157,9 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
public CredentialSummary(
SummaryType type,
- String gatewayId,
- String username,
- String token)
+ java.lang.String gatewayId,
+ java.lang.String username,
+ java.lang.String token)
{
this();
this.type = type;
@@ -271,11 +241,11 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
}
}
- public String getGatewayId() {
+ public java.lang.String getGatewayId() {
return this.gatewayId;
}
- public void setGatewayId(String gatewayId) {
+ public void setGatewayId(java.lang.String gatewayId) {
this.gatewayId = gatewayId;
}
@@ -294,11 +264,11 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
}
}
- public String getUsername() {
+ public java.lang.String getUsername() {
return this.username;
}
- public void setUsername(String username) {
+ public void setUsername(java.lang.String username) {
this.username = username;
}
@@ -317,11 +287,11 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
}
}
- public String getPublicKey() {
+ public java.lang.String getPublicKey() {
return this.publicKey;
}
- public void setPublicKey(String publicKey) {
+ public void setPublicKey(java.lang.String publicKey) {
this.publicKey = publicKey;
}
@@ -350,23 +320,23 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
}
public void unsetPersistedTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.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);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID);
}
public void setPersistedTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID, value);
}
- public String getToken() {
+ public java.lang.String getToken() {
return this.token;
}
- public void setToken(String token) {
+ public void setToken(java.lang.String token) {
this.token = token;
}
@@ -385,11 +355,11 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
}
}
- public String getDescription() {
+ public java.lang.String getDescription() {
return this.description;
}
- public void setDescription(String description) {
+ public void setDescription(java.lang.String description) {
this.description = description;
}
@@ -408,7 +378,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case TYPE:
if (value == null) {
@@ -422,7 +392,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
if (value == null) {
unsetGatewayId();
} else {
- setGatewayId((String)value);
+ setGatewayId((java.lang.String)value);
}
break;
@@ -430,7 +400,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
if (value == null) {
unsetUsername();
} else {
- setUsername((String)value);
+ setUsername((java.lang.String)value);
}
break;
@@ -438,7 +408,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
if (value == null) {
unsetPublicKey();
} else {
- setPublicKey((String)value);
+ setPublicKey((java.lang.String)value);
}
break;
@@ -446,7 +416,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
if (value == null) {
unsetPersistedTime();
} else {
- setPersistedTime((Long)value);
+ setPersistedTime((java.lang.Long)value);
}
break;
@@ -454,7 +424,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
if (value == null) {
unsetToken();
} else {
- setToken((String)value);
+ setToken((java.lang.String)value);
}
break;
@@ -462,14 +432,14 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
if (value == null) {
unsetDescription();
} else {
- setDescription((String)value);
+ setDescription((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case TYPE:
return getType();
@@ -493,13 +463,13 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
return getDescription();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -518,11 +488,11 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
case DESCRIPTION:
return isSetDescription();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof CredentialSummary)
@@ -533,6 +503,8 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
public boolean equals(CredentialSummary that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_type = true && this.isSetType();
boolean that_present_type = true && that.isSetType();
@@ -602,44 +574,37 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_type = true && (isSetType());
- list.add(present_type);
- if (present_type)
- list.add(type.getValue());
-
- boolean present_gatewayId = true && (isSetGatewayId());
- list.add(present_gatewayId);
- if (present_gatewayId)
- list.add(gatewayId);
-
- boolean present_username = true && (isSetUsername());
- list.add(present_username);
- if (present_username)
- list.add(username);
-
- boolean present_publicKey = true && (isSetPublicKey());
- list.add(present_publicKey);
- if (present_publicKey)
- list.add(publicKey);
-
- boolean present_persistedTime = true && (isSetPersistedTime());
- list.add(present_persistedTime);
- if (present_persistedTime)
- list.add(persistedTime);
-
- boolean present_token = true && (isSetToken());
- list.add(present_token);
- if (present_token)
- list.add(token);
-
- boolean present_description = true && (isSetDescription());
- list.add(present_description);
- if (present_description)
- list.add(description);
-
- return list.hashCode();
+ int hashCode = 1;
+
+ hashCode = hashCode * 8191 + ((isSetType()) ? 131071 : 524287);
+ if (isSetType())
+ hashCode = hashCode * 8191 + type.getValue();
+
+ hashCode = hashCode * 8191 + ((isSetGatewayId()) ? 131071 : 524287);
+ if (isSetGatewayId())
+ hashCode = hashCode * 8191 + gatewayId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetUsername()) ? 131071 : 524287);
+ if (isSetUsername())
+ hashCode = hashCode * 8191 + username.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetPublicKey()) ? 131071 : 524287);
+ if (isSetPublicKey())
+ hashCode = hashCode * 8191 + publicKey.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetPersistedTime()) ? 131071 : 524287);
+ if (isSetPersistedTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(persistedTime);
+
+ hashCode = hashCode * 8191 + ((isSetToken()) ? 131071 : 524287);
+ if (isSetToken())
+ hashCode = hashCode * 8191 + token.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetDescription()) ? 131071 : 524287);
+ if (isSetDescription())
+ hashCode = hashCode * 8191 + description.hashCode();
+
+ return hashCode;
}
@Override
@@ -650,7 +615,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetType()).compareTo(other.isSetType());
+ lastComparison = java.lang.Boolean.valueOf(isSetType()).compareTo(other.isSetType());
if (lastComparison != 0) {
return lastComparison;
}
@@ -660,7 +625,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(other.isSetGatewayId());
+ lastComparison = java.lang.Boolean.valueOf(isSetGatewayId()).compareTo(other.isSetGatewayId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -670,7 +635,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUsername()).compareTo(other.isSetUsername());
+ lastComparison = java.lang.Boolean.valueOf(isSetUsername()).compareTo(other.isSetUsername());
if (lastComparison != 0) {
return lastComparison;
}
@@ -680,7 +645,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPublicKey()).compareTo(other.isSetPublicKey());
+ lastComparison = java.lang.Boolean.valueOf(isSetPublicKey()).compareTo(other.isSetPublicKey());
if (lastComparison != 0) {
return lastComparison;
}
@@ -690,7 +655,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPersistedTime()).compareTo(other.isSetPersistedTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetPersistedTime()).compareTo(other.isSetPersistedTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -700,7 +665,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetToken()).compareTo(other.isSetToken());
+ lastComparison = java.lang.Boolean.valueOf(isSetToken()).compareTo(other.isSetToken());
if (lastComparison != 0) {
return lastComparison;
}
@@ -710,7 +675,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -728,16 +693,16 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("CredentialSummary(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("CredentialSummary(");
boolean first = true;
sb.append("type:");
@@ -830,7 +795,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -840,13 +805,13 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
}
}
- private static class CredentialSummaryStandardSchemeFactory implements SchemeFactory {
+ private static class CredentialSummaryStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public CredentialSummaryStandardScheme getScheme() {
return new CredentialSummaryStandardScheme();
}
}
- private static class CredentialSummaryStandardScheme extends StandardScheme<CredentialSummary> {
+ private static class CredentialSummaryStandardScheme extends org.apache.thrift.scheme.StandardScheme<CredentialSummary> {
public void read(org.apache.thrift.protocol.TProtocol iprot, CredentialSummary struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -972,22 +937,22 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
}
- private static class CredentialSummaryTupleSchemeFactory implements SchemeFactory {
+ private static class CredentialSummaryTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public CredentialSummaryTupleScheme getScheme() {
return new CredentialSummaryTupleScheme();
}
}
- private static class CredentialSummaryTupleScheme extends TupleScheme<CredentialSummary> {
+ private static class CredentialSummaryTupleScheme extends org.apache.thrift.scheme.TupleScheme<CredentialSummary> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, CredentialSummary struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeI32(struct.type.getValue());
oprot.writeString(struct.gatewayId);
oprot.writeString(struct.username);
oprot.writeString(struct.token);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetPublicKey()) {
optionals.set(0);
}
@@ -1011,7 +976,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, CredentialSummary struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.type = org.apache.airavata.model.credential.store.SummaryType.findByValue(iprot.readI32());
struct.setTypeIsSet(true);
struct.gatewayId = iprot.readString();
@@ -1020,7 +985,7 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
struct.setUsernameIsSet(true);
struct.token = iprot.readString();
struct.setTokenIsSet(true);
- BitSet incoming = iprot.readBitSet(3);
+ java.util.BitSet incoming = iprot.readBitSet(3);
if (incoming.get(0)) {
struct.publicKey = iprot.readString();
struct.setPublicKeyIsSet(true);
@@ -1036,5 +1001,8 @@ public class CredentialSummary implements org.apache.thrift.TBase<CredentialSumm
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
[42/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/computeresource/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/computeresource/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/computeresource/ttypes.py
index 9d9aa0d..cb5e083 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/computeresource/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/computeresource/ttypes.py
@@ -1,1784 +1,1687 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.commons.ttypes
import apache.airavata.model.appcatalog.parallelism.ttypes
import apache.airavata.model.data.movement.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class ResourceJobManagerType:
- """
- * Enumeration of local resource job manager types supported by Airavata
- *
- * FORK:
- * Forking of commands without any job manager
- *
- * PBS:
- * Job manager supporting the Portal Batch System (PBS) protocol. Some examples include TORQUE, PBSPro, Grid Engine.
- *
- * SLURM:
- * The Simple Linux Utility for Resource Management is a open source workload manager.
- *
- * UGE:
- * Univa Grid Engine, a variation of PBS implementation.
- *
- * LSF:
- * IBM Platform Load Sharing Facility is dominantly installed on IBM clusters.
- *
- """
- FORK = 0
- PBS = 1
- SLURM = 2
- LSF = 3
- UGE = 4
- CLOUD = 5
- AIRAVATA_CUSTOM = 6
-
- _VALUES_TO_NAMES = {
- 0: "FORK",
- 1: "PBS",
- 2: "SLURM",
- 3: "LSF",
- 4: "UGE",
- 5: "CLOUD",
- 6: "AIRAVATA_CUSTOM",
- }
-
- _NAMES_TO_VALUES = {
- "FORK": 0,
- "PBS": 1,
- "SLURM": 2,
- "LSF": 3,
- "UGE": 4,
- "CLOUD": 5,
- "AIRAVATA_CUSTOM": 6,
- }
-
-class JobManagerCommand:
- """
- Enumeration of resource job manager commands
-
- SUBMISSION:
- Ex: qsub, sbatch
-
- JOBMONITORING:
- Ex: qstat, squeue
-
- DELETION:
- Ex: qdel, scancel
-
- CHECK_JOB:
- Detailed Status about the Job. Ex: checkjob
-
- SHOW_QUEUE:
- List of Queued Job by the schedular. Ex: showq
-
- SHOW_RESERVATION:
- List all reservations. Ex:showres, show_res
-
- SHOW_START:
- Display the start time of the specified job. Ex: showstart
-
- """
- SUBMISSION = 0
- JOB_MONITORING = 1
- DELETION = 2
- CHECK_JOB = 3
- SHOW_QUEUE = 4
- SHOW_RESERVATION = 5
- SHOW_START = 6
-
- _VALUES_TO_NAMES = {
- 0: "SUBMISSION",
- 1: "JOB_MONITORING",
- 2: "DELETION",
- 3: "CHECK_JOB",
- 4: "SHOW_QUEUE",
- 5: "SHOW_RESERVATION",
- 6: "SHOW_START",
- }
-
- _NAMES_TO_VALUES = {
- "SUBMISSION": 0,
- "JOB_MONITORING": 1,
- "DELETION": 2,
- "CHECK_JOB": 3,
- "SHOW_QUEUE": 4,
- "SHOW_RESERVATION": 5,
- "SHOW_START": 6,
- }
-
-class FileSystems:
- """
- Enumeration of File Systems on the resource
-
- FORK:
- Forking of commands without any job manager
-
- PBS:
- Job manager supporting the Portal Batch System (PBS) protocol. Some examples include TORQUE, PBSPro, Grid Engine.
-
- UGE:
- Univa Grid Engine, a variation of PBS implementation.
-
- SLURM:
- The Simple Linux Utility for Resource Management is a open source workload manager.
-
- """
- HOME = 0
- WORK = 1
- LOCALTMP = 2
- SCRATCH = 3
- ARCHIVE = 4
-
- _VALUES_TO_NAMES = {
- 0: "HOME",
- 1: "WORK",
- 2: "LOCALTMP",
- 3: "SCRATCH",
- 4: "ARCHIVE",
- }
-
- _NAMES_TO_VALUES = {
- "HOME": 0,
- "WORK": 1,
- "LOCALTMP": 2,
- "SCRATCH": 3,
- "ARCHIVE": 4,
- }
-
-class JobSubmissionProtocol:
- """
- Enumeration of Airavata supported Job Submission Mechanisms for High Performance Computing Clusters.
-
- SSH:
- Execute remote job submission commands using via secure shell protocol.
-
- GRAM:
- Execute remote jobs via Globus GRAM service.
-
- UNICORE:
- Execute remote jobs via Unicore services
-
- """
- LOCAL = 0
- SSH = 1
- GLOBUS = 2
- UNICORE = 3
- CLOUD = 4
- SSH_FORK = 5
- LOCAL_FORK = 6
-
- _VALUES_TO_NAMES = {
- 0: "LOCAL",
- 1: "SSH",
- 2: "GLOBUS",
- 3: "UNICORE",
- 4: "CLOUD",
- 5: "SSH_FORK",
- 6: "LOCAL_FORK",
- }
-
- _NAMES_TO_VALUES = {
- "LOCAL": 0,
- "SSH": 1,
- "GLOBUS": 2,
- "UNICORE": 3,
- "CLOUD": 4,
- "SSH_FORK": 5,
- "LOCAL_FORK": 6,
- }
-
-class MonitorMode:
- """
- Monitoring modes
-
- POLL_JOB_MANAGER:
- GFac need to pull job status changes.
-
- XSEDE_AMQP_SUBSCRIBE:
- Server will publish job status changes to amqp servert.
-
-
- """
- POLL_JOB_MANAGER = 0
- CLOUD_JOB_MONITOR = 1
- JOB_EMAIL_NOTIFICATION_MONITOR = 2
- XSEDE_AMQP_SUBSCRIBE = 3
- FORK = 4
- LOCAL = 5
-
- _VALUES_TO_NAMES = {
- 0: "POLL_JOB_MANAGER",
- 1: "CLOUD_JOB_MONITOR",
- 2: "JOB_EMAIL_NOTIFICATION_MONITOR",
- 3: "XSEDE_AMQP_SUBSCRIBE",
- 4: "FORK",
- 5: "LOCAL",
- }
-
- _NAMES_TO_VALUES = {
- "POLL_JOB_MANAGER": 0,
- "CLOUD_JOB_MONITOR": 1,
- "JOB_EMAIL_NOTIFICATION_MONITOR": 2,
- "XSEDE_AMQP_SUBSCRIBE": 3,
- "FORK": 4,
- "LOCAL": 5,
- }
-
-class DMType:
- COMPUTE_RESOURCE = 0
- STORAGE_RESOURCE = 1
-
- _VALUES_TO_NAMES = {
- 0: "COMPUTE_RESOURCE",
- 1: "STORAGE_RESOURCE",
- }
-
- _NAMES_TO_VALUES = {
- "COMPUTE_RESOURCE": 0,
- "STORAGE_RESOURCE": 1,
- }
-
-class ProviderName:
- """
- Provider name
-
- """
- EC2 = 0
- AWSEC2 = 1
- RACKSPACE = 2
-
- _VALUES_TO_NAMES = {
- 0: "EC2",
- 1: "AWSEC2",
- 2: "RACKSPACE",
- }
-
- _NAMES_TO_VALUES = {
- "EC2": 0,
- "AWSEC2": 1,
- "RACKSPACE": 2,
- }
-
-
-class ResourceJobManager:
- """
- Resource Job Manager Information
-
- resourceJobManagerType:
- A typical HPC cluster has a single Job Manager to manage the resources.
-
- pushMonitoringEndpoint:
- If the job manager pushes out state changes to a database or bus, specify the service endpoint.
- Ex: Moab Web Service, Moab MongoDB URL, AMQP (GLUE2) Broker
-
- jobManagerBinPath:
- Path to the Job Manager Installation Binary directory.
-
- jobManagerCommands:
- An enumeration of commonly used manager commands.
-
-
- Attributes:
- - resourceJobManagerId
- - resourceJobManagerType
- - pushMonitoringEndpoint
- - jobManagerBinPath
- - jobManagerCommands
- - parallelismPrefix
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'resourceJobManagerId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.I32, 'resourceJobManagerType', None, None, ), # 2
- (3, TType.STRING, 'pushMonitoringEndpoint', None, None, ), # 3
- (4, TType.STRING, 'jobManagerBinPath', None, None, ), # 4
- (5, TType.MAP, 'jobManagerCommands', (TType.I32,None,TType.STRING,None), None, ), # 5
- (6, TType.MAP, 'parallelismPrefix', (TType.I32,None,TType.STRING,None), None, ), # 6
- )
-
- def __init__(self, resourceJobManagerId=thrift_spec[1][4], resourceJobManagerType=None, pushMonitoringEndpoint=None, jobManagerBinPath=None, jobManagerCommands=None, parallelismPrefix=None,):
- self.resourceJobManagerId = resourceJobManagerId
- self.resourceJobManagerType = resourceJobManagerType
- self.pushMonitoringEndpoint = pushMonitoringEndpoint
- self.jobManagerBinPath = jobManagerBinPath
- self.jobManagerCommands = jobManagerCommands
- self.parallelismPrefix = parallelismPrefix
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.resourceJobManagerId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.resourceJobManagerType = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.pushMonitoringEndpoint = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.jobManagerBinPath = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.MAP:
- self.jobManagerCommands = {}
- (_ktype1, _vtype2, _size0 ) = iprot.readMapBegin()
- for _i4 in xrange(_size0):
- _key5 = iprot.readI32()
- _val6 = iprot.readString()
- self.jobManagerCommands[_key5] = _val6
- iprot.readMapEnd()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.MAP:
- self.parallelismPrefix = {}
- (_ktype8, _vtype9, _size7 ) = iprot.readMapBegin()
- for _i11 in xrange(_size7):
- _key12 = iprot.readI32()
- _val13 = iprot.readString()
- self.parallelismPrefix[_key12] = _val13
- iprot.readMapEnd()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ResourceJobManager')
- if self.resourceJobManagerId is not None:
- oprot.writeFieldBegin('resourceJobManagerId', TType.STRING, 1)
- oprot.writeString(self.resourceJobManagerId)
- oprot.writeFieldEnd()
- if self.resourceJobManagerType is not None:
- oprot.writeFieldBegin('resourceJobManagerType', TType.I32, 2)
- oprot.writeI32(self.resourceJobManagerType)
- oprot.writeFieldEnd()
- if self.pushMonitoringEndpoint is not None:
- oprot.writeFieldBegin('pushMonitoringEndpoint', TType.STRING, 3)
- oprot.writeString(self.pushMonitoringEndpoint)
- oprot.writeFieldEnd()
- if self.jobManagerBinPath is not None:
- oprot.writeFieldBegin('jobManagerBinPath', TType.STRING, 4)
- oprot.writeString(self.jobManagerBinPath)
- oprot.writeFieldEnd()
- if self.jobManagerCommands is not None:
- oprot.writeFieldBegin('jobManagerCommands', TType.MAP, 5)
- oprot.writeMapBegin(TType.I32, TType.STRING, len(self.jobManagerCommands))
- for kiter14,viter15 in self.jobManagerCommands.items():
- oprot.writeI32(kiter14)
- oprot.writeString(viter15)
- oprot.writeMapEnd()
- oprot.writeFieldEnd()
- if self.parallelismPrefix is not None:
- oprot.writeFieldBegin('parallelismPrefix', TType.MAP, 6)
- oprot.writeMapBegin(TType.I32, TType.STRING, len(self.parallelismPrefix))
- for kiter16,viter17 in self.parallelismPrefix.items():
- oprot.writeI32(kiter16)
- oprot.writeString(viter17)
- oprot.writeMapEnd()
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.resourceJobManagerId is None:
- raise TProtocol.TProtocolException(message='Required field resourceJobManagerId is unset!')
- if self.resourceJobManagerType is None:
- raise TProtocol.TProtocolException(message='Required field resourceJobManagerType is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.resourceJobManagerId)
- value = (value * 31) ^ hash(self.resourceJobManagerType)
- value = (value * 31) ^ hash(self.pushMonitoringEndpoint)
- value = (value * 31) ^ hash(self.jobManagerBinPath)
- value = (value * 31) ^ hash(self.jobManagerCommands)
- value = (value * 31) ^ hash(self.parallelismPrefix)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class BatchQueue:
- """
- Batch Queue Information on SuperComputers
-
- maxRunTime:
- Maximum allowed run time in hours.
-
- Attributes:
- - queueName
- - queueDescription
- - maxRunTime
- - maxNodes
- - maxProcessors
- - maxJobsInQueue
- - maxMemory
- - cpuPerNode
- - defaultNodeCount
- - defaultCPUCount
- - defaultWalltime
- - queueSpecificMacros
- - isDefaultQueue
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'queueName', None, None, ), # 1
- (2, TType.STRING, 'queueDescription', None, None, ), # 2
- (3, TType.I32, 'maxRunTime', None, None, ), # 3
- (4, TType.I32, 'maxNodes', None, None, ), # 4
- (5, TType.I32, 'maxProcessors', None, None, ), # 5
- (6, TType.I32, 'maxJobsInQueue', None, None, ), # 6
- (7, TType.I32, 'maxMemory', None, None, ), # 7
- (8, TType.I32, 'cpuPerNode', None, None, ), # 8
- (9, TType.I32, 'defaultNodeCount', None, None, ), # 9
- (10, TType.I32, 'defaultCPUCount', None, None, ), # 10
- (11, TType.I32, 'defaultWalltime', None, None, ), # 11
- (12, TType.STRING, 'queueSpecificMacros', None, None, ), # 12
- (13, TType.BOOL, 'isDefaultQueue', None, None, ), # 13
- )
-
- def __init__(self, queueName=None, queueDescription=None, maxRunTime=None, maxNodes=None, maxProcessors=None, maxJobsInQueue=None, maxMemory=None, cpuPerNode=None, defaultNodeCount=None, defaultCPUCount=None, defaultWalltime=None, queueSpecificMacros=None, isDefaultQueue=None,):
- self.queueName = queueName
- self.queueDescription = queueDescription
- self.maxRunTime = maxRunTime
- self.maxNodes = maxNodes
- self.maxProcessors = maxProcessors
- self.maxJobsInQueue = maxJobsInQueue
- self.maxMemory = maxMemory
- self.cpuPerNode = cpuPerNode
- self.defaultNodeCount = defaultNodeCount
- self.defaultCPUCount = defaultCPUCount
- self.defaultWalltime = defaultWalltime
- self.queueSpecificMacros = queueSpecificMacros
- self.isDefaultQueue = isDefaultQueue
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.queueName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.queueDescription = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.I32:
- self.maxRunTime = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.I32:
- self.maxNodes = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I32:
- self.maxProcessors = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.I32:
- self.maxJobsInQueue = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.I32:
- self.maxMemory = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.I32:
- self.cpuPerNode = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.I32:
- self.defaultNodeCount = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.I32:
- self.defaultCPUCount = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 11:
- if ftype == TType.I32:
- self.defaultWalltime = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 12:
- if ftype == TType.STRING:
- self.queueSpecificMacros = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 13:
- if ftype == TType.BOOL:
- self.isDefaultQueue = iprot.readBool()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('BatchQueue')
- if self.queueName is not None:
- oprot.writeFieldBegin('queueName', TType.STRING, 1)
- oprot.writeString(self.queueName)
- oprot.writeFieldEnd()
- if self.queueDescription is not None:
- oprot.writeFieldBegin('queueDescription', TType.STRING, 2)
- oprot.writeString(self.queueDescription)
- oprot.writeFieldEnd()
- if self.maxRunTime is not None:
- oprot.writeFieldBegin('maxRunTime', TType.I32, 3)
- oprot.writeI32(self.maxRunTime)
- oprot.writeFieldEnd()
- if self.maxNodes is not None:
- oprot.writeFieldBegin('maxNodes', TType.I32, 4)
- oprot.writeI32(self.maxNodes)
- oprot.writeFieldEnd()
- if self.maxProcessors is not None:
- oprot.writeFieldBegin('maxProcessors', TType.I32, 5)
- oprot.writeI32(self.maxProcessors)
- oprot.writeFieldEnd()
- if self.maxJobsInQueue is not None:
- oprot.writeFieldBegin('maxJobsInQueue', TType.I32, 6)
- oprot.writeI32(self.maxJobsInQueue)
- oprot.writeFieldEnd()
- if self.maxMemory is not None:
- oprot.writeFieldBegin('maxMemory', TType.I32, 7)
- oprot.writeI32(self.maxMemory)
- oprot.writeFieldEnd()
- if self.cpuPerNode is not None:
- oprot.writeFieldBegin('cpuPerNode', TType.I32, 8)
- oprot.writeI32(self.cpuPerNode)
- oprot.writeFieldEnd()
- if self.defaultNodeCount is not None:
- oprot.writeFieldBegin('defaultNodeCount', TType.I32, 9)
- oprot.writeI32(self.defaultNodeCount)
- oprot.writeFieldEnd()
- if self.defaultCPUCount is not None:
- oprot.writeFieldBegin('defaultCPUCount', TType.I32, 10)
- oprot.writeI32(self.defaultCPUCount)
- oprot.writeFieldEnd()
- if self.defaultWalltime is not None:
- oprot.writeFieldBegin('defaultWalltime', TType.I32, 11)
- oprot.writeI32(self.defaultWalltime)
- oprot.writeFieldEnd()
- if self.queueSpecificMacros is not None:
- oprot.writeFieldBegin('queueSpecificMacros', TType.STRING, 12)
- oprot.writeString(self.queueSpecificMacros)
- oprot.writeFieldEnd()
- if self.isDefaultQueue is not None:
- oprot.writeFieldBegin('isDefaultQueue', TType.BOOL, 13)
- oprot.writeBool(self.isDefaultQueue)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.queueName is None:
- raise TProtocol.TProtocolException(message='Required field queueName is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.queueName)
- value = (value * 31) ^ hash(self.queueDescription)
- value = (value * 31) ^ hash(self.maxRunTime)
- value = (value * 31) ^ hash(self.maxNodes)
- value = (value * 31) ^ hash(self.maxProcessors)
- value = (value * 31) ^ hash(self.maxJobsInQueue)
- value = (value * 31) ^ hash(self.maxMemory)
- value = (value * 31) ^ hash(self.cpuPerNode)
- value = (value * 31) ^ hash(self.defaultNodeCount)
- value = (value * 31) ^ hash(self.defaultCPUCount)
- value = (value * 31) ^ hash(self.defaultWalltime)
- value = (value * 31) ^ hash(self.queueSpecificMacros)
- value = (value * 31) ^ hash(self.isDefaultQueue)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class LOCALSubmission:
- """
- Locally Fork Jobs as OS processes
-
- alternativeSSHHostName:
- If the login to ssh is different than the hostname itself, specify it here
-
- sshPort:
- If a non-default port needs to used, specify it.
-
- Attributes:
- - jobSubmissionInterfaceId
- - resourceJobManager
- - securityProtocol
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'jobSubmissionInterfaceId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.STRUCT, 'resourceJobManager', (ResourceJobManager, ResourceJobManager.thrift_spec), None, ), # 2
- (3, TType.I32, 'securityProtocol', None, None, ), # 3
- )
-
- def __init__(self, jobSubmissionInterfaceId=thrift_spec[1][4], resourceJobManager=None, securityProtocol=None,):
- self.jobSubmissionInterfaceId = jobSubmissionInterfaceId
- self.resourceJobManager = resourceJobManager
- self.securityProtocol = securityProtocol
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.jobSubmissionInterfaceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRUCT:
- self.resourceJobManager = ResourceJobManager()
- self.resourceJobManager.read(iprot)
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.I32:
- self.securityProtocol = iprot.readI32()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('LOCALSubmission')
- if self.jobSubmissionInterfaceId is not None:
- oprot.writeFieldBegin('jobSubmissionInterfaceId', TType.STRING, 1)
- oprot.writeString(self.jobSubmissionInterfaceId)
- oprot.writeFieldEnd()
- if self.resourceJobManager is not None:
- oprot.writeFieldBegin('resourceJobManager', TType.STRUCT, 2)
- self.resourceJobManager.write(oprot)
- oprot.writeFieldEnd()
- if self.securityProtocol is not None:
- oprot.writeFieldBegin('securityProtocol', TType.I32, 3)
- oprot.writeI32(self.securityProtocol)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.jobSubmissionInterfaceId is None:
- raise TProtocol.TProtocolException(message='Required field jobSubmissionInterfaceId is unset!')
- if self.resourceJobManager is None:
- raise TProtocol.TProtocolException(message='Required field resourceJobManager is unset!')
- if self.securityProtocol is None:
- raise TProtocol.TProtocolException(message='Required field securityProtocol is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.jobSubmissionInterfaceId)
- value = (value * 31) ^ hash(self.resourceJobManager)
- value = (value * 31) ^ hash(self.securityProtocol)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class SSHJobSubmission:
- """
- Authenticate using Secured Shell
-
- alternativeSSHHostName:
- If the login to ssh is different than the hostname itself, specify it here
-
- sshPort:
- If a non-default port needs to used, specify it.
-
- batchQueueEmailSenders:
- If a resource always sends the monitoring from a specific address, specify the
- full email address. If a resource sends emails from multiple addresses (
- example: based on the submitted login node) then use the wildchar * to indicate
- the same. Example: *@*.example.com or *@example.com
-
-
- Attributes:
- - jobSubmissionInterfaceId
- - securityProtocol
- - resourceJobManager
- - alternativeSSHHostName
- - sshPort
- - monitorMode
- - batchQueueEmailSenders
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'jobSubmissionInterfaceId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.I32, 'securityProtocol', None, None, ), # 2
- (3, TType.STRUCT, 'resourceJobManager', (ResourceJobManager, ResourceJobManager.thrift_spec), None, ), # 3
- (4, TType.STRING, 'alternativeSSHHostName', None, None, ), # 4
- (5, TType.I32, 'sshPort', None, 22, ), # 5
- (6, TType.I32, 'monitorMode', None, None, ), # 6
- (7, TType.LIST, 'batchQueueEmailSenders', (TType.STRING,None), None, ), # 7
- )
-
- def __init__(self, jobSubmissionInterfaceId=thrift_spec[1][4], securityProtocol=None, resourceJobManager=None, alternativeSSHHostName=None, sshPort=thrift_spec[5][4], monitorMode=None, batchQueueEmailSenders=None,):
- self.jobSubmissionInterfaceId = jobSubmissionInterfaceId
- self.securityProtocol = securityProtocol
- self.resourceJobManager = resourceJobManager
- self.alternativeSSHHostName = alternativeSSHHostName
- self.sshPort = sshPort
- self.monitorMode = monitorMode
- self.batchQueueEmailSenders = batchQueueEmailSenders
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.jobSubmissionInterfaceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.securityProtocol = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRUCT:
- self.resourceJobManager = ResourceJobManager()
- self.resourceJobManager.read(iprot)
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.alternativeSSHHostName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I32:
- self.sshPort = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.I32:
- self.monitorMode = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.LIST:
- self.batchQueueEmailSenders = []
- (_etype21, _size18) = iprot.readListBegin()
- for _i22 in xrange(_size18):
- _elem23 = iprot.readString()
- self.batchQueueEmailSenders.append(_elem23)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('SSHJobSubmission')
- if self.jobSubmissionInterfaceId is not None:
- oprot.writeFieldBegin('jobSubmissionInterfaceId', TType.STRING, 1)
- oprot.writeString(self.jobSubmissionInterfaceId)
- oprot.writeFieldEnd()
- if self.securityProtocol is not None:
- oprot.writeFieldBegin('securityProtocol', TType.I32, 2)
- oprot.writeI32(self.securityProtocol)
- oprot.writeFieldEnd()
- if self.resourceJobManager is not None:
- oprot.writeFieldBegin('resourceJobManager', TType.STRUCT, 3)
- self.resourceJobManager.write(oprot)
- oprot.writeFieldEnd()
- if self.alternativeSSHHostName is not None:
- oprot.writeFieldBegin('alternativeSSHHostName', TType.STRING, 4)
- oprot.writeString(self.alternativeSSHHostName)
- oprot.writeFieldEnd()
- if self.sshPort is not None:
- oprot.writeFieldBegin('sshPort', TType.I32, 5)
- oprot.writeI32(self.sshPort)
- oprot.writeFieldEnd()
- if self.monitorMode is not None:
- oprot.writeFieldBegin('monitorMode', TType.I32, 6)
- oprot.writeI32(self.monitorMode)
- oprot.writeFieldEnd()
- if self.batchQueueEmailSenders is not None:
- oprot.writeFieldBegin('batchQueueEmailSenders', TType.LIST, 7)
- oprot.writeListBegin(TType.STRING, len(self.batchQueueEmailSenders))
- for iter24 in self.batchQueueEmailSenders:
- oprot.writeString(iter24)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.jobSubmissionInterfaceId is None:
- raise TProtocol.TProtocolException(message='Required field jobSubmissionInterfaceId is unset!')
- if self.securityProtocol is None:
- raise TProtocol.TProtocolException(message='Required field securityProtocol is unset!')
- if self.resourceJobManager is None:
- raise TProtocol.TProtocolException(message='Required field resourceJobManager is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.jobSubmissionInterfaceId)
- value = (value * 31) ^ hash(self.securityProtocol)
- value = (value * 31) ^ hash(self.resourceJobManager)
- value = (value * 31) ^ hash(self.alternativeSSHHostName)
- value = (value * 31) ^ hash(self.sshPort)
- value = (value * 31) ^ hash(self.monitorMode)
- value = (value * 31) ^ hash(self.batchQueueEmailSenders)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class GlobusJobSubmission:
- """
- Attributes:
- - jobSubmissionInterfaceId
- - securityProtocol
- - globusGateKeeperEndPoint
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'jobSubmissionInterfaceId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.I32, 'securityProtocol', None, None, ), # 2
- (3, TType.LIST, 'globusGateKeeperEndPoint', (TType.STRING,None), None, ), # 3
- )
-
- def __init__(self, jobSubmissionInterfaceId=thrift_spec[1][4], securityProtocol=None, globusGateKeeperEndPoint=None,):
- self.jobSubmissionInterfaceId = jobSubmissionInterfaceId
- self.securityProtocol = securityProtocol
- self.globusGateKeeperEndPoint = globusGateKeeperEndPoint
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.jobSubmissionInterfaceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.securityProtocol = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.LIST:
- self.globusGateKeeperEndPoint = []
- (_etype28, _size25) = iprot.readListBegin()
- for _i29 in xrange(_size25):
- _elem30 = iprot.readString()
- self.globusGateKeeperEndPoint.append(_elem30)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('GlobusJobSubmission')
- if self.jobSubmissionInterfaceId is not None:
- oprot.writeFieldBegin('jobSubmissionInterfaceId', TType.STRING, 1)
- oprot.writeString(self.jobSubmissionInterfaceId)
- oprot.writeFieldEnd()
- if self.securityProtocol is not None:
- oprot.writeFieldBegin('securityProtocol', TType.I32, 2)
- oprot.writeI32(self.securityProtocol)
- oprot.writeFieldEnd()
- if self.globusGateKeeperEndPoint is not None:
- oprot.writeFieldBegin('globusGateKeeperEndPoint', TType.LIST, 3)
- oprot.writeListBegin(TType.STRING, len(self.globusGateKeeperEndPoint))
- for iter31 in self.globusGateKeeperEndPoint:
- oprot.writeString(iter31)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.jobSubmissionInterfaceId is None:
- raise TProtocol.TProtocolException(message='Required field jobSubmissionInterfaceId is unset!')
- if self.securityProtocol is None:
- raise TProtocol.TProtocolException(message='Required field securityProtocol is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.jobSubmissionInterfaceId)
- value = (value * 31) ^ hash(self.securityProtocol)
- value = (value * 31) ^ hash(self.globusGateKeeperEndPoint)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class UnicoreJobSubmission:
- """
- Unicore Job Submission
-
- unicoreEndPointURL:
- unicoreGateway End Point. The provider will query this service to fetch required service end points.
- authenticationMode
- The authenticationMode defines the way certificate is fetched.
-
- Attributes:
- - jobSubmissionInterfaceId
- - securityProtocol
- - unicoreEndPointURL
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'jobSubmissionInterfaceId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.I32, 'securityProtocol', None, None, ), # 2
- (3, TType.STRING, 'unicoreEndPointURL', None, None, ), # 3
- )
-
- def __init__(self, jobSubmissionInterfaceId=thrift_spec[1][4], securityProtocol=None, unicoreEndPointURL=None,):
- self.jobSubmissionInterfaceId = jobSubmissionInterfaceId
- self.securityProtocol = securityProtocol
- self.unicoreEndPointURL = unicoreEndPointURL
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.jobSubmissionInterfaceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.securityProtocol = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.unicoreEndPointURL = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('UnicoreJobSubmission')
- if self.jobSubmissionInterfaceId is not None:
- oprot.writeFieldBegin('jobSubmissionInterfaceId', TType.STRING, 1)
- oprot.writeString(self.jobSubmissionInterfaceId)
- oprot.writeFieldEnd()
- if self.securityProtocol is not None:
- oprot.writeFieldBegin('securityProtocol', TType.I32, 2)
- oprot.writeI32(self.securityProtocol)
- oprot.writeFieldEnd()
- if self.unicoreEndPointURL is not None:
- oprot.writeFieldBegin('unicoreEndPointURL', TType.STRING, 3)
- oprot.writeString(self.unicoreEndPointURL)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.jobSubmissionInterfaceId is None:
- raise TProtocol.TProtocolException(message='Required field jobSubmissionInterfaceId is unset!')
- if self.securityProtocol is None:
- raise TProtocol.TProtocolException(message='Required field securityProtocol is unset!')
- if self.unicoreEndPointURL is None:
- raise TProtocol.TProtocolException(message='Required field unicoreEndPointURL is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.jobSubmissionInterfaceId)
- value = (value * 31) ^ hash(self.securityProtocol)
- value = (value * 31) ^ hash(self.unicoreEndPointURL)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class CloudJobSubmission:
- """
- Cloud Job Submission
-
-
-
- Attributes:
- - jobSubmissionInterfaceId
- - securityProtocol
- - nodeId
- - executableType
- - providerName
- - userAccountName
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'jobSubmissionInterfaceId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.I32, 'securityProtocol', None, None, ), # 2
- (3, TType.STRING, 'nodeId', None, None, ), # 3
- (4, TType.STRING, 'executableType', None, None, ), # 4
- (5, TType.I32, 'providerName', None, None, ), # 5
- (6, TType.STRING, 'userAccountName', None, None, ), # 6
- )
-
- def __init__(self, jobSubmissionInterfaceId=thrift_spec[1][4], securityProtocol=None, nodeId=None, executableType=None, providerName=None, userAccountName=None,):
- self.jobSubmissionInterfaceId = jobSubmissionInterfaceId
- self.securityProtocol = securityProtocol
- self.nodeId = nodeId
- self.executableType = executableType
- self.providerName = providerName
- self.userAccountName = userAccountName
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.jobSubmissionInterfaceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.securityProtocol = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.nodeId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.executableType = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I32:
- self.providerName = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.userAccountName = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('CloudJobSubmission')
- if self.jobSubmissionInterfaceId is not None:
- oprot.writeFieldBegin('jobSubmissionInterfaceId', TType.STRING, 1)
- oprot.writeString(self.jobSubmissionInterfaceId)
- oprot.writeFieldEnd()
- if self.securityProtocol is not None:
- oprot.writeFieldBegin('securityProtocol', TType.I32, 2)
- oprot.writeI32(self.securityProtocol)
- oprot.writeFieldEnd()
- if self.nodeId is not None:
- oprot.writeFieldBegin('nodeId', TType.STRING, 3)
- oprot.writeString(self.nodeId)
- oprot.writeFieldEnd()
- if self.executableType is not None:
- oprot.writeFieldBegin('executableType', TType.STRING, 4)
- oprot.writeString(self.executableType)
- oprot.writeFieldEnd()
- if self.providerName is not None:
- oprot.writeFieldBegin('providerName', TType.I32, 5)
- oprot.writeI32(self.providerName)
- oprot.writeFieldEnd()
- if self.userAccountName is not None:
- oprot.writeFieldBegin('userAccountName', TType.STRING, 6)
- oprot.writeString(self.userAccountName)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.jobSubmissionInterfaceId is None:
- raise TProtocol.TProtocolException(message='Required field jobSubmissionInterfaceId is unset!')
- if self.securityProtocol is None:
- raise TProtocol.TProtocolException(message='Required field securityProtocol is unset!')
- if self.nodeId is None:
- raise TProtocol.TProtocolException(message='Required field nodeId is unset!')
- if self.executableType is None:
- raise TProtocol.TProtocolException(message='Required field executableType is unset!')
- if self.providerName is None:
- raise TProtocol.TProtocolException(message='Required field providerName is unset!')
- if self.userAccountName is None:
- raise TProtocol.TProtocolException(message='Required field userAccountName is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.jobSubmissionInterfaceId)
- value = (value * 31) ^ hash(self.securityProtocol)
- value = (value * 31) ^ hash(self.nodeId)
- value = (value * 31) ^ hash(self.executableType)
- value = (value * 31) ^ hash(self.providerName)
- value = (value * 31) ^ hash(self.userAccountName)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class JobSubmissionInterface:
- """
- Job Submission Interfaces
-
- jobSubmissionInterfaceId: The Job Submission Interface has to be previously registered and referenced here.
-
- priorityOrder:
- For resources with multiple interfaces, the priority order should be selected.
- Lower the numerical number, higher the priority
-
-
- Attributes:
- - jobSubmissionInterfaceId
- - jobSubmissionProtocol
- - priorityOrder
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'jobSubmissionInterfaceId', None, None, ), # 1
- (2, TType.I32, 'jobSubmissionProtocol', None, None, ), # 2
- (3, TType.I32, 'priorityOrder', None, 0, ), # 3
- )
-
- def __init__(self, jobSubmissionInterfaceId=None, jobSubmissionProtocol=None, priorityOrder=thrift_spec[3][4],):
- self.jobSubmissionInterfaceId = jobSubmissionInterfaceId
- self.jobSubmissionProtocol = jobSubmissionProtocol
- self.priorityOrder = priorityOrder
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.jobSubmissionInterfaceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.jobSubmissionProtocol = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.I32:
- self.priorityOrder = iprot.readI32()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('JobSubmissionInterface')
- if self.jobSubmissionInterfaceId is not None:
- oprot.writeFieldBegin('jobSubmissionInterfaceId', TType.STRING, 1)
- oprot.writeString(self.jobSubmissionInterfaceId)
- oprot.writeFieldEnd()
- if self.jobSubmissionProtocol is not None:
- oprot.writeFieldBegin('jobSubmissionProtocol', TType.I32, 2)
- oprot.writeI32(self.jobSubmissionProtocol)
- oprot.writeFieldEnd()
- if self.priorityOrder is not None:
- oprot.writeFieldBegin('priorityOrder', TType.I32, 3)
- oprot.writeI32(self.priorityOrder)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.jobSubmissionInterfaceId is None:
- raise TProtocol.TProtocolException(message='Required field jobSubmissionInterfaceId is unset!')
- if self.jobSubmissionProtocol is None:
- raise TProtocol.TProtocolException(message='Required field jobSubmissionProtocol is unset!')
- if self.priorityOrder is None:
- raise TProtocol.TProtocolException(message='Required field priorityOrder is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.jobSubmissionInterfaceId)
- value = (value * 31) ^ hash(self.jobSubmissionProtocol)
- value = (value * 31) ^ hash(self.priorityOrder)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ComputeResourceDescription:
- """
- Computational Resource Description
-
- computeResourceId: Airavata Internal Unique Identifier to distinguish Compute Resource.
-
- hostName:
- Fully Qualified Host Name.
-
- hostAliases:
- Aliases if any.
-
- ipAddress:
- IP Addresses of the Resource.
-
- resourceDescription:
- A user friendly description of the resource.
-
- JobSubmissionProtocols:
- A computational resources may have one or more ways of submitting Jobs. This structure
- will hold all available mechanisms to interact with the resource.
- The key is the priority
-
- DataMovementProtocol:
- Option to specify a prefered data movement mechanism of the available options.
-
- fileSystems:
- Map of file systems type and the path.
-
-
- Attributes:
- - computeResourceId
- - hostName
- - hostAliases
- - ipAddresses
- - resourceDescription
- - enabled
- - batchQueues
- - fileSystems
- - jobSubmissionInterfaces
- - dataMovementInterfaces
- - maxMemoryPerNode
- - gatewayUsageReporting
- - gatewayUsageModuleLoadCommand
- - gatewayUsageExecutable
- - cpusPerNode
- - defaultNodeCount
- - defaultCPUCount
- - defaultWalltime
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'computeResourceId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.STRING, 'hostName', None, None, ), # 2
- (3, TType.LIST, 'hostAliases', (TType.STRING,None), None, ), # 3
- (4, TType.LIST, 'ipAddresses', (TType.STRING,None), None, ), # 4
- (5, TType.STRING, 'resourceDescription', None, None, ), # 5
- (6, TType.BOOL, 'enabled', None, None, ), # 6
- (7, TType.LIST, 'batchQueues', (TType.STRUCT,(BatchQueue, BatchQueue.thrift_spec)), None, ), # 7
- (8, TType.MAP, 'fileSystems', (TType.I32,None,TType.STRING,None), None, ), # 8
- (9, TType.LIST, 'jobSubmissionInterfaces', (TType.STRUCT,(JobSubmissionInterface, JobSubmissionInterface.thrift_spec)), None, ), # 9
- (10, TType.LIST, 'dataMovementInterfaces', (TType.STRUCT,(apache.airavata.model.data.movement.ttypes.DataMovementInterface, apache.airavata.model.data.movement.ttypes.DataMovementInterface.thrift_spec)), None, ), # 10
- (11, TType.I32, 'maxMemoryPerNode', None, None, ), # 11
- (12, TType.BOOL, 'gatewayUsageReporting', None, None, ), # 12
- (13, TType.STRING, 'gatewayUsageModuleLoadCommand', None, None, ), # 13
- (14, TType.STRING, 'gatewayUsageExecutable', None, None, ), # 14
- (15, TType.I32, 'cpusPerNode', None, None, ), # 15
- (16, TType.I32, 'defaultNodeCount', None, None, ), # 16
- (17, TType.I32, 'defaultCPUCount', None, None, ), # 17
- (18, TType.I32, 'defaultWalltime', None, None, ), # 18
- )
-
- def __init__(self, computeResourceId=thrift_spec[1][4], hostName=None, hostAliases=None, ipAddresses=None, resourceDescription=None, enabled=None, batchQueues=None, fileSystems=None, jobSubmissionInterfaces=None, dataMovementInterfaces=None, maxMemoryPerNode=None, gatewayUsageReporting=None, gatewayUsageModuleLoadCommand=None, gatewayUsageExecutable=None, cpusPerNode=None, defaultNodeCount=None, defaultCPUCount=None, defaultWalltime=None,):
- self.computeResourceId = computeResourceId
- self.hostName = hostName
- self.hostAliases = hostAliases
- self.ipAddresses = ipAddresses
- self.resourceDescription = resourceDescription
- self.enabled = enabled
- self.batchQueues = batchQueues
- self.fileSystems = fileSystems
- self.jobSubmissionInterfaces = jobSubmissionInterfaces
- self.dataMovementInterfaces = dataMovementInterfaces
- self.maxMemoryPerNode = maxMemoryPerNode
- self.gatewayUsageReporting = gatewayUsageReporting
- self.gatewayUsageModuleLoadCommand = gatewayUsageModuleLoadCommand
- self.gatewayUsageExecutable = gatewayUsageExecutable
- self.cpusPerNode = cpusPerNode
- self.defaultNodeCount = defaultNodeCount
- self.defaultCPUCount = defaultCPUCount
- self.defaultWalltime = defaultWalltime
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.computeResourceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.hostName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.LIST:
- self.hostAliases = []
- (_etype35, _size32) = iprot.readListBegin()
- for _i36 in xrange(_size32):
- _elem37 = iprot.readString()
- self.hostAliases.append(_elem37)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.LIST:
- self.ipAddresses = []
- (_etype41, _size38) = iprot.readListBegin()
- for _i42 in xrange(_size38):
- _elem43 = iprot.readString()
- self.ipAddresses.append(_elem43)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.resourceDescription = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.BOOL:
- self.enabled = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.LIST:
- self.batchQueues = []
- (_etype47, _size44) = iprot.readListBegin()
- for _i48 in xrange(_size44):
- _elem49 = BatchQueue()
- _elem49.read(iprot)
- self.batchQueues.append(_elem49)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.MAP:
- self.fileSystems = {}
- (_ktype51, _vtype52, _size50 ) = iprot.readMapBegin()
- for _i54 in xrange(_size50):
- _key55 = iprot.readI32()
- _val56 = iprot.readString()
- self.fileSystems[_key55] = _val56
- iprot.readMapEnd()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.LIST:
- self.jobSubmissionInterfaces = []
- (_etype60, _size57) = iprot.readListBegin()
- for _i61 in xrange(_size57):
- _elem62 = JobSubmissionInterface()
- _elem62.read(iprot)
- self.jobSubmissionInterfaces.append(_elem62)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.LIST:
- self.dataMovementInterfaces = []
- (_etype66, _size63) = iprot.readListBegin()
- for _i67 in xrange(_size63):
- _elem68 = apache.airavata.model.data.movement.ttypes.DataMovementInterface()
- _elem68.read(iprot)
- self.dataMovementInterfaces.append(_elem68)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 11:
- if ftype == TType.I32:
- self.maxMemoryPerNode = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 12:
- if ftype == TType.BOOL:
- self.gatewayUsageReporting = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 13:
- if ftype == TType.STRING:
- self.gatewayUsageModuleLoadCommand = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 14:
- if ftype == TType.STRING:
- self.gatewayUsageExecutable = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 15:
- if ftype == TType.I32:
- self.cpusPerNode = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 16:
- if ftype == TType.I32:
- self.defaultNodeCount = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 17:
- if ftype == TType.I32:
- self.defaultCPUCount = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 18:
- if ftype == TType.I32:
- self.defaultWalltime = iprot.readI32()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ComputeResourceDescription')
- if self.computeResourceId is not None:
- oprot.writeFieldBegin('computeResourceId', TType.STRING, 1)
- oprot.writeString(self.computeResourceId)
- oprot.writeFieldEnd()
- if self.hostName is not None:
- oprot.writeFieldBegin('hostName', TType.STRING, 2)
- oprot.writeString(self.hostName)
- oprot.writeFieldEnd()
- if self.hostAliases is not None:
- oprot.writeFieldBegin('hostAliases', TType.LIST, 3)
- oprot.writeListBegin(TType.STRING, len(self.hostAliases))
- for iter69 in self.hostAliases:
- oprot.writeString(iter69)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.ipAddresses is not None:
- oprot.writeFieldBegin('ipAddresses', TType.LIST, 4)
- oprot.writeListBegin(TType.STRING, len(self.ipAddresses))
- for iter70 in self.ipAddresses:
- oprot.writeString(iter70)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.resourceDescription is not None:
- oprot.writeFieldBegin('resourceDescription', TType.STRING, 5)
- oprot.writeString(self.resourceDescription)
- oprot.writeFieldEnd()
- if self.enabled is not None:
- oprot.writeFieldBegin('enabled', TType.BOOL, 6)
- oprot.writeBool(self.enabled)
- oprot.writeFieldEnd()
- if self.batchQueues is not None:
- oprot.writeFieldBegin('batchQueues', TType.LIST, 7)
- oprot.writeListBegin(TType.STRUCT, len(self.batchQueues))
- for iter71 in self.batchQueues:
- iter71.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.fileSystems is not None:
- oprot.writeFieldBegin('fileSystems', TType.MAP, 8)
- oprot.writeMapBegin(TType.I32, TType.STRING, len(self.fileSystems))
- for kiter72,viter73 in self.fileSystems.items():
- oprot.writeI32(kiter72)
- oprot.writeString(viter73)
- oprot.writeMapEnd()
- oprot.writeFieldEnd()
- if self.jobSubmissionInterfaces is not None:
- oprot.writeFieldBegin('jobSubmissionInterfaces', TType.LIST, 9)
- oprot.writeListBegin(TType.STRUCT, len(self.jobSubmissionInterfaces))
- for iter74 in self.jobSubmissionInterfaces:
- iter74.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.dataMovementInterfaces is not None:
- oprot.writeFieldBegin('dataMovementInterfaces', TType.LIST, 10)
- oprot.writeListBegin(TType.STRUCT, len(self.dataMovementInterfaces))
- for iter75 in self.dataMovementInterfaces:
- iter75.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.maxMemoryPerNode is not None:
- oprot.writeFieldBegin('maxMemoryPerNode', TType.I32, 11)
- oprot.writeI32(self.maxMemoryPerNode)
- oprot.writeFieldEnd()
- if self.gatewayUsageReporting is not None:
- oprot.writeFieldBegin('gatewayUsageReporting', TType.BOOL, 12)
- oprot.writeBool(self.gatewayUsageReporting)
- oprot.writeFieldEnd()
- if self.gatewayUsageModuleLoadCommand is not None:
- oprot.writeFieldBegin('gatewayUsageModuleLoadCommand', TType.STRING, 13)
- oprot.writeString(self.gatewayUsageModuleLoadCommand)
- oprot.writeFieldEnd()
- if self.gatewayUsageExecutable is not None:
- oprot.writeFieldBegin('gatewayUsageExecutable', TType.STRING, 14)
- oprot.writeString(self.gatewayUsageExecutable)
- oprot.writeFieldEnd()
- if self.cpusPerNode is not None:
- oprot.writeFieldBegin('cpusPerNode', TType.I32, 15)
- oprot.writeI32(self.cpusPerNode)
- oprot.writeFieldEnd()
- if self.defaultNodeCount is not None:
- oprot.writeFieldBegin('defaultNodeCount', TType.I32, 16)
- oprot.writeI32(self.defaultNodeCount)
- oprot.writeFieldEnd()
- if self.defaultCPUCount is not None:
- oprot.writeFieldBegin('defaultCPUCount', TType.I32, 17)
- oprot.writeI32(self.defaultCPUCount)
- oprot.writeFieldEnd()
- if self.defaultWalltime is not None:
- oprot.writeFieldBegin('defaultWalltime', TType.I32, 18)
- oprot.writeI32(self.defaultWalltime)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.computeResourceId is None:
- raise TProtocol.TProtocolException(message='Required field computeResourceId is unset!')
- if self.hostName is None:
- raise TProtocol.TProtocolException(message='Required field hostName is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.computeResourceId)
- value = (value * 31) ^ hash(self.hostName)
- value = (value * 31) ^ hash(self.hostAliases)
- value = (value * 31) ^ hash(self.ipAddresses)
- value = (value * 31) ^ hash(self.resourceDescription)
- value = (value * 31) ^ hash(self.enabled)
- value = (value * 31) ^ hash(self.batchQueues)
- value = (value * 31) ^ hash(self.fileSystems)
- value = (value * 31) ^ hash(self.jobSubmissionInterfaces)
- value = (value * 31) ^ hash(self.dataMovementInterfaces)
- value = (value * 31) ^ hash(self.maxMemoryPerNode)
- value = (value * 31) ^ hash(self.gatewayUsageReporting)
- value = (value * 31) ^ hash(self.gatewayUsageModuleLoadCommand)
- value = (value * 31) ^ hash(self.gatewayUsageExecutable)
- value = (value * 31) ^ hash(self.cpusPerNode)
- value = (value * 31) ^ hash(self.defaultNodeCount)
- value = (value * 31) ^ hash(self.defaultCPUCount)
- value = (value * 31) ^ hash(self.defaultWalltime)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class ResourceJobManagerType(object):
+ """
+ * Enumeration of local resource job manager types supported by Airavata
+ *
+ * FORK:
+ * Forking of commands without any job manager
+ *
+ * PBS:
+ * Job manager supporting the Portal Batch System (PBS) protocol. Some examples include TORQUE, PBSPro, Grid Engine.
+ *
+ * SLURM:
+ * The Simple Linux Utility for Resource Management is a open source workload manager.
+ *
+ * UGE:
+ * Univa Grid Engine, a variation of PBS implementation.
+ *
+ * LSF:
+ * IBM Platform Load Sharing Facility is dominantly installed on IBM clusters.
+ *
+ """
+ FORK = 0
+ PBS = 1
+ SLURM = 2
+ LSF = 3
+ UGE = 4
+ CLOUD = 5
+ AIRAVATA_CUSTOM = 6
+
+ _VALUES_TO_NAMES = {
+ 0: "FORK",
+ 1: "PBS",
+ 2: "SLURM",
+ 3: "LSF",
+ 4: "UGE",
+ 5: "CLOUD",
+ 6: "AIRAVATA_CUSTOM",
+ }
+
+ _NAMES_TO_VALUES = {
+ "FORK": 0,
+ "PBS": 1,
+ "SLURM": 2,
+ "LSF": 3,
+ "UGE": 4,
+ "CLOUD": 5,
+ "AIRAVATA_CUSTOM": 6,
+ }
+
+
+class JobManagerCommand(object):
+ """
+ Enumeration of resource job manager commands
+
+ SUBMISSION:
+ Ex: qsub, sbatch
+
+ JOBMONITORING:
+ Ex: qstat, squeue
+
+ DELETION:
+ Ex: qdel, scancel
+
+ CHECK_JOB:
+ Detailed Status about the Job. Ex: checkjob
+
+ SHOW_QUEUE:
+ List of Queued Job by the schedular. Ex: showq
+
+ SHOW_RESERVATION:
+ List all reservations. Ex:showres, show_res
+
+ SHOW_START:
+ Display the start time of the specified job. Ex: showstart
+
+ """
+ SUBMISSION = 0
+ JOB_MONITORING = 1
+ DELETION = 2
+ CHECK_JOB = 3
+ SHOW_QUEUE = 4
+ SHOW_RESERVATION = 5
+ SHOW_START = 6
+
+ _VALUES_TO_NAMES = {
+ 0: "SUBMISSION",
+ 1: "JOB_MONITORING",
+ 2: "DELETION",
+ 3: "CHECK_JOB",
+ 4: "SHOW_QUEUE",
+ 5: "SHOW_RESERVATION",
+ 6: "SHOW_START",
+ }
+
+ _NAMES_TO_VALUES = {
+ "SUBMISSION": 0,
+ "JOB_MONITORING": 1,
+ "DELETION": 2,
+ "CHECK_JOB": 3,
+ "SHOW_QUEUE": 4,
+ "SHOW_RESERVATION": 5,
+ "SHOW_START": 6,
+ }
+
+
+class FileSystems(object):
+ """
+ Enumeration of File Systems on the resource
+
+ FORK:
+ Forking of commands without any job manager
+
+ PBS:
+ Job manager supporting the Portal Batch System (PBS) protocol. Some examples include TORQUE, PBSPro, Grid Engine.
+
+ UGE:
+ Univa Grid Engine, a variation of PBS implementation.
+
+ SLURM:
+ The Simple Linux Utility for Resource Management is a open source workload manager.
+
+ """
+ HOME = 0
+ WORK = 1
+ LOCALTMP = 2
+ SCRATCH = 3
+ ARCHIVE = 4
+
+ _VALUES_TO_NAMES = {
+ 0: "HOME",
+ 1: "WORK",
+ 2: "LOCALTMP",
+ 3: "SCRATCH",
+ 4: "ARCHIVE",
+ }
+
+ _NAMES_TO_VALUES = {
+ "HOME": 0,
+ "WORK": 1,
+ "LOCALTMP": 2,
+ "SCRATCH": 3,
+ "ARCHIVE": 4,
+ }
+
+
+class JobSubmissionProtocol(object):
+ """
+ Enumeration of Airavata supported Job Submission Mechanisms for High Performance Computing Clusters.
+
+ SSH:
+ Execute remote job submission commands using via secure shell protocol.
+
+ GRAM:
+ Execute remote jobs via Globus GRAM service.
+
+ UNICORE:
+ Execute remote jobs via Unicore services
+
+ """
+ LOCAL = 0
+ SSH = 1
+ GLOBUS = 2
+ UNICORE = 3
+ CLOUD = 4
+ SSH_FORK = 5
+ LOCAL_FORK = 6
+
+ _VALUES_TO_NAMES = {
+ 0: "LOCAL",
+ 1: "SSH",
+ 2: "GLOBUS",
+ 3: "UNICORE",
+ 4: "CLOUD",
+ 5: "SSH_FORK",
+ 6: "LOCAL_FORK",
+ }
+
+ _NAMES_TO_VALUES = {
+ "LOCAL": 0,
+ "SSH": 1,
+ "GLOBUS": 2,
+ "UNICORE": 3,
+ "CLOUD": 4,
+ "SSH_FORK": 5,
+ "LOCAL_FORK": 6,
+ }
+
+
+class MonitorMode(object):
+ """
+ Monitoring modes
+
+ POLL_JOB_MANAGER:
+ GFac need to pull job status changes.
+
+ XSEDE_AMQP_SUBSCRIBE:
+ Server will publish job status changes to amqp servert.
+
+
+ """
+ POLL_JOB_MANAGER = 0
+ CLOUD_JOB_MONITOR = 1
+ JOB_EMAIL_NOTIFICATION_MONITOR = 2
+ XSEDE_AMQP_SUBSCRIBE = 3
+ FORK = 4
+ LOCAL = 5
+
+ _VALUES_TO_NAMES = {
+ 0: "POLL_JOB_MANAGER",
+ 1: "CLOUD_JOB_MONITOR",
+ 2: "JOB_EMAIL_NOTIFICATION_MONITOR",
+ 3: "XSEDE_AMQP_SUBSCRIBE",
+ 4: "FORK",
+ 5: "LOCAL",
+ }
+
+ _NAMES_TO_VALUES = {
+ "POLL_JOB_MANAGER": 0,
+ "CLOUD_JOB_MONITOR": 1,
+ "JOB_EMAIL_NOTIFICATION_MONITOR": 2,
+ "XSEDE_AMQP_SUBSCRIBE": 3,
+ "FORK": 4,
+ "LOCAL": 5,
+ }
+
+
+class DMType(object):
+ COMPUTE_RESOURCE = 0
+ STORAGE_RESOURCE = 1
+
+ _VALUES_TO_NAMES = {
+ 0: "COMPUTE_RESOURCE",
+ 1: "STORAGE_RESOURCE",
+ }
+
+ _NAMES_TO_VALUES = {
+ "COMPUTE_RESOURCE": 0,
+ "STORAGE_RESOURCE": 1,
+ }
+
+
+class ProviderName(object):
+ """
+ Provider name
+
+ """
+ EC2 = 0
+ AWSEC2 = 1
+ RACKSPACE = 2
+
+ _VALUES_TO_NAMES = {
+ 0: "EC2",
+ 1: "AWSEC2",
+ 2: "RACKSPACE",
+ }
+
+ _NAMES_TO_VALUES = {
+ "EC2": 0,
+ "AWSEC2": 1,
+ "RACKSPACE": 2,
+ }
+
+
+class ResourceJobManager(object):
+ """
+ Resource Job Manager Information
+
+ resourceJobManagerType:
+ A typical HPC cluster has a single Job Manager to manage the resources.
+
+ pushMonitoringEndpoint:
+ If the job manager pushes out state changes to a database or bus, specify the service endpoint.
+ Ex: Moab Web Service, Moab MongoDB URL, AMQP (GLUE2) Broker
+
+ jobManagerBinPath:
+ Path to the Job Manager Installation Binary directory.
+
+ jobManagerCommands:
+ An enumeration of commonly used manager commands.
+
+
+ Attributes:
+ - resourceJobManagerId
+ - resourceJobManagerType
+ - pushMonitoringEndpoint
+ - jobManagerBinPath
+ - jobManagerCommands
+ - parallelismPrefix
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'resourceJobManagerId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.I32, 'resourceJobManagerType', None, None, ), # 2
+ (3, TType.STRING, 'pushMonitoringEndpoint', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'jobManagerBinPath', 'UTF8', None, ), # 4
+ (5, TType.MAP, 'jobManagerCommands', (TType.I32, None, TType.STRING, 'UTF8', False), None, ), # 5
+ (6, TType.MAP, 'parallelismPrefix', (TType.I32, None, TType.STRING, 'UTF8', False), None, ), # 6
+ )
+
+ def __init__(self, resourceJobManagerId=thrift_spec[1][4], resourceJobManagerType=None, pushMonitoringEndpoint=None, jobManagerBinPath=None, jobManagerCommands=None, parallelismPrefix=None,):
+ self.resourceJobManagerId = resourceJobManagerId
+ self.resourceJobManagerType = resourceJobManagerType
+ self.pushMonitoringEndpoint = pushMonitoringEndpoint
+ self.jobManagerBinPath = jobManagerBinPath
+ self.jobManagerCommands = jobManagerCommands
+ self.parallelismPrefix = parallelismPrefix
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.resourceJobManagerId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I32:
+ self.resourceJobManagerType = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.pushMonitoringEndpoint = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.jobManagerBinPath = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.MAP:
+ self.jobManagerCommands = {}
+ (_ktype1, _vtype2, _size0) = iprot.readMapBegin()
+ for _i4 in range(_size0):
+ _key5 = iprot.readI32()
+ _val6 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ self.jobManagerCommands[_key5] = _val6
+ iprot.readMapEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.MAP:
+ self.parallelismPrefix = {}
+ (_ktype8, _vtype9, _size7) = iprot.readMapBegin()
+ for _i11 in range(_size7):
+ _key12 = iprot.readI32()
+ _val13 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ self.parallelismPrefix[_key12] = _val13
+ iprot.readMapEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ResourceJobManager')
+ if self.resourceJobManagerId is not None:
+ oprot.writeFieldBegin('resourceJobManagerId', TType.STRING, 1)
+ oprot.writeString(self.resourceJobManagerId.encode('utf-8') if sys.version_info[0] == 2 else self.resourceJobManagerId)
+ oprot.writeFieldEnd()
+ if self.resourceJobManagerType is not None:
+ oprot.writeFieldBegin('resourceJobManagerType', TType.I32, 2)
+ oprot.writeI32(self.resourceJobManagerType)
+ oprot.writeFieldEnd()
+ if self.pushMonitoringEndpoint is not None:
+ oprot.writeFieldBegin('pushMonitoringEndpoint', TType.STRING, 3)
+ oprot.writeString(self.pushMonitoringEndpoint.encode('utf-8') if sys.version_info[0] == 2 else self.pushMonitoringEndpoint)
+ oprot.writeFieldEnd()
+ if self.jobManagerBinPath is not None:
+ oprot.writeFieldBegin('jobManagerBinPath', TType.STRING, 4)
+ oprot.writeString(self.jobManagerBinPath.encode('utf-8') if sys.version_info[0] == 2 else self.jobManagerBinPath)
+ oprot.writeFieldEnd()
+ if self.jobManagerCommands is not None:
+ oprot.writeFieldBegin('jobManagerCommands', TType.MAP, 5)
+ oprot.writeMapBegin(TType.I32, TType.STRING, len(self.jobManagerCommands))
+ for kiter14, viter15 in self.jobManagerCommands.items():
+ oprot.writeI32(kiter14)
+ oprot.writeString(viter15.encode('utf-8') if sys.version_info[0] == 2 else viter15)
+ oprot.writeMapEnd()
+ oprot.writeFieldEnd()
+ if self.parallelismPrefix is not None:
+ oprot.writeFieldBegin('parallelismPrefix', TType.MAP, 6)
+ oprot.writeMapBegin(TType.I32, TType.STRING, len(self.parallelismPrefix))
+ for kiter16, viter17 in self.parallelismPrefix.items():
+ oprot.writeI32(kiter16)
+ oprot.writeString(viter17.encode('utf-8') if sys.version_info[0] == 2 else viter17)
+ oprot.writeMapEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.resourceJobManagerId is None:
+ raise TProtocolException(message='Required field resourceJobManagerId is unset!')
+ if self.resourceJobManagerType is None:
+ raise TProtocolException(message='Required field resourceJobManagerType is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class BatchQueue(object):
+ """
+ Batch Queue Information on SuperComputers
+
+ maxRunTime:
+ Maximum allowed run time in hours.
+
+ Attributes:
+ - queueName
+ - queueDescription
+ - maxRunTime
+ - maxNodes
+ - maxProcessors
+ - maxJobsInQueue
+ - maxMemory
+ - cpuPerNode
+ - defaultNodeCount
+ - defaultCPUCount
+ - defaultWalltime
+ - queueSpecificMacros
+ - isDefaultQueue
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'queueName', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'queueDescription', 'UTF8', None, ), # 2
+ (3, TType.I32, 'maxRunTime', None, None, ), # 3
+ (4, TType.I32, 'maxNodes', None, None, ), # 4
+ (5, TType.I32, 'maxProcessors', None, None, ), # 5
+ (6, TType.I32, 'maxJobsInQueue', None, None, ), # 6
+ (7, TType.I32, 'maxMemory', None, None, ), # 7
+ (8, TType.I32, 'cpuPerNode', None, None, ), # 8
+ (9, TType.I32, 'defaultNodeCount', None, None, ), # 9
+ (10, TType.I32, 'defaultCPUCount', None, None, ), # 10
+ (11, TType.I32, 'defaultWalltime', None, None, ), # 11
+ (12, TType.STRING, 'queueSpecificMacros', 'UTF8', None, ), # 12
+ (13, TType.BOOL, 'isDefaultQueue', None, None, ), # 13
+ )
+
+ def __init__(self, queueName=None, queueDescription=None, maxRunTime=None, maxNodes=None, maxProcessors=None, maxJobsInQueue=None, maxMemory=None, cpuPerNode=None, defaultNodeCount=None, defaultCPUCount=None, defaultWalltime=None, queueSpecificMacros=None, isDefaultQueue=None,):
+ self.queueName = queueName
+ self.queueDescription = queueDescription
+ self.maxRunTime = maxRunTime
+ self.maxNodes = maxNodes
+ self.maxProcessors = maxProcessors
+ self.maxJobsInQueue = maxJobsInQueue
+ self.maxMemory = maxMemory
+ self.cpuPerNode = cpuPerNode
+ self.defaultNodeCount = defaultNodeCount
+ self.defaultCPUCount = defaultCPUCount
+ self.defaultWalltime = defaultWalltime
+ self.queueSpecificMacros = queueSpecificMacros
+ self.isDefaultQueue = isDefaultQueue
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.queueName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.queueDescription = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I32:
+ self.maxRunTime = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.I32:
+ self.maxNodes = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.I32:
+ self.maxProcessors = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.I32:
+ self.maxJobsInQueue = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.I32:
+ self.maxMemory = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.I32:
+ self.cpuPerNode = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.I32:
+ self.defaultNodeCount = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.I32:
+ self.defaultCPUCount = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 11:
+ if ftype == TType.I32:
+ self.defaultWalltime = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 12:
+ if ftype == TType.STRING:
+ self.queueSpecificMacros = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 13:
+ if ftype == TType.BOOL:
+ self.isDefaultQueue = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('BatchQueue')
+ if self.queueName is not None:
+ oprot.writeFieldBegin('queueName', TType.STRING, 1)
+ oprot.writeString(self.queueName.encode('utf-8') if sys.version_info[0] == 2 else self.queueName)
+ oprot.writeFieldEnd()
+ if self.queueDescription is not None:
+ oprot.writeFieldBegin('queueDescription', TType.STRING, 2)
+ oprot.writeString(self.queueDescription.encode('utf-8') if sys.version_info[0] == 2 else self.queueDescription)
+ oprot.writeFieldEnd()
+ if self.maxRunTime is not None:
+ oprot.writeFieldBegin('maxRunTime', TType.I32, 3)
+ oprot.writeI32(self.maxRunTime)
+ oprot.writeFieldEnd()
+ if self.maxNodes is not None:
+ oprot.writeFieldBegin('maxNodes', TType.I32, 4)
+ oprot.writeI32(self.maxNodes)
+ oprot.writeFieldEnd()
+ if self.maxProcessors is not None:
+ oprot.writeFieldBegin('maxProcessors', TType.I32, 5)
+ oprot.writeI32(self.maxProcessors)
+ oprot.writeFieldEnd()
+ if self.maxJobsInQueue is not None:
+ oprot.writeFieldBegin('maxJobsInQueue', TType.I32, 6)
+ oprot.writeI32(self.maxJobsInQueue)
+ oprot.writeFieldEnd()
+ if self.maxMemory is not None:
+ oprot.writeFieldBegin('maxMemory', TType.I32, 7)
+ oprot.writeI32(self.maxMemory)
+ oprot.writeFieldEnd()
+ if self.cpuPerNode is not None:
+ oprot.writeFieldBegin('cpuPerNode', TType.I32, 8)
+ oprot.writeI32(self.cpuPerNode)
+ oprot.writeFieldEnd()
+ if self.defaultNodeCount is not None:
+ oprot.writeFieldBegin('defaultNodeCount', TType.I32, 9)
+ oprot.writeI32(self.defaultNodeCount)
+ oprot.writeFieldEnd()
+ if self.defaultCPUCount is not None:
+ oprot.writeFieldBegin('defaultCPUCount', TType.I32, 10)
+ oprot.writeI32(self.defaultCPUCount)
+ oprot.writeFieldEnd()
+ if self.defaultWalltime is not None:
+ oprot.writeFieldBegin('defaultWalltime', TType.I32, 11)
+ oprot.writeI32(self.defaultWalltime)
+ oprot.writeFieldEnd()
+ if self.queueSpecificMacros is not None:
+ oprot.writeFieldBegin('queueSpecificMacros', TType.STRING, 12)
+ oprot.writeString(self.queueSpecificMacros.encode('utf-8') if sys.version_info[0] == 2 else self.queueSpecificMacros)
+ oprot.writeFieldEnd()
+ if self.isDefaultQueue is not None:
+ oprot.writeFieldBegin('isDefaultQueue', TType.BOOL, 13)
+ oprot.writeBool(self.isDefaultQueue)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.queueName is None:
+ raise TProtocolException(message='Required field queueName is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class LOCALSubmission(object):
+ """
+ Locally Fork Jobs as OS processes
+
+ alternativeSSHHostName:
+ If the login to ssh is different than the hostname itself, specify it here
+
+ sshPort:
+ If a non-default port needs to used, specify it.
+
+ Attributes:
+ - jobSubmissionInterfaceId
+ - resourceJobManager
+ - securityProtocol
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'jobSubmissionInterfaceId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.STRUCT, 'resourceJobManager', (ResourceJobManager, ResourceJobManager.thrift_spec), None, ), # 2
+ (3, TType.I32, 'securityProtocol', None, None, ), # 3
+ )
+
+ def __init__(self, jobSubmissionInterfaceId=thrift_spec[1][4], resourceJobManager=None, securityProtocol=None,):
+ self.jobSubmissionInterfaceId = jobSubmissionInterfaceId
+ self.resourceJobManager = resourceJobManager
+ self.securityProtocol = securityProtocol
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.jobSubmissionInterfaceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRUCT:
+ self.resourceJobManager = ResourceJobManager()
+ self.resourceJobManager.read(iprot)
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I32:
+ self.securityProtocol = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('LOCALSubmission')
+ if self.jobSubmissionInterfaceId is not None:
+ oprot.writeFieldBegin('jobSubmissionInterfaceId', TType.STRING, 1)
+ oprot
<TRUNCATED>
[32/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/status/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/status/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/status/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/status/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/status/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/status/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/status/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/status/ttypes.py
index f3bae9c..cd26873 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/status/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/status/ttypes.py
@@ -1,684 +1,645 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class ExperimentState:
- CREATED = 0
- VALIDATED = 1
- SCHEDULED = 2
- LAUNCHED = 3
- EXECUTING = 4
- CANCELING = 5
- CANCELED = 6
- COMPLETED = 7
- FAILED = 8
-
- _VALUES_TO_NAMES = {
- 0: "CREATED",
- 1: "VALIDATED",
- 2: "SCHEDULED",
- 3: "LAUNCHED",
- 4: "EXECUTING",
- 5: "CANCELING",
- 6: "CANCELED",
- 7: "COMPLETED",
- 8: "FAILED",
- }
-
- _NAMES_TO_VALUES = {
- "CREATED": 0,
- "VALIDATED": 1,
- "SCHEDULED": 2,
- "LAUNCHED": 3,
- "EXECUTING": 4,
- "CANCELING": 5,
- "CANCELED": 6,
- "COMPLETED": 7,
- "FAILED": 8,
- }
-
-class TaskState:
- CREATED = 0
- EXECUTING = 1
- COMPLETED = 2
- FAILED = 3
- CANCELED = 4
-
- _VALUES_TO_NAMES = {
- 0: "CREATED",
- 1: "EXECUTING",
- 2: "COMPLETED",
- 3: "FAILED",
- 4: "CANCELED",
- }
-
- _NAMES_TO_VALUES = {
- "CREATED": 0,
- "EXECUTING": 1,
- "COMPLETED": 2,
- "FAILED": 3,
- "CANCELED": 4,
- }
-
-class ProcessState:
- CREATED = 0
- VALIDATED = 1
- STARTED = 2
- PRE_PROCESSING = 3
- CONFIGURING_WORKSPACE = 4
- INPUT_DATA_STAGING = 5
- EXECUTING = 6
- MONITORING = 7
- OUTPUT_DATA_STAGING = 8
- POST_PROCESSING = 9
- COMPLETED = 10
- FAILED = 11
- CANCELLING = 12
- CANCELED = 13
-
- _VALUES_TO_NAMES = {
- 0: "CREATED",
- 1: "VALIDATED",
- 2: "STARTED",
- 3: "PRE_PROCESSING",
- 4: "CONFIGURING_WORKSPACE",
- 5: "INPUT_DATA_STAGING",
- 6: "EXECUTING",
- 7: "MONITORING",
- 8: "OUTPUT_DATA_STAGING",
- 9: "POST_PROCESSING",
- 10: "COMPLETED",
- 11: "FAILED",
- 12: "CANCELLING",
- 13: "CANCELED",
- }
-
- _NAMES_TO_VALUES = {
- "CREATED": 0,
- "VALIDATED": 1,
- "STARTED": 2,
- "PRE_PROCESSING": 3,
- "CONFIGURING_WORKSPACE": 4,
- "INPUT_DATA_STAGING": 5,
- "EXECUTING": 6,
- "MONITORING": 7,
- "OUTPUT_DATA_STAGING": 8,
- "POST_PROCESSING": 9,
- "COMPLETED": 10,
- "FAILED": 11,
- "CANCELLING": 12,
- "CANCELED": 13,
- }
-
-class JobState:
- SUBMITTED = 0
- QUEUED = 1
- ACTIVE = 2
- COMPLETE = 3
- CANCELED = 4
- FAILED = 5
- SUSPENDED = 6
- UNKNOWN = 7
-
- _VALUES_TO_NAMES = {
- 0: "SUBMITTED",
- 1: "QUEUED",
- 2: "ACTIVE",
- 3: "COMPLETE",
- 4: "CANCELED",
- 5: "FAILED",
- 6: "SUSPENDED",
- 7: "UNKNOWN",
- }
-
- _NAMES_TO_VALUES = {
- "SUBMITTED": 0,
- "QUEUED": 1,
- "ACTIVE": 2,
- "COMPLETE": 3,
- "CANCELED": 4,
- "FAILED": 5,
- "SUSPENDED": 6,
- "UNKNOWN": 7,
- }
-
-
-class ExperimentStatus:
- """
- Status: A generic status object.
-
- state:
- State .
-
- timeOfStateChange:
- time the status was last updated.
-
- reason:
- User friendly reason on how the state is inferred.
-
-
- Attributes:
- - state
- - timeOfStateChange
- - reason
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'state', None, None, ), # 1
- (2, TType.I64, 'timeOfStateChange', None, None, ), # 2
- (3, TType.STRING, 'reason', None, None, ), # 3
- )
-
- def __init__(self, state=None, timeOfStateChange=None, reason=None,):
- self.state = state
- self.timeOfStateChange = timeOfStateChange
- self.reason = reason
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.state = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I64:
- self.timeOfStateChange = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.reason = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ExperimentStatus')
- if self.state is not None:
- oprot.writeFieldBegin('state', TType.I32, 1)
- oprot.writeI32(self.state)
- oprot.writeFieldEnd()
- if self.timeOfStateChange is not None:
- oprot.writeFieldBegin('timeOfStateChange', TType.I64, 2)
- oprot.writeI64(self.timeOfStateChange)
- oprot.writeFieldEnd()
- if self.reason is not None:
- oprot.writeFieldBegin('reason', TType.STRING, 3)
- oprot.writeString(self.reason)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.state is None:
- raise TProtocol.TProtocolException(message='Required field state is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.state)
- value = (value * 31) ^ hash(self.timeOfStateChange)
- value = (value * 31) ^ hash(self.reason)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ProcessStatus:
- """
- Attributes:
- - state
- - timeOfStateChange
- - reason
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'state', None, None, ), # 1
- (2, TType.I64, 'timeOfStateChange', None, None, ), # 2
- (3, TType.STRING, 'reason', None, None, ), # 3
- )
-
- def __init__(self, state=None, timeOfStateChange=None, reason=None,):
- self.state = state
- self.timeOfStateChange = timeOfStateChange
- self.reason = reason
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.state = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I64:
- self.timeOfStateChange = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.reason = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ProcessStatus')
- if self.state is not None:
- oprot.writeFieldBegin('state', TType.I32, 1)
- oprot.writeI32(self.state)
- oprot.writeFieldEnd()
- if self.timeOfStateChange is not None:
- oprot.writeFieldBegin('timeOfStateChange', TType.I64, 2)
- oprot.writeI64(self.timeOfStateChange)
- oprot.writeFieldEnd()
- if self.reason is not None:
- oprot.writeFieldBegin('reason', TType.STRING, 3)
- oprot.writeString(self.reason)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.state is None:
- raise TProtocol.TProtocolException(message='Required field state is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.state)
- value = (value * 31) ^ hash(self.timeOfStateChange)
- value = (value * 31) ^ hash(self.reason)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class TaskStatus:
- """
- Attributes:
- - state
- - timeOfStateChange
- - reason
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'state', None, None, ), # 1
- (2, TType.I64, 'timeOfStateChange', None, None, ), # 2
- (3, TType.STRING, 'reason', None, None, ), # 3
- )
-
- def __init__(self, state=None, timeOfStateChange=None, reason=None,):
- self.state = state
- self.timeOfStateChange = timeOfStateChange
- self.reason = reason
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.state = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I64:
- self.timeOfStateChange = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.reason = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('TaskStatus')
- if self.state is not None:
- oprot.writeFieldBegin('state', TType.I32, 1)
- oprot.writeI32(self.state)
- oprot.writeFieldEnd()
- if self.timeOfStateChange is not None:
- oprot.writeFieldBegin('timeOfStateChange', TType.I64, 2)
- oprot.writeI64(self.timeOfStateChange)
- oprot.writeFieldEnd()
- if self.reason is not None:
- oprot.writeFieldBegin('reason', TType.STRING, 3)
- oprot.writeString(self.reason)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.state is None:
- raise TProtocol.TProtocolException(message='Required field state is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.state)
- value = (value * 31) ^ hash(self.timeOfStateChange)
- value = (value * 31) ^ hash(self.reason)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class JobStatus:
- """
- Attributes:
- - jobState
- - timeOfStateChange
- - reason
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'jobState', None, None, ), # 1
- (2, TType.I64, 'timeOfStateChange', None, None, ), # 2
- (3, TType.STRING, 'reason', None, None, ), # 3
- )
-
- def __init__(self, jobState=None, timeOfStateChange=None, reason=None,):
- self.jobState = jobState
- self.timeOfStateChange = timeOfStateChange
- self.reason = reason
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.jobState = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I64:
- self.timeOfStateChange = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.reason = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('JobStatus')
- if self.jobState is not None:
- oprot.writeFieldBegin('jobState', TType.I32, 1)
- oprot.writeI32(self.jobState)
- oprot.writeFieldEnd()
- if self.timeOfStateChange is not None:
- oprot.writeFieldBegin('timeOfStateChange', TType.I64, 2)
- oprot.writeI64(self.timeOfStateChange)
- oprot.writeFieldEnd()
- if self.reason is not None:
- oprot.writeFieldBegin('reason', TType.STRING, 3)
- oprot.writeString(self.reason)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.jobState is None:
- raise TProtocol.TProtocolException(message='Required field jobState is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.jobState)
- value = (value * 31) ^ hash(self.timeOfStateChange)
- value = (value * 31) ^ hash(self.reason)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class QueueStatusModel:
- """
- Attributes:
- - hostName
- - queueName
- - queueUp
- - runningJobs
- - queuedJobs
- - time
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'hostName', None, None, ), # 1
- (2, TType.STRING, 'queueName', None, None, ), # 2
- (3, TType.BOOL, 'queueUp', None, None, ), # 3
- (4, TType.I32, 'runningJobs', None, None, ), # 4
- (5, TType.I32, 'queuedJobs', None, None, ), # 5
- (6, TType.I64, 'time', None, None, ), # 6
- )
-
- def __init__(self, hostName=None, queueName=None, queueUp=None, runningJobs=None, queuedJobs=None, time=None,):
- self.hostName = hostName
- self.queueName = queueName
- self.queueUp = queueUp
- self.runningJobs = runningJobs
- self.queuedJobs = queuedJobs
- self.time = time
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.hostName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.queueName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.BOOL:
- self.queueUp = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.I32:
- self.runningJobs = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I32:
- self.queuedJobs = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.I64:
- self.time = iprot.readI64()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('QueueStatusModel')
- if self.hostName is not None:
- oprot.writeFieldBegin('hostName', TType.STRING, 1)
- oprot.writeString(self.hostName)
- oprot.writeFieldEnd()
- if self.queueName is not None:
- oprot.writeFieldBegin('queueName', TType.STRING, 2)
- oprot.writeString(self.queueName)
- oprot.writeFieldEnd()
- if self.queueUp is not None:
- oprot.writeFieldBegin('queueUp', TType.BOOL, 3)
- oprot.writeBool(self.queueUp)
- oprot.writeFieldEnd()
- if self.runningJobs is not None:
- oprot.writeFieldBegin('runningJobs', TType.I32, 4)
- oprot.writeI32(self.runningJobs)
- oprot.writeFieldEnd()
- if self.queuedJobs is not None:
- oprot.writeFieldBegin('queuedJobs', TType.I32, 5)
- oprot.writeI32(self.queuedJobs)
- oprot.writeFieldEnd()
- if self.time is not None:
- oprot.writeFieldBegin('time', TType.I64, 6)
- oprot.writeI64(self.time)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.hostName is None:
- raise TProtocol.TProtocolException(message='Required field hostName is unset!')
- if self.queueName is None:
- raise TProtocol.TProtocolException(message='Required field queueName is unset!')
- if self.queueUp is None:
- raise TProtocol.TProtocolException(message='Required field queueUp is unset!')
- if self.runningJobs is None:
- raise TProtocol.TProtocolException(message='Required field runningJobs is unset!')
- if self.queuedJobs is None:
- raise TProtocol.TProtocolException(message='Required field queuedJobs is unset!')
- if self.time is None:
- raise TProtocol.TProtocolException(message='Required field time is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.hostName)
- value = (value * 31) ^ hash(self.queueName)
- value = (value * 31) ^ hash(self.queueUp)
- value = (value * 31) ^ hash(self.runningJobs)
- value = (value * 31) ^ hash(self.queuedJobs)
- value = (value * 31) ^ hash(self.time)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class ExperimentState(object):
+ CREATED = 0
+ VALIDATED = 1
+ SCHEDULED = 2
+ LAUNCHED = 3
+ EXECUTING = 4
+ CANCELING = 5
+ CANCELED = 6
+ COMPLETED = 7
+ FAILED = 8
+
+ _VALUES_TO_NAMES = {
+ 0: "CREATED",
+ 1: "VALIDATED",
+ 2: "SCHEDULED",
+ 3: "LAUNCHED",
+ 4: "EXECUTING",
+ 5: "CANCELING",
+ 6: "CANCELED",
+ 7: "COMPLETED",
+ 8: "FAILED",
+ }
+
+ _NAMES_TO_VALUES = {
+ "CREATED": 0,
+ "VALIDATED": 1,
+ "SCHEDULED": 2,
+ "LAUNCHED": 3,
+ "EXECUTING": 4,
+ "CANCELING": 5,
+ "CANCELED": 6,
+ "COMPLETED": 7,
+ "FAILED": 8,
+ }
+
+
+class TaskState(object):
+ CREATED = 0
+ EXECUTING = 1
+ COMPLETED = 2
+ FAILED = 3
+ CANCELED = 4
+
+ _VALUES_TO_NAMES = {
+ 0: "CREATED",
+ 1: "EXECUTING",
+ 2: "COMPLETED",
+ 3: "FAILED",
+ 4: "CANCELED",
+ }
+
+ _NAMES_TO_VALUES = {
+ "CREATED": 0,
+ "EXECUTING": 1,
+ "COMPLETED": 2,
+ "FAILED": 3,
+ "CANCELED": 4,
+ }
+
+
+class ProcessState(object):
+ CREATED = 0
+ VALIDATED = 1
+ STARTED = 2
+ PRE_PROCESSING = 3
+ CONFIGURING_WORKSPACE = 4
+ INPUT_DATA_STAGING = 5
+ EXECUTING = 6
+ MONITORING = 7
+ OUTPUT_DATA_STAGING = 8
+ POST_PROCESSING = 9
+ COMPLETED = 10
+ FAILED = 11
+ CANCELLING = 12
+ CANCELED = 13
+
+ _VALUES_TO_NAMES = {
+ 0: "CREATED",
+ 1: "VALIDATED",
+ 2: "STARTED",
+ 3: "PRE_PROCESSING",
+ 4: "CONFIGURING_WORKSPACE",
+ 5: "INPUT_DATA_STAGING",
+ 6: "EXECUTING",
+ 7: "MONITORING",
+ 8: "OUTPUT_DATA_STAGING",
+ 9: "POST_PROCESSING",
+ 10: "COMPLETED",
+ 11: "FAILED",
+ 12: "CANCELLING",
+ 13: "CANCELED",
+ }
+
+ _NAMES_TO_VALUES = {
+ "CREATED": 0,
+ "VALIDATED": 1,
+ "STARTED": 2,
+ "PRE_PROCESSING": 3,
+ "CONFIGURING_WORKSPACE": 4,
+ "INPUT_DATA_STAGING": 5,
+ "EXECUTING": 6,
+ "MONITORING": 7,
+ "OUTPUT_DATA_STAGING": 8,
+ "POST_PROCESSING": 9,
+ "COMPLETED": 10,
+ "FAILED": 11,
+ "CANCELLING": 12,
+ "CANCELED": 13,
+ }
+
+
+class JobState(object):
+ SUBMITTED = 0
+ QUEUED = 1
+ ACTIVE = 2
+ COMPLETE = 3
+ CANCELED = 4
+ FAILED = 5
+ SUSPENDED = 6
+ UNKNOWN = 7
+
+ _VALUES_TO_NAMES = {
+ 0: "SUBMITTED",
+ 1: "QUEUED",
+ 2: "ACTIVE",
+ 3: "COMPLETE",
+ 4: "CANCELED",
+ 5: "FAILED",
+ 6: "SUSPENDED",
+ 7: "UNKNOWN",
+ }
+
+ _NAMES_TO_VALUES = {
+ "SUBMITTED": 0,
+ "QUEUED": 1,
+ "ACTIVE": 2,
+ "COMPLETE": 3,
+ "CANCELED": 4,
+ "FAILED": 5,
+ "SUSPENDED": 6,
+ "UNKNOWN": 7,
+ }
+
+
+class ExperimentStatus(object):
+ """
+ Status: A generic status object.
+
+ state:
+ State .
+
+ timeOfStateChange:
+ time the status was last updated.
+
+ reason:
+ User friendly reason on how the state is inferred.
+
+
+ Attributes:
+ - state
+ - timeOfStateChange
+ - reason
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'state', None, None, ), # 1
+ (2, TType.I64, 'timeOfStateChange', None, None, ), # 2
+ (3, TType.STRING, 'reason', 'UTF8', None, ), # 3
+ )
+
+ def __init__(self, state=None, timeOfStateChange=None, reason=None,):
+ self.state = state
+ self.timeOfStateChange = timeOfStateChange
+ self.reason = reason
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.state = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I64:
+ self.timeOfStateChange = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.reason = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ExperimentStatus')
+ if self.state is not None:
+ oprot.writeFieldBegin('state', TType.I32, 1)
+ oprot.writeI32(self.state)
+ oprot.writeFieldEnd()
+ if self.timeOfStateChange is not None:
+ oprot.writeFieldBegin('timeOfStateChange', TType.I64, 2)
+ oprot.writeI64(self.timeOfStateChange)
+ oprot.writeFieldEnd()
+ if self.reason is not None:
+ oprot.writeFieldBegin('reason', TType.STRING, 3)
+ oprot.writeString(self.reason.encode('utf-8') if sys.version_info[0] == 2 else self.reason)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.state is None:
+ raise TProtocolException(message='Required field state is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class ProcessStatus(object):
+ """
+ Attributes:
+ - state
+ - timeOfStateChange
+ - reason
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'state', None, None, ), # 1
+ (2, TType.I64, 'timeOfStateChange', None, None, ), # 2
+ (3, TType.STRING, 'reason', 'UTF8', None, ), # 3
+ )
+
+ def __init__(self, state=None, timeOfStateChange=None, reason=None,):
+ self.state = state
+ self.timeOfStateChange = timeOfStateChange
+ self.reason = reason
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.state = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I64:
+ self.timeOfStateChange = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.reason = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ProcessStatus')
+ if self.state is not None:
+ oprot.writeFieldBegin('state', TType.I32, 1)
+ oprot.writeI32(self.state)
+ oprot.writeFieldEnd()
+ if self.timeOfStateChange is not None:
+ oprot.writeFieldBegin('timeOfStateChange', TType.I64, 2)
+ oprot.writeI64(self.timeOfStateChange)
+ oprot.writeFieldEnd()
+ if self.reason is not None:
+ oprot.writeFieldBegin('reason', TType.STRING, 3)
+ oprot.writeString(self.reason.encode('utf-8') if sys.version_info[0] == 2 else self.reason)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.state is None:
+ raise TProtocolException(message='Required field state is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class TaskStatus(object):
+ """
+ Attributes:
+ - state
+ - timeOfStateChange
+ - reason
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'state', None, None, ), # 1
+ (2, TType.I64, 'timeOfStateChange', None, None, ), # 2
+ (3, TType.STRING, 'reason', 'UTF8', None, ), # 3
+ )
+
+ def __init__(self, state=None, timeOfStateChange=None, reason=None,):
+ self.state = state
+ self.timeOfStateChange = timeOfStateChange
+ self.reason = reason
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.state = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I64:
+ self.timeOfStateChange = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.reason = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('TaskStatus')
+ if self.state is not None:
+ oprot.writeFieldBegin('state', TType.I32, 1)
+ oprot.writeI32(self.state)
+ oprot.writeFieldEnd()
+ if self.timeOfStateChange is not None:
+ oprot.writeFieldBegin('timeOfStateChange', TType.I64, 2)
+ oprot.writeI64(self.timeOfStateChange)
+ oprot.writeFieldEnd()
+ if self.reason is not None:
+ oprot.writeFieldBegin('reason', TType.STRING, 3)
+ oprot.writeString(self.reason.encode('utf-8') if sys.version_info[0] == 2 else self.reason)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.state is None:
+ raise TProtocolException(message='Required field state is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class JobStatus(object):
+ """
+ Attributes:
+ - jobState
+ - timeOfStateChange
+ - reason
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'jobState', None, None, ), # 1
+ (2, TType.I64, 'timeOfStateChange', None, None, ), # 2
+ (3, TType.STRING, 'reason', 'UTF8', None, ), # 3
+ )
+
+ def __init__(self, jobState=None, timeOfStateChange=None, reason=None,):
+ self.jobState = jobState
+ self.timeOfStateChange = timeOfStateChange
+ self.reason = reason
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.jobState = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I64:
+ self.timeOfStateChange = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.reason = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('JobStatus')
+ if self.jobState is not None:
+ oprot.writeFieldBegin('jobState', TType.I32, 1)
+ oprot.writeI32(self.jobState)
+ oprot.writeFieldEnd()
+ if self.timeOfStateChange is not None:
+ oprot.writeFieldBegin('timeOfStateChange', TType.I64, 2)
+ oprot.writeI64(self.timeOfStateChange)
+ oprot.writeFieldEnd()
+ if self.reason is not None:
+ oprot.writeFieldBegin('reason', TType.STRING, 3)
+ oprot.writeString(self.reason.encode('utf-8') if sys.version_info[0] == 2 else self.reason)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.jobState is None:
+ raise TProtocolException(message='Required field jobState is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class QueueStatusModel(object):
+ """
+ Attributes:
+ - hostName
+ - queueName
+ - queueUp
+ - runningJobs
+ - queuedJobs
+ - time
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'hostName', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'queueName', 'UTF8', None, ), # 2
+ (3, TType.BOOL, 'queueUp', None, None, ), # 3
+ (4, TType.I32, 'runningJobs', None, None, ), # 4
+ (5, TType.I32, 'queuedJobs', None, None, ), # 5
+ (6, TType.I64, 'time', None, None, ), # 6
+ )
+
+ def __init__(self, hostName=None, queueName=None, queueUp=None, runningJobs=None, queuedJobs=None, time=None,):
+ self.hostName = hostName
+ self.queueName = queueName
+ self.queueUp = queueUp
+ self.runningJobs = runningJobs
+ self.queuedJobs = queuedJobs
+ self.time = time
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.hostName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.queueName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.BOOL:
+ self.queueUp = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.I32:
+ self.runningJobs = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.I32:
+ self.queuedJobs = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.I64:
+ self.time = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('QueueStatusModel')
+ if self.hostName is not None:
+ oprot.writeFieldBegin('hostName', TType.STRING, 1)
+ oprot.writeString(self.hostName.encode('utf-8') if sys.version_info[0] == 2 else self.hostName)
+ oprot.writeFieldEnd()
+ if self.queueName is not None:
+ oprot.writeFieldBegin('queueName', TType.STRING, 2)
+ oprot.writeString(self.queueName.encode('utf-8') if sys.version_info[0] == 2 else self.queueName)
+ oprot.writeFieldEnd()
+ if self.queueUp is not None:
+ oprot.writeFieldBegin('queueUp', TType.BOOL, 3)
+ oprot.writeBool(self.queueUp)
+ oprot.writeFieldEnd()
+ if self.runningJobs is not None:
+ oprot.writeFieldBegin('runningJobs', TType.I32, 4)
+ oprot.writeI32(self.runningJobs)
+ oprot.writeFieldEnd()
+ if self.queuedJobs is not None:
+ oprot.writeFieldBegin('queuedJobs', TType.I32, 5)
+ oprot.writeI32(self.queuedJobs)
+ oprot.writeFieldEnd()
+ if self.time is not None:
+ oprot.writeFieldBegin('time', TType.I64, 6)
+ oprot.writeI64(self.time)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.hostName is None:
+ raise TProtocolException(message='Required field hostName is unset!')
+ if self.queueName is None:
+ raise TProtocolException(message='Required field queueName is unset!')
+ if self.queueUp is None:
+ raise TProtocolException(message='Required field queueUp is unset!')
+ if self.runningJobs is None:
+ raise TProtocolException(message='Required field runningJobs is unset!')
+ if self.queuedJobs is None:
+ raise TProtocolException(message='Required field queuedJobs is unset!')
+ if self.time is None:
+ raise TProtocolException(message='Required field time is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/task/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/task/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/task/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/task/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/task/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
[40/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/userresourceprofile/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/userresourceprofile/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/userresourceprofile/ttypes.py
index 5903ba0..1ce8736 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/userresourceprofile/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/userresourceprofile/ttypes.py
@@ -1,538 +1,498 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.appcatalog.computeresource.ttypes
import apache.airavata.model.data.movement.ttypes
import apache.airavata.model.user.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-
-class UserComputeResourcePreference:
- """
- User specific preferences for a Computer Resource
-
- computeResourceId:
- Corelate the preference to a compute resource.
-
-
- loginUserName:
- If turned true, Airavata will override the preferences of better alternatives exist.
-
-
- preferredBatchQueue:
- Gateways can choose a defualt batch queue based on average job dimention, reservations or other metrics.
-
- scratchLocation:
- Path to the local scratch space on a HPC cluster. Typically used to create working directory for job execution.
-
- allocationProjectNumber:
- Typically used on HPC machines to charge computing usage to a account number. For instance, on XSEDE once an
- allocation is approved, an allocation number is assigned. Before passing this number with job submittions, the
- account to be used has to be added to the allocation.
-
- resourceSpecificCredentialStoreToken:
- Resource specific credential store token. If this token is specified, then it is superceeded by the gateway's
- default credential store.
-
-
- Attributes:
- - computeResourceId
- - loginUserName
- - preferredBatchQueue
- - scratchLocation
- - allocationProjectNumber
- - resourceSpecificCredentialStoreToken
- - qualityOfService
- - reservation
- - reservationStartTime
- - reservationEndTime
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'computeResourceId', None, None, ), # 1
- (2, TType.STRING, 'loginUserName', None, None, ), # 2
- (3, TType.STRING, 'preferredBatchQueue', None, None, ), # 3
- (4, TType.STRING, 'scratchLocation', None, None, ), # 4
- (5, TType.STRING, 'allocationProjectNumber', None, None, ), # 5
- (6, TType.STRING, 'resourceSpecificCredentialStoreToken', None, None, ), # 6
- (7, TType.STRING, 'qualityOfService', None, None, ), # 7
- (8, TType.STRING, 'reservation', None, None, ), # 8
- (9, TType.I64, 'reservationStartTime', None, None, ), # 9
- (10, TType.I64, 'reservationEndTime', None, None, ), # 10
- )
-
- def __init__(self, computeResourceId=None, loginUserName=None, preferredBatchQueue=None, scratchLocation=None, allocationProjectNumber=None, resourceSpecificCredentialStoreToken=None, qualityOfService=None, reservation=None, reservationStartTime=None, reservationEndTime=None,):
- self.computeResourceId = computeResourceId
- self.loginUserName = loginUserName
- self.preferredBatchQueue = preferredBatchQueue
- self.scratchLocation = scratchLocation
- self.allocationProjectNumber = allocationProjectNumber
- self.resourceSpecificCredentialStoreToken = resourceSpecificCredentialStoreToken
- self.qualityOfService = qualityOfService
- self.reservation = reservation
- self.reservationStartTime = reservationStartTime
- self.reservationEndTime = reservationEndTime
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.computeResourceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.loginUserName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.preferredBatchQueue = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.scratchLocation = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.allocationProjectNumber = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.resourceSpecificCredentialStoreToken = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.STRING:
- self.qualityOfService = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.STRING:
- self.reservation = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.I64:
- self.reservationStartTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.I64:
- self.reservationEndTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('UserComputeResourcePreference')
- if self.computeResourceId is not None:
- oprot.writeFieldBegin('computeResourceId', TType.STRING, 1)
- oprot.writeString(self.computeResourceId)
- oprot.writeFieldEnd()
- if self.loginUserName is not None:
- oprot.writeFieldBegin('loginUserName', TType.STRING, 2)
- oprot.writeString(self.loginUserName)
- oprot.writeFieldEnd()
- if self.preferredBatchQueue is not None:
- oprot.writeFieldBegin('preferredBatchQueue', TType.STRING, 3)
- oprot.writeString(self.preferredBatchQueue)
- oprot.writeFieldEnd()
- if self.scratchLocation is not None:
- oprot.writeFieldBegin('scratchLocation', TType.STRING, 4)
- oprot.writeString(self.scratchLocation)
- oprot.writeFieldEnd()
- if self.allocationProjectNumber is not None:
- oprot.writeFieldBegin('allocationProjectNumber', TType.STRING, 5)
- oprot.writeString(self.allocationProjectNumber)
- oprot.writeFieldEnd()
- if self.resourceSpecificCredentialStoreToken is not None:
- oprot.writeFieldBegin('resourceSpecificCredentialStoreToken', TType.STRING, 6)
- oprot.writeString(self.resourceSpecificCredentialStoreToken)
- oprot.writeFieldEnd()
- if self.qualityOfService is not None:
- oprot.writeFieldBegin('qualityOfService', TType.STRING, 7)
- oprot.writeString(self.qualityOfService)
- oprot.writeFieldEnd()
- if self.reservation is not None:
- oprot.writeFieldBegin('reservation', TType.STRING, 8)
- oprot.writeString(self.reservation)
- oprot.writeFieldEnd()
- if self.reservationStartTime is not None:
- oprot.writeFieldBegin('reservationStartTime', TType.I64, 9)
- oprot.writeI64(self.reservationStartTime)
- oprot.writeFieldEnd()
- if self.reservationEndTime is not None:
- oprot.writeFieldBegin('reservationEndTime', TType.I64, 10)
- oprot.writeI64(self.reservationEndTime)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.computeResourceId is None:
- raise TProtocol.TProtocolException(message='Required field computeResourceId is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.computeResourceId)
- value = (value * 31) ^ hash(self.loginUserName)
- value = (value * 31) ^ hash(self.preferredBatchQueue)
- value = (value * 31) ^ hash(self.scratchLocation)
- value = (value * 31) ^ hash(self.allocationProjectNumber)
- value = (value * 31) ^ hash(self.resourceSpecificCredentialStoreToken)
- value = (value * 31) ^ hash(self.qualityOfService)
- value = (value * 31) ^ hash(self.reservation)
- value = (value * 31) ^ hash(self.reservationStartTime)
- value = (value * 31) ^ hash(self.reservationEndTime)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class UserStoragePreference:
- """
- Attributes:
- - storageResourceId
- - loginUserName
- - fileSystemRootLocation
- - resourceSpecificCredentialStoreToken
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'storageResourceId', None, None, ), # 1
- (2, TType.STRING, 'loginUserName', None, None, ), # 2
- (3, TType.STRING, 'fileSystemRootLocation', None, None, ), # 3
- (4, TType.STRING, 'resourceSpecificCredentialStoreToken', None, None, ), # 4
- )
-
- def __init__(self, storageResourceId=None, loginUserName=None, fileSystemRootLocation=None, resourceSpecificCredentialStoreToken=None,):
- self.storageResourceId = storageResourceId
- self.loginUserName = loginUserName
- self.fileSystemRootLocation = fileSystemRootLocation
- self.resourceSpecificCredentialStoreToken = resourceSpecificCredentialStoreToken
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.storageResourceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.loginUserName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.fileSystemRootLocation = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.resourceSpecificCredentialStoreToken = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('UserStoragePreference')
- if self.storageResourceId is not None:
- oprot.writeFieldBegin('storageResourceId', TType.STRING, 1)
- oprot.writeString(self.storageResourceId)
- oprot.writeFieldEnd()
- if self.loginUserName is not None:
- oprot.writeFieldBegin('loginUserName', TType.STRING, 2)
- oprot.writeString(self.loginUserName)
- oprot.writeFieldEnd()
- if self.fileSystemRootLocation is not None:
- oprot.writeFieldBegin('fileSystemRootLocation', TType.STRING, 3)
- oprot.writeString(self.fileSystemRootLocation)
- oprot.writeFieldEnd()
- if self.resourceSpecificCredentialStoreToken is not None:
- oprot.writeFieldBegin('resourceSpecificCredentialStoreToken', TType.STRING, 4)
- oprot.writeString(self.resourceSpecificCredentialStoreToken)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.storageResourceId is None:
- raise TProtocol.TProtocolException(message='Required field storageResourceId is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.storageResourceId)
- value = (value * 31) ^ hash(self.loginUserName)
- value = (value * 31) ^ hash(self.fileSystemRootLocation)
- value = (value * 31) ^ hash(self.resourceSpecificCredentialStoreToken)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class UserResourceProfile:
- """
- User Resource Profile
-
- userId:
- Unique identifier used to link user to corresponding user data model
-
- gatewayID:
- Unique identifier for the gateway assigned by Airavata. Corelate this to Airavata Admin API Gateway Registration.
-
- credentialStoreToken:
- Gateway's defualt credential store token.
-
- computeResourcePreferences:
- List of resource preferences for each of the registered compute resources.
-
- identityServerTenant:
-
- identityServerPwdCredToken:
-
- isNull:
- Indicates that this instance is just a container for a null value.
-
-
- Attributes:
- - userId
- - gatewayID
- - credentialStoreToken
- - userComputeResourcePreferences
- - userStoragePreferences
- - identityServerTenant
- - identityServerPwdCredToken
- - isNull
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'userId', None, None, ), # 1
- (2, TType.STRING, 'gatewayID', None, None, ), # 2
- (3, TType.STRING, 'credentialStoreToken', None, None, ), # 3
- (4, TType.LIST, 'userComputeResourcePreferences', (TType.STRUCT,(UserComputeResourcePreference, UserComputeResourcePreference.thrift_spec)), None, ), # 4
- (5, TType.LIST, 'userStoragePreferences', (TType.STRUCT,(UserStoragePreference, UserStoragePreference.thrift_spec)), None, ), # 5
- (6, TType.STRING, 'identityServerTenant', None, None, ), # 6
- (7, TType.STRING, 'identityServerPwdCredToken', None, None, ), # 7
- (8, TType.BOOL, 'isNull', None, False, ), # 8
- )
-
- def __init__(self, userId=None, gatewayID=None, credentialStoreToken=None, userComputeResourcePreferences=None, userStoragePreferences=None, identityServerTenant=None, identityServerPwdCredToken=None, isNull=thrift_spec[8][4],):
- self.userId = userId
- self.gatewayID = gatewayID
- self.credentialStoreToken = credentialStoreToken
- self.userComputeResourcePreferences = userComputeResourcePreferences
- self.userStoragePreferences = userStoragePreferences
- self.identityServerTenant = identityServerTenant
- self.identityServerPwdCredToken = identityServerPwdCredToken
- self.isNull = isNull
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.userId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.gatewayID = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.credentialStoreToken = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.LIST:
- self.userComputeResourcePreferences = []
- (_etype3, _size0) = iprot.readListBegin()
- for _i4 in xrange(_size0):
- _elem5 = UserComputeResourcePreference()
- _elem5.read(iprot)
- self.userComputeResourcePreferences.append(_elem5)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.LIST:
- self.userStoragePreferences = []
- (_etype9, _size6) = iprot.readListBegin()
- for _i10 in xrange(_size6):
- _elem11 = UserStoragePreference()
- _elem11.read(iprot)
- self.userStoragePreferences.append(_elem11)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.identityServerTenant = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.STRING:
- self.identityServerPwdCredToken = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.BOOL:
- self.isNull = iprot.readBool()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('UserResourceProfile')
- if self.userId is not None:
- oprot.writeFieldBegin('userId', TType.STRING, 1)
- oprot.writeString(self.userId)
- oprot.writeFieldEnd()
- if self.gatewayID is not None:
- oprot.writeFieldBegin('gatewayID', TType.STRING, 2)
- oprot.writeString(self.gatewayID)
- oprot.writeFieldEnd()
- if self.credentialStoreToken is not None:
- oprot.writeFieldBegin('credentialStoreToken', TType.STRING, 3)
- oprot.writeString(self.credentialStoreToken)
- oprot.writeFieldEnd()
- if self.userComputeResourcePreferences is not None:
- oprot.writeFieldBegin('userComputeResourcePreferences', TType.LIST, 4)
- oprot.writeListBegin(TType.STRUCT, len(self.userComputeResourcePreferences))
- for iter12 in self.userComputeResourcePreferences:
- iter12.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.userStoragePreferences is not None:
- oprot.writeFieldBegin('userStoragePreferences', TType.LIST, 5)
- oprot.writeListBegin(TType.STRUCT, len(self.userStoragePreferences))
- for iter13 in self.userStoragePreferences:
- iter13.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.identityServerTenant is not None:
- oprot.writeFieldBegin('identityServerTenant', TType.STRING, 6)
- oprot.writeString(self.identityServerTenant)
- oprot.writeFieldEnd()
- if self.identityServerPwdCredToken is not None:
- oprot.writeFieldBegin('identityServerPwdCredToken', TType.STRING, 7)
- oprot.writeString(self.identityServerPwdCredToken)
- oprot.writeFieldEnd()
- if self.isNull is not None:
- oprot.writeFieldBegin('isNull', TType.BOOL, 8)
- oprot.writeBool(self.isNull)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.userId is None:
- raise TProtocol.TProtocolException(message='Required field userId is unset!')
- if self.gatewayID is None:
- raise TProtocol.TProtocolException(message='Required field gatewayID is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.userId)
- value = (value * 31) ^ hash(self.gatewayID)
- value = (value * 31) ^ hash(self.credentialStoreToken)
- value = (value * 31) ^ hash(self.userComputeResourcePreferences)
- value = (value * 31) ^ hash(self.userStoragePreferences)
- value = (value * 31) ^ hash(self.identityServerTenant)
- value = (value * 31) ^ hash(self.identityServerPwdCredToken)
- value = (value * 31) ^ hash(self.isNull)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class UserComputeResourcePreference(object):
+ """
+ User specific preferences for a Computer Resource
+
+ computeResourceId:
+ Corelate the preference to a compute resource.
+
+
+ loginUserName:
+ If turned true, Airavata will override the preferences of better alternatives exist.
+
+
+ preferredBatchQueue:
+ Gateways can choose a defualt batch queue based on average job dimention, reservations or other metrics.
+
+ scratchLocation:
+ Path to the local scratch space on a HPC cluster. Typically used to create working directory for job execution.
+
+ allocationProjectNumber:
+ Typically used on HPC machines to charge computing usage to a account number. For instance, on XSEDE once an
+ allocation is approved, an allocation number is assigned. Before passing this number with job submittions, the
+ account to be used has to be added to the allocation.
+
+ resourceSpecificCredentialStoreToken:
+ Resource specific credential store token. If this token is specified, then it is superceeded by the gateway's
+ default credential store.
+
+
+ Attributes:
+ - computeResourceId
+ - loginUserName
+ - preferredBatchQueue
+ - scratchLocation
+ - allocationProjectNumber
+ - resourceSpecificCredentialStoreToken
+ - qualityOfService
+ - reservation
+ - reservationStartTime
+ - reservationEndTime
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'computeResourceId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'loginUserName', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'preferredBatchQueue', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'scratchLocation', 'UTF8', None, ), # 4
+ (5, TType.STRING, 'allocationProjectNumber', 'UTF8', None, ), # 5
+ (6, TType.STRING, 'resourceSpecificCredentialStoreToken', 'UTF8', None, ), # 6
+ (7, TType.STRING, 'qualityOfService', 'UTF8', None, ), # 7
+ (8, TType.STRING, 'reservation', 'UTF8', None, ), # 8
+ (9, TType.I64, 'reservationStartTime', None, None, ), # 9
+ (10, TType.I64, 'reservationEndTime', None, None, ), # 10
+ )
+
+ def __init__(self, computeResourceId=None, loginUserName=None, preferredBatchQueue=None, scratchLocation=None, allocationProjectNumber=None, resourceSpecificCredentialStoreToken=None, qualityOfService=None, reservation=None, reservationStartTime=None, reservationEndTime=None,):
+ self.computeResourceId = computeResourceId
+ self.loginUserName = loginUserName
+ self.preferredBatchQueue = preferredBatchQueue
+ self.scratchLocation = scratchLocation
+ self.allocationProjectNumber = allocationProjectNumber
+ self.resourceSpecificCredentialStoreToken = resourceSpecificCredentialStoreToken
+ self.qualityOfService = qualityOfService
+ self.reservation = reservation
+ self.reservationStartTime = reservationStartTime
+ self.reservationEndTime = reservationEndTime
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.computeResourceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.loginUserName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.preferredBatchQueue = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.scratchLocation = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRING:
+ self.allocationProjectNumber = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.resourceSpecificCredentialStoreToken = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.STRING:
+ self.qualityOfService = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.STRING:
+ self.reservation = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.I64:
+ self.reservationStartTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.I64:
+ self.reservationEndTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('UserComputeResourcePreference')
+ if self.computeResourceId is not None:
+ oprot.writeFieldBegin('computeResourceId', TType.STRING, 1)
+ oprot.writeString(self.computeResourceId.encode('utf-8') if sys.version_info[0] == 2 else self.computeResourceId)
+ oprot.writeFieldEnd()
+ if self.loginUserName is not None:
+ oprot.writeFieldBegin('loginUserName', TType.STRING, 2)
+ oprot.writeString(self.loginUserName.encode('utf-8') if sys.version_info[0] == 2 else self.loginUserName)
+ oprot.writeFieldEnd()
+ if self.preferredBatchQueue is not None:
+ oprot.writeFieldBegin('preferredBatchQueue', TType.STRING, 3)
+ oprot.writeString(self.preferredBatchQueue.encode('utf-8') if sys.version_info[0] == 2 else self.preferredBatchQueue)
+ oprot.writeFieldEnd()
+ if self.scratchLocation is not None:
+ oprot.writeFieldBegin('scratchLocation', TType.STRING, 4)
+ oprot.writeString(self.scratchLocation.encode('utf-8') if sys.version_info[0] == 2 else self.scratchLocation)
+ oprot.writeFieldEnd()
+ if self.allocationProjectNumber is not None:
+ oprot.writeFieldBegin('allocationProjectNumber', TType.STRING, 5)
+ oprot.writeString(self.allocationProjectNumber.encode('utf-8') if sys.version_info[0] == 2 else self.allocationProjectNumber)
+ oprot.writeFieldEnd()
+ if self.resourceSpecificCredentialStoreToken is not None:
+ oprot.writeFieldBegin('resourceSpecificCredentialStoreToken', TType.STRING, 6)
+ oprot.writeString(self.resourceSpecificCredentialStoreToken.encode('utf-8') if sys.version_info[0] == 2 else self.resourceSpecificCredentialStoreToken)
+ oprot.writeFieldEnd()
+ if self.qualityOfService is not None:
+ oprot.writeFieldBegin('qualityOfService', TType.STRING, 7)
+ oprot.writeString(self.qualityOfService.encode('utf-8') if sys.version_info[0] == 2 else self.qualityOfService)
+ oprot.writeFieldEnd()
+ if self.reservation is not None:
+ oprot.writeFieldBegin('reservation', TType.STRING, 8)
+ oprot.writeString(self.reservation.encode('utf-8') if sys.version_info[0] == 2 else self.reservation)
+ oprot.writeFieldEnd()
+ if self.reservationStartTime is not None:
+ oprot.writeFieldBegin('reservationStartTime', TType.I64, 9)
+ oprot.writeI64(self.reservationStartTime)
+ oprot.writeFieldEnd()
+ if self.reservationEndTime is not None:
+ oprot.writeFieldBegin('reservationEndTime', TType.I64, 10)
+ oprot.writeI64(self.reservationEndTime)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.computeResourceId is None:
+ raise TProtocolException(message='Required field computeResourceId is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class UserStoragePreference(object):
+ """
+ Attributes:
+ - storageResourceId
+ - loginUserName
+ - fileSystemRootLocation
+ - resourceSpecificCredentialStoreToken
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'storageResourceId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'loginUserName', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'fileSystemRootLocation', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'resourceSpecificCredentialStoreToken', 'UTF8', None, ), # 4
+ )
+
+ def __init__(self, storageResourceId=None, loginUserName=None, fileSystemRootLocation=None, resourceSpecificCredentialStoreToken=None,):
+ self.storageResourceId = storageResourceId
+ self.loginUserName = loginUserName
+ self.fileSystemRootLocation = fileSystemRootLocation
+ self.resourceSpecificCredentialStoreToken = resourceSpecificCredentialStoreToken
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.storageResourceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.loginUserName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.fileSystemRootLocation = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.resourceSpecificCredentialStoreToken = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('UserStoragePreference')
+ if self.storageResourceId is not None:
+ oprot.writeFieldBegin('storageResourceId', TType.STRING, 1)
+ oprot.writeString(self.storageResourceId.encode('utf-8') if sys.version_info[0] == 2 else self.storageResourceId)
+ oprot.writeFieldEnd()
+ if self.loginUserName is not None:
+ oprot.writeFieldBegin('loginUserName', TType.STRING, 2)
+ oprot.writeString(self.loginUserName.encode('utf-8') if sys.version_info[0] == 2 else self.loginUserName)
+ oprot.writeFieldEnd()
+ if self.fileSystemRootLocation is not None:
+ oprot.writeFieldBegin('fileSystemRootLocation', TType.STRING, 3)
+ oprot.writeString(self.fileSystemRootLocation.encode('utf-8') if sys.version_info[0] == 2 else self.fileSystemRootLocation)
+ oprot.writeFieldEnd()
+ if self.resourceSpecificCredentialStoreToken is not None:
+ oprot.writeFieldBegin('resourceSpecificCredentialStoreToken', TType.STRING, 4)
+ oprot.writeString(self.resourceSpecificCredentialStoreToken.encode('utf-8') if sys.version_info[0] == 2 else self.resourceSpecificCredentialStoreToken)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.storageResourceId is None:
+ raise TProtocolException(message='Required field storageResourceId is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class UserResourceProfile(object):
+ """
+ User Resource Profile
+
+ userId:
+ Unique identifier used to link user to corresponding user data model
+
+ gatewayID:
+ Unique identifier for the gateway assigned by Airavata. Corelate this to Airavata Admin API Gateway Registration.
+
+ credentialStoreToken:
+ Gateway's defualt credential store token.
+
+ computeResourcePreferences:
+ List of resource preferences for each of the registered compute resources.
+
+ identityServerTenant:
+
+ identityServerPwdCredToken:
+
+ isNull:
+ Indicates that this instance is just a container for a null value.
+
+
+ Attributes:
+ - userId
+ - gatewayID
+ - credentialStoreToken
+ - userComputeResourcePreferences
+ - userStoragePreferences
+ - identityServerTenant
+ - identityServerPwdCredToken
+ - isNull
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'userId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'gatewayID', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'credentialStoreToken', 'UTF8', None, ), # 3
+ (4, TType.LIST, 'userComputeResourcePreferences', (TType.STRUCT, (UserComputeResourcePreference, UserComputeResourcePreference.thrift_spec), False), None, ), # 4
+ (5, TType.LIST, 'userStoragePreferences', (TType.STRUCT, (UserStoragePreference, UserStoragePreference.thrift_spec), False), None, ), # 5
+ (6, TType.STRING, 'identityServerTenant', 'UTF8', None, ), # 6
+ (7, TType.STRING, 'identityServerPwdCredToken', 'UTF8', None, ), # 7
+ (8, TType.BOOL, 'isNull', None, False, ), # 8
+ )
+
+ def __init__(self, userId=None, gatewayID=None, credentialStoreToken=None, userComputeResourcePreferences=None, userStoragePreferences=None, identityServerTenant=None, identityServerPwdCredToken=None, isNull=thrift_spec[8][4],):
+ self.userId = userId
+ self.gatewayID = gatewayID
+ self.credentialStoreToken = credentialStoreToken
+ self.userComputeResourcePreferences = userComputeResourcePreferences
+ self.userStoragePreferences = userStoragePreferences
+ self.identityServerTenant = identityServerTenant
+ self.identityServerPwdCredToken = identityServerPwdCredToken
+ self.isNull = isNull
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.userId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.gatewayID = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.credentialStoreToken = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.LIST:
+ self.userComputeResourcePreferences = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in range(_size0):
+ _elem5 = UserComputeResourcePreference()
+ _elem5.read(iprot)
+ self.userComputeResourcePreferences.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.LIST:
+ self.userStoragePreferences = []
+ (_etype9, _size6) = iprot.readListBegin()
+ for _i10 in range(_size6):
+ _elem11 = UserStoragePreference()
+ _elem11.read(iprot)
+ self.userStoragePreferences.append(_elem11)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.identityServerTenant = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.STRING:
+ self.identityServerPwdCredToken = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.BOOL:
+ self.isNull = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('UserResourceProfile')
+ if self.userId is not None:
+ oprot.writeFieldBegin('userId', TType.STRING, 1)
+ oprot.writeString(self.userId.encode('utf-8') if sys.version_info[0] == 2 else self.userId)
+ oprot.writeFieldEnd()
+ if self.gatewayID is not None:
+ oprot.writeFieldBegin('gatewayID', TType.STRING, 2)
+ oprot.writeString(self.gatewayID.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayID)
+ oprot.writeFieldEnd()
+ if self.credentialStoreToken is not None:
+ oprot.writeFieldBegin('credentialStoreToken', TType.STRING, 3)
+ oprot.writeString(self.credentialStoreToken.encode('utf-8') if sys.version_info[0] == 2 else self.credentialStoreToken)
+ oprot.writeFieldEnd()
+ if self.userComputeResourcePreferences is not None:
+ oprot.writeFieldBegin('userComputeResourcePreferences', TType.LIST, 4)
+ oprot.writeListBegin(TType.STRUCT, len(self.userComputeResourcePreferences))
+ for iter12 in self.userComputeResourcePreferences:
+ iter12.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.userStoragePreferences is not None:
+ oprot.writeFieldBegin('userStoragePreferences', TType.LIST, 5)
+ oprot.writeListBegin(TType.STRUCT, len(self.userStoragePreferences))
+ for iter13 in self.userStoragePreferences:
+ iter13.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.identityServerTenant is not None:
+ oprot.writeFieldBegin('identityServerTenant', TType.STRING, 6)
+ oprot.writeString(self.identityServerTenant.encode('utf-8') if sys.version_info[0] == 2 else self.identityServerTenant)
+ oprot.writeFieldEnd()
+ if self.identityServerPwdCredToken is not None:
+ oprot.writeFieldBegin('identityServerPwdCredToken', TType.STRING, 7)
+ oprot.writeString(self.identityServerPwdCredToken.encode('utf-8') if sys.version_info[0] == 2 else self.identityServerPwdCredToken)
+ oprot.writeFieldEnd()
+ if self.isNull is not None:
+ oprot.writeFieldBegin('isNull', TType.BOOL, 8)
+ oprot.writeBool(self.isNull)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.userId is None:
+ raise TProtocolException(message='Required field userId is unset!')
+ if self.gatewayID is None:
+ raise TProtocolException(message='Required field gatewayID is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/application/io/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/application/io/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/application/io/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/application/io/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/application/io/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/application/io/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/application/io/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/application/io/ttypes.py
index 0e678da..da1e363 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/application/io/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/application/io/ttypes.py
@@ -1,523 +1,486 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.appcatalog.computeresource.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class DataType:
- """
- Data Types supported in Airavata. The primitive data types
-
- """
- STRING = 0
- INTEGER = 1
- FLOAT = 2
- URI = 3
- URI_COLLECTION = 4
- STDOUT = 5
- STDERR = 6
-
- _VALUES_TO_NAMES = {
- 0: "STRING",
- 1: "INTEGER",
- 2: "FLOAT",
- 3: "URI",
- 4: "URI_COLLECTION",
- 5: "STDOUT",
- 6: "STDERR",
- }
-
- _NAMES_TO_VALUES = {
- "STRING": 0,
- "INTEGER": 1,
- "FLOAT": 2,
- "URI": 3,
- "URI_COLLECTION": 4,
- "STDOUT": 5,
- "STDERR": 6,
- }
-
-
-class InputDataObjectType:
- """
- Application Inputs. The paramters describe how inputs are passed to the application.
-
- name:
- Name of the parameter.
-
- value:
- Value of the parameter. A default value could be set during registration.
-
- type:
- Data type of the parameter
-
- applicationArguement:
- The argument flag sent to the application. Such as -p pressure.
-
- standardInput:
- When this value is set, the parameter is sent as standard input rather than a parameter.
- Typically this is passed using redirection operator ">".
-
- userFriendlyDescription:
- Description to be displayed at the user interface.
-
- metaData:
- Any metadat. This is typically ignore by Airavata and is used by gateways for application configuration.
-
-
- Attributes:
- - name
- - value
- - type
- - applicationArgument
- - standardInput
- - userFriendlyDescription
- - metaData
- - inputOrder
- - isRequired
- - requiredToAddedToCommandLine
- - dataStaged
- - storageResourceId
- - isReadOnly
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'name', None, None, ), # 1
- (2, TType.STRING, 'value', None, None, ), # 2
- (3, TType.I32, 'type', None, None, ), # 3
- (4, TType.STRING, 'applicationArgument', None, None, ), # 4
- (5, TType.BOOL, 'standardInput', None, None, ), # 5
- (6, TType.STRING, 'userFriendlyDescription', None, None, ), # 6
- (7, TType.STRING, 'metaData', None, None, ), # 7
- (8, TType.I32, 'inputOrder', None, None, ), # 8
- (9, TType.BOOL, 'isRequired', None, None, ), # 9
- (10, TType.BOOL, 'requiredToAddedToCommandLine', None, None, ), # 10
- (11, TType.BOOL, 'dataStaged', None, None, ), # 11
- (12, TType.STRING, 'storageResourceId', None, None, ), # 12
- (13, TType.BOOL, 'isReadOnly', None, None, ), # 13
- )
-
- def __init__(self, name=None, value=None, type=None, applicationArgument=None, standardInput=None, userFriendlyDescription=None, metaData=None, inputOrder=None, isRequired=None, requiredToAddedToCommandLine=None, dataStaged=None, storageResourceId=None, isReadOnly=None,):
- self.name = name
- self.value = value
- self.type = type
- self.applicationArgument = applicationArgument
- self.standardInput = standardInput
- self.userFriendlyDescription = userFriendlyDescription
- self.metaData = metaData
- self.inputOrder = inputOrder
- self.isRequired = isRequired
- self.requiredToAddedToCommandLine = requiredToAddedToCommandLine
- self.dataStaged = dataStaged
- self.storageResourceId = storageResourceId
- self.isReadOnly = isReadOnly
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.name = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.value = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.I32:
- self.type = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.applicationArgument = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.BOOL:
- self.standardInput = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.userFriendlyDescription = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.STRING:
- self.metaData = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.I32:
- self.inputOrder = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.BOOL:
- self.isRequired = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.BOOL:
- self.requiredToAddedToCommandLine = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 11:
- if ftype == TType.BOOL:
- self.dataStaged = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 12:
- if ftype == TType.STRING:
- self.storageResourceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 13:
- if ftype == TType.BOOL:
- self.isReadOnly = iprot.readBool()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('InputDataObjectType')
- if self.name is not None:
- oprot.writeFieldBegin('name', TType.STRING, 1)
- oprot.writeString(self.name)
- oprot.writeFieldEnd()
- if self.value is not None:
- oprot.writeFieldBegin('value', TType.STRING, 2)
- oprot.writeString(self.value)
- oprot.writeFieldEnd()
- if self.type is not None:
- oprot.writeFieldBegin('type', TType.I32, 3)
- oprot.writeI32(self.type)
- oprot.writeFieldEnd()
- if self.applicationArgument is not None:
- oprot.writeFieldBegin('applicationArgument', TType.STRING, 4)
- oprot.writeString(self.applicationArgument)
- oprot.writeFieldEnd()
- if self.standardInput is not None:
- oprot.writeFieldBegin('standardInput', TType.BOOL, 5)
- oprot.writeBool(self.standardInput)
- oprot.writeFieldEnd()
- if self.userFriendlyDescription is not None:
- oprot.writeFieldBegin('userFriendlyDescription', TType.STRING, 6)
- oprot.writeString(self.userFriendlyDescription)
- oprot.writeFieldEnd()
- if self.metaData is not None:
- oprot.writeFieldBegin('metaData', TType.STRING, 7)
- oprot.writeString(self.metaData)
- oprot.writeFieldEnd()
- if self.inputOrder is not None:
- oprot.writeFieldBegin('inputOrder', TType.I32, 8)
- oprot.writeI32(self.inputOrder)
- oprot.writeFieldEnd()
- if self.isRequired is not None:
- oprot.writeFieldBegin('isRequired', TType.BOOL, 9)
- oprot.writeBool(self.isRequired)
- oprot.writeFieldEnd()
- if self.requiredToAddedToCommandLine is not None:
- oprot.writeFieldBegin('requiredToAddedToCommandLine', TType.BOOL, 10)
- oprot.writeBool(self.requiredToAddedToCommandLine)
- oprot.writeFieldEnd()
- if self.dataStaged is not None:
- oprot.writeFieldBegin('dataStaged', TType.BOOL, 11)
- oprot.writeBool(self.dataStaged)
- oprot.writeFieldEnd()
- if self.storageResourceId is not None:
- oprot.writeFieldBegin('storageResourceId', TType.STRING, 12)
- oprot.writeString(self.storageResourceId)
- oprot.writeFieldEnd()
- if self.isReadOnly is not None:
- oprot.writeFieldBegin('isReadOnly', TType.BOOL, 13)
- oprot.writeBool(self.isReadOnly)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.name is None:
- raise TProtocol.TProtocolException(message='Required field name is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.name)
- value = (value * 31) ^ hash(self.value)
- value = (value * 31) ^ hash(self.type)
- value = (value * 31) ^ hash(self.applicationArgument)
- value = (value * 31) ^ hash(self.standardInput)
- value = (value * 31) ^ hash(self.userFriendlyDescription)
- value = (value * 31) ^ hash(self.metaData)
- value = (value * 31) ^ hash(self.inputOrder)
- value = (value * 31) ^ hash(self.isRequired)
- value = (value * 31) ^ hash(self.requiredToAddedToCommandLine)
- value = (value * 31) ^ hash(self.dataStaged)
- value = (value * 31) ^ hash(self.storageResourceId)
- value = (value * 31) ^ hash(self.isReadOnly)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class OutputDataObjectType:
- """
- Application Outputs. The paramters describe how outputs generated by the application.
-
- name:
- Name of the parameter.
-
- value:
- Value of the parameter.
-
- type:
- Data type of the parameter
-
- applicationArguement:
- The argument flag sent to the application. Such as -p pressure.
-
- standardInput:
- When this value is set, the parameter is sent as standard input rather than a parameter.
- Typically this is passed using redirection operator ">".
-
- userFriendlyDescription:
- Description to be displayed at the user interface.
-
- metaData:
- Any metadat. This is typically ignore by Airavata and is used by gateways for application configuration.
-
-
- Attributes:
- - name
- - value
- - type
- - applicationArgument
- - isRequired
- - requiredToAddedToCommandLine
- - dataMovement
- - location
- - searchQuery
- - outputStreaming
- - storageResourceId
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'name', None, None, ), # 1
- (2, TType.STRING, 'value', None, None, ), # 2
- (3, TType.I32, 'type', None, None, ), # 3
- (4, TType.STRING, 'applicationArgument', None, None, ), # 4
- (5, TType.BOOL, 'isRequired', None, None, ), # 5
- (6, TType.BOOL, 'requiredToAddedToCommandLine', None, None, ), # 6
- (7, TType.BOOL, 'dataMovement', None, None, ), # 7
- (8, TType.STRING, 'location', None, None, ), # 8
- (9, TType.STRING, 'searchQuery', None, None, ), # 9
- (10, TType.BOOL, 'outputStreaming', None, None, ), # 10
- (11, TType.STRING, 'storageResourceId', None, None, ), # 11
- )
-
- def __init__(self, name=None, value=None, type=None, applicationArgument=None, isRequired=None, requiredToAddedToCommandLine=None, dataMovement=None, location=None, searchQuery=None, outputStreaming=None, storageResourceId=None,):
- self.name = name
- self.value = value
- self.type = type
- self.applicationArgument = applicationArgument
- self.isRequired = isRequired
- self.requiredToAddedToCommandLine = requiredToAddedToCommandLine
- self.dataMovement = dataMovement
- self.location = location
- self.searchQuery = searchQuery
- self.outputStreaming = outputStreaming
- self.storageResourceId = storageResourceId
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.name = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.value = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.I32:
- self.type = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.applicationArgument = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.BOOL:
- self.isRequired = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.BOOL:
- self.requiredToAddedToCommandLine = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.BOOL:
- self.dataMovement = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.STRING:
- self.location = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.STRING:
- self.searchQuery = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.BOOL:
- self.outputStreaming = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 11:
- if ftype == TType.STRING:
- self.storageResourceId = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('OutputDataObjectType')
- if self.name is not None:
- oprot.writeFieldBegin('name', TType.STRING, 1)
- oprot.writeString(self.name)
- oprot.writeFieldEnd()
- if self.value is not None:
- oprot.writeFieldBegin('value', TType.STRING, 2)
- oprot.writeString(self.value)
- oprot.writeFieldEnd()
- if self.type is not None:
- oprot.writeFieldBegin('type', TType.I32, 3)
- oprot.writeI32(self.type)
- oprot.writeFieldEnd()
- if self.applicationArgument is not None:
- oprot.writeFieldBegin('applicationArgument', TType.STRING, 4)
- oprot.writeString(self.applicationArgument)
- oprot.writeFieldEnd()
- if self.isRequired is not None:
- oprot.writeFieldBegin('isRequired', TType.BOOL, 5)
- oprot.writeBool(self.isRequired)
- oprot.writeFieldEnd()
- if self.requiredToAddedToCommandLine is not None:
- oprot.writeFieldBegin('requiredToAddedToCommandLine', TType.BOOL, 6)
- oprot.writeBool(self.requiredToAddedToCommandLine)
- oprot.writeFieldEnd()
- if self.dataMovement is not None:
- oprot.writeFieldBegin('dataMovement', TType.BOOL, 7)
- oprot.writeBool(self.dataMovement)
- oprot.writeFieldEnd()
- if self.location is not None:
- oprot.writeFieldBegin('location', TType.STRING, 8)
- oprot.writeString(self.location)
- oprot.writeFieldEnd()
- if self.searchQuery is not None:
- oprot.writeFieldBegin('searchQuery', TType.STRING, 9)
- oprot.writeString(self.searchQuery)
- oprot.writeFieldEnd()
- if self.outputStreaming is not None:
- oprot.writeFieldBegin('outputStreaming', TType.BOOL, 10)
- oprot.writeBool(self.outputStreaming)
- oprot.writeFieldEnd()
- if self.storageResourceId is not None:
- oprot.writeFieldBegin('storageResourceId', TType.STRING, 11)
- oprot.writeString(self.storageResourceId)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.name is None:
- raise TProtocol.TProtocolException(message='Required field name is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.name)
- value = (value * 31) ^ hash(self.value)
- value = (value * 31) ^ hash(self.type)
- value = (value * 31) ^ hash(self.applicationArgument)
- value = (value * 31) ^ hash(self.isRequired)
- value = (value * 31) ^ hash(self.requiredToAddedToCommandLine)
- value = (value * 31) ^ hash(self.dataMovement)
- value = (value * 31) ^ hash(self.location)
- value = (value * 31) ^ hash(self.searchQuery)
- value = (value * 31) ^ hash(self.outputStreaming)
- value = (value * 31) ^ hash(self.storageResourceId)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class DataType(object):
+ """
+ Data Types supported in Airavata. The primitive data types
+
+ """
+ STRING = 0
+ INTEGER = 1
+ FLOAT = 2
+ URI = 3
+ URI_COLLECTION = 4
+ STDOUT = 5
+ STDERR = 6
+
+ _VALUES_TO_NAMES = {
+ 0: "STRING",
+ 1: "INTEGER",
+ 2: "FLOAT",
+ 3: "URI",
+ 4: "URI_COLLECTION",
+ 5: "STDOUT",
+ 6: "STDERR",
+ }
+
+ _NAMES_TO_VALUES = {
+ "STRING": 0,
+ "INTEGER": 1,
+ "FLOAT": 2,
+ "URI": 3,
+ "URI_COLLECTION": 4,
+ "STDOUT": 5,
+ "STDERR": 6,
+ }
+
+
+class InputDataObjectType(object):
+ """
+ Application Inputs. The paramters describe how inputs are passed to the application.
+
+ name:
+ Name of the parameter.
+
+ value:
+ Value of the parameter. A default value could be set during registration.
+
+ type:
+ Data type of the parameter
+
+ applicationArguement:
+ The argument flag sent to the application. Such as -p pressure.
+
+ standardInput:
+ When this value is set, the parameter is sent as standard input rather than a parameter.
+ Typically this is passed using redirection operator ">".
+
+ userFriendlyDescription:
+ Description to be displayed at the user interface.
+
+ metaData:
+ Any metadat. This is typically ignore by Airavata and is used by gateways for application configuration.
+
+
+ Attributes:
+ - name
+ - value
+ - type
+ - applicationArgument
+ - standardInput
+ - userFriendlyDescription
+ - metaData
+ - inputOrder
+ - isRequired
+ - requiredToAddedToCommandLine
+ - dataStaged
+ - storageResourceId
+ - isReadOnly
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'name', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'value', 'UTF8', None, ), # 2
+ (3, TType.I32, 'type', None, None, ), # 3
+ (4, TType.STRING, 'applicationArgument', 'UTF8', None, ), # 4
+ (5, TType.BOOL, 'standardInput', None, None, ), # 5
+ (6, TType.STRING, 'userFriendlyDescription', 'UTF8', None, ), # 6
+ (7, TType.STRING, 'metaData', 'UTF8', None, ), # 7
+ (8, TType.I32, 'inputOrder', None, None, ), # 8
+ (9, TType.BOOL, 'isRequired', None, None, ), # 9
+ (10, TType.BOOL, 'requiredToAddedToCommandLine', None, None, ), # 10
+ (11, TType.BOOL, 'dataStaged', None, None, ), # 11
+ (12, TType.STRING, 'storageResourceId', 'UTF8', None, ), # 12
+ (13, TType.BOOL, 'isReadOnly', None, None, ), # 13
+ )
+
+ def __init__(self, name=None, value=None, type=None, applicationArgument=None, standardInput=None, userFriendlyDescription=None, metaData=None, inputOrder=None, isRequired=None, requiredToAddedToCommandLine=None, dataStaged=None, storageResourceId=None, isReadOnly=None,):
+ self.name = name
+ self.value = value
+ self.type = type
+ self.applicationArgument = applicationArgument
+ self.standardInput = standardInput
+ self.userFriendlyDescription = userFriendlyDescription
+ self.metaData = metaData
+ self.inputOrder = inputOrder
+ self.isRequired = isRequired
+ self.requiredToAddedToCommandLine = requiredToAddedToCommandLine
+ self.dataStaged = dataStaged
+ self.storageResourceId = storageResourceId
+ self.isReadOnly = isReadOnly
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.name = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.value = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I32:
+ self.type = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.applicationArgument = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.BOOL:
+ self.standardInput = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.userFriendlyDescription = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.STRING:
+ self.metaData = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.I32:
+ self.inputOrder = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.BOOL:
+ self.isRequired = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.BOOL:
+ self.requiredToAddedToCommandLine = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 11:
+ if ftype == TType.BOOL:
+ self.dataStaged = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 12:
+ if ftype == TType.STRING:
+ self.storageResourceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 13:
+ if ftype == TType.BOOL:
+ self.isReadOnly = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('InputDataObjectType')
+ if self.name is not None:
+ oprot.writeFieldBegin('name', TType.STRING, 1)
+ oprot.writeString(self.name.encode('utf-8') if sys.version_info[0] == 2 else self.name)
+ oprot.writeFieldEnd()
+ if self.value is not None:
+ oprot.writeFieldBegin('value', TType.STRING, 2)
+ oprot.writeString(self.value.encode('utf-8') if sys.version_info[0] == 2 else self.value)
+ oprot.writeFieldEnd()
+ if self.type is not None:
+ oprot.writeFieldBegin('type', TType.I32, 3)
+ oprot.writeI32(self.type)
+ oprot.writeFieldEnd()
+ if self.applicationArgument is not None:
+ oprot.writeFieldBegin('applicationArgument', TType.STRING, 4)
+ oprot.writeString(self.applicationArgument.encode('utf-8') if sys.version_info[0] == 2 else self.applicationArgument)
+ oprot.writeFieldEnd()
+ if self.standardInput is not None:
+ oprot.writeFieldBegin('standardInput', TType.BOOL, 5)
+ oprot.writeBool(self.standardInput)
+ oprot.writeFieldEnd()
+ if self.userFriendlyDescription is not None:
+ oprot.writeFieldBegin('userFriendlyDescription', TType.STRING, 6)
+ oprot.writeString(self.userFriendlyDescription.encode('utf-8') if sys.version_info[0] == 2 else self.userFriendlyDescription)
+ oprot.writeFieldEnd()
+ if self.metaData is not None:
+ oprot.writeFieldBegin('metaData', TType.STRING, 7)
+ oprot.writeString(self.metaData.encode('utf-8') if sys.version_info[0] == 2 else self.metaData)
+ oprot.writeFieldEnd()
+ if self.inputOrder is not None:
+ oprot.writeFieldBegin('inputOrder', TType.I32, 8)
+ oprot.writeI32(self.inputOrder)
+ oprot.writeFieldEnd()
+ if self.isRequired is not None:
+ oprot.writeFieldBegin('isRequired', TType.BOOL, 9)
+ oprot.writeBool(self.isRequired)
+ oprot.writeFieldEnd()
+ if self.requiredToAddedToCommandLine is not None:
+ oprot.writeFieldBegin('requiredToAddedToCommandLine', TType.BOOL, 10)
+ oprot.writeBool(self.requiredToAddedToCommandLine)
+ oprot.writeFieldEnd()
+ if self.dataStaged is not None:
+ oprot.writeFieldBegin('dataStaged', TType.BOOL, 11)
+ oprot.writeBool(self.dataStaged)
+ oprot.writeFieldEnd()
+ if self.storageResourceId is not None:
+ oprot.writeFieldBegin('storageResourceId', TType.STRING, 12)
+ oprot.writeString(self.storageResourceId.encode('utf-8') if sys.version_info[0] == 2 else self.storageResourceId)
+ oprot.writeFieldEnd()
+ if self.isReadOnly is not None:
+ oprot.writeFieldBegin('isReadOnly', TType.BOOL, 13)
+ oprot.writeBool(self.isReadOnly)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.name is None:
+ raise TProtocolException(message='Required field name is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class OutputDataObjectType(object):
+ """
+ Application Outputs. The paramters describe how outputs generated by the application.
+
+ name:
+ Name of the parameter.
+
+ value:
+ Value of the parameter.
+
+ type:
+ Data type of the parameter
+
+ applicationArguement:
+ The argument flag sent to the application. Such as -p pressure.
+
+ standardInput:
+ When this value is set, the parameter is sent as standard input rather than a parameter.
+ Typically this is passed using redirection operator ">".
+
+ userFriendlyDescription:
+ Description to be displayed at the user interface.
+
+ metaData:
+ Any metadat. This is typically ignore by Airavata and is used by gateways for application configuration.
+
+
+ Attributes:
+ - name
+ - value
+ - type
+ - applicationArgument
+ - isRequired
+ - requiredToAddedToCommandLine
+ - dataMovement
+ - location
+ - searchQuery
+ - outputStreaming
+ - storageResourceId
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'name', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'value', 'UTF8', None, ), # 2
+ (3, TType.I32, 'type', None, None, ), # 3
+ (4, TType.STRING, 'applicationArgument', 'UTF8', None, ), # 4
+ (5, TType.BOOL, 'isRequired', None, None, ), # 5
+ (6, TType.BOOL, 'requiredToAddedToCommandLine', None, None, ), # 6
+ (7, TType.BOOL, 'dataMovement', None, None, ), # 7
+ (8, TType.STRING, 'location', 'UTF8', None, ), # 8
+ (9, TType.STRING, 'searchQuery', 'UTF8', None, ), # 9
+ (10, TType.BOOL, 'outputStreaming', None, None, ), # 10
+ (11, TType.STRING, 'storageResourceId', 'UTF8', None, ), # 11
+ )
+
+ def __init__(self, name=None, value=None, type=None, applicationArgument=None, isRequired=None, requiredToAddedToCommandLine=None, dataMovement=None, location=None, searchQuery=None, outputStreaming=None, storageResourceId=None,):
+ self.name = name
+ self.value = value
+ self.type = type
+ self.applicationArgument = applicationArgument
+ self.isRequired = isRequired
+ self.requiredToAddedToCommandLine = requiredToAddedToCommandLine
+ self.dataMovement = dataMovement
+ self.location = location
+ self.searchQuery = searchQuery
+ self.outputStreaming = outputStreaming
+ self.storageResourceId = storageResourceId
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.name = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.value = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I32:
+ self.type = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.applicationArgument = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.BOOL:
+ self.isRequired = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.BOOL:
+ self.requiredToAddedToCommandLine = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.BOOL:
+ self.dataMovement = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.STRING:
+ self.location = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.STRING:
+ self.searchQuery = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.BOOL:
+ self.outputStreaming = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 11:
+ if ftype == TType.STRING:
+ self.storageResourceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('OutputDataObjectType')
+ if self.name is not None:
+ oprot.writeFieldBegin('name', TType.STRING, 1)
+ oprot.writeString(self.name.encode('utf-8') if sys.version_info[0] == 2 else self.name)
+ oprot.writeFieldEnd()
+ if self.value is not None:
+ oprot.writeFieldBegin('value', TType.STRING, 2)
+ oprot.writeString(self.value.encode('utf-8') if sys.version_info[0] == 2 else self.value)
+ oprot.writeFieldEnd()
+ if self.type is not None:
+ oprot.writeFieldBegin('type', TType.I32, 3)
+ oprot.writeI32(self.type)
+ oprot.writeFieldEnd()
+ if self.applicationArgument is not None:
+ oprot.writeFieldBegin('applicationArgument', TType.STRING, 4)
+ oprot.writeString(self.applicationArgument.encode('utf-8') if sys.version_info[0] == 2 else self.applicationArgument)
+ oprot.writeFieldEnd()
+ if self.isRequired is not None:
+ oprot.writeFieldBegin('isRequired', TType.BOOL, 5)
+ oprot.writeBool(self.isRequired)
+ oprot.writeFieldEnd()
+ if self.requiredToAddedToCommandLine is not None:
+ oprot.writeFieldBegin('requiredToAddedToCommandLine', TType.BOOL, 6)
+ oprot.writeBool(self.requiredToAddedToCommandLine)
+ oprot.writeFieldEnd()
+ if self.dataMovement is not None:
+ oprot.writeFieldBegin('dataMovement', TType.BOOL, 7)
+ oprot.writeBool(self.dataMovement)
+ oprot.writeFieldEnd()
+ if self.location is not None:
+ oprot.writeFieldBegin('location', TType.STRING, 8)
+ oprot.writeString(self.location.encode('utf-8') if sys.version_info[0] == 2 else self.location)
+ oprot.writeFieldEnd()
+ if self.searchQuery is not None:
+ oprot.writeFieldBegin('searchQuery', TType.STRING, 9)
+ oprot.writeString(self.searchQuery.encode('utf-8') if sys.version_info[0] == 2 else self.searchQuery)
+ oprot.writeFieldEnd()
+ if self.outputStreaming is not None:
+ oprot.writeFieldBegin('outputStreaming', TType.BOOL, 10)
+ oprot.writeBool(self.outputStreaming)
+ oprot.writeFieldEnd()
+ if self.storageResourceId is not None:
+ oprot.writeFieldBegin('storageResourceId', TType.STRING, 11)
+ oprot.writeString(self.storageResourceId.encode('utf-8') if sys.version_info[0] == 2 else self.storageResourceId)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.name is None:
+ raise TProtocolException(message='Required field name is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/commons/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/commons/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/commons/constants.py
index abf8bc6..2b09fa9 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/commons/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/commons/constants.py
@@ -1,12 +1,13 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
DEFAULT_ID = "DO_NOT_SET_AT_CLIENTS"
[23/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/ApplicationDeploymentDescription.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/ApplicationDeploymentDescription.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/ApplicationDeploymentDescription.java
index f3f6042..3ddd318 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/ApplicationDeploymentDescription.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/ApplicationDeploymentDescription.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.appdeployment;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Application Deployment Description
*
@@ -77,7 +50,7 @@ import org.slf4j.LoggerFactory;
* assigns to the environment variable "NAME" the value
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class ApplicationDeploymentDescription implements org.apache.thrift.TBase<ApplicationDeploymentDescription, ApplicationDeploymentDescription._Fields>, java.io.Serializable, Cloneable, Comparable<ApplicationDeploymentDescription> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ApplicationDeploymentDescription");
@@ -99,25 +72,22 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
private static final org.apache.thrift.protocol.TField DEFAULT_WALLTIME_FIELD_DESC = new org.apache.thrift.protocol.TField("defaultWalltime", org.apache.thrift.protocol.TType.I32, (short)16);
private static final org.apache.thrift.protocol.TField EDITABLE_BY_USER_FIELD_DESC = new org.apache.thrift.protocol.TField("editableByUser", org.apache.thrift.protocol.TType.BOOL, (short)17);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new ApplicationDeploymentDescriptionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ApplicationDeploymentDescriptionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ApplicationDeploymentDescriptionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ApplicationDeploymentDescriptionTupleSchemeFactory();
- private String appDeploymentId; // required
- private String appModuleId; // required
- private String computeHostId; // required
- private String executablePath; // required
+ private java.lang.String appDeploymentId; // required
+ private java.lang.String appModuleId; // required
+ private java.lang.String computeHostId; // required
+ private java.lang.String executablePath; // required
private org.apache.airavata.model.parallelism.ApplicationParallelismType parallelism; // required
- private String appDeploymentDescription; // optional
- private List<CommandObject> moduleLoadCmds; // optional
- private List<SetEnvPaths> libPrependPaths; // optional
- private List<SetEnvPaths> libAppendPaths; // optional
- private List<SetEnvPaths> setEnvironment; // optional
- private List<CommandObject> preJobCommands; // optional
- private List<CommandObject> postJobCommands; // optional
- private String defaultQueueName; // optional
+ private java.lang.String appDeploymentDescription; // optional
+ private java.util.List<CommandObject> moduleLoadCmds; // optional
+ private java.util.List<SetEnvPaths> libPrependPaths; // optional
+ private java.util.List<SetEnvPaths> libAppendPaths; // optional
+ private java.util.List<SetEnvPaths> setEnvironment; // optional
+ private java.util.List<CommandObject> preJobCommands; // optional
+ private java.util.List<CommandObject> postJobCommands; // optional
+ private java.lang.String defaultQueueName; // optional
private int defaultNodeCount; // optional
private int defaultCPUCount; // optional
private int defaultWalltime; // optional
@@ -147,10 +117,10 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
DEFAULT_WALLTIME((short)16, "defaultWalltime"),
EDITABLE_BY_USER((short)17, "editableByUser");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -205,21 +175,21 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -228,7 +198,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -240,9 +210,9 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
private static final int __EDITABLEBYUSER_ISSET_ID = 3;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.APP_DEPLOYMENT_DESCRIPTION,_Fields.MODULE_LOAD_CMDS,_Fields.LIB_PREPEND_PATHS,_Fields.LIB_APPEND_PATHS,_Fields.SET_ENVIRONMENT,_Fields.PRE_JOB_COMMANDS,_Fields.POST_JOB_COMMANDS,_Fields.DEFAULT_QUEUE_NAME,_Fields.DEFAULT_NODE_COUNT,_Fields.DEFAULT_CPUCOUNT,_Fields.DEFAULT_WALLTIME,_Fields.EDITABLE_BY_USER};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.APP_DEPLOYMENT_ID, new org.apache.thrift.meta_data.FieldMetaData("appDeploymentId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.APP_MODULE_ID, new org.apache.thrift.meta_data.FieldMetaData("appModuleId", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -283,7 +253,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
tmpMap.put(_Fields.EDITABLE_BY_USER, new org.apache.thrift.meta_data.FieldMetaData("editableByUser", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ApplicationDeploymentDescription.class, metaDataMap);
}
@@ -295,10 +265,10 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
}
public ApplicationDeploymentDescription(
- String appDeploymentId,
- String appModuleId,
- String computeHostId,
- String executablePath,
+ java.lang.String appDeploymentId,
+ java.lang.String appModuleId,
+ java.lang.String computeHostId,
+ java.lang.String executablePath,
org.apache.airavata.model.parallelism.ApplicationParallelismType parallelism)
{
this();
@@ -333,42 +303,42 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
this.appDeploymentDescription = other.appDeploymentDescription;
}
if (other.isSetModuleLoadCmds()) {
- List<CommandObject> __this__moduleLoadCmds = new ArrayList<CommandObject>(other.moduleLoadCmds.size());
+ java.util.List<CommandObject> __this__moduleLoadCmds = new java.util.ArrayList<CommandObject>(other.moduleLoadCmds.size());
for (CommandObject other_element : other.moduleLoadCmds) {
__this__moduleLoadCmds.add(new CommandObject(other_element));
}
this.moduleLoadCmds = __this__moduleLoadCmds;
}
if (other.isSetLibPrependPaths()) {
- List<SetEnvPaths> __this__libPrependPaths = new ArrayList<SetEnvPaths>(other.libPrependPaths.size());
+ java.util.List<SetEnvPaths> __this__libPrependPaths = new java.util.ArrayList<SetEnvPaths>(other.libPrependPaths.size());
for (SetEnvPaths other_element : other.libPrependPaths) {
__this__libPrependPaths.add(new SetEnvPaths(other_element));
}
this.libPrependPaths = __this__libPrependPaths;
}
if (other.isSetLibAppendPaths()) {
- List<SetEnvPaths> __this__libAppendPaths = new ArrayList<SetEnvPaths>(other.libAppendPaths.size());
+ java.util.List<SetEnvPaths> __this__libAppendPaths = new java.util.ArrayList<SetEnvPaths>(other.libAppendPaths.size());
for (SetEnvPaths other_element : other.libAppendPaths) {
__this__libAppendPaths.add(new SetEnvPaths(other_element));
}
this.libAppendPaths = __this__libAppendPaths;
}
if (other.isSetSetEnvironment()) {
- List<SetEnvPaths> __this__setEnvironment = new ArrayList<SetEnvPaths>(other.setEnvironment.size());
+ java.util.List<SetEnvPaths> __this__setEnvironment = new java.util.ArrayList<SetEnvPaths>(other.setEnvironment.size());
for (SetEnvPaths other_element : other.setEnvironment) {
__this__setEnvironment.add(new SetEnvPaths(other_element));
}
this.setEnvironment = __this__setEnvironment;
}
if (other.isSetPreJobCommands()) {
- List<CommandObject> __this__preJobCommands = new ArrayList<CommandObject>(other.preJobCommands.size());
+ java.util.List<CommandObject> __this__preJobCommands = new java.util.ArrayList<CommandObject>(other.preJobCommands.size());
for (CommandObject other_element : other.preJobCommands) {
__this__preJobCommands.add(new CommandObject(other_element));
}
this.preJobCommands = __this__preJobCommands;
}
if (other.isSetPostJobCommands()) {
- List<CommandObject> __this__postJobCommands = new ArrayList<CommandObject>(other.postJobCommands.size());
+ java.util.List<CommandObject> __this__postJobCommands = new java.util.ArrayList<CommandObject>(other.postJobCommands.size());
for (CommandObject other_element : other.postJobCommands) {
__this__postJobCommands.add(new CommandObject(other_element));
}
@@ -414,11 +384,11 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
this.editableByUser = false;
}
- public String getAppDeploymentId() {
+ public java.lang.String getAppDeploymentId() {
return this.appDeploymentId;
}
- public void setAppDeploymentId(String appDeploymentId) {
+ public void setAppDeploymentId(java.lang.String appDeploymentId) {
this.appDeploymentId = appDeploymentId;
}
@@ -437,11 +407,11 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
}
}
- public String getAppModuleId() {
+ public java.lang.String getAppModuleId() {
return this.appModuleId;
}
- public void setAppModuleId(String appModuleId) {
+ public void setAppModuleId(java.lang.String appModuleId) {
this.appModuleId = appModuleId;
}
@@ -460,11 +430,11 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
}
}
- public String getComputeHostId() {
+ public java.lang.String getComputeHostId() {
return this.computeHostId;
}
- public void setComputeHostId(String computeHostId) {
+ public void setComputeHostId(java.lang.String computeHostId) {
this.computeHostId = computeHostId;
}
@@ -483,11 +453,11 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
}
}
- public String getExecutablePath() {
+ public java.lang.String getExecutablePath() {
return this.executablePath;
}
- public void setExecutablePath(String executablePath) {
+ public void setExecutablePath(java.lang.String executablePath) {
this.executablePath = executablePath;
}
@@ -537,11 +507,11 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
}
}
- public String getAppDeploymentDescription() {
+ public java.lang.String getAppDeploymentDescription() {
return this.appDeploymentDescription;
}
- public void setAppDeploymentDescription(String appDeploymentDescription) {
+ public void setAppDeploymentDescription(java.lang.String appDeploymentDescription) {
this.appDeploymentDescription = appDeploymentDescription;
}
@@ -570,16 +540,16 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
public void addToModuleLoadCmds(CommandObject elem) {
if (this.moduleLoadCmds == null) {
- this.moduleLoadCmds = new ArrayList<CommandObject>();
+ this.moduleLoadCmds = new java.util.ArrayList<CommandObject>();
}
this.moduleLoadCmds.add(elem);
}
- public List<CommandObject> getModuleLoadCmds() {
+ public java.util.List<CommandObject> getModuleLoadCmds() {
return this.moduleLoadCmds;
}
- public void setModuleLoadCmds(List<CommandObject> moduleLoadCmds) {
+ public void setModuleLoadCmds(java.util.List<CommandObject> moduleLoadCmds) {
this.moduleLoadCmds = moduleLoadCmds;
}
@@ -608,16 +578,16 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
public void addToLibPrependPaths(SetEnvPaths elem) {
if (this.libPrependPaths == null) {
- this.libPrependPaths = new ArrayList<SetEnvPaths>();
+ this.libPrependPaths = new java.util.ArrayList<SetEnvPaths>();
}
this.libPrependPaths.add(elem);
}
- public List<SetEnvPaths> getLibPrependPaths() {
+ public java.util.List<SetEnvPaths> getLibPrependPaths() {
return this.libPrependPaths;
}
- public void setLibPrependPaths(List<SetEnvPaths> libPrependPaths) {
+ public void setLibPrependPaths(java.util.List<SetEnvPaths> libPrependPaths) {
this.libPrependPaths = libPrependPaths;
}
@@ -646,16 +616,16 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
public void addToLibAppendPaths(SetEnvPaths elem) {
if (this.libAppendPaths == null) {
- this.libAppendPaths = new ArrayList<SetEnvPaths>();
+ this.libAppendPaths = new java.util.ArrayList<SetEnvPaths>();
}
this.libAppendPaths.add(elem);
}
- public List<SetEnvPaths> getLibAppendPaths() {
+ public java.util.List<SetEnvPaths> getLibAppendPaths() {
return this.libAppendPaths;
}
- public void setLibAppendPaths(List<SetEnvPaths> libAppendPaths) {
+ public void setLibAppendPaths(java.util.List<SetEnvPaths> libAppendPaths) {
this.libAppendPaths = libAppendPaths;
}
@@ -684,16 +654,16 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
public void addToSetEnvironment(SetEnvPaths elem) {
if (this.setEnvironment == null) {
- this.setEnvironment = new ArrayList<SetEnvPaths>();
+ this.setEnvironment = new java.util.ArrayList<SetEnvPaths>();
}
this.setEnvironment.add(elem);
}
- public List<SetEnvPaths> getSetEnvironment() {
+ public java.util.List<SetEnvPaths> getSetEnvironment() {
return this.setEnvironment;
}
- public void setSetEnvironment(List<SetEnvPaths> setEnvironment) {
+ public void setSetEnvironment(java.util.List<SetEnvPaths> setEnvironment) {
this.setEnvironment = setEnvironment;
}
@@ -722,16 +692,16 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
public void addToPreJobCommands(CommandObject elem) {
if (this.preJobCommands == null) {
- this.preJobCommands = new ArrayList<CommandObject>();
+ this.preJobCommands = new java.util.ArrayList<CommandObject>();
}
this.preJobCommands.add(elem);
}
- public List<CommandObject> getPreJobCommands() {
+ public java.util.List<CommandObject> getPreJobCommands() {
return this.preJobCommands;
}
- public void setPreJobCommands(List<CommandObject> preJobCommands) {
+ public void setPreJobCommands(java.util.List<CommandObject> preJobCommands) {
this.preJobCommands = preJobCommands;
}
@@ -760,16 +730,16 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
public void addToPostJobCommands(CommandObject elem) {
if (this.postJobCommands == null) {
- this.postJobCommands = new ArrayList<CommandObject>();
+ this.postJobCommands = new java.util.ArrayList<CommandObject>();
}
this.postJobCommands.add(elem);
}
- public List<CommandObject> getPostJobCommands() {
+ public java.util.List<CommandObject> getPostJobCommands() {
return this.postJobCommands;
}
- public void setPostJobCommands(List<CommandObject> postJobCommands) {
+ public void setPostJobCommands(java.util.List<CommandObject> postJobCommands) {
this.postJobCommands = postJobCommands;
}
@@ -788,11 +758,11 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
}
}
- public String getDefaultQueueName() {
+ public java.lang.String getDefaultQueueName() {
return this.defaultQueueName;
}
- public void setDefaultQueueName(String defaultQueueName) {
+ public void setDefaultQueueName(java.lang.String defaultQueueName) {
this.defaultQueueName = defaultQueueName;
}
@@ -821,16 +791,16 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
}
public void unsetDefaultNodeCount() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID);
}
/** Returns true if field defaultNodeCount is set (has been assigned a value) and false otherwise */
public boolean isSetDefaultNodeCount() {
- return EncodingUtils.testBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID);
}
public void setDefaultNodeCountIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID, value);
}
public int getDefaultCPUCount() {
@@ -843,16 +813,16 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
}
public void unsetDefaultCPUCount() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID);
}
/** Returns true if field defaultCPUCount is set (has been assigned a value) and false otherwise */
public boolean isSetDefaultCPUCount() {
- return EncodingUtils.testBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID);
}
public void setDefaultCPUCountIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID, value);
}
public int getDefaultWalltime() {
@@ -865,16 +835,16 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
}
public void unsetDefaultWalltime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID);
}
/** Returns true if field defaultWalltime is set (has been assigned a value) and false otherwise */
public boolean isSetDefaultWalltime() {
- return EncodingUtils.testBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID);
}
public void setDefaultWalltimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID, value);
}
public boolean isEditableByUser() {
@@ -887,25 +857,25 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
}
public void unsetEditableByUser() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __EDITABLEBYUSER_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __EDITABLEBYUSER_ISSET_ID);
}
/** Returns true if field editableByUser is set (has been assigned a value) and false otherwise */
public boolean isSetEditableByUser() {
- return EncodingUtils.testBit(__isset_bitfield, __EDITABLEBYUSER_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __EDITABLEBYUSER_ISSET_ID);
}
public void setEditableByUserIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __EDITABLEBYUSER_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __EDITABLEBYUSER_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case APP_DEPLOYMENT_ID:
if (value == null) {
unsetAppDeploymentId();
} else {
- setAppDeploymentId((String)value);
+ setAppDeploymentId((java.lang.String)value);
}
break;
@@ -913,7 +883,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (value == null) {
unsetAppModuleId();
} else {
- setAppModuleId((String)value);
+ setAppModuleId((java.lang.String)value);
}
break;
@@ -921,7 +891,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (value == null) {
unsetComputeHostId();
} else {
- setComputeHostId((String)value);
+ setComputeHostId((java.lang.String)value);
}
break;
@@ -929,7 +899,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (value == null) {
unsetExecutablePath();
} else {
- setExecutablePath((String)value);
+ setExecutablePath((java.lang.String)value);
}
break;
@@ -945,7 +915,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (value == null) {
unsetAppDeploymentDescription();
} else {
- setAppDeploymentDescription((String)value);
+ setAppDeploymentDescription((java.lang.String)value);
}
break;
@@ -953,7 +923,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (value == null) {
unsetModuleLoadCmds();
} else {
- setModuleLoadCmds((List<CommandObject>)value);
+ setModuleLoadCmds((java.util.List<CommandObject>)value);
}
break;
@@ -961,7 +931,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (value == null) {
unsetLibPrependPaths();
} else {
- setLibPrependPaths((List<SetEnvPaths>)value);
+ setLibPrependPaths((java.util.List<SetEnvPaths>)value);
}
break;
@@ -969,7 +939,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (value == null) {
unsetLibAppendPaths();
} else {
- setLibAppendPaths((List<SetEnvPaths>)value);
+ setLibAppendPaths((java.util.List<SetEnvPaths>)value);
}
break;
@@ -977,7 +947,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (value == null) {
unsetSetEnvironment();
} else {
- setSetEnvironment((List<SetEnvPaths>)value);
+ setSetEnvironment((java.util.List<SetEnvPaths>)value);
}
break;
@@ -985,7 +955,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (value == null) {
unsetPreJobCommands();
} else {
- setPreJobCommands((List<CommandObject>)value);
+ setPreJobCommands((java.util.List<CommandObject>)value);
}
break;
@@ -993,7 +963,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (value == null) {
unsetPostJobCommands();
} else {
- setPostJobCommands((List<CommandObject>)value);
+ setPostJobCommands((java.util.List<CommandObject>)value);
}
break;
@@ -1001,7 +971,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (value == null) {
unsetDefaultQueueName();
} else {
- setDefaultQueueName((String)value);
+ setDefaultQueueName((java.lang.String)value);
}
break;
@@ -1009,7 +979,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (value == null) {
unsetDefaultNodeCount();
} else {
- setDefaultNodeCount((Integer)value);
+ setDefaultNodeCount((java.lang.Integer)value);
}
break;
@@ -1017,7 +987,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (value == null) {
unsetDefaultCPUCount();
} else {
- setDefaultCPUCount((Integer)value);
+ setDefaultCPUCount((java.lang.Integer)value);
}
break;
@@ -1025,7 +995,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (value == null) {
unsetDefaultWalltime();
} else {
- setDefaultWalltime((Integer)value);
+ setDefaultWalltime((java.lang.Integer)value);
}
break;
@@ -1033,14 +1003,14 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (value == null) {
unsetEditableByUser();
} else {
- setEditableByUser((Boolean)value);
+ setEditableByUser((java.lang.Boolean)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case APP_DEPLOYMENT_ID:
return getAppDeploymentId();
@@ -1094,13 +1064,13 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return isEditableByUser();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -1139,11 +1109,11 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
case EDITABLE_BY_USER:
return isSetEditableByUser();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ApplicationDeploymentDescription)
@@ -1154,6 +1124,8 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
public boolean equals(ApplicationDeploymentDescription that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_appDeploymentId = true && this.isSetAppDeploymentId();
boolean that_present_appDeploymentId = true && that.isSetAppDeploymentId();
@@ -1313,94 +1285,77 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_appDeploymentId = true && (isSetAppDeploymentId());
- list.add(present_appDeploymentId);
- if (present_appDeploymentId)
- list.add(appDeploymentId);
-
- boolean present_appModuleId = true && (isSetAppModuleId());
- list.add(present_appModuleId);
- if (present_appModuleId)
- list.add(appModuleId);
-
- boolean present_computeHostId = true && (isSetComputeHostId());
- list.add(present_computeHostId);
- if (present_computeHostId)
- list.add(computeHostId);
-
- boolean present_executablePath = true && (isSetExecutablePath());
- list.add(present_executablePath);
- if (present_executablePath)
- list.add(executablePath);
-
- boolean present_parallelism = true && (isSetParallelism());
- list.add(present_parallelism);
- if (present_parallelism)
- list.add(parallelism.getValue());
-
- boolean present_appDeploymentDescription = true && (isSetAppDeploymentDescription());
- list.add(present_appDeploymentDescription);
- if (present_appDeploymentDescription)
- list.add(appDeploymentDescription);
-
- boolean present_moduleLoadCmds = true && (isSetModuleLoadCmds());
- list.add(present_moduleLoadCmds);
- if (present_moduleLoadCmds)
- list.add(moduleLoadCmds);
-
- boolean present_libPrependPaths = true && (isSetLibPrependPaths());
- list.add(present_libPrependPaths);
- if (present_libPrependPaths)
- list.add(libPrependPaths);
-
- boolean present_libAppendPaths = true && (isSetLibAppendPaths());
- list.add(present_libAppendPaths);
- if (present_libAppendPaths)
- list.add(libAppendPaths);
-
- boolean present_setEnvironment = true && (isSetSetEnvironment());
- list.add(present_setEnvironment);
- if (present_setEnvironment)
- list.add(setEnvironment);
-
- boolean present_preJobCommands = true && (isSetPreJobCommands());
- list.add(present_preJobCommands);
- if (present_preJobCommands)
- list.add(preJobCommands);
-
- boolean present_postJobCommands = true && (isSetPostJobCommands());
- list.add(present_postJobCommands);
- if (present_postJobCommands)
- list.add(postJobCommands);
-
- boolean present_defaultQueueName = true && (isSetDefaultQueueName());
- list.add(present_defaultQueueName);
- if (present_defaultQueueName)
- list.add(defaultQueueName);
-
- boolean present_defaultNodeCount = true && (isSetDefaultNodeCount());
- list.add(present_defaultNodeCount);
- if (present_defaultNodeCount)
- list.add(defaultNodeCount);
-
- boolean present_defaultCPUCount = true && (isSetDefaultCPUCount());
- list.add(present_defaultCPUCount);
- if (present_defaultCPUCount)
- list.add(defaultCPUCount);
-
- boolean present_defaultWalltime = true && (isSetDefaultWalltime());
- list.add(present_defaultWalltime);
- if (present_defaultWalltime)
- list.add(defaultWalltime);
-
- boolean present_editableByUser = true && (isSetEditableByUser());
- list.add(present_editableByUser);
- if (present_editableByUser)
- list.add(editableByUser);
-
- return list.hashCode();
+ int hashCode = 1;
+
+ hashCode = hashCode * 8191 + ((isSetAppDeploymentId()) ? 131071 : 524287);
+ if (isSetAppDeploymentId())
+ hashCode = hashCode * 8191 + appDeploymentId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetAppModuleId()) ? 131071 : 524287);
+ if (isSetAppModuleId())
+ hashCode = hashCode * 8191 + appModuleId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetComputeHostId()) ? 131071 : 524287);
+ if (isSetComputeHostId())
+ hashCode = hashCode * 8191 + computeHostId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetExecutablePath()) ? 131071 : 524287);
+ if (isSetExecutablePath())
+ hashCode = hashCode * 8191 + executablePath.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetParallelism()) ? 131071 : 524287);
+ if (isSetParallelism())
+ hashCode = hashCode * 8191 + parallelism.getValue();
+
+ hashCode = hashCode * 8191 + ((isSetAppDeploymentDescription()) ? 131071 : 524287);
+ if (isSetAppDeploymentDescription())
+ hashCode = hashCode * 8191 + appDeploymentDescription.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetModuleLoadCmds()) ? 131071 : 524287);
+ if (isSetModuleLoadCmds())
+ hashCode = hashCode * 8191 + moduleLoadCmds.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetLibPrependPaths()) ? 131071 : 524287);
+ if (isSetLibPrependPaths())
+ hashCode = hashCode * 8191 + libPrependPaths.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetLibAppendPaths()) ? 131071 : 524287);
+ if (isSetLibAppendPaths())
+ hashCode = hashCode * 8191 + libAppendPaths.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetSetEnvironment()) ? 131071 : 524287);
+ if (isSetSetEnvironment())
+ hashCode = hashCode * 8191 + setEnvironment.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetPreJobCommands()) ? 131071 : 524287);
+ if (isSetPreJobCommands())
+ hashCode = hashCode * 8191 + preJobCommands.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetPostJobCommands()) ? 131071 : 524287);
+ if (isSetPostJobCommands())
+ hashCode = hashCode * 8191 + postJobCommands.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetDefaultQueueName()) ? 131071 : 524287);
+ if (isSetDefaultQueueName())
+ hashCode = hashCode * 8191 + defaultQueueName.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetDefaultNodeCount()) ? 131071 : 524287);
+ if (isSetDefaultNodeCount())
+ hashCode = hashCode * 8191 + defaultNodeCount;
+
+ hashCode = hashCode * 8191 + ((isSetDefaultCPUCount()) ? 131071 : 524287);
+ if (isSetDefaultCPUCount())
+ hashCode = hashCode * 8191 + defaultCPUCount;
+
+ hashCode = hashCode * 8191 + ((isSetDefaultWalltime()) ? 131071 : 524287);
+ if (isSetDefaultWalltime())
+ hashCode = hashCode * 8191 + defaultWalltime;
+
+ hashCode = hashCode * 8191 + ((isSetEditableByUser()) ? 131071 : 524287);
+ if (isSetEditableByUser())
+ hashCode = hashCode * 8191 + ((editableByUser) ? 131071 : 524287);
+
+ return hashCode;
}
@Override
@@ -1411,7 +1366,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetAppDeploymentId()).compareTo(other.isSetAppDeploymentId());
+ lastComparison = java.lang.Boolean.valueOf(isSetAppDeploymentId()).compareTo(other.isSetAppDeploymentId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1421,7 +1376,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAppModuleId()).compareTo(other.isSetAppModuleId());
+ lastComparison = java.lang.Boolean.valueOf(isSetAppModuleId()).compareTo(other.isSetAppModuleId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1431,7 +1386,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetComputeHostId()).compareTo(other.isSetComputeHostId());
+ lastComparison = java.lang.Boolean.valueOf(isSetComputeHostId()).compareTo(other.isSetComputeHostId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1441,7 +1396,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetExecutablePath()).compareTo(other.isSetExecutablePath());
+ lastComparison = java.lang.Boolean.valueOf(isSetExecutablePath()).compareTo(other.isSetExecutablePath());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1451,7 +1406,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetParallelism()).compareTo(other.isSetParallelism());
+ lastComparison = java.lang.Boolean.valueOf(isSetParallelism()).compareTo(other.isSetParallelism());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1461,7 +1416,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAppDeploymentDescription()).compareTo(other.isSetAppDeploymentDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetAppDeploymentDescription()).compareTo(other.isSetAppDeploymentDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1471,7 +1426,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetModuleLoadCmds()).compareTo(other.isSetModuleLoadCmds());
+ lastComparison = java.lang.Boolean.valueOf(isSetModuleLoadCmds()).compareTo(other.isSetModuleLoadCmds());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1481,7 +1436,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetLibPrependPaths()).compareTo(other.isSetLibPrependPaths());
+ lastComparison = java.lang.Boolean.valueOf(isSetLibPrependPaths()).compareTo(other.isSetLibPrependPaths());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1491,7 +1446,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetLibAppendPaths()).compareTo(other.isSetLibAppendPaths());
+ lastComparison = java.lang.Boolean.valueOf(isSetLibAppendPaths()).compareTo(other.isSetLibAppendPaths());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1501,7 +1456,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetSetEnvironment()).compareTo(other.isSetSetEnvironment());
+ lastComparison = java.lang.Boolean.valueOf(isSetSetEnvironment()).compareTo(other.isSetSetEnvironment());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1511,7 +1466,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPreJobCommands()).compareTo(other.isSetPreJobCommands());
+ lastComparison = java.lang.Boolean.valueOf(isSetPreJobCommands()).compareTo(other.isSetPreJobCommands());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1521,7 +1476,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPostJobCommands()).compareTo(other.isSetPostJobCommands());
+ lastComparison = java.lang.Boolean.valueOf(isSetPostJobCommands()).compareTo(other.isSetPostJobCommands());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1531,7 +1486,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDefaultQueueName()).compareTo(other.isSetDefaultQueueName());
+ lastComparison = java.lang.Boolean.valueOf(isSetDefaultQueueName()).compareTo(other.isSetDefaultQueueName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1541,7 +1496,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDefaultNodeCount()).compareTo(other.isSetDefaultNodeCount());
+ lastComparison = java.lang.Boolean.valueOf(isSetDefaultNodeCount()).compareTo(other.isSetDefaultNodeCount());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1551,7 +1506,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDefaultCPUCount()).compareTo(other.isSetDefaultCPUCount());
+ lastComparison = java.lang.Boolean.valueOf(isSetDefaultCPUCount()).compareTo(other.isSetDefaultCPUCount());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1561,7 +1516,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDefaultWalltime()).compareTo(other.isSetDefaultWalltime());
+ lastComparison = java.lang.Boolean.valueOf(isSetDefaultWalltime()).compareTo(other.isSetDefaultWalltime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1571,7 +1526,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetEditableByUser()).compareTo(other.isSetEditableByUser());
+ lastComparison = java.lang.Boolean.valueOf(isSetEditableByUser()).compareTo(other.isSetEditableByUser());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1589,16 +1544,16 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ApplicationDeploymentDescription(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ApplicationDeploymentDescription(");
boolean first = true;
sb.append("appDeploymentId:");
@@ -1781,7 +1736,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -1791,13 +1746,13 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
}
}
- private static class ApplicationDeploymentDescriptionStandardSchemeFactory implements SchemeFactory {
+ private static class ApplicationDeploymentDescriptionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ApplicationDeploymentDescriptionStandardScheme getScheme() {
return new ApplicationDeploymentDescriptionStandardScheme();
}
}
- private static class ApplicationDeploymentDescriptionStandardScheme extends StandardScheme<ApplicationDeploymentDescription> {
+ private static class ApplicationDeploymentDescriptionStandardScheme extends org.apache.thrift.scheme.StandardScheme<ApplicationDeploymentDescription> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ApplicationDeploymentDescription struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1861,7 +1816,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list0 = iprot.readListBegin();
- struct.moduleLoadCmds = new ArrayList<CommandObject>(_list0.size);
+ struct.moduleLoadCmds = new java.util.ArrayList<CommandObject>(_list0.size);
CommandObject _elem1;
for (int _i2 = 0; _i2 < _list0.size; ++_i2)
{
@@ -1880,7 +1835,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list3 = iprot.readListBegin();
- struct.libPrependPaths = new ArrayList<SetEnvPaths>(_list3.size);
+ struct.libPrependPaths = new java.util.ArrayList<SetEnvPaths>(_list3.size);
SetEnvPaths _elem4;
for (int _i5 = 0; _i5 < _list3.size; ++_i5)
{
@@ -1899,7 +1854,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list6 = iprot.readListBegin();
- struct.libAppendPaths = new ArrayList<SetEnvPaths>(_list6.size);
+ struct.libAppendPaths = new java.util.ArrayList<SetEnvPaths>(_list6.size);
SetEnvPaths _elem7;
for (int _i8 = 0; _i8 < _list6.size; ++_i8)
{
@@ -1918,7 +1873,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list9 = iprot.readListBegin();
- struct.setEnvironment = new ArrayList<SetEnvPaths>(_list9.size);
+ struct.setEnvironment = new java.util.ArrayList<SetEnvPaths>(_list9.size);
SetEnvPaths _elem10;
for (int _i11 = 0; _i11 < _list9.size; ++_i11)
{
@@ -1937,7 +1892,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list12 = iprot.readListBegin();
- struct.preJobCommands = new ArrayList<CommandObject>(_list12.size);
+ struct.preJobCommands = new java.util.ArrayList<CommandObject>(_list12.size);
CommandObject _elem13;
for (int _i14 = 0; _i14 < _list12.size; ++_i14)
{
@@ -1956,7 +1911,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list15 = iprot.readListBegin();
- struct.postJobCommands = new ArrayList<CommandObject>(_list15.size);
+ struct.postJobCommands = new java.util.ArrayList<CommandObject>(_list15.size);
CommandObject _elem16;
for (int _i17 = 0; _i17 < _list15.size; ++_i17)
{
@@ -2173,23 +2128,23 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
}
- private static class ApplicationDeploymentDescriptionTupleSchemeFactory implements SchemeFactory {
+ private static class ApplicationDeploymentDescriptionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ApplicationDeploymentDescriptionTupleScheme getScheme() {
return new ApplicationDeploymentDescriptionTupleScheme();
}
}
- private static class ApplicationDeploymentDescriptionTupleScheme extends TupleScheme<ApplicationDeploymentDescription> {
+ private static class ApplicationDeploymentDescriptionTupleScheme extends org.apache.thrift.scheme.TupleScheme<ApplicationDeploymentDescription> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ApplicationDeploymentDescription struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.appDeploymentId);
oprot.writeString(struct.appModuleId);
oprot.writeString(struct.computeHostId);
oprot.writeString(struct.executablePath);
oprot.writeI32(struct.parallelism.getValue());
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetAppDeploymentDescription()) {
optionals.set(0);
}
@@ -2303,7 +2258,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ApplicationDeploymentDescription struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.appDeploymentId = iprot.readString();
struct.setAppDeploymentIdIsSet(true);
struct.appModuleId = iprot.readString();
@@ -2314,7 +2269,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
struct.setExecutablePathIsSet(true);
struct.parallelism = org.apache.airavata.model.parallelism.ApplicationParallelismType.findByValue(iprot.readI32());
struct.setParallelismIsSet(true);
- BitSet incoming = iprot.readBitSet(12);
+ java.util.BitSet incoming = iprot.readBitSet(12);
if (incoming.get(0)) {
struct.appDeploymentDescription = iprot.readString();
struct.setAppDeploymentDescriptionIsSet(true);
@@ -2322,7 +2277,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (incoming.get(1)) {
{
org.apache.thrift.protocol.TList _list30 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.moduleLoadCmds = new ArrayList<CommandObject>(_list30.size);
+ struct.moduleLoadCmds = new java.util.ArrayList<CommandObject>(_list30.size);
CommandObject _elem31;
for (int _i32 = 0; _i32 < _list30.size; ++_i32)
{
@@ -2336,7 +2291,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (incoming.get(2)) {
{
org.apache.thrift.protocol.TList _list33 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.libPrependPaths = new ArrayList<SetEnvPaths>(_list33.size);
+ struct.libPrependPaths = new java.util.ArrayList<SetEnvPaths>(_list33.size);
SetEnvPaths _elem34;
for (int _i35 = 0; _i35 < _list33.size; ++_i35)
{
@@ -2350,7 +2305,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (incoming.get(3)) {
{
org.apache.thrift.protocol.TList _list36 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.libAppendPaths = new ArrayList<SetEnvPaths>(_list36.size);
+ struct.libAppendPaths = new java.util.ArrayList<SetEnvPaths>(_list36.size);
SetEnvPaths _elem37;
for (int _i38 = 0; _i38 < _list36.size; ++_i38)
{
@@ -2364,7 +2319,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (incoming.get(4)) {
{
org.apache.thrift.protocol.TList _list39 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.setEnvironment = new ArrayList<SetEnvPaths>(_list39.size);
+ struct.setEnvironment = new java.util.ArrayList<SetEnvPaths>(_list39.size);
SetEnvPaths _elem40;
for (int _i41 = 0; _i41 < _list39.size; ++_i41)
{
@@ -2378,7 +2333,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (incoming.get(5)) {
{
org.apache.thrift.protocol.TList _list42 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.preJobCommands = new ArrayList<CommandObject>(_list42.size);
+ struct.preJobCommands = new java.util.ArrayList<CommandObject>(_list42.size);
CommandObject _elem43;
for (int _i44 = 0; _i44 < _list42.size; ++_i44)
{
@@ -2392,7 +2347,7 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
if (incoming.get(6)) {
{
org.apache.thrift.protocol.TList _list45 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.postJobCommands = new ArrayList<CommandObject>(_list45.size);
+ struct.postJobCommands = new java.util.ArrayList<CommandObject>(_list45.size);
CommandObject _elem46;
for (int _i47 = 0; _i47 < _list45.size; ++_i47)
{
@@ -2426,5 +2381,8 @@ public class ApplicationDeploymentDescription implements org.apache.thrift.TBase
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/ApplicationModule.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/ApplicationModule.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/ApplicationModule.java
index f574e9a..746df51 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/ApplicationModule.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/appdeployment/ApplicationModule.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.appdeployment;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Application Module Information. A module has to be registered before registering a deployment.
*
@@ -66,7 +39,7 @@ import org.slf4j.LoggerFactory;
* Descriprion of the Module
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class ApplicationModule implements org.apache.thrift.TBase<ApplicationModule, ApplicationModule._Fields>, java.io.Serializable, Cloneable, Comparable<ApplicationModule> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ApplicationModule");
@@ -75,16 +48,13 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
private static final org.apache.thrift.protocol.TField APP_MODULE_VERSION_FIELD_DESC = new org.apache.thrift.protocol.TField("appModuleVersion", org.apache.thrift.protocol.TType.STRING, (short)3);
private static final org.apache.thrift.protocol.TField APP_MODULE_DESCRIPTION_FIELD_DESC = new org.apache.thrift.protocol.TField("appModuleDescription", 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 ApplicationModuleStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ApplicationModuleTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ApplicationModuleStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ApplicationModuleTupleSchemeFactory();
- private String appModuleId; // required
- private String appModuleName; // required
- private String appModuleVersion; // optional
- private String appModuleDescription; // optional
+ private java.lang.String appModuleId; // required
+ private java.lang.String appModuleName; // required
+ private java.lang.String appModuleVersion; // optional
+ private java.lang.String appModuleDescription; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -93,10 +63,10 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
APP_MODULE_VERSION((short)3, "appModuleVersion"),
APP_MODULE_DESCRIPTION((short)4, "appModuleDescription");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -125,21 +95,21 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -148,16 +118,16 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
private static final _Fields optionals[] = {_Fields.APP_MODULE_VERSION,_Fields.APP_MODULE_DESCRIPTION};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.APP_MODULE_ID, new org.apache.thrift.meta_data.FieldMetaData("appModuleId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.APP_MODULE_NAME, new org.apache.thrift.meta_data.FieldMetaData("appModuleName", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -166,7 +136,7 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.APP_MODULE_DESCRIPTION, new org.apache.thrift.meta_data.FieldMetaData("appModuleDescription", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ApplicationModule.class, metaDataMap);
}
@@ -176,8 +146,8 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
}
public ApplicationModule(
- String appModuleId,
- String appModuleName)
+ java.lang.String appModuleId,
+ java.lang.String appModuleName)
{
this();
this.appModuleId = appModuleId;
@@ -215,11 +185,11 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
this.appModuleDescription = null;
}
- public String getAppModuleId() {
+ public java.lang.String getAppModuleId() {
return this.appModuleId;
}
- public void setAppModuleId(String appModuleId) {
+ public void setAppModuleId(java.lang.String appModuleId) {
this.appModuleId = appModuleId;
}
@@ -238,11 +208,11 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
}
}
- public String getAppModuleName() {
+ public java.lang.String getAppModuleName() {
return this.appModuleName;
}
- public void setAppModuleName(String appModuleName) {
+ public void setAppModuleName(java.lang.String appModuleName) {
this.appModuleName = appModuleName;
}
@@ -261,11 +231,11 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
}
}
- public String getAppModuleVersion() {
+ public java.lang.String getAppModuleVersion() {
return this.appModuleVersion;
}
- public void setAppModuleVersion(String appModuleVersion) {
+ public void setAppModuleVersion(java.lang.String appModuleVersion) {
this.appModuleVersion = appModuleVersion;
}
@@ -284,11 +254,11 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
}
}
- public String getAppModuleDescription() {
+ public java.lang.String getAppModuleDescription() {
return this.appModuleDescription;
}
- public void setAppModuleDescription(String appModuleDescription) {
+ public void setAppModuleDescription(java.lang.String appModuleDescription) {
this.appModuleDescription = appModuleDescription;
}
@@ -307,13 +277,13 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case APP_MODULE_ID:
if (value == null) {
unsetAppModuleId();
} else {
- setAppModuleId((String)value);
+ setAppModuleId((java.lang.String)value);
}
break;
@@ -321,7 +291,7 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
if (value == null) {
unsetAppModuleName();
} else {
- setAppModuleName((String)value);
+ setAppModuleName((java.lang.String)value);
}
break;
@@ -329,7 +299,7 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
if (value == null) {
unsetAppModuleVersion();
} else {
- setAppModuleVersion((String)value);
+ setAppModuleVersion((java.lang.String)value);
}
break;
@@ -337,14 +307,14 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
if (value == null) {
unsetAppModuleDescription();
} else {
- setAppModuleDescription((String)value);
+ setAppModuleDescription((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case APP_MODULE_ID:
return getAppModuleId();
@@ -359,13 +329,13 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
return getAppModuleDescription();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -378,11 +348,11 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
case APP_MODULE_DESCRIPTION:
return isSetAppModuleDescription();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ApplicationModule)
@@ -393,6 +363,8 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
public boolean equals(ApplicationModule that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_appModuleId = true && this.isSetAppModuleId();
boolean that_present_appModuleId = true && that.isSetAppModuleId();
@@ -435,29 +407,25 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_appModuleId = true && (isSetAppModuleId());
- list.add(present_appModuleId);
- if (present_appModuleId)
- list.add(appModuleId);
+ hashCode = hashCode * 8191 + ((isSetAppModuleId()) ? 131071 : 524287);
+ if (isSetAppModuleId())
+ hashCode = hashCode * 8191 + appModuleId.hashCode();
- boolean present_appModuleName = true && (isSetAppModuleName());
- list.add(present_appModuleName);
- if (present_appModuleName)
- list.add(appModuleName);
+ hashCode = hashCode * 8191 + ((isSetAppModuleName()) ? 131071 : 524287);
+ if (isSetAppModuleName())
+ hashCode = hashCode * 8191 + appModuleName.hashCode();
- boolean present_appModuleVersion = true && (isSetAppModuleVersion());
- list.add(present_appModuleVersion);
- if (present_appModuleVersion)
- list.add(appModuleVersion);
+ hashCode = hashCode * 8191 + ((isSetAppModuleVersion()) ? 131071 : 524287);
+ if (isSetAppModuleVersion())
+ hashCode = hashCode * 8191 + appModuleVersion.hashCode();
- boolean present_appModuleDescription = true && (isSetAppModuleDescription());
- list.add(present_appModuleDescription);
- if (present_appModuleDescription)
- list.add(appModuleDescription);
+ hashCode = hashCode * 8191 + ((isSetAppModuleDescription()) ? 131071 : 524287);
+ if (isSetAppModuleDescription())
+ hashCode = hashCode * 8191 + appModuleDescription.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -468,7 +436,7 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetAppModuleId()).compareTo(other.isSetAppModuleId());
+ lastComparison = java.lang.Boolean.valueOf(isSetAppModuleId()).compareTo(other.isSetAppModuleId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -478,7 +446,7 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAppModuleName()).compareTo(other.isSetAppModuleName());
+ lastComparison = java.lang.Boolean.valueOf(isSetAppModuleName()).compareTo(other.isSetAppModuleName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -488,7 +456,7 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAppModuleVersion()).compareTo(other.isSetAppModuleVersion());
+ lastComparison = java.lang.Boolean.valueOf(isSetAppModuleVersion()).compareTo(other.isSetAppModuleVersion());
if (lastComparison != 0) {
return lastComparison;
}
@@ -498,7 +466,7 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAppModuleDescription()).compareTo(other.isSetAppModuleDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetAppModuleDescription()).compareTo(other.isSetAppModuleDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -516,16 +484,16 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ApplicationModule(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ApplicationModule(");
boolean first = true;
sb.append("appModuleId:");
@@ -588,7 +556,7 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -596,13 +564,13 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
}
}
- private static class ApplicationModuleStandardSchemeFactory implements SchemeFactory {
+ private static class ApplicationModuleStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ApplicationModuleStandardScheme getScheme() {
return new ApplicationModuleStandardScheme();
}
}
- private static class ApplicationModuleStandardScheme extends StandardScheme<ApplicationModule> {
+ private static class ApplicationModuleStandardScheme extends org.apache.thrift.scheme.StandardScheme<ApplicationModule> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ApplicationModule struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -689,20 +657,20 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
}
- private static class ApplicationModuleTupleSchemeFactory implements SchemeFactory {
+ private static class ApplicationModuleTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ApplicationModuleTupleScheme getScheme() {
return new ApplicationModuleTupleScheme();
}
}
- private static class ApplicationModuleTupleScheme extends TupleScheme<ApplicationModule> {
+ private static class ApplicationModuleTupleScheme extends org.apache.thrift.scheme.TupleScheme<ApplicationModule> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ApplicationModule struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.appModuleId);
oprot.writeString(struct.appModuleName);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetAppModuleVersion()) {
optionals.set(0);
}
@@ -720,12 +688,12 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ApplicationModule struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.appModuleId = iprot.readString();
struct.setAppModuleIdIsSet(true);
struct.appModuleName = iprot.readString();
struct.setAppModuleNameIsSet(true);
- BitSet incoming = iprot.readBitSet(2);
+ java.util.BitSet incoming = iprot.readBitSet(2);
if (incoming.get(0)) {
struct.appModuleVersion = iprot.readString();
struct.setAppModuleVersionIsSet(true);
@@ -737,5 +705,8 @@ public class ApplicationModule implements org.apache.thrift.TBase<ApplicationMod
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
[47/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/Airavata.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/Airavata.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/Airavata.py
index ee69980..8263292 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/Airavata.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/Airavata.py
@@ -1,54851 +1,52177 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import logging
-from ttypes import *
+from .ttypes import *
from thrift.Thrift import TProcessor
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-class Iface:
- def getAPIVersion(self, authzToken):
- """
- Fetch Apache Airavata API version
+class Iface(object):
+ def getAPIVersion(self, authzToken):
+ """
+ Fetch Apache Airavata API version
- Parameters:
- - authzToken
- """
- pass
+ Parameters:
+ - authzToken
+ """
+ pass
- def isUserExists(self, authzToken, gatewayId, userName):
- """
- Verify if User Exists within Airavata.
+ def isUserExists(self, authzToken, gatewayId, userName):
+ """
+ Verify if User Exists within Airavata.
- @param gatewayId
+ @param gatewayId
- @param userName
+ @param userName
- @return true/false
+ @return true/false
- Parameters:
- - authzToken
- - gatewayId
- - userName
- """
- pass
+ Parameters:
+ - authzToken
+ - gatewayId
+ - userName
+ """
+ pass
- def addGateway(self, authzToken, gateway):
- """
- Register a Gateway with Airavata.
+ def addGateway(self, authzToken, gateway):
+ """
+ Register a Gateway with Airavata.
- @param gateway
- The gateway data model.
+ @param gateway
+ The gateway data model.
- @return gatewayId
- Th unique identifier of the newly registered gateway.
+ @return gatewayId
+ Th unique identifier of the newly registered gateway.
- Parameters:
- - authzToken
- - gateway
- """
- pass
+ Parameters:
+ - authzToken
+ - gateway
+ """
+ pass
- def getAllUsersInGateway(self, authzToken, gatewayId):
- """
- Get all users in the gateway
+ def getAllUsersInGateway(self, authzToken, gatewayId):
+ """
+ Get all users in the gateway
- @param gatewayId
- The gateway data model.
+ @param gatewayId
+ The gateway data model.
- @return users
- list of usernames of the users in the gateway
+ @return users
+ list of usernames of the users in the gateway
- Parameters:
- - authzToken
- - gatewayId
- """
- pass
+ Parameters:
+ - authzToken
+ - gatewayId
+ """
+ pass
- def updateGateway(self, authzToken, gatewayId, updatedGateway):
- """
- Update previously registered Gateway metadata.
+ def updateGateway(self, authzToken, gatewayId, updatedGateway):
+ """
+ Update previously registered Gateway metadata.
- @param gatewayId
- The gateway Id of the Gateway which require an update.
+ @param gatewayId
+ The gateway Id of the Gateway which require an update.
- @return gateway
- Modified gateway obejct.
+ @return gateway
+ Modified gateway obejct.
- @exception AiravataClientException
+ @exception AiravataClientException
- Parameters:
- - authzToken
- - gatewayId
- - updatedGateway
- """
- pass
+ Parameters:
+ - authzToken
+ - gatewayId
+ - updatedGateway
+ """
+ pass
- def getGateway(self, authzToken, gatewayId):
- """
- Get Gateway details by providing gatewayId
+ def getGateway(self, authzToken, gatewayId):
+ """
+ Get Gateway details by providing gatewayId
- @param gatewayId
- The gateway Id of the Gateway.
+ @param gatewayId
+ The gateway Id of the Gateway.
- @return gateway
- Gateway obejct.
+ @return gateway
+ Gateway obejct.
- Parameters:
- - authzToken
- - gatewayId
- """
- pass
+ Parameters:
+ - authzToken
+ - gatewayId
+ """
+ pass
- def deleteGateway(self, authzToken, gatewayId):
- """
- Delete a Gateway
+ def deleteGateway(self, authzToken, gatewayId):
+ """
+ Delete a Gateway
- @param gatewayId
- The gateway Id of the Gateway to be deleted.
+ @param gatewayId
+ The gateway Id of the Gateway to be deleted.
- @return boolean
- Boolean identifier for the success or failure of the deletion operation.
+ @return boolean
+ Boolean identifier for the success or failure of the deletion operation.
- Parameters:
- - authzToken
- - gatewayId
- """
- pass
+ Parameters:
+ - authzToken
+ - gatewayId
+ """
+ pass
- def getAllGateways(self, authzToken):
- """
- Get All the Gateways Connected to Airavata.
+ def getAllGateways(self, authzToken):
+ """
+ Get All the Gateways Connected to Airavata.
- Parameters:
- - authzToken
- """
- pass
+ Parameters:
+ - authzToken
+ """
+ pass
- def isGatewayExist(self, authzToken, gatewayId):
- """
- Check for the Existance of a Gateway within Airavata
+ def isGatewayExist(self, authzToken, gatewayId):
+ """
+ Check for the Existance of a Gateway within Airavata
- @param gatewayId
- Provide the gatewayId of the gateway you want to check the existancy
+ @param gatewayId
+ Provide the gatewayId of the gateway you want to check the existancy
- @return boolean
- Boolean idetifier for the existance or non-existane of the gatewayId
+ @return boolean
+ Boolean idetifier for the existance or non-existane of the gatewayId
- @return gatewayId
- return the gatewayId of the existing gateway.
+ @return gatewayId
+ return the gatewayId of the existing gateway.
- Parameters:
- - authzToken
- - gatewayId
- """
- pass
+ Parameters:
+ - authzToken
+ - gatewayId
+ """
+ pass
- def createNotification(self, authzToken, notification):
- """
- * API methods to retrieve notifications
- *
+ def createNotification(self, authzToken, notification):
+ """
+ * API methods to retrieve notifications
+ *
- Parameters:
- - authzToken
- - notification
- """
- pass
+ Parameters:
+ - authzToken
+ - notification
+ """
+ pass
- def updateNotification(self, authzToken, notification):
- """
- Parameters:
- - authzToken
- - notification
- """
- pass
+ def updateNotification(self, authzToken, notification):
+ """
+ Parameters:
+ - authzToken
+ - notification
+ """
+ pass
- def deleteNotification(self, authzToken, gatewayId, notificationId):
- """
- Parameters:
- - authzToken
- - gatewayId
- - notificationId
- """
- pass
+ def deleteNotification(self, authzToken, gatewayId, notificationId):
+ """
+ Parameters:
+ - authzToken
+ - gatewayId
+ - notificationId
+ """
+ pass
- def getNotification(self, authzToken, gatewayId, notificationId):
- """
- Parameters:
- - authzToken
- - gatewayId
- - notificationId
- """
- pass
+ def getNotification(self, authzToken, gatewayId, notificationId):
+ """
+ Parameters:
+ - authzToken
+ - gatewayId
+ - notificationId
+ """
+ pass
- def getAllNotifications(self, authzToken, gatewayId):
- """
- Parameters:
- - authzToken
- - gatewayId
- """
- pass
+ def getAllNotifications(self, authzToken, gatewayId):
+ """
+ Parameters:
+ - authzToken
+ - gatewayId
+ """
+ pass
- def generateAndRegisterSSHKeys(self, authzToken, gatewayId, userName, description, credentialOwnerType):
- """
- Generate and Register SSH Key Pair with Airavata Credential Store.
+ def generateAndRegisterSSHKeys(self, authzToken, gatewayId, userName, description, credentialOwnerType):
+ """
+ Generate and Register SSH Key Pair with Airavata Credential Store.
- @param gatewayId
- The identifier for the requested Gateway.
+ @param gatewayId
+ The identifier for the requested Gateway.
- @param userName
- The User for which the credential should be registered. For community accounts, this user is the name of the
- community user name. For computational resources, this user name need not be the same user name on resoruces.
+ @param userName
+ The User for which the credential should be registered. For community accounts, this user is the name of the
+ community user name. For computational resources, this user name need not be the same user name on resoruces.
- @param description
- The description field for a credential type, all type of credential can have a description.
+ @param description
+ The description field for a credential type, all type of credential can have a description.
- @param credentialOwnerType
- The type of owner of this credential. Two possible values: GATEWAY (default) and USER
+ @param credentialOwnerType
+ The type of owner of this credential. Two possible values: GATEWAY (default) and USER
- @return airavataCredStoreToken
- An SSH Key pair is generated and stored in the credential store and associated with users or community account
- belonging to a Gateway.
+ @return airavataCredStoreToken
+ An SSH Key pair is generated and stored in the credential store and associated with users or community account
+ belonging to a Gateway.
- Parameters:
- - authzToken
- - gatewayId
- - userName
- - description
- - credentialOwnerType
- """
- pass
+ Parameters:
+ - authzToken
+ - gatewayId
+ - userName
+ - description
+ - credentialOwnerType
+ """
+ pass
- def registerPwdCredential(self, authzToken, gatewayId, portalUserName, loginUserName, password, description):
- """
- Generate and Register Username PWD Pair with Airavata Credential Store.
+ def registerPwdCredential(self, authzToken, gatewayId, portalUserName, loginUserName, password, description):
+ """
+ Generate and Register Username PWD Pair with Airavata Credential Store.
- @param gatewayId
- The identifier for the requested Gateway.
+ @param gatewayId
+ The identifier for the requested Gateway.
- @param portalUserName
- The User for which the credential should be registered. For community accounts, this user is the name of the
- community user name. For computational resources, this user name need not be the same user name on resoruces.
+ @param portalUserName
+ The User for which the credential should be registered. For community accounts, this user is the name of the
+ community user name. For computational resources, this user name need not be the same user name on resoruces.
- @param loginUserName
+ @param loginUserName
- @param password
+ @param password
- @return airavataCredStoreToken
- An SSH Key pair is generated and stored in the credential store and associated with users or community account
- belonging to a Gateway.
+ @return airavataCredStoreToken
+ An SSH Key pair is generated and stored in the credential store and associated with users or community account
+ belonging to a Gateway.
- Parameters:
- - authzToken
- - gatewayId
- - portalUserName
- - loginUserName
- - password
- - description
- """
- pass
+ Parameters:
+ - authzToken
+ - gatewayId
+ - portalUserName
+ - loginUserName
+ - password
+ - description
+ """
+ pass
- def getSSHPubKey(self, authzToken, airavataCredStoreToken, gatewayId):
- """
- Get a Public Key by Providing the Token
+ def getSSHPubKey(self, authzToken, airavataCredStoreToken, gatewayId):
+ """
+ Get a Public Key by Providing the Token
- @param CredStoreToken
- Credential Store Token which you want to find the Public Key for.
+ @param CredStoreToken
+ Credential Store Token which you want to find the Public Key for.
- @param gatewayId
- This is the unique identifier of your gateway where the token and public key was generated from.
+ @param gatewayId
+ This is the unique identifier of your gateway where the token and public key was generated from.
- @return publicKey
+ @return publicKey
- Parameters:
- - authzToken
- - airavataCredStoreToken
- - gatewayId
- """
- pass
+ Parameters:
+ - authzToken
+ - airavataCredStoreToken
+ - gatewayId
+ """
+ pass
- def getAllGatewaySSHPubKeys(self, authzToken, gatewayId):
- """
+ def getAllGatewaySSHPubKeys(self, authzToken, gatewayId):
+ """
- Get all Public Keys of the Gateway
+ Get all Public Keys of the Gateway
- @param CredStoreToken
- Credential Store Token which you want to find the Public Key for.
+ @param CredStoreToken
+ Credential Store Token which you want to find the Public Key for.
- @param gatewayId
- This is the unique identifier of your gateway where the token and public key was generated from.
+ @param gatewayId
+ This is the unique identifier of your gateway where the token and public key was generated from.
- @return publicKey
+ @return publicKey
- Parameters:
- - authzToken
- - gatewayId
- """
- pass
+ Parameters:
+ - authzToken
+ - gatewayId
+ """
+ pass
- def getAllCredentialSummaryForGateway(self, authzToken, type, gatewayId):
- """
+ def getAllCredentialSummaryForGateway(self, authzToken, type, gatewayId):
+ """
- Get all Credential summaries for the Gateway
+ Get all Credential summaries for the Gateway
- @param CredStoreToken
- Credential Store Token which you want to find the Public Key for.
+ @param CredStoreToken
+ Credential Store Token which you want to find the Public Key for.
- @param credential_store_data_models.SummaryType
- Summary type : SSH,PASSWD or CERT
+ @param credential_store_data_models.SummaryType
+ Summary type : SSH,PASSWD or CERT
- @param gatewayId
- This is the unique identifier of your gateway where the token and public key was generated from.
+ @param gatewayId
+ This is the unique identifier of your gateway where the token and public key was generated from.
- @return List of Credential Summary Objects
+ @return List of Credential Summary Objects
- Parameters:
- - authzToken
- - type
- - gatewayId
- """
- pass
+ Parameters:
+ - authzToken
+ - type
+ - gatewayId
+ """
+ pass
- def getAllCredentialSummaryForUsersInGateway(self, authzToken, type, gatewayId, userId):
- """
+ def getAllCredentialSummaryForUsersInGateway(self, authzToken, type, gatewayId, userId):
+ """
- Get all Credential summaries for user in a Gateway
+ Get all Credential summaries for user in a Gateway
- @param CredStoreToken
- Credential Store Token which you want to find the Public Key for.
+ @param CredStoreToken
+ Credential Store Token which you want to find the Public Key for.
- @param credential_store_data_models.SummaryType
- Summary type : SSH,PASSWD or CERT
+ @param credential_store_data_models.SummaryType
+ Summary type : SSH,PASSWD or CERT
- @param gatewayId
- This is the unique identifier of your gateway where the token and public key was generated from.
+ @param gatewayId
+ This is the unique identifier of your gateway where the token and public key was generated from.
- @param userId
- This is the unique identifier of user whose public keys are to be fetched.
+ @param userId
+ This is the unique identifier of user whose public keys are to be fetched.
- @return CredentialSummary
+ @return CredentialSummary
- Parameters:
- - authzToken
- - type
- - gatewayId
- - userId
- """
- pass
+ Parameters:
+ - authzToken
+ - type
+ - gatewayId
+ - userId
+ """
+ pass
- def getAllGatewayPWDCredentials(self, authzToken, gatewayId):
- """
- Parameters:
- - authzToken
- - gatewayId
- """
- pass
+ def getAllGatewayPWDCredentials(self, authzToken, gatewayId):
+ """
+ Parameters:
+ - authzToken
+ - gatewayId
+ """
+ pass
- def deleteSSHPubKey(self, authzToken, airavataCredStoreToken, gatewayId):
- """
+ def deleteSSHPubKey(self, authzToken, airavataCredStoreToken, gatewayId):
+ """
- Delete a Gateway
+ Delete a Gateway
- @param gatewayId
- The gateway Id of the Gateway to be deleted.
+ @param gatewayId
+ The gateway Id of the Gateway to be deleted.
- @return boolean
- Boolean identifier for the success or failure of the deletion operation.
+ @return boolean
+ Boolean identifier for the success or failure of the deletion operation.
- Parameters:
- - authzToken
- - airavataCredStoreToken
- - gatewayId
- """
- pass
+ Parameters:
+ - authzToken
+ - airavataCredStoreToken
+ - gatewayId
+ """
+ pass
- def deletePWDCredential(self, authzToken, airavataCredStoreToken, gatewayId):
- """
- Parameters:
- - authzToken
- - airavataCredStoreToken
- - gatewayId
- """
- pass
+ def deletePWDCredential(self, authzToken, airavataCredStoreToken, gatewayId):
+ """
+ Parameters:
+ - authzToken
+ - airavataCredStoreToken
+ - gatewayId
+ """
+ pass
- def createProject(self, authzToken, gatewayId, project):
- """
+ def createProject(self, authzToken, gatewayId, project):
+ """
- Creates a Project with basic metadata.
- A Project is a container of experiments.
+ Creates a Project with basic metadata.
+ A Project is a container of experiments.
- @param gatewayId
- The identifier for the requested gateway.
+ @param gatewayId
+ The identifier for the requested gateway.
- @param Project
- The Project Object described in the workspace_model.
+ @param Project
+ The Project Object described in the workspace_model.
- Parameters:
- - authzToken
- - gatewayId
- - project
- """
- pass
+ Parameters:
+ - authzToken
+ - gatewayId
+ - project
+ """
+ pass
- def updateProject(self, authzToken, projectId, updatedProject):
- """
+ def updateProject(self, authzToken, projectId, updatedProject):
+ """
- Update an Existing Project
+ Update an Existing Project
- @param projectId
- The projectId of the project needed an update.
+ @param projectId
+ The projectId of the project needed an update.
- @return void
- Currently this does not return any value.
+ @return void
+ Currently this does not return any value.
- Parameters:
- - authzToken
- - projectId
- - updatedProject
- """
- pass
+ Parameters:
+ - authzToken
+ - projectId
+ - updatedProject
+ """
+ pass
- def getProject(self, authzToken, projectId):
- """
+ def getProject(self, authzToken, projectId):
+ """
- Get a Project by ID
- This method is to obtain a project by providing a projectId.
+ Get a Project by ID
+ This method is to obtain a project by providing a projectId.
- @param projectId
- projectId of the project you require.
+ @param projectId
+ projectId of the project you require.
- @return project
- project data model will be returned.
+ @return project
+ project data model will be returned.
- Parameters:
- - authzToken
- - projectId
- """
- pass
+ Parameters:
+ - authzToken
+ - projectId
+ """
+ pass
- def deleteProject(self, authzToken, projectId):
- """
+ def deleteProject(self, authzToken, projectId):
+ """
- Delete a Project
- This method is used to delete an existing Project.
+ Delete a Project
+ This method is used to delete an existing Project.
- @param projectId
- projectId of the project you want to delete.
+ @param projectId
+ projectId of the project you want to delete.
- @return boolean
- Boolean identifier for the success or failure of the deletion operation.
+ @return boolean
+ Boolean identifier for the success or failure of the deletion operation.
- NOTE: This method is not used within gateways connected with Airavata.
+ NOTE: This method is not used within gateways connected with Airavata.
- Parameters:
- - authzToken
- - projectId
- """
- pass
+ Parameters:
+ - authzToken
+ - projectId
+ """
+ pass
- def getUserProjects(self, authzToken, gatewayId, userName, limit, offset):
- """
+ def getUserProjects(self, authzToken, gatewayId, userName, limit, offset):
+ """
- Get All User Projects
- Get all Project for the user with pagination. Results will be ordered based on creation time DESC.
+ Get All User Projects
+ Get all Project for the user with pagination. Results will be ordered based on creation time DESC.
- @param gatewayId
- The identifier for the requested gateway.
+ @param gatewayId
+ The identifier for the requested gateway.
- @param userName
- The identifier of the user.
+ @param userName
+ The identifier of the user.
- @param limit
- The amount results to be fetched.
+ @param limit
+ The amount results to be fetched.
- @param offset
- The starting point of the results to be fetched.
+ @param offset
+ The starting point of the results to be fetched.
- Parameters:
- - authzToken
- - gatewayId
- - userName
- - limit
- - offset
- """
- pass
+ Parameters:
+ - authzToken
+ - gatewayId
+ - userName
+ - limit
+ - offset
+ """
+ pass
- def searchProjects(self, authzToken, gatewayId, userName, filters, limit, offset):
- """
+ def searchProjects(self, authzToken, gatewayId, userName, filters, limit, offset):
+ """
- Search User Projects
- Search and get all Projects for user by project description or/and project name with pagination.
- Results will be ordered based on creation time DESC.
+ Search User Projects
+ Search and get all Projects for user by project description or/and project name with pagination.
+ Results will be ordered based on creation time DESC.
- @param gatewayId
- The unique identifier of the gateway making the request.
+ @param gatewayId
+ The unique identifier of the gateway making the request.
- @param userName
- The identifier of the user.
+ @param userName
+ The identifier of the user.
- @param filters
- Map of multiple filter criteria. Currenlt search filters includes Project Name and Project Description
+ @param filters
+ Map of multiple filter criteria. Currenlt search filters includes Project Name and Project Description
- @param limit
- The amount results to be fetched.
+ @param limit
+ The amount results to be fetched.
- @param offset
- The starting point of the results to be fetched.
+ @param offset
+ The starting point of the results to be fetched.
- Parameters:
- - authzToken
- - gatewayId
- - userName
- - filters
- - limit
- - offset
- """
- pass
+ Parameters:
+ - authzToken
+ - gatewayId
+ - userName
+ - filters
+ - limit
+ - offset
+ """
+ pass
- def searchExperiments(self, authzToken, gatewayId, userName, filters, limit, offset):
- """
- Search Experiments.
- Search Experiments by using multiple filter criteria with pagination. Results will be sorted based on creation time DESC.
+ def searchExperiments(self, authzToken, gatewayId, userName, filters, limit, offset):
+ """
+ Search Experiments.
+ Search Experiments by using multiple filter criteria with pagination. Results will be sorted based on creation time DESC.
- @param gatewayId
- Identifier of the requested gateway.
+ @param gatewayId
+ Identifier of the requested gateway.
- @param userName
- Username of the user requesting the search function.
+ @param userName
+ Username of the user requesting the search function.
- @param filters
- Map of multiple filter criteria. Currenlt search filters includes Experiment Name, Description, Application, etc....
+ @param filters
+ Map of multiple filter criteria. Currenlt search filters includes Experiment Name, Description, Application, etc....
- @param limit
- Amount of results to be fetched.
+ @param limit
+ Amount of results to be fetched.
- @param offset
- The starting point of the results to be fetched.
+ @param offset
+ The starting point of the results to be fetched.
- @return ExperimentSummaryModel
- List of experiments for the given search filter. Here only the Experiment summary will be returned.
+ @return ExperimentSummaryModel
+ List of experiments for the given search filter. Here only the Experiment summary will be returned.
- Parameters:
- - authzToken
- - gatewayId
- - userName
- - filters
- - limit
- - offset
- """
- pass
+ Parameters:
+ - authzToken
+ - gatewayId
+ - userName
+ - filters
+ - limit
+ - offset
+ """
+ pass
- def getExperimentStatistics(self, authzToken, gatewayId, fromTime, toTime, userName, applicationName, resourceHostName):
- """
+ def getExperimentStatistics(self, authzToken, gatewayId, fromTime, toTime, userName, applicationName, resourceHostName):
+ """
- Get Experiment Statistics
- Get Experiment Statisitics for a given gateway for a specific time period. This feature is available only for admins of a particular gateway. Gateway admin access is managed by the user roles.
+ Get Experiment Statistics
+ Get Experiment Statisitics for a given gateway for a specific time period. This feature is available only for admins of a particular gateway. Gateway admin access is managed by the user roles.
- @param gatewayId
- Unique identifier of the gateway making the request to fetch statistics.
+ @param gatewayId
+ Unique identifier of the gateway making the request to fetch statistics.
- @param fromTime
- Starting date time.
+ @param fromTime
+ Starting date time.
- @param toTime
- Ending data time.
+ @param toTime
+ Ending data time.
- @param userName
- Gateway username substring with which to further filter statistics.
+ @param userName
+ Gateway username substring with which to further filter statistics.
- @param applicationName
- Application id substring with which to further filter statistics.
+ @param applicationName
+ Application id substring with which to further filter statistics.
- @param resourceHostName
- Hostname id substring with which to further filter statistics.
+ @param resourceHostName
+ Hostname id substring with which to further filter statistics.
+
+
+
+ Parameters:
+ - authzToken
+ - gatewayId
+ - fromTime
+ - toTime
+ - userName
+ - applicationName
+ - resourceHostName
+ """
+ pass
+
+ def getExperimentsInProject(self, authzToken, projectId, limit, offset):
+ """
+
+ Get All Experiments of the Project
+ Get Experiments within project with pagination. Results will be sorted based on creation time DESC.
+
+ @param projectId
+ Uniqie identifier of the project.
+
+ @param limit
+ Amount of results to be fetched.
+
+ @param offset
+ The starting point of the results to be fetched.
+
+
+
+ Parameters:
+ - authzToken
+ - projectId
+ - limit
+ - offset
+ """
+ pass
+
+ def getUserExperiments(self, authzToken, gatewayId, userName, limit, offset):
+ """
+
+ Get All Experiments of the User
+ Get experiments by user with pagination. Results will be sorted based on creation time DESC.
+
+ @param gatewayId
+ Identifier of the requesting gateway.
+
+ @param userName
+ Username of the requested end user.
+
+ @param limit
+ Amount of results to be fetched.
+
+ @param offset
+ The starting point of the results to be fetched.
+
+
+
+ Parameters:
+ - authzToken
+ - gatewayId
+ - userName
+ - limit
+ - offset
+ """
+ pass
+
+ def createExperiment(self, authzToken, gatewayId, experiment):
+ """
+ *
+ * Create New Experiment
+ * Create an experiment for the specified user belonging to the gateway. The gateway identity is not explicitly passed
+ * but inferred from the sshKeyAuthentication header. This experiment is just a persistent place holder. The client
+ * has to subsequently configure and launch the created experiment. No action is taken on Airavata Server except
+ * registering the experiment in a persistent store.
+ *
+ * @param gatewayId
+ * The unique ID of the gateway where the experiment is been created.
+ *
+ * @param ExperimentModel
+ * The create experiment will require the basic experiment metadata like the name and description, intended user,
+ * the gateway identifer and if the experiment should be shared public by defualt. During the creation of an experiment
+ * the ExperimentMetadata is a required field.
+ *
+ * @return
+ * The server-side generated.airavata.registry.core.experiment.globally unique identifier.
+ *
+ * @throws org.apache.airavata.model.error.InvalidRequestException
+ * For any incorrect forming of the request itself.
+ *
+ * @throws org.apache.airavata.model.error.AiravataClientException
+ * The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
+ *
+ * UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
+ * step, then Airavata Registry will not have a provenance area setup. The client has to follow
+ * gateway registration steps and retry this request.
+ *
+ * AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
+ * For now this is a place holder.
+ *
+ * INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
+ * is implemented, the authorization will be more substantial.
+ *
+ * @throws org.apache.airavata.model.error.AiravataSystemException
+ * This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
+ * rather an Airavata Administrator will be notified to take corrective action.
+ *
+ *
+
+ Parameters:
+ - authzToken
+ - gatewayId
+ - experiment
+ """
+ pass
+
+ def deleteExperiment(self, authzToken, experimentId):
+ """
+
+ Delete an Experiment
+ If the experiment is not already launched experiment can be deleted.
+
+ @param authzToken
+
+ @param experiementId
+ Experiment ID of the experimnet you want to delete.
+
+ @return boolean
+ Identifier for the success or failure of the deletion operation.
+
+
+
+ Parameters:
+ - authzToken
+ - experimentId
+ """
+ pass
+
+ def getExperiment(self, authzToken, airavataExperimentId):
+ """
+ *
+ * Get Experiment
+ * Fetch previously created experiment metadata.
+ *
+ * @param airavataExperimentId
+ * The unique identifier of the requested experiment. This ID is returned during the create experiment step.
+ *
+ * @return ExperimentModel
+ * This method will return the previously stored experiment metadata.
+ *
+ * @throws org.apache.airavata.model.error.InvalidRequestException
+ * For any incorrect forming of the request itself.
+ *
+ * @throws org.apache.airavata.model.error.ExperimentNotFoundException
+ * If the specified experiment is not previously created, then an Experiment Not Found Exception is thrown.
+ *
+ * @throws org.apache.airavata.model.error.AiravataClientException
+ * The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
+ *
+ * UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
+ * step, then Airavata Registry will not have a provenance area setup. The client has to follow
+ * gateway registration steps and retry this request.
+ *
+ * AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
+ * For now this is a place holder.
+ *
+ * INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
+ * is implemented, the authorization will be more substantial.
+ *
+ * @throws org.apache.airavata.model.error.AiravataSystemException
+ * This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
+ * rather an Airavata Administrator will be notified to take corrective action.
+ *
+ *
+
+ Parameters:
+ - authzToken
+ - airavataExperimentId
+ """
+ pass
+
+ def getExperimentByAdmin(self, authzToken, airavataExperimentId):
+ """
+ *
+ * Get Experiment by an admin user
+ *
+ * Used by an admin user to fetch previously created experiment metadata.
+ *
+ * @param airavataExperimentId
+ * The unique identifier of the requested experiment. This ID is returned during the create experiment step.
+ *
+ * @return ExperimentModel
+ * This method will return the previously stored experiment metadata.
+ *
+ * @throws org.apache.airavata.model.error.InvalidRequestException
+ * For any incorrect forming of the request itself.
+ *
+ * @throws org.apache.airavata.model.error.ExperimentNotFoundException
+ * If the specified experiment is not previously created, then an Experiment Not Found Exception is thrown.
+ *
+ * @throws org.apache.airavata.model.error.AiravataClientException
+ * The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
+ *
+ * UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
+ * step, then Airavata Registry will not have a provenance area setup. The client has to follow
+ * gateway registration steps and retry this request.
+ *
+ * AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
+ * For now this is a place holder.
+ *
+ * INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
+ * is implemented, the authorization will be more substantial.
+ *
+ * @throws org.apache.airavata.model.error.AiravataSystemException
+ * This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
+ * rather an Airavata Administrator will be notified to take corrective action.
+ *
+ *
+
+ Parameters:
+ - authzToken
+ - airavataExperimentId
+ """
+ pass
+
+ def getDetailedExperimentTree(self, authzToken, airavataExperimentId):
+ """
+
+ Get Complete Experiment Details
+ Fetch the completed nested tree structue of previously created experiment metadata which includes processes ->
+ tasks -> jobs information.
+
+ @param airavataExperimentId
+ The identifier for the requested experiment. This is returned during the create experiment step.
+
+ @return ExperimentModel
+ This method will return the previously stored experiment metadata including application input parameters, computational resource scheduling
+ information, special input output handling and additional quality of service parameters.
+
+ @throws org.apache.airavata.model.error.InvalidRequestException
+ For any incorrect forming of the request itself.
+
+ @throws org.apache.airavata.model.error.ExperimentNotFoundException
+ If the specified experiment is not previously created, then an Experiment Not Found Exception is thrown.
+
+ @throws org.apache.airavata.model.error.AiravataClientException
+ The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
+
+ UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
+ step, then Airavata Registry will not have a provenance area setup. The client has to follow
+ gateway registration steps and retry this request.
+
+ AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
+ For now this is a place holder.
+
+ INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
+ is implemented, the authorization will be more substantial.
+
+ @throws org.apache.airavata.model.error.AiravataSystemException
+ This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
+ rather an Airavata Administrator will be notified to take corrective action.
+
+
+ Parameters:
+ - authzToken
+ - airavataExperimentId
+ """
+ pass
+
+ def updateExperiment(self, authzToken, airavataExperimentId, experiment):
+ """
+
+ Update a Previously Created Experiment
+ Configure the CREATED experiment with required inputs, scheduling and other quality of service parameters. This method only updates the experiment object within the registry.
+ The experiment has to be launched to make it actionable by the server.
+
+ @param airavataExperimentId
+ The identifier for the requested experiment. This is returned during the create experiment step.
+
+ @param ExperimentModel
+ The configuration information of the experiment with application input parameters, computational resource scheduling
+ information, special input output handling and additional quality of service parameters.
+
+ @return
+ This method call does not have a return value.
+
+ @throws org.apache.airavata.model.error.InvalidRequestException
+ For any incorrect forming of the request itself.
+
+ @throws org.apache.airavata.model.error.ExperimentNotFoundException
+ If the specified experiment is not previously created, then an Experiment Not Found Exception is thrown.
+
+ @throws org.apache.airavata.model.error.AiravataClientException
+ The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
+
+ UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
+ step, then Airavata Registry will not have a provenance area setup. The client has to follow
+ gateway registration steps and retry this request.
+
+ AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
+ For now this is a place holder.
+
+ INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
+ is implemented, the authorization will be more substantial.
+
+ @throws org.apache.airavata.model.error.AiravataSystemException
+ This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
+ rather an Airavata Administrator will be notified to take corrective action.
+
+
+ Parameters:
+ - authzToken
+ - airavataExperimentId
+ - experiment
+ """
+ pass
+ def updateExperimentConfiguration(self, authzToken, airavataExperimentId, userConfiguration):
+ """
+ Parameters:
+ - authzToken
+ - airavataExperimentId
+ - userConfiguration
+ """
+ pass
+ def updateResourceScheduleing(self, authzToken, airavataExperimentId, resourceScheduling):
+ """
+ Parameters:
+ - authzToken
+ - airavataExperimentId
+ - resourceScheduling
+ """
+ pass
- Parameters:
- - authzToken
- - gatewayId
- - fromTime
- - toTime
- - userName
- - applicationName
- - resourceHostName
- """
- pass
+ def validateExperiment(self, authzToken, airavataExperimentId):
+ """
+ *
+ * Validate experiment configuration.
+ * A true in general indicates, the experiment is ready to be launched.
+ *
+ * @param airavataExperimentId
+ * Unique identifier of the experiment (Experimnent ID) of the experiment which need to be validated.
+ *
+ * @return boolean
+ * Identifier for the success or failure of the validation operation.
+ *
+ *
- def getExperimentsInProject(self, authzToken, projectId, limit, offset):
- """
+ Parameters:
+ - authzToken
+ - airavataExperimentId
+ """
+ pass
- Get All Experiments of the Project
- Get Experiments within project with pagination. Results will be sorted based on creation time DESC.
+ def launchExperiment(self, authzToken, airavataExperimentId, gatewayId):
+ """
- @param projectId
- Uniqie identifier of the project.
+ Launch a Previously Created & Configured Experiment.
+ Airavata Server will then start processing the request and appropriate notifications and intermediate and output data will be subsequently available for this experiment.
- @param limit
- Amount of results to be fetched.
+ @gatewayId
+ ID of the gateway which will launch the experiment.
- @param offset
- The starting point of the results to be fetched.
+ @param airavataExperimentId
+ The identifier for the requested experiment. This is returned during the create experiment step.
+ @return
+ This method call does not have a return value.
+ @throws org.apache.airavata.model.error.InvalidRequestException
+ For any incorrect forming of the request itself.
- Parameters:
- - authzToken
- - projectId
- - limit
- - offset
- """
- pass
+ @throws org.apache.airavata.model.error.ExperimentNotFoundException
+ If the specified experiment is not previously created, then an Experiment Not Found Exception is thrown.
- def getUserExperiments(self, authzToken, gatewayId, userName, limit, offset):
- """
+ @throws org.apache.airavata.model.error.AiravataClientException
+ The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
+
+ UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
+ step, then Airavata Registry will not have a provenance area setup. The client has to follow
+ gateway registration steps and retry this request.
- Get All Experiments of the User
- Get experiments by user with pagination. Results will be sorted based on creation time DESC.
+ AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
+ For now this is a place holder.
- @param gatewayId
- Identifier of the requesting gateway.
+ INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
+ is implemented, the authorization will be more substantial.
- @param userName
- Username of the requested end user.
+ @throws org.apache.airavata.model.error.AiravataSystemException
+ This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
+ rather an Airavata Administrator will be notified to take corrective action.
- @param limit
- Amount of results to be fetched.
- @param offset
- The starting point of the results to be fetched.
+ Parameters:
+ - authzToken
+ - airavataExperimentId
+ - gatewayId
+ """
+ pass
+ def getExperimentStatus(self, authzToken, airavataExperimentId):
+ """
+ Get Experiment Status
- Parameters:
- - authzToken
- - gatewayId
- - userName
- - limit
- - offset
- """
- pass
-
- def createExperiment(self, authzToken, gatewayId, experiment):
- """
- *
- * Create New Experiment
- * Create an experiment for the specified user belonging to the gateway. The gateway identity is not explicitly passed
- * but inferred from the sshKeyAuthentication header. This experiment is just a persistent place holder. The client
- * has to subsequently configure and launch the created experiment. No action is taken on Airavata Server except
- * registering the experiment in a persistent store.
- *
- * @param gatewayId
- * The unique ID of the gateway where the experiment is been created.
- *
- * @param ExperimentModel
- * The create experiment will require the basic experiment metadata like the name and description, intended user,
- * the gateway identifer and if the experiment should be shared public by defualt. During the creation of an experiment
- * the ExperimentMetadata is a required field.
- *
- * @return
- * The server-side generated.airavata.registry.core.experiment.globally unique identifier.
- *
- * @throws org.apache.airavata.model.error.InvalidRequestException
- * For any incorrect forming of the request itself.
- *
- * @throws org.apache.airavata.model.error.AiravataClientException
- * The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
- *
- * UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
- * step, then Airavata Registry will not have a provenance area setup. The client has to follow
- * gateway registration steps and retry this request.
- *
- * AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
- * For now this is a place holder.
- *
- * INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
- * is implemented, the authorization will be more substantial.
- *
- * @throws org.apache.airavata.model.error.AiravataSystemException
- * This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
- * rather an Airavata Administrator will be notified to take corrective action.
- *
- *
-
- Parameters:
- - authzToken
- - gatewayId
- - experiment
- """
- pass
+ Obtain the status of an experiment by providing the Experiment Id
- def deleteExperiment(self, authzToken, experimentId):
- """
+ @param authzToken
- Delete an Experiment
- If the experiment is not already launched experiment can be deleted.
+ @param airavataExperimentId
+ Experiment ID of the experimnet you require the status.
- @param authzToken
+ @return ExperimentStatus
+ ExperimentStatus model with the current status will be returned.
- @param experiementId
- Experiment ID of the experimnet you want to delete.
- @return boolean
- Identifier for the success or failure of the deletion operation.
+ Parameters:
+ - authzToken
+ - airavataExperimentId
+ """
+ pass
+ def getExperimentOutputs(self, authzToken, airavataExperimentId):
+ """
- Parameters:
- - authzToken
- - experimentId
- """
- pass
-
- def getExperiment(self, authzToken, airavataExperimentId):
- """
- *
- * Get Experiment
- * Fetch previously created experiment metadata.
- *
- * @param airavataExperimentId
- * The unique identifier of the requested experiment. This ID is returned during the create experiment step.
- *
- * @return ExperimentModel
- * This method will return the previously stored experiment metadata.
- *
- * @throws org.apache.airavata.model.error.InvalidRequestException
- * For any incorrect forming of the request itself.
- *
- * @throws org.apache.airavata.model.error.ExperimentNotFoundException
- * If the specified experiment is not previously created, then an Experiment Not Found Exception is thrown.
- *
- * @throws org.apache.airavata.model.error.AiravataClientException
- * The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
- *
- * UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
- * step, then Airavata Registry will not have a provenance area setup. The client has to follow
- * gateway registration steps and retry this request.
- *
- * AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
- * For now this is a place holder.
- *
- * INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
- * is implemented, the authorization will be more substantial.
- *
- * @throws org.apache.airavata.model.error.AiravataSystemException
- * This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
- * rather an Airavata Administrator will be notified to take corrective action.
- *
- *
-
- Parameters:
- - authzToken
- - airavataExperimentId
- """
- pass
-
- def getExperimentByAdmin(self, authzToken, airavataExperimentId):
- """
- *
- * Get Experiment by an admin user
- *
- * Used by an admin user to fetch previously created experiment metadata.
- *
- * @param airavataExperimentId
- * The unique identifier of the requested experiment. This ID is returned during the create experiment step.
- *
- * @return ExperimentModel
- * This method will return the previously stored experiment metadata.
- *
- * @throws org.apache.airavata.model.error.InvalidRequestException
- * For any incorrect forming of the request itself.
- *
- * @throws org.apache.airavata.model.error.ExperimentNotFoundException
- * If the specified experiment is not previously created, then an Experiment Not Found Exception is thrown.
- *
- * @throws org.apache.airavata.model.error.AiravataClientException
- * The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
- *
- * UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
- * step, then Airavata Registry will not have a provenance area setup. The client has to follow
- * gateway registration steps and retry this request.
- *
- * AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
- * For now this is a place holder.
- *
- * INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
- * is implemented, the authorization will be more substantial.
- *
- * @throws org.apache.airavata.model.error.AiravataSystemException
- * This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
- * rather an Airavata Administrator will be notified to take corrective action.
- *
- *
-
- Parameters:
- - authzToken
- - airavataExperimentId
- """
- pass
+ Get Experiment Outputs
+ This method to be used when need to obtain final outputs of a certain Experiment
- def getDetailedExperimentTree(self, authzToken, airavataExperimentId):
- """
+ @param authzToken
- Get Complete Experiment Details
- Fetch the completed nested tree structue of previously created experiment metadata which includes processes ->
- tasks -> jobs information.
+ @param airavataExperimentId
+ Experiment ID of the experimnet you need the outputs.
- @param airavataExperimentId
- The identifier for the requested experiment. This is returned during the create experiment step.
+ @return list
+ List of experiment outputs will be returned. They will be returned as a list of OutputDataObjectType for the experiment.
- @return ExperimentModel
- This method will return the previously stored experiment metadata including application input parameters, computational resource scheduling
- information, special input output handling and additional quality of service parameters.
- @throws org.apache.airavata.model.error.InvalidRequestException
- For any incorrect forming of the request itself.
- @throws org.apache.airavata.model.error.ExperimentNotFoundException
- If the specified experiment is not previously created, then an Experiment Not Found Exception is thrown.
+ Parameters:
+ - authzToken
+ - airavataExperimentId
+ """
+ pass
- @throws org.apache.airavata.model.error.AiravataClientException
- The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
+ def getIntermediateOutputs(self, authzToken, airavataExperimentId):
+ """
- UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
- step, then Airavata Registry will not have a provenance area setup. The client has to follow
- gateway registration steps and retry this request.
+ Get Intermediate Experiment Outputs
+ This method to be used when need to obtain intermediate outputs of a certain Experiment
- AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
- For now this is a place holder.
+ @param authzToken
- INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
- is implemented, the authorization will be more substantial.
+ @param airavataExperimentId
+ Experiment ID of the experimnet you need intermediate outputs.
- @throws org.apache.airavata.model.error.AiravataSystemException
- This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
- rather an Airavata Administrator will be notified to take corrective action.
+ @return list
+ List of intermediate experiment outputs will be returned. They will be returned as a list of OutputDataObjectType for the experiment.
- Parameters:
- - authzToken
- - airavataExperimentId
- """
- pass
- def updateExperiment(self, authzToken, airavataExperimentId, experiment):
- """
+ Parameters:
+ - authzToken
+ - airavataExperimentId
+ """
+ pass
- Update a Previously Created Experiment
- Configure the CREATED experiment with required inputs, scheduling and other quality of service parameters. This method only updates the experiment object within the registry.
- The experiment has to be launched to make it actionable by the server.
+ def getJobStatuses(self, authzToken, airavataExperimentId):
+ """
- @param airavataExperimentId
- The identifier for the requested experiment. This is returned during the create experiment step.
+ Get Job Statuses for an Experiment
+ This method to be used when need to get the job status of an Experiment. An experiment may have one or many jobs; there for one or many job statuses may turnup
- @param ExperimentModel
- The configuration information of the experiment with application input parameters, computational resource scheduling
- information, special input output handling and additional quality of service parameters.
+ @param authzToken
- @return
- This method call does not have a return value.
+ @param experiementId
+ Experiment ID of the experimnet you need the job statuses.
- @throws org.apache.airavata.model.error.InvalidRequestException
- For any incorrect forming of the request itself.
+ @return JobStatus
+ Job status (string) for all all the existing jobs for the experiment will be returned in the form of a map
- @throws org.apache.airavata.model.error.ExperimentNotFoundException
- If the specified experiment is not previously created, then an Experiment Not Found Exception is thrown.
- @throws org.apache.airavata.model.error.AiravataClientException
- The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
-
- UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
- step, then Airavata Registry will not have a provenance area setup. The client has to follow
- gateway registration steps and retry this request.
- AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
- For now this is a place holder.
+ Parameters:
+ - authzToken
+ - airavataExperimentId
+ """
+ pass
- INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
- is implemented, the authorization will be more substantial.
+ def getJobDetails(self, authzToken, airavataExperimentId):
+ """
- @throws org.apache.airavata.model.error.AiravataSystemException
- This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
- rather an Airavata Administrator will be notified to take corrective action.
+ Get Job Details for all the jobs within an Experiment.
+ This method to be used when need to get the job details for one or many jobs of an Experiment.
+ @param authzToken
- Parameters:
- - authzToken
- - airavataExperimentId
- - experiment
- """
- pass
+ @param experiementId
+ Experiment ID of the experimnet you need job details.
- def updateExperimentConfiguration(self, authzToken, airavataExperimentId, userConfiguration):
- """
- Parameters:
- - authzToken
- - airavataExperimentId
- - userConfiguration
- """
- pass
+ @return list of JobDetails
+ Job details.
- def updateResourceScheduleing(self, authzToken, airavataExperimentId, resourceScheduling):
- """
- Parameters:
- - authzToken
- - airavataExperimentId
- - resourceScheduling
- """
- pass
- def validateExperiment(self, authzToken, airavataExperimentId):
- """
- *
- * Validate experiment configuration.
- * A true in general indicates, the experiment is ready to be launched.
- *
- * @param airavataExperimentId
- * Unique identifier of the experiment (Experimnent ID) of the experiment which need to be validated.
- *
- * @return boolean
- * Identifier for the success or failure of the validation operation.
- *
- *
- Parameters:
- - authzToken
- - airavataExperimentId
- """
- pass
+ Parameters:
+ - authzToken
+ - airavataExperimentId
+ """
+ pass
- def launchExperiment(self, authzToken, airavataExperimentId, gatewayId):
- """
+ def cloneExperiment(self, authzToken, existingExperimentID, newExperimentName, newExperimentProjectId):
+ """
- Launch a Previously Created & Configured Experiment.
- Airavata Server will then start processing the request and appropriate notifications and intermediate and output data will be subsequently available for this experiment.
+ Clone an Existing Experiment
+ Existing specified experiment is cloned and a new name is provided. A copy of the experiment configuration is made and is persisted with new metadata.
+ The client has to subsequently update this configuration if needed and launch the cloned experiment.
- @gatewayId
- ID of the gateway which will launch the experiment.
+ @param newExperimentName
+ experiment name that should be used in the cloned experiment
- @param airavataExperimentId
- The identifier for the requested experiment. This is returned during the create experiment step.
+ @param updatedExperiment
+ Once an experiment is cloned, to disambiguate, the users are suggested to provide new metadata. This will again require
+ the basic experiment metadata like the name and description, intended user, the gateway identifier and if the experiment
+ should be shared public by default.
+ @param newExperimentProjectId
+ The project in which to create the cloned experiment. This is optional and if null the experiment will be created
+ in the same project as the existing experiment.
- @return
- This method call does not have a return value.
+ @return
+ The server-side generated.airavata.registry.core.experiment.globally unique identifier (Experiment ID) for the newly cloned experiment.
- @throws org.apache.airavata.model.error.InvalidRequestException
- For any incorrect forming of the request itself.
+ @throws org.apache.airavata.model.error.InvalidRequestException
+ For any incorrect forming of the request itself.
- @throws org.apache.airavata.model.error.ExperimentNotFoundException
- If the specified experiment is not previously created, then an Experiment Not Found Exception is thrown.
+ @throws org.apache.airavata.model.error.ExperimentNotFoundException
+ If the specified experiment is not previously created, then an Experiment Not Found Exception is thrown.
- @throws org.apache.airavata.model.error.AiravataClientException
- The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
-
- UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
- step, then Airavata Registry will not have a provenance area setup. The client has to follow
- gateway registration steps and retry this request.
+ @throws org.apache.airavata.model.error.AiravataClientException
+ The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
+
+ UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
+ step, then Airavata Registry will not have a provenance area setup. The client has to follow
+ gateway registration steps and retry this request.
- AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
- For now this is a place holder.
+ AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
+ For now this is a place holder.
- INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
- is implemented, the authorization will be more substantial.
+ INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
+ is implemented, the authorization will be more substantial.
- @throws org.apache.airavata.model.error.AiravataSystemException
- This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
- rather an Airavata Administrator will be notified to take corrective action.
+ @throws org.apache.airavata.model.error.AiravataSystemException
+ This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
+ rather an Airavata Administrator will be notified to take corrective action.
- Parameters:
- - authzToken
- - airavataExperimentId
- - gatewayId
- """
- pass
+ Parameters:
+ - authzToken
+ - existingExperimentID
+ - newExperimentName
+ - newExperimentProjectId
+ """
+ pass
- def getExperimentStatus(self, authzToken, airavataExperimentId):
- """
+ def cloneExperimentByAdmin(self, authzToken, existingExperimentID, newExperimentName, newExperimentProjectId):
+ """
- Get Experiment Status
+ Clone an Existing Experiment by an admin user
+ Existing specified experiment is cloned and a new name is provided. A copy of the experiment configuration is made and is persisted with new metadata.
+ The client has to subsequently update this configuration if needed and launch the cloned experiment.
- Obtain the status of an experiment by providing the Experiment Id
+ @param newExperimentName
+ experiment name that should be used in the cloned experiment
- @param authzToken
+ @param updatedExperiment
+ Once an experiment is cloned, to disambiguate, the users are suggested to provide new metadata. This will again require
+ the basic experiment metadata like the name and description, intended user, the gateway identifier and if the experiment
+ should be shared public by default.
+ @param newExperimentProjectId
+ The project in which to create the cloned experiment. This is optional and if null the experiment will be created
+ in the same project as the existing experiment.
- @param airavataExperimentId
- Experiment ID of the experimnet you require the status.
+ @return
+ The server-side generated.airavata.registry.core.experiment.globally unique identifier (Experiment ID) for the newly cloned experiment.
- @return ExperimentStatus
- ExperimentStatus model with the current status will be returned.
+ @throws org.apache.airavata.model.error.InvalidRequestException
+ For any incorrect forming of the request itself.
+ @throws org.apache.airavata.model.error.ExperimentNotFoundException
+ If the specified experiment is not previously created, then an Experiment Not Found Exception is thrown.
+ @throws org.apache.airavata.model.error.AiravataClientException
+ The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
- Parameters:
- - authzToken
- - airavataExperimentId
- """
- pass
+ UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
+ step, then Airavata Registry will not have a provenance area setup. The client has to follow
+ gateway registration steps and retry this request.
- def getExperimentOutputs(self, authzToken, airavataExperimentId):
- """
+ AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
+ For now this is a place holder.
- Get Experiment Outputs
- This method to be used when need to obtain final outputs of a certain Experiment
+ INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
+ is implemented, the authorization will be more substantial.
- @param authzToken
+ @throws org.apache.airavata.model.error.AiravataSystemException
+ This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
+ rather an Airavata Administrator will be notified to take corrective action.
- @param airavataExperimentId
- Experiment ID of the experimnet you need the outputs.
- @return list
- List of experiment outputs will be returned. They will be returned as a list of OutputDataObjectType for the experiment.
+ Parameters:
+ - authzToken
+ - existingExperimentID
+ - newExperimentName
+ - newExperimentProjectId
+ """
+ pass
+ def terminateExperiment(self, authzToken, airavataExperimentId, gatewayId):
+ """
+ Terminate a running Experiment.
- Parameters:
- - authzToken
- - airavataExperimentId
- """
- pass
+ @gatewayId
+ ID of the gateway which will terminate the running Experiment.
- def getIntermediateOutputs(self, authzToken, airavataExperimentId):
- """
+ @param airavataExperimentId
+ The identifier of the experiment required termination. This ID is returned during the create experiment step.
- Get Intermediate Experiment Outputs
- This method to be used when need to obtain intermediate outputs of a certain Experiment
+ @return status
+ This method call does not have a return value.
- @param authzToken
+ @throws org.apache.airavata.model.error.InvalidRequestException
+ For any incorrect forming of the request itself.
- @param airavataExperimentId
- Experiment ID of the experimnet you need intermediate outputs.
+ @throws org.apache.airavata.model.error.ExperimentNotFoundException
+ If the specified experiment is not previously created, then an Experiment Not Found Exception is thrown.
- @return list
- List of intermediate experiment outputs will be returned. They will be returned as a list of OutputDataObjectType for the experiment.
+ @throws org.apache.airavata.model.error.AiravataClientException
+ The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
+
+ UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
+ step, then Airavata Registry will not have a provenance area setup. The client has to follow
+ gateway registration steps and retry this request.
+ AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
+ For now this is a place holder.
+ INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
+ is implemented, the authorization will be more substantial.
- Parameters:
- - authzToken
- - airavataExperimentId
- """
- pass
+ @throws org.apache.airavata.model.error.AiravataSystemException
+ This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
+ rather an Airavata Administrator will be notified to take corrective action.
- def getJobStatuses(self, authzToken, airavataExperimentId):
- """
- Get Job Statuses for an Experiment
- This method to be used when need to get the job status of an Experiment. An experiment may have one or many jobs; there for one or many job statuses may turnup
+ Parameters:
+ - authzToken
+ - airavataExperimentId
+ - gatewayId
+ """
+ pass
- @param authzToken
+ def registerApplicationModule(self, authzToken, gatewayId, applicationModule):
+ """
- @param experiementId
- Experiment ID of the experimnet you need the job statuses.
+ Register a Application Module.
- @return JobStatus
- Job status (string) for all all the existing jobs for the experiment will be returned in the form of a map
+ @gatewayId
+ ID of the gateway which is registering the new Application Module.
+ @param applicationModule
+ Application Module Object created from the datamodel.
+ @return appModuleId
+ Returns the server-side generated airavata appModule globally unique identifier.
- Parameters:
- - authzToken
- - airavataExperimentId
- """
- pass
- def getJobDetails(self, authzToken, airavataExperimentId):
- """
+ Parameters:
+ - authzToken
+ - gatewayId
+ - applicationModule
+ """
+ pass
- Get Job Details for all the jobs within an Experiment.
- This method to be used when need to get the job details for one or many jobs of an Experiment.
+ def getApplicationModule(self, authzToken, appModuleId):
+ """
- @param authzToken
+ Fetch a Application Module.
- @param experiementId
- Experiment ID of the experimnet you need job details.
+ @param appModuleId
+ The unique identifier of the application module required
- @return list of JobDetails
- Job details.
+ @return applicationModule
+ Returns an Application Module Object.
+ Parameters:
+ - authzToken
+ - appModuleId
+ """
+ pass
- Parameters:
- - authzToken
- - airavataExperimentId
- """
- pass
+ def updateApplicationModule(self, authzToken, appModuleId, applicationModule):
+ """
- def cloneExperiment(self, authzToken, existingExperimentID, newExperimentName, newExperimentProjectId):
- """
+ Update a Application Module.
- Clone an Existing Experiment
- Existing specified experiment is cloned and a new name is provided. A copy of the experiment configuration is made and is persisted with new metadata.
- The client has to subsequently update this configuration if needed and launch the cloned experiment.
+ @param appModuleId
+ The identifier for the requested application module to be updated.
- @param newExperimentName
- experiment name that should be used in the cloned experiment
+ @param applicationModule
+ Application Module Object created from the datamodel.
- @param updatedExperiment
- Once an experiment is cloned, to disambiguate, the users are suggested to provide new metadata. This will again require
- the basic experiment metadata like the name and description, intended user, the gateway identifier and if the experiment
- should be shared public by default.
- @param newExperimentProjectId
- The project in which to create the cloned experiment. This is optional and if null the experiment will be created
- in the same project as the existing experiment.
+ @return status
+ Returns a success/failure of the update.
- @return
- The server-side generated.airavata.registry.core.experiment.globally unique identifier (Experiment ID) for the newly cloned experiment.
- @throws org.apache.airavata.model.error.InvalidRequestException
- For any incorrect forming of the request itself.
+ Parameters:
+ - authzToken
+ - appModuleId
+ - applicationModule
+ """
+ pass
- @throws org.apache.airavata.model.error.ExperimentNotFoundException
- If the specified experiment is not previously created, then an Experiment Not Found Exception is thrown.
+ def getAllAppModules(self, authzToken, gatewayId):
+ """
- @throws org.apache.airavata.model.error.AiravataClientException
- The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
-
- UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
- step, then Airavata Registry will not have a provenance area setup. The client has to follow
- gateway registration steps and retry this request.
+ Fetch all Application Module Descriptions.
- AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
- For now this is a place holder.
+ @param gatewayId
+ ID of the gateway which need to list all available application deployment documentation.
- INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
- is implemented, the authorization will be more substantial.
+ @return list
+ Returns the list of all Application Module Objects.
- @throws org.apache.airavata.model.error.AiravataSystemException
- This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
- rather an Airavata Administrator will be notified to take corrective action.
+ Parameters:
+ - authzToken
+ - gatewayId
+ """
+ pass
- Parameters:
- - authzToken
- - existingExperimentID
- - newExperimentName
- - newExperimentProjectId
- """
- pass
+ def deleteApplicationModule(self, authzToken, appModuleId):
+ """
- def cloneExperimentByAdmin(self, authzToken, existingExperimentID, newExperimentName, newExperimentProjectId):
- """
+ Delete an Application Module.
- Clone an Existing Experiment by an admin user
- Existing specified experiment is cloned and a new name is provided. A copy of the experiment configuration is made and is persisted with new metadata.
- The client has to subsequently update this configuration if needed and launch the cloned experiment.
+ @param appModuleId
+ The identifier of the Application Module to be deleted.
- @param newExperimentName
- experiment name that should be used in the cloned experiment
+ @return status
+ Returns a success/failure of the deletion.
- @param updatedExperiment
- Once an experiment is cloned, to disambiguate, the users are suggested to provide new metadata. This will again require
- the basic experiment metadata like the name and description, intended user, the gateway identifier and if the experiment
- should be shared public by default.
- @param newExperimentProjectId
- The project in which to create the cloned experiment. This is optional and if null the experiment will be created
- in the same project as the existing experiment.
- @return
- The server-side generated.airavata.registry.core.experiment.globally unique identifier (Experiment ID) for the newly cloned experiment.
+ Parameters:
+ - authzToken
+ - appModuleId
+ """
+ pass
- @throws org.apache.airavata.model.error.InvalidRequestException
- For any incorrect forming of the request itself.
+ def registerApplicationDeployment(self, authzToken, gatewayId, applicationDeployment):
+ """
- @throws org.apache.airavata.model.error.ExperimentNotFoundException
- If the specified experiment is not previously created, then an Experiment Not Found Exception is thrown.
+ Register an Application Deployment.
- @throws org.apache.airavata.model.error.AiravataClientException
- The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
+ @param gatewayId
+ ID of the gateway which is registering the new Application Deployment.
- UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
- step, then Airavata Registry will not have a provenance area setup. The client has to follow
- gateway registration steps and retry this request.
+ @param applicationDeployment
+ Application Module Object created from the datamodel.
- AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
- For now this is a place holder.
+ @return appDeploymentId
+ Returns a server-side generated airavata appDeployment globally unique identifier.
- INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
- is implemented, the authorization will be more substantial.
- @throws org.apache.airavata.model.error.AiravataSystemException
- This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
- rather an Airavata Administrator will be notified to take corrective action.
+ Parameters:
+ - authzToken
+ - gatewayId
+ - applicationDeployment
+ """
+ pass
+ def getApplicationDeployment(self, authzToken, appDeploymentId):
+ """
- Parameters:
- - authzToken
- - existingExperimentID
- - newExperimentName
- - newExperimentProjectId
- """
- pass
+ Fetch a Application Deployment.
- def terminateExperiment(self, authzToken, airavataExperimentId, gatewayId):
- """
+ @param appDeploymentId
+ The identifier for the requested application module
- Terminate a running Experiment.
+ @return applicationDeployment
+ Returns a application Deployment Object.
- @gatewayId
- ID of the gateway which will terminate the running Experiment.
- @param airavataExperimentId
- The identifier of the experiment required termination. This ID is returned during the create experiment step.
+ Parameters:
+ - authzToken
+ - appDeploymentId
+ """
+ pass
- @return status
- This method call does not have a return value.
+ def updateApplicationDeployment(self, authzToken, appDeploymentId, applicationDeployment):
+ """
- @throws org.apache.airavata.model.error.InvalidRequestException
- For any incorrect forming of the request itself.
+ Update an Application Deployment.
- @throws org.apache.airavata.model.error.ExperimentNotFoundException
- If the specified experiment is not previously created, then an Experiment Not Found Exception is thrown.
+ @param appDeploymentId
+ The identifier of the requested application deployment to be updated.
- @throws org.apache.airavata.model.error.AiravataClientException
- The following list of exceptions are thrown which Airavata Client can take corrective actions to resolve:
-
- UNKNOWN_GATEWAY_ID - If a Gateway is not registered with Airavata as a one time administrative
- step, then Airavata Registry will not have a provenance area setup. The client has to follow
- gateway registration steps and retry this request.
+ @param appDeployment
+ Application Deployment Object created from the datamodel.
- AUTHENTICATION_FAILURE - How Authentication will be implemented is yet to be determined.
- For now this is a place holder.
+ @return status
+ Returns a success/failure of the update.
- INVALID_AUTHORIZATION - This will throw an authorization exception. When a more robust security hand-shake
- is implemented, the authorization will be more substantial.
- @throws org.apache.airavata.model.error.AiravataSystemException
- This exception will be thrown for any Airavata Server side issues and if the problem cannot be corrected by the client
- rather an Airavata Administrator will be notified to take corrective action.
+ Parameters:
+ - authzToken
+ - appDeploymentId
+ - applicationDeployment
+ """
+ pass
+ def deleteApplicationDeployment(self, authzToken, appDeploymentId):
+ """
- Parameters:
- - authzToken
- - airavataExperimentId
- - gatewayId
- """
- pass
+ Delete an Application Deployment.
- def registerApplicationModule(self, authzToken, gatewayId, applicationModule):
- """
+ @param appDeploymentId
+ The unique identifier of application deployment to be deleted.
- Register a Application Module.
+ @return status
+ Returns a success/failure of the deletion.
- @gatewayId
- ID of the
<TRUNCATED>
[38/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/replica/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/replica/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/replica/ttypes.py
index 22adc42..ca2ecbb 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/replica/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/data/replica/ttypes.py
@@ -1,511 +1,477 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class ReplicaLocationCategory:
- GATEWAY_DATA_STORE = 0
- COMPUTE_RESOURCE = 1
- LONG_TERM_STORAGE_RESOURCE = 2
- OTHER = 3
-
- _VALUES_TO_NAMES = {
- 0: "GATEWAY_DATA_STORE",
- 1: "COMPUTE_RESOURCE",
- 2: "LONG_TERM_STORAGE_RESOURCE",
- 3: "OTHER",
- }
-
- _NAMES_TO_VALUES = {
- "GATEWAY_DATA_STORE": 0,
- "COMPUTE_RESOURCE": 1,
- "LONG_TERM_STORAGE_RESOURCE": 2,
- "OTHER": 3,
- }
-
-class ReplicaPersistentType:
- TRANSIENT = 0
- PERSISTENT = 1
-
- _VALUES_TO_NAMES = {
- 0: "TRANSIENT",
- 1: "PERSISTENT",
- }
-
- _NAMES_TO_VALUES = {
- "TRANSIENT": 0,
- "PERSISTENT": 1,
- }
-
-class DataProductType:
- FILE = 0
- COLLECTION = 1
-
- _VALUES_TO_NAMES = {
- 0: "FILE",
- 1: "COLLECTION",
- }
-
- _NAMES_TO_VALUES = {
- "FILE": 0,
- "COLLECTION": 1,
- }
-
-
-class DataReplicaLocationModel:
- """
- Attributes:
- - replicaId
- - productUri
- - replicaName
- - replicaDescription
- - creationTime
- - lastModifiedTime
- - validUntilTime
- - replicaLocationCategory
- - replicaPersistentType
- - storageResourceId
- - filePath
- - replicaMetadata
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'replicaId', None, None, ), # 1
- (2, TType.STRING, 'productUri', None, None, ), # 2
- (3, TType.STRING, 'replicaName', None, None, ), # 3
- (4, TType.STRING, 'replicaDescription', None, None, ), # 4
- (5, TType.I64, 'creationTime', None, None, ), # 5
- (6, TType.I64, 'lastModifiedTime', None, None, ), # 6
- (7, TType.I64, 'validUntilTime', None, None, ), # 7
- (8, TType.I32, 'replicaLocationCategory', None, None, ), # 8
- (9, TType.I32, 'replicaPersistentType', None, None, ), # 9
- (10, TType.STRING, 'storageResourceId', None, None, ), # 10
- (11, TType.STRING, 'filePath', None, None, ), # 11
- (12, TType.MAP, 'replicaMetadata', (TType.STRING,None,TType.STRING,None), None, ), # 12
- )
-
- def __init__(self, replicaId=None, productUri=None, replicaName=None, replicaDescription=None, creationTime=None, lastModifiedTime=None, validUntilTime=None, replicaLocationCategory=None, replicaPersistentType=None, storageResourceId=None, filePath=None, replicaMetadata=None,):
- self.replicaId = replicaId
- self.productUri = productUri
- self.replicaName = replicaName
- self.replicaDescription = replicaDescription
- self.creationTime = creationTime
- self.lastModifiedTime = lastModifiedTime
- self.validUntilTime = validUntilTime
- self.replicaLocationCategory = replicaLocationCategory
- self.replicaPersistentType = replicaPersistentType
- self.storageResourceId = storageResourceId
- self.filePath = filePath
- self.replicaMetadata = replicaMetadata
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.replicaId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.productUri = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.replicaName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.replicaDescription = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I64:
- self.creationTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.I64:
- self.lastModifiedTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.I64:
- self.validUntilTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.I32:
- self.replicaLocationCategory = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.I32:
- self.replicaPersistentType = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.STRING:
- self.storageResourceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 11:
- if ftype == TType.STRING:
- self.filePath = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 12:
- if ftype == TType.MAP:
- self.replicaMetadata = {}
- (_ktype1, _vtype2, _size0 ) = iprot.readMapBegin()
- for _i4 in xrange(_size0):
- _key5 = iprot.readString()
- _val6 = iprot.readString()
- self.replicaMetadata[_key5] = _val6
- iprot.readMapEnd()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('DataReplicaLocationModel')
- if self.replicaId is not None:
- oprot.writeFieldBegin('replicaId', TType.STRING, 1)
- oprot.writeString(self.replicaId)
- oprot.writeFieldEnd()
- if self.productUri is not None:
- oprot.writeFieldBegin('productUri', TType.STRING, 2)
- oprot.writeString(self.productUri)
- oprot.writeFieldEnd()
- if self.replicaName is not None:
- oprot.writeFieldBegin('replicaName', TType.STRING, 3)
- oprot.writeString(self.replicaName)
- oprot.writeFieldEnd()
- if self.replicaDescription is not None:
- oprot.writeFieldBegin('replicaDescription', TType.STRING, 4)
- oprot.writeString(self.replicaDescription)
- oprot.writeFieldEnd()
- if self.creationTime is not None:
- oprot.writeFieldBegin('creationTime', TType.I64, 5)
- oprot.writeI64(self.creationTime)
- oprot.writeFieldEnd()
- if self.lastModifiedTime is not None:
- oprot.writeFieldBegin('lastModifiedTime', TType.I64, 6)
- oprot.writeI64(self.lastModifiedTime)
- oprot.writeFieldEnd()
- if self.validUntilTime is not None:
- oprot.writeFieldBegin('validUntilTime', TType.I64, 7)
- oprot.writeI64(self.validUntilTime)
- oprot.writeFieldEnd()
- if self.replicaLocationCategory is not None:
- oprot.writeFieldBegin('replicaLocationCategory', TType.I32, 8)
- oprot.writeI32(self.replicaLocationCategory)
- oprot.writeFieldEnd()
- if self.replicaPersistentType is not None:
- oprot.writeFieldBegin('replicaPersistentType', TType.I32, 9)
- oprot.writeI32(self.replicaPersistentType)
- oprot.writeFieldEnd()
- if self.storageResourceId is not None:
- oprot.writeFieldBegin('storageResourceId', TType.STRING, 10)
- oprot.writeString(self.storageResourceId)
- oprot.writeFieldEnd()
- if self.filePath is not None:
- oprot.writeFieldBegin('filePath', TType.STRING, 11)
- oprot.writeString(self.filePath)
- oprot.writeFieldEnd()
- if self.replicaMetadata is not None:
- oprot.writeFieldBegin('replicaMetadata', TType.MAP, 12)
- oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.replicaMetadata))
- for kiter7,viter8 in self.replicaMetadata.items():
- oprot.writeString(kiter7)
- oprot.writeString(viter8)
- oprot.writeMapEnd()
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.replicaId)
- value = (value * 31) ^ hash(self.productUri)
- value = (value * 31) ^ hash(self.replicaName)
- value = (value * 31) ^ hash(self.replicaDescription)
- value = (value * 31) ^ hash(self.creationTime)
- value = (value * 31) ^ hash(self.lastModifiedTime)
- value = (value * 31) ^ hash(self.validUntilTime)
- value = (value * 31) ^ hash(self.replicaLocationCategory)
- value = (value * 31) ^ hash(self.replicaPersistentType)
- value = (value * 31) ^ hash(self.storageResourceId)
- value = (value * 31) ^ hash(self.filePath)
- value = (value * 31) ^ hash(self.replicaMetadata)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class DataProductModel:
- """
- Attributes:
- - productUri
- - gatewayId
- - parentProductUri
- - productName
- - productDescription
- - ownerName
- - dataProductType
- - productSize
- - creationTime
- - lastModifiedTime
- - productMetadata
- - replicaLocations
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'productUri', None, None, ), # 1
- (2, TType.STRING, 'gatewayId', None, None, ), # 2
- (3, TType.STRING, 'parentProductUri', None, None, ), # 3
- (4, TType.STRING, 'productName', None, None, ), # 4
- (5, TType.STRING, 'productDescription', None, None, ), # 5
- (6, TType.STRING, 'ownerName', None, None, ), # 6
- (7, TType.I32, 'dataProductType', None, None, ), # 7
- (8, TType.I32, 'productSize', None, None, ), # 8
- (9, TType.I64, 'creationTime', None, None, ), # 9
- (10, TType.I64, 'lastModifiedTime', None, None, ), # 10
- (11, TType.MAP, 'productMetadata', (TType.STRING,None,TType.STRING,None), None, ), # 11
- (12, TType.LIST, 'replicaLocations', (TType.STRUCT,(DataReplicaLocationModel, DataReplicaLocationModel.thrift_spec)), None, ), # 12
- )
-
- def __init__(self, productUri=None, gatewayId=None, parentProductUri=None, productName=None, productDescription=None, ownerName=None, dataProductType=None, productSize=None, creationTime=None, lastModifiedTime=None, productMetadata=None, replicaLocations=None,):
- self.productUri = productUri
- self.gatewayId = gatewayId
- self.parentProductUri = parentProductUri
- self.productName = productName
- self.productDescription = productDescription
- self.ownerName = ownerName
- self.dataProductType = dataProductType
- self.productSize = productSize
- self.creationTime = creationTime
- self.lastModifiedTime = lastModifiedTime
- self.productMetadata = productMetadata
- self.replicaLocations = replicaLocations
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.productUri = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.parentProductUri = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.productName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.productDescription = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.ownerName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.I32:
- self.dataProductType = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.I32:
- self.productSize = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.I64:
- self.creationTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.I64:
- self.lastModifiedTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 11:
- if ftype == TType.MAP:
- self.productMetadata = {}
- (_ktype10, _vtype11, _size9 ) = iprot.readMapBegin()
- for _i13 in xrange(_size9):
- _key14 = iprot.readString()
- _val15 = iprot.readString()
- self.productMetadata[_key14] = _val15
- iprot.readMapEnd()
- else:
- iprot.skip(ftype)
- elif fid == 12:
- if ftype == TType.LIST:
- self.replicaLocations = []
- (_etype19, _size16) = iprot.readListBegin()
- for _i20 in xrange(_size16):
- _elem21 = DataReplicaLocationModel()
- _elem21.read(iprot)
- self.replicaLocations.append(_elem21)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('DataProductModel')
- if self.productUri is not None:
- oprot.writeFieldBegin('productUri', TType.STRING, 1)
- oprot.writeString(self.productUri)
- oprot.writeFieldEnd()
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 2)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- if self.parentProductUri is not None:
- oprot.writeFieldBegin('parentProductUri', TType.STRING, 3)
- oprot.writeString(self.parentProductUri)
- oprot.writeFieldEnd()
- if self.productName is not None:
- oprot.writeFieldBegin('productName', TType.STRING, 4)
- oprot.writeString(self.productName)
- oprot.writeFieldEnd()
- if self.productDescription is not None:
- oprot.writeFieldBegin('productDescription', TType.STRING, 5)
- oprot.writeString(self.productDescription)
- oprot.writeFieldEnd()
- if self.ownerName is not None:
- oprot.writeFieldBegin('ownerName', TType.STRING, 6)
- oprot.writeString(self.ownerName)
- oprot.writeFieldEnd()
- if self.dataProductType is not None:
- oprot.writeFieldBegin('dataProductType', TType.I32, 7)
- oprot.writeI32(self.dataProductType)
- oprot.writeFieldEnd()
- if self.productSize is not None:
- oprot.writeFieldBegin('productSize', TType.I32, 8)
- oprot.writeI32(self.productSize)
- oprot.writeFieldEnd()
- if self.creationTime is not None:
- oprot.writeFieldBegin('creationTime', TType.I64, 9)
- oprot.writeI64(self.creationTime)
- oprot.writeFieldEnd()
- if self.lastModifiedTime is not None:
- oprot.writeFieldBegin('lastModifiedTime', TType.I64, 10)
- oprot.writeI64(self.lastModifiedTime)
- oprot.writeFieldEnd()
- if self.productMetadata is not None:
- oprot.writeFieldBegin('productMetadata', TType.MAP, 11)
- oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.productMetadata))
- for kiter22,viter23 in self.productMetadata.items():
- oprot.writeString(kiter22)
- oprot.writeString(viter23)
- oprot.writeMapEnd()
- oprot.writeFieldEnd()
- if self.replicaLocations is not None:
- oprot.writeFieldBegin('replicaLocations', TType.LIST, 12)
- oprot.writeListBegin(TType.STRUCT, len(self.replicaLocations))
- for iter24 in self.replicaLocations:
- iter24.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.productUri)
- value = (value * 31) ^ hash(self.gatewayId)
- value = (value * 31) ^ hash(self.parentProductUri)
- value = (value * 31) ^ hash(self.productName)
- value = (value * 31) ^ hash(self.productDescription)
- value = (value * 31) ^ hash(self.ownerName)
- value = (value * 31) ^ hash(self.dataProductType)
- value = (value * 31) ^ hash(self.productSize)
- value = (value * 31) ^ hash(self.creationTime)
- value = (value * 31) ^ hash(self.lastModifiedTime)
- value = (value * 31) ^ hash(self.productMetadata)
- value = (value * 31) ^ hash(self.replicaLocations)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class ReplicaLocationCategory(object):
+ GATEWAY_DATA_STORE = 0
+ COMPUTE_RESOURCE = 1
+ LONG_TERM_STORAGE_RESOURCE = 2
+ OTHER = 3
+
+ _VALUES_TO_NAMES = {
+ 0: "GATEWAY_DATA_STORE",
+ 1: "COMPUTE_RESOURCE",
+ 2: "LONG_TERM_STORAGE_RESOURCE",
+ 3: "OTHER",
+ }
+
+ _NAMES_TO_VALUES = {
+ "GATEWAY_DATA_STORE": 0,
+ "COMPUTE_RESOURCE": 1,
+ "LONG_TERM_STORAGE_RESOURCE": 2,
+ "OTHER": 3,
+ }
+
+
+class ReplicaPersistentType(object):
+ TRANSIENT = 0
+ PERSISTENT = 1
+
+ _VALUES_TO_NAMES = {
+ 0: "TRANSIENT",
+ 1: "PERSISTENT",
+ }
+
+ _NAMES_TO_VALUES = {
+ "TRANSIENT": 0,
+ "PERSISTENT": 1,
+ }
+
+
+class DataProductType(object):
+ FILE = 0
+ COLLECTION = 1
+
+ _VALUES_TO_NAMES = {
+ 0: "FILE",
+ 1: "COLLECTION",
+ }
+
+ _NAMES_TO_VALUES = {
+ "FILE": 0,
+ "COLLECTION": 1,
+ }
+
+
+class DataReplicaLocationModel(object):
+ """
+ Attributes:
+ - replicaId
+ - productUri
+ - replicaName
+ - replicaDescription
+ - creationTime
+ - lastModifiedTime
+ - validUntilTime
+ - replicaLocationCategory
+ - replicaPersistentType
+ - storageResourceId
+ - filePath
+ - replicaMetadata
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'replicaId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'productUri', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'replicaName', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'replicaDescription', 'UTF8', None, ), # 4
+ (5, TType.I64, 'creationTime', None, None, ), # 5
+ (6, TType.I64, 'lastModifiedTime', None, None, ), # 6
+ (7, TType.I64, 'validUntilTime', None, None, ), # 7
+ (8, TType.I32, 'replicaLocationCategory', None, None, ), # 8
+ (9, TType.I32, 'replicaPersistentType', None, None, ), # 9
+ (10, TType.STRING, 'storageResourceId', 'UTF8', None, ), # 10
+ (11, TType.STRING, 'filePath', 'UTF8', None, ), # 11
+ (12, TType.MAP, 'replicaMetadata', (TType.STRING, 'UTF8', TType.STRING, 'UTF8', False), None, ), # 12
+ )
+
+ def __init__(self, replicaId=None, productUri=None, replicaName=None, replicaDescription=None, creationTime=None, lastModifiedTime=None, validUntilTime=None, replicaLocationCategory=None, replicaPersistentType=None, storageResourceId=None, filePath=None, replicaMetadata=None,):
+ self.replicaId = replicaId
+ self.productUri = productUri
+ self.replicaName = replicaName
+ self.replicaDescription = replicaDescription
+ self.creationTime = creationTime
+ self.lastModifiedTime = lastModifiedTime
+ self.validUntilTime = validUntilTime
+ self.replicaLocationCategory = replicaLocationCategory
+ self.replicaPersistentType = replicaPersistentType
+ self.storageResourceId = storageResourceId
+ self.filePath = filePath
+ self.replicaMetadata = replicaMetadata
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.replicaId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.productUri = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.replicaName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.replicaDescription = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.I64:
+ self.creationTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.I64:
+ self.lastModifiedTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.I64:
+ self.validUntilTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.I32:
+ self.replicaLocationCategory = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.I32:
+ self.replicaPersistentType = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.STRING:
+ self.storageResourceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 11:
+ if ftype == TType.STRING:
+ self.filePath = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 12:
+ if ftype == TType.MAP:
+ self.replicaMetadata = {}
+ (_ktype1, _vtype2, _size0) = iprot.readMapBegin()
+ for _i4 in range(_size0):
+ _key5 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ _val6 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ self.replicaMetadata[_key5] = _val6
+ iprot.readMapEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('DataReplicaLocationModel')
+ if self.replicaId is not None:
+ oprot.writeFieldBegin('replicaId', TType.STRING, 1)
+ oprot.writeString(self.replicaId.encode('utf-8') if sys.version_info[0] == 2 else self.replicaId)
+ oprot.writeFieldEnd()
+ if self.productUri is not None:
+ oprot.writeFieldBegin('productUri', TType.STRING, 2)
+ oprot.writeString(self.productUri.encode('utf-8') if sys.version_info[0] == 2 else self.productUri)
+ oprot.writeFieldEnd()
+ if self.replicaName is not None:
+ oprot.writeFieldBegin('replicaName', TType.STRING, 3)
+ oprot.writeString(self.replicaName.encode('utf-8') if sys.version_info[0] == 2 else self.replicaName)
+ oprot.writeFieldEnd()
+ if self.replicaDescription is not None:
+ oprot.writeFieldBegin('replicaDescription', TType.STRING, 4)
+ oprot.writeString(self.replicaDescription.encode('utf-8') if sys.version_info[0] == 2 else self.replicaDescription)
+ oprot.writeFieldEnd()
+ if self.creationTime is not None:
+ oprot.writeFieldBegin('creationTime', TType.I64, 5)
+ oprot.writeI64(self.creationTime)
+ oprot.writeFieldEnd()
+ if self.lastModifiedTime is not None:
+ oprot.writeFieldBegin('lastModifiedTime', TType.I64, 6)
+ oprot.writeI64(self.lastModifiedTime)
+ oprot.writeFieldEnd()
+ if self.validUntilTime is not None:
+ oprot.writeFieldBegin('validUntilTime', TType.I64, 7)
+ oprot.writeI64(self.validUntilTime)
+ oprot.writeFieldEnd()
+ if self.replicaLocationCategory is not None:
+ oprot.writeFieldBegin('replicaLocationCategory', TType.I32, 8)
+ oprot.writeI32(self.replicaLocationCategory)
+ oprot.writeFieldEnd()
+ if self.replicaPersistentType is not None:
+ oprot.writeFieldBegin('replicaPersistentType', TType.I32, 9)
+ oprot.writeI32(self.replicaPersistentType)
+ oprot.writeFieldEnd()
+ if self.storageResourceId is not None:
+ oprot.writeFieldBegin('storageResourceId', TType.STRING, 10)
+ oprot.writeString(self.storageResourceId.encode('utf-8') if sys.version_info[0] == 2 else self.storageResourceId)
+ oprot.writeFieldEnd()
+ if self.filePath is not None:
+ oprot.writeFieldBegin('filePath', TType.STRING, 11)
+ oprot.writeString(self.filePath.encode('utf-8') if sys.version_info[0] == 2 else self.filePath)
+ oprot.writeFieldEnd()
+ if self.replicaMetadata is not None:
+ oprot.writeFieldBegin('replicaMetadata', TType.MAP, 12)
+ oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.replicaMetadata))
+ for kiter7, viter8 in self.replicaMetadata.items():
+ oprot.writeString(kiter7.encode('utf-8') if sys.version_info[0] == 2 else kiter7)
+ oprot.writeString(viter8.encode('utf-8') if sys.version_info[0] == 2 else viter8)
+ oprot.writeMapEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class DataProductModel(object):
+ """
+ Attributes:
+ - productUri
+ - gatewayId
+ - parentProductUri
+ - productName
+ - productDescription
+ - ownerName
+ - dataProductType
+ - productSize
+ - creationTime
+ - lastModifiedTime
+ - productMetadata
+ - replicaLocations
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'productUri', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'gatewayId', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'parentProductUri', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'productName', 'UTF8', None, ), # 4
+ (5, TType.STRING, 'productDescription', 'UTF8', None, ), # 5
+ (6, TType.STRING, 'ownerName', 'UTF8', None, ), # 6
+ (7, TType.I32, 'dataProductType', None, None, ), # 7
+ (8, TType.I32, 'productSize', None, None, ), # 8
+ (9, TType.I64, 'creationTime', None, None, ), # 9
+ (10, TType.I64, 'lastModifiedTime', None, None, ), # 10
+ (11, TType.MAP, 'productMetadata', (TType.STRING, 'UTF8', TType.STRING, 'UTF8', False), None, ), # 11
+ (12, TType.LIST, 'replicaLocations', (TType.STRUCT, (DataReplicaLocationModel, DataReplicaLocationModel.thrift_spec), False), None, ), # 12
+ )
+
+ def __init__(self, productUri=None, gatewayId=None, parentProductUri=None, productName=None, productDescription=None, ownerName=None, dataProductType=None, productSize=None, creationTime=None, lastModifiedTime=None, productMetadata=None, replicaLocations=None,):
+ self.productUri = productUri
+ self.gatewayId = gatewayId
+ self.parentProductUri = parentProductUri
+ self.productName = productName
+ self.productDescription = productDescription
+ self.ownerName = ownerName
+ self.dataProductType = dataProductType
+ self.productSize = productSize
+ self.creationTime = creationTime
+ self.lastModifiedTime = lastModifiedTime
+ self.productMetadata = productMetadata
+ self.replicaLocations = replicaLocations
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.productUri = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.parentProductUri = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.productName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRING:
+ self.productDescription = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.ownerName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.I32:
+ self.dataProductType = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.I32:
+ self.productSize = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.I64:
+ self.creationTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.I64:
+ self.lastModifiedTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 11:
+ if ftype == TType.MAP:
+ self.productMetadata = {}
+ (_ktype10, _vtype11, _size9) = iprot.readMapBegin()
+ for _i13 in range(_size9):
+ _key14 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ _val15 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ self.productMetadata[_key14] = _val15
+ iprot.readMapEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 12:
+ if ftype == TType.LIST:
+ self.replicaLocations = []
+ (_etype19, _size16) = iprot.readListBegin()
+ for _i20 in range(_size16):
+ _elem21 = DataReplicaLocationModel()
+ _elem21.read(iprot)
+ self.replicaLocations.append(_elem21)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('DataProductModel')
+ if self.productUri is not None:
+ oprot.writeFieldBegin('productUri', TType.STRING, 1)
+ oprot.writeString(self.productUri.encode('utf-8') if sys.version_info[0] == 2 else self.productUri)
+ oprot.writeFieldEnd()
+ if self.gatewayId is not None:
+ oprot.writeFieldBegin('gatewayId', TType.STRING, 2)
+ oprot.writeString(self.gatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayId)
+ oprot.writeFieldEnd()
+ if self.parentProductUri is not None:
+ oprot.writeFieldBegin('parentProductUri', TType.STRING, 3)
+ oprot.writeString(self.parentProductUri.encode('utf-8') if sys.version_info[0] == 2 else self.parentProductUri)
+ oprot.writeFieldEnd()
+ if self.productName is not None:
+ oprot.writeFieldBegin('productName', TType.STRING, 4)
+ oprot.writeString(self.productName.encode('utf-8') if sys.version_info[0] == 2 else self.productName)
+ oprot.writeFieldEnd()
+ if self.productDescription is not None:
+ oprot.writeFieldBegin('productDescription', TType.STRING, 5)
+ oprot.writeString(self.productDescription.encode('utf-8') if sys.version_info[0] == 2 else self.productDescription)
+ oprot.writeFieldEnd()
+ if self.ownerName is not None:
+ oprot.writeFieldBegin('ownerName', TType.STRING, 6)
+ oprot.writeString(self.ownerName.encode('utf-8') if sys.version_info[0] == 2 else self.ownerName)
+ oprot.writeFieldEnd()
+ if self.dataProductType is not None:
+ oprot.writeFieldBegin('dataProductType', TType.I32, 7)
+ oprot.writeI32(self.dataProductType)
+ oprot.writeFieldEnd()
+ if self.productSize is not None:
+ oprot.writeFieldBegin('productSize', TType.I32, 8)
+ oprot.writeI32(self.productSize)
+ oprot.writeFieldEnd()
+ if self.creationTime is not None:
+ oprot.writeFieldBegin('creationTime', TType.I64, 9)
+ oprot.writeI64(self.creationTime)
+ oprot.writeFieldEnd()
+ if self.lastModifiedTime is not None:
+ oprot.writeFieldBegin('lastModifiedTime', TType.I64, 10)
+ oprot.writeI64(self.lastModifiedTime)
+ oprot.writeFieldEnd()
+ if self.productMetadata is not None:
+ oprot.writeFieldBegin('productMetadata', TType.MAP, 11)
+ oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.productMetadata))
+ for kiter22, viter23 in self.productMetadata.items():
+ oprot.writeString(kiter22.encode('utf-8') if sys.version_info[0] == 2 else kiter22)
+ oprot.writeString(viter23.encode('utf-8') if sys.version_info[0] == 2 else viter23)
+ oprot.writeMapEnd()
+ oprot.writeFieldEnd()
+ if self.replicaLocations is not None:
+ oprot.writeFieldBegin('replicaLocations', TType.LIST, 12)
+ oprot.writeListBegin(TType.STRUCT, len(self.replicaLocations))
+ for iter24 in self.replicaLocations:
+ iter24.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/dbevent/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/dbevent/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/dbevent/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/dbevent/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/dbevent/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/dbevent/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/dbevent/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/dbevent/ttypes.py
index 996f5bb..d33f0df 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/dbevent/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/dbevent/ttypes.py
@@ -1,494 +1,462 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class CrudType:
- CREATE = 0
- READ = 1
- UPDATE = 2
- DELETE = 3
-
- _VALUES_TO_NAMES = {
- 0: "CREATE",
- 1: "READ",
- 2: "UPDATE",
- 3: "DELETE",
- }
-
- _NAMES_TO_VALUES = {
- "CREATE": 0,
- "READ": 1,
- "UPDATE": 2,
- "DELETE": 3,
- }
-
-class EntityType:
- USER_PROFILE = 0
- TENANT = 1
- GROUP = 2
- PROJECT = 3
- EXPERIMENT = 4
- APPLICATION = 5
- SHARING = 6
- REGISTRY = 7
-
- _VALUES_TO_NAMES = {
- 0: "USER_PROFILE",
- 1: "TENANT",
- 2: "GROUP",
- 3: "PROJECT",
- 4: "EXPERIMENT",
- 5: "APPLICATION",
- 6: "SHARING",
- 7: "REGISTRY",
- }
-
- _NAMES_TO_VALUES = {
- "USER_PROFILE": 0,
- "TENANT": 1,
- "GROUP": 2,
- "PROJECT": 3,
- "EXPERIMENT": 4,
- "APPLICATION": 5,
- "SHARING": 6,
- "REGISTRY": 7,
- }
-
-class DBEventType:
- PUBLISHER = 0
- SUBSCRIBER = 1
-
- _VALUES_TO_NAMES = {
- 0: "PUBLISHER",
- 1: "SUBSCRIBER",
- }
-
- _NAMES_TO_VALUES = {
- "PUBLISHER": 0,
- "SUBSCRIBER": 1,
- }
-
-
-class DBEventPublisherContext:
- """
- Attributes:
- - crudType
- - entityType
- - entityDataModel
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'crudType', None, None, ), # 1
- (2, TType.I32, 'entityType', None, None, ), # 2
- (3, TType.STRING, 'entityDataModel', None, None, ), # 3
- )
-
- def __init__(self, crudType=None, entityType=None, entityDataModel=None,):
- self.crudType = crudType
- self.entityType = entityType
- self.entityDataModel = entityDataModel
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.crudType = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.entityType = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.entityDataModel = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('DBEventPublisherContext')
- if self.crudType is not None:
- oprot.writeFieldBegin('crudType', TType.I32, 1)
- oprot.writeI32(self.crudType)
- oprot.writeFieldEnd()
- if self.entityType is not None:
- oprot.writeFieldBegin('entityType', TType.I32, 2)
- oprot.writeI32(self.entityType)
- oprot.writeFieldEnd()
- if self.entityDataModel is not None:
- oprot.writeFieldBegin('entityDataModel', TType.STRING, 3)
- oprot.writeString(self.entityDataModel)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.crudType is None:
- raise TProtocol.TProtocolException(message='Required field crudType is unset!')
- if self.entityType is None:
- raise TProtocol.TProtocolException(message='Required field entityType is unset!')
- if self.entityDataModel is None:
- raise TProtocol.TProtocolException(message='Required field entityDataModel is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.crudType)
- value = (value * 31) ^ hash(self.entityType)
- value = (value * 31) ^ hash(self.entityDataModel)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class DBEventPublisher:
- """
- Attributes:
- - publisherContext
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRUCT, 'publisherContext', (DBEventPublisherContext, DBEventPublisherContext.thrift_spec), None, ), # 1
- )
-
- def __init__(self, publisherContext=None,):
- self.publisherContext = publisherContext
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRUCT:
- self.publisherContext = DBEventPublisherContext()
- self.publisherContext.read(iprot)
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('DBEventPublisher')
- if self.publisherContext is not None:
- oprot.writeFieldBegin('publisherContext', TType.STRUCT, 1)
- self.publisherContext.write(oprot)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.publisherContext is None:
- raise TProtocol.TProtocolException(message='Required field publisherContext is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.publisherContext)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class DBEventSubscriber:
- """
- Attributes:
- - subscriberService
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'subscriberService', None, None, ), # 1
- )
-
- def __init__(self, subscriberService=None,):
- self.subscriberService = subscriberService
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.subscriberService = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('DBEventSubscriber')
- if self.subscriberService is not None:
- oprot.writeFieldBegin('subscriberService', TType.STRING, 1)
- oprot.writeString(self.subscriberService)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.subscriberService is None:
- raise TProtocol.TProtocolException(message='Required field subscriberService is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.subscriberService)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class DBEventMessageContext:
- """
- Attributes:
- - publisher
- - subscriber
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRUCT, 'publisher', (DBEventPublisher, DBEventPublisher.thrift_spec), None, ), # 1
- (2, TType.STRUCT, 'subscriber', (DBEventSubscriber, DBEventSubscriber.thrift_spec), None, ), # 2
- )
-
- def __init__(self, publisher=None, subscriber=None,):
- self.publisher = publisher
- self.subscriber = subscriber
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRUCT:
- self.publisher = DBEventPublisher()
- self.publisher.read(iprot)
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRUCT:
- self.subscriber = DBEventSubscriber()
- self.subscriber.read(iprot)
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('DBEventMessageContext')
- if self.publisher is not None:
- oprot.writeFieldBegin('publisher', TType.STRUCT, 1)
- self.publisher.write(oprot)
- oprot.writeFieldEnd()
- if self.subscriber is not None:
- oprot.writeFieldBegin('subscriber', TType.STRUCT, 2)
- self.subscriber.write(oprot)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.publisher)
- value = (value * 31) ^ hash(self.subscriber)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class DBEventMessage:
- """
- Attributes:
- - dbEventType
- - messageContext
- - publisherService
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'dbEventType', None, None, ), # 1
- (2, TType.STRUCT, 'messageContext', (DBEventMessageContext, DBEventMessageContext.thrift_spec), None, ), # 2
- (3, TType.STRING, 'publisherService', None, None, ), # 3
- )
-
- def __init__(self, dbEventType=None, messageContext=None, publisherService=None,):
- self.dbEventType = dbEventType
- self.messageContext = messageContext
- self.publisherService = publisherService
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.dbEventType = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRUCT:
- self.messageContext = DBEventMessageContext()
- self.messageContext.read(iprot)
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.publisherService = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('DBEventMessage')
- if self.dbEventType is not None:
- oprot.writeFieldBegin('dbEventType', TType.I32, 1)
- oprot.writeI32(self.dbEventType)
- oprot.writeFieldEnd()
- if self.messageContext is not None:
- oprot.writeFieldBegin('messageContext', TType.STRUCT, 2)
- self.messageContext.write(oprot)
- oprot.writeFieldEnd()
- if self.publisherService is not None:
- oprot.writeFieldBegin('publisherService', TType.STRING, 3)
- oprot.writeString(self.publisherService)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.dbEventType is None:
- raise TProtocol.TProtocolException(message='Required field dbEventType is unset!')
- if self.messageContext is None:
- raise TProtocol.TProtocolException(message='Required field messageContext is unset!')
- if self.publisherService is None:
- raise TProtocol.TProtocolException(message='Required field publisherService is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.dbEventType)
- value = (value * 31) ^ hash(self.messageContext)
- value = (value * 31) ^ hash(self.publisherService)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class CrudType(object):
+ CREATE = 0
+ READ = 1
+ UPDATE = 2
+ DELETE = 3
+
+ _VALUES_TO_NAMES = {
+ 0: "CREATE",
+ 1: "READ",
+ 2: "UPDATE",
+ 3: "DELETE",
+ }
+
+ _NAMES_TO_VALUES = {
+ "CREATE": 0,
+ "READ": 1,
+ "UPDATE": 2,
+ "DELETE": 3,
+ }
+
+
+class EntityType(object):
+ USER_PROFILE = 0
+ TENANT = 1
+ GROUP = 2
+ PROJECT = 3
+ EXPERIMENT = 4
+ APPLICATION = 5
+ SHARING = 6
+ REGISTRY = 7
+
+ _VALUES_TO_NAMES = {
+ 0: "USER_PROFILE",
+ 1: "TENANT",
+ 2: "GROUP",
+ 3: "PROJECT",
+ 4: "EXPERIMENT",
+ 5: "APPLICATION",
+ 6: "SHARING",
+ 7: "REGISTRY",
+ }
+
+ _NAMES_TO_VALUES = {
+ "USER_PROFILE": 0,
+ "TENANT": 1,
+ "GROUP": 2,
+ "PROJECT": 3,
+ "EXPERIMENT": 4,
+ "APPLICATION": 5,
+ "SHARING": 6,
+ "REGISTRY": 7,
+ }
+
+
+class DBEventType(object):
+ PUBLISHER = 0
+ SUBSCRIBER = 1
+
+ _VALUES_TO_NAMES = {
+ 0: "PUBLISHER",
+ 1: "SUBSCRIBER",
+ }
+
+ _NAMES_TO_VALUES = {
+ "PUBLISHER": 0,
+ "SUBSCRIBER": 1,
+ }
+
+
+class DBEventPublisherContext(object):
+ """
+ Attributes:
+ - crudType
+ - entityType
+ - entityDataModel
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'crudType', None, None, ), # 1
+ (2, TType.I32, 'entityType', None, None, ), # 2
+ (3, TType.STRING, 'entityDataModel', 'BINARY', None, ), # 3
+ )
+
+ def __init__(self, crudType=None, entityType=None, entityDataModel=None,):
+ self.crudType = crudType
+ self.entityType = entityType
+ self.entityDataModel = entityDataModel
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.crudType = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I32:
+ self.entityType = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.entityDataModel = iprot.readBinary()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('DBEventPublisherContext')
+ if self.crudType is not None:
+ oprot.writeFieldBegin('crudType', TType.I32, 1)
+ oprot.writeI32(self.crudType)
+ oprot.writeFieldEnd()
+ if self.entityType is not None:
+ oprot.writeFieldBegin('entityType', TType.I32, 2)
+ oprot.writeI32(self.entityType)
+ oprot.writeFieldEnd()
+ if self.entityDataModel is not None:
+ oprot.writeFieldBegin('entityDataModel', TType.STRING, 3)
+ oprot.writeBinary(self.entityDataModel)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.crudType is None:
+ raise TProtocolException(message='Required field crudType is unset!')
+ if self.entityType is None:
+ raise TProtocolException(message='Required field entityType is unset!')
+ if self.entityDataModel is None:
+ raise TProtocolException(message='Required field entityDataModel is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class DBEventPublisher(object):
+ """
+ Attributes:
+ - publisherContext
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRUCT, 'publisherContext', (DBEventPublisherContext, DBEventPublisherContext.thrift_spec), None, ), # 1
+ )
+
+ def __init__(self, publisherContext=None,):
+ self.publisherContext = publisherContext
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRUCT:
+ self.publisherContext = DBEventPublisherContext()
+ self.publisherContext.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('DBEventPublisher')
+ if self.publisherContext is not None:
+ oprot.writeFieldBegin('publisherContext', TType.STRUCT, 1)
+ self.publisherContext.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.publisherContext is None:
+ raise TProtocolException(message='Required field publisherContext is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class DBEventSubscriber(object):
+ """
+ Attributes:
+ - subscriberService
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'subscriberService', 'UTF8', None, ), # 1
+ )
+
+ def __init__(self, subscriberService=None,):
+ self.subscriberService = subscriberService
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.subscriberService = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('DBEventSubscriber')
+ if self.subscriberService is not None:
+ oprot.writeFieldBegin('subscriberService', TType.STRING, 1)
+ oprot.writeString(self.subscriberService.encode('utf-8') if sys.version_info[0] == 2 else self.subscriberService)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.subscriberService is None:
+ raise TProtocolException(message='Required field subscriberService is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class DBEventMessageContext(object):
+ """
+ Attributes:
+ - publisher
+ - subscriber
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRUCT, 'publisher', (DBEventPublisher, DBEventPublisher.thrift_spec), None, ), # 1
+ (2, TType.STRUCT, 'subscriber', (DBEventSubscriber, DBEventSubscriber.thrift_spec), None, ), # 2
+ )
+
+ def __init__(self, publisher=None, subscriber=None,):
+ self.publisher = publisher
+ self.subscriber = subscriber
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRUCT:
+ self.publisher = DBEventPublisher()
+ self.publisher.read(iprot)
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRUCT:
+ self.subscriber = DBEventSubscriber()
+ self.subscriber.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('DBEventMessageContext')
+ if self.publisher is not None:
+ oprot.writeFieldBegin('publisher', TType.STRUCT, 1)
+ self.publisher.write(oprot)
+ oprot.writeFieldEnd()
+ if self.subscriber is not None:
+ oprot.writeFieldBegin('subscriber', TType.STRUCT, 2)
+ self.subscriber.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class DBEventMessage(object):
+ """
+ Attributes:
+ - dbEventType
+ - messageContext
+ - publisherService
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'dbEventType', None, None, ), # 1
+ (2, TType.STRUCT, 'messageContext', (DBEventMessageContext, DBEventMessageContext.thrift_spec), None, ), # 2
+ (3, TType.STRING, 'publisherService', 'UTF8', None, ), # 3
+ )
+
+ def __init__(self, dbEventType=None, messageContext=None, publisherService=None,):
+ self.dbEventType = dbEventType
+ self.messageContext = messageContext
+ self.publisherService = publisherService
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.dbEventType = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRUCT:
+ self.messageContext = DBEventMessageContext()
+ self.messageContext.read(iprot)
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.publisherService = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('DBEventMessage')
+ if self.dbEventType is not None:
+ oprot.writeFieldBegin('dbEventType', TType.I32, 1)
+ oprot.writeI32(self.dbEventType)
+ oprot.writeFieldEnd()
+ if self.messageContext is not None:
+ oprot.writeFieldBegin('messageContext', TType.STRUCT, 2)
+ self.messageContext.write(oprot)
+ oprot.writeFieldEnd()
+ if self.publisherService is not None:
+ oprot.writeFieldBegin('publisherService', TType.STRING, 3)
+ oprot.writeString(self.publisherService.encode('utf-8') if sys.version_info[0] == 2 else self.publisherService)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.dbEventType is None:
+ raise TProtocolException(message='Required field dbEventType is unset!')
+ if self.messageContext is None:
+ raise TProtocolException(message='Required field messageContext is unset!')
+ if self.publisherService is None:
+ raise TProtocolException(message='Required field publisherService is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/experiment/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/experiment/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/experiment/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/experiment/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/experiment/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
[46/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/constants.py
index 9bc7220..b7efdcc 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/constants.py
@@ -1,12 +1,13 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
AIRAVATA_API_VERSION = "0.17.0"
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/error/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/error/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/error/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/error/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/error/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/error/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/error/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/error/ttypes.py
index ba5b056..390ffe8 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/error/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/error/ttypes.py
@@ -1,1016 +1,947 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.experiment.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class AiravataErrorType:
- """
- A list of Airavata API Error Message Types
-
- UNKNOWN: No information available about the error
-
- PERMISSION_DENIED: Not permitted to perform action
-
- INTERNAL_ERROR: Unexpected problem with the service
-
- AUTHENTICATION_FAILURE: The client failed to authenticate.
-
- INVALID_AUTHORIZATION: Security Token and/or Username and/or password is incorrect
-
- AUTHORIZATION_EXPIRED: Authentication token expired
-
- UNKNOWN_GATEWAY_ID: The gateway is not registered with Airavata.
-
- UNSUPPORTED_OPERATION: Operation denied because it is currently unsupported.
- """
- UNKNOWN = 0
- PERMISSION_DENIED = 1
- INTERNAL_ERROR = 2
- AUTHENTICATION_FAILURE = 3
- INVALID_AUTHORIZATION = 4
- AUTHORIZATION_EXPIRED = 5
- UNKNOWN_GATEWAY_ID = 6
- UNSUPPORTED_OPERATION = 7
-
- _VALUES_TO_NAMES = {
- 0: "UNKNOWN",
- 1: "PERMISSION_DENIED",
- 2: "INTERNAL_ERROR",
- 3: "AUTHENTICATION_FAILURE",
- 4: "INVALID_AUTHORIZATION",
- 5: "AUTHORIZATION_EXPIRED",
- 6: "UNKNOWN_GATEWAY_ID",
- 7: "UNSUPPORTED_OPERATION",
- }
-
- _NAMES_TO_VALUES = {
- "UNKNOWN": 0,
- "PERMISSION_DENIED": 1,
- "INTERNAL_ERROR": 2,
- "AUTHENTICATION_FAILURE": 3,
- "INVALID_AUTHORIZATION": 4,
- "AUTHORIZATION_EXPIRED": 5,
- "UNKNOWN_GATEWAY_ID": 6,
- "UNSUPPORTED_OPERATION": 7,
- }
+
+
+class AiravataErrorType(object):
+ """
+ A list of Airavata API Error Message Types
+
+ UNKNOWN: No information available about the error
+
+ PERMISSION_DENIED: Not permitted to perform action
+
+ INTERNAL_ERROR: Unexpected problem with the service
+
+ AUTHENTICATION_FAILURE: The client failed to authenticate.
+
+ INVALID_AUTHORIZATION: Security Token and/or Username and/or password is incorrect
+
+ AUTHORIZATION_EXPIRED: Authentication token expired
+
+ UNKNOWN_GATEWAY_ID: The gateway is not registered with Airavata.
+
+ UNSUPPORTED_OPERATION: Operation denied because it is currently unsupported.
+ """
+ UNKNOWN = 0
+ PERMISSION_DENIED = 1
+ INTERNAL_ERROR = 2
+ AUTHENTICATION_FAILURE = 3
+ INVALID_AUTHORIZATION = 4
+ AUTHORIZATION_EXPIRED = 5
+ UNKNOWN_GATEWAY_ID = 6
+ UNSUPPORTED_OPERATION = 7
+
+ _VALUES_TO_NAMES = {
+ 0: "UNKNOWN",
+ 1: "PERMISSION_DENIED",
+ 2: "INTERNAL_ERROR",
+ 3: "AUTHENTICATION_FAILURE",
+ 4: "INVALID_AUTHORIZATION",
+ 5: "AUTHORIZATION_EXPIRED",
+ 6: "UNKNOWN_GATEWAY_ID",
+ 7: "UNSUPPORTED_OPERATION",
+ }
+
+ _NAMES_TO_VALUES = {
+ "UNKNOWN": 0,
+ "PERMISSION_DENIED": 1,
+ "INTERNAL_ERROR": 2,
+ "AUTHENTICATION_FAILURE": 3,
+ "INVALID_AUTHORIZATION": 4,
+ "AUTHORIZATION_EXPIRED": 5,
+ "UNKNOWN_GATEWAY_ID": 6,
+ "UNSUPPORTED_OPERATION": 7,
+ }
class ExperimentNotFoundException(TException):
- """
- This exception is thrown when a client asks to perform an operation on an experiment that does not exist.
-
- identifier: A description of the experiment that was not found on the server.
-
- key: The value passed from the client in the identifier, which was not found.
-
- Attributes:
- - message
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'message', None, None, ), # 1
- )
-
- def __init__(self, message=None,):
- self.message = message
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.message = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ExperimentNotFoundException')
- if self.message is not None:
- oprot.writeFieldBegin('message', TType.STRING, 1)
- oprot.writeString(self.message)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.message is None:
- raise TProtocol.TProtocolException(message='Required field message is unset!')
- return
-
-
- def __str__(self):
- return repr(self)
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.message)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+ """
+ This exception is thrown when a client asks to perform an operation on an experiment that does not exist.
+
+ identifier: A description of the experiment that was not found on the server.
+
+ key: The value passed from the client in the identifier, which was not found.
+
+ Attributes:
+ - message
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'message', 'UTF8', None, ), # 1
+ )
+
+ def __init__(self, message=None,):
+ self.message = message
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.message = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ExperimentNotFoundException')
+ if self.message is not None:
+ oprot.writeFieldBegin('message', TType.STRING, 1)
+ oprot.writeString(self.message.encode('utf-8') if sys.version_info[0] == 2 else self.message)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.message is None:
+ raise TProtocolException(message='Required field message is unset!')
+ return
+
+ def __str__(self):
+ return repr(self)
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
class ProjectNotFoundException(TException):
- """
- 1: optional string identifier,
- 2: optional string key
-
-
- Attributes:
- - message
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'message', None, None, ), # 1
- )
-
- def __init__(self, message=None,):
- self.message = message
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.message = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ProjectNotFoundException')
- if self.message is not None:
- oprot.writeFieldBegin('message', TType.STRING, 1)
- oprot.writeString(self.message)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.message is None:
- raise TProtocol.TProtocolException(message='Required field message is unset!')
- return
-
-
- def __str__(self):
- return repr(self)
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.message)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+ """
+ 1: optional string identifier,
+ 2: optional string key
+
+
+ Attributes:
+ - message
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'message', 'UTF8', None, ), # 1
+ )
+
+ def __init__(self, message=None,):
+ self.message = message
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.message = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ProjectNotFoundException')
+ if self.message is not None:
+ oprot.writeFieldBegin('message', TType.STRING, 1)
+ oprot.writeString(self.message.encode('utf-8') if sys.version_info[0] == 2 else self.message)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.message is None:
+ raise TProtocolException(message='Required field message is unset!')
+ return
+
+ def __str__(self):
+ return repr(self)
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
class InvalidRequestException(TException):
- """
- This exception is thrown for invalid requests that occur from any reasons like required input parameters are missing,
- or a parameter is malformed.
-
- message: contains the associated error message.
-
- Attributes:
- - message
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'message', None, None, ), # 1
- )
-
- def __init__(self, message=None,):
- self.message = message
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.message = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('InvalidRequestException')
- if self.message is not None:
- oprot.writeFieldBegin('message', TType.STRING, 1)
- oprot.writeString(self.message)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.message is None:
- raise TProtocol.TProtocolException(message='Required field message is unset!')
- return
-
-
- def __str__(self):
- return repr(self)
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.message)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+ """
+ This exception is thrown for invalid requests that occur from any reasons like required input parameters are missing,
+ or a parameter is malformed.
+
+ message: contains the associated error message.
+
+ Attributes:
+ - message
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'message', 'UTF8', None, ), # 1
+ )
+
+ def __init__(self, message=None,):
+ self.message = message
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.message = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('InvalidRequestException')
+ if self.message is not None:
+ oprot.writeFieldBegin('message', TType.STRING, 1)
+ oprot.writeString(self.message.encode('utf-8') if sys.version_info[0] == 2 else self.message)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.message is None:
+ raise TProtocolException(message='Required field message is unset!')
+ return
+
+ def __str__(self):
+ return repr(self)
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
class TimedOutException(TException):
- """
- This exception is thrown when RPC timeout gets exceeded.
- """
-
- thrift_spec = (
- )
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('TimedOutException')
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- return
-
-
- def __str__(self):
- return repr(self)
-
- def __hash__(self):
- value = 17
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+ """
+ This exception is thrown when RPC timeout gets exceeded.
+ """
+
+ thrift_spec = (
+ )
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('TimedOutException')
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+ def __str__(self):
+ return repr(self)
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
class AuthenticationException(TException):
- """
- This exception is thrown for invalid sshKeyAuthentication requests.
-
- message: contains the cause of the authorization failure.
-
- Attributes:
- - message
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'message', None, None, ), # 1
- )
-
- def __init__(self, message=None,):
- self.message = message
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.message = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('AuthenticationException')
- if self.message is not None:
- oprot.writeFieldBegin('message', TType.STRING, 1)
- oprot.writeString(self.message)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.message is None:
- raise TProtocol.TProtocolException(message='Required field message is unset!')
- return
-
-
- def __str__(self):
- return repr(self)
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.message)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+ """
+ This exception is thrown for invalid sshKeyAuthentication requests.
+
+ message: contains the cause of the authorization failure.
+
+ Attributes:
+ - message
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'message', 'UTF8', None, ), # 1
+ )
+
+ def __init__(self, message=None,):
+ self.message = message
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.message = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('AuthenticationException')
+ if self.message is not None:
+ oprot.writeFieldBegin('message', TType.STRING, 1)
+ oprot.writeString(self.message.encode('utf-8') if sys.version_info[0] == 2 else self.message)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.message is None:
+ raise TProtocolException(message='Required field message is unset!')
+ return
+
+ def __str__(self):
+ return repr(self)
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
class AuthorizationException(TException):
- """
- This exception is thrown for invalid authorization requests such user does not have acces to an aplication or resource.
-
- message: contains the authorization failure message
-
- Attributes:
- - message
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'message', None, None, ), # 1
- )
-
- def __init__(self, message=None,):
- self.message = message
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.message = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('AuthorizationException')
- if self.message is not None:
- oprot.writeFieldBegin('message', TType.STRING, 1)
- oprot.writeString(self.message)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.message is None:
- raise TProtocol.TProtocolException(message='Required field message is unset!')
- return
-
-
- def __str__(self):
- return repr(self)
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.message)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+ """
+ This exception is thrown for invalid authorization requests such user does not have acces to an aplication or resource.
+
+ message: contains the authorization failure message
+
+ Attributes:
+ - message
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'message', 'UTF8', None, ), # 1
+ )
+
+ def __init__(self, message=None,):
+ self.message = message
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.message = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('AuthorizationException')
+ if self.message is not None:
+ oprot.writeFieldBegin('message', TType.STRING, 1)
+ oprot.writeString(self.message.encode('utf-8') if sys.version_info[0] == 2 else self.message)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.message is None:
+ raise TProtocolException(message='Required field message is unset!')
+ return
+
+ def __str__(self):
+ return repr(self)
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
class DuplicateEntryException(TException):
- """
- This exception is thrown when you try to save a duplicate entity that already exists
- in the database.
-
- message: contains the associated error message
-
-
- Attributes:
- - message
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'message', None, None, ), # 1
- )
-
- def __init__(self, message=None,):
- self.message = message
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.message = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('DuplicateEntryException')
- if self.message is not None:
- oprot.writeFieldBegin('message', TType.STRING, 1)
- oprot.writeString(self.message)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.message is None:
- raise TProtocol.TProtocolException(message='Required field message is unset!')
- return
-
-
- def __str__(self):
- return repr(self)
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.message)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+ """
+ This exception is thrown when you try to save a duplicate entity that already exists
+ in the database.
+
+ message: contains the associated error message
+
+
+ Attributes:
+ - message
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'message', 'UTF8', None, ), # 1
+ )
+
+ def __init__(self, message=None,):
+ self.message = message
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.message = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('DuplicateEntryException')
+ if self.message is not None:
+ oprot.writeFieldBegin('message', TType.STRING, 1)
+ oprot.writeString(self.message.encode('utf-8') if sys.version_info[0] == 2 else self.message)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.message is None:
+ raise TProtocolException(message='Required field message is unset!')
+ return
+
+ def __str__(self):
+ return repr(self)
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
class AiravataClientException(TException):
- """
- This exception is thrown by Airavata Services when a call fails as a result of
- a problem that a client may be able to resolve. For example, if the user
- attempts to execute an application on a resource gateway does not have access to.
-
- This exception would not be used for internal system errors that do not
- reflect user actions, but rather reflect a problem within the service that
- the client cannot resolve.
-
- airavataErrorType: The message type indicating the error that occurred.
- must be one of the values of AiravataErrorType.
-
- parameter: If the error applied to a particular input parameter, this will
- indicate which parameter.
-
- Attributes:
- - airavataErrorType
- - parameter
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'airavataErrorType', None, None, ), # 1
- (2, TType.STRING, 'parameter', None, None, ), # 2
- )
-
- def __init__(self, airavataErrorType=None, parameter=None,):
- self.airavataErrorType = airavataErrorType
- self.parameter = parameter
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.airavataErrorType = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.parameter = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('AiravataClientException')
- if self.airavataErrorType is not None:
- oprot.writeFieldBegin('airavataErrorType', TType.I32, 1)
- oprot.writeI32(self.airavataErrorType)
- oprot.writeFieldEnd()
- if self.parameter is not None:
- oprot.writeFieldBegin('parameter', TType.STRING, 2)
- oprot.writeString(self.parameter)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.airavataErrorType is None:
- raise TProtocol.TProtocolException(message='Required field airavataErrorType is unset!')
- return
-
-
- def __str__(self):
- return repr(self)
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.airavataErrorType)
- value = (value * 31) ^ hash(self.parameter)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ValidatorResult:
- """
- Attributes:
- - result
- - errorDetails
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.BOOL, 'result', None, None, ), # 1
- (2, TType.STRING, 'errorDetails', None, None, ), # 2
- )
-
- def __init__(self, result=None, errorDetails=None,):
- self.result = result
- self.errorDetails = errorDetails
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.BOOL:
- self.result = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.errorDetails = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ValidatorResult')
- if self.result is not None:
- oprot.writeFieldBegin('result', TType.BOOL, 1)
- oprot.writeBool(self.result)
- oprot.writeFieldEnd()
- if self.errorDetails is not None:
- oprot.writeFieldBegin('errorDetails', TType.STRING, 2)
- oprot.writeString(self.errorDetails)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.result is None:
- raise TProtocol.TProtocolException(message='Required field result is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.result)
- value = (value * 31) ^ hash(self.errorDetails)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ValidationResults:
- """
- Attributes:
- - validationState
- - validationResultList
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.BOOL, 'validationState', None, None, ), # 1
- (2, TType.LIST, 'validationResultList', (TType.STRUCT,(ValidatorResult, ValidatorResult.thrift_spec)), None, ), # 2
- )
-
- def __init__(self, validationState=None, validationResultList=None,):
- self.validationState = validationState
- self.validationResultList = validationResultList
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.BOOL:
- self.validationState = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.LIST:
- self.validationResultList = []
- (_etype3, _size0) = iprot.readListBegin()
- for _i4 in xrange(_size0):
- _elem5 = ValidatorResult()
- _elem5.read(iprot)
- self.validationResultList.append(_elem5)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ValidationResults')
- if self.validationState is not None:
- oprot.writeFieldBegin('validationState', TType.BOOL, 1)
- oprot.writeBool(self.validationState)
- oprot.writeFieldEnd()
- if self.validationResultList is not None:
- oprot.writeFieldBegin('validationResultList', TType.LIST, 2)
- oprot.writeListBegin(TType.STRUCT, len(self.validationResultList))
- for iter6 in self.validationResultList:
- iter6.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.validationState is None:
- raise TProtocol.TProtocolException(message='Required field validationState is unset!')
- if self.validationResultList is None:
- raise TProtocol.TProtocolException(message='Required field validationResultList is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.validationState)
- value = (value * 31) ^ hash(self.validationResultList)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+ """
+ This exception is thrown by Airavata Services when a call fails as a result of
+ a problem that a client may be able to resolve. For example, if the user
+ attempts to execute an application on a resource gateway does not have access to.
+
+ This exception would not be used for internal system errors that do not
+ reflect user actions, but rather reflect a problem within the service that
+ the client cannot resolve.
+
+ airavataErrorType: The message type indicating the error that occurred.
+ must be one of the values of AiravataErrorType.
+
+ parameter: If the error applied to a particular input parameter, this will
+ indicate which parameter.
+
+ Attributes:
+ - airavataErrorType
+ - parameter
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'airavataErrorType', None, None, ), # 1
+ (2, TType.STRING, 'parameter', 'UTF8', None, ), # 2
+ )
+
+ def __init__(self, airavataErrorType=None, parameter=None,):
+ self.airavataErrorType = airavataErrorType
+ self.parameter = parameter
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.airavataErrorType = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.parameter = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('AiravataClientException')
+ if self.airavataErrorType is not None:
+ oprot.writeFieldBegin('airavataErrorType', TType.I32, 1)
+ oprot.writeI32(self.airavataErrorType)
+ oprot.writeFieldEnd()
+ if self.parameter is not None:
+ oprot.writeFieldBegin('parameter', TType.STRING, 2)
+ oprot.writeString(self.parameter.encode('utf-8') if sys.version_info[0] == 2 else self.parameter)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.airavataErrorType is None:
+ raise TProtocolException(message='Required field airavataErrorType is unset!')
+ return
+
+ def __str__(self):
+ return repr(self)
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class ValidatorResult(object):
+ """
+ Attributes:
+ - result
+ - errorDetails
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.BOOL, 'result', None, None, ), # 1
+ (2, TType.STRING, 'errorDetails', 'UTF8', None, ), # 2
+ )
+
+ def __init__(self, result=None, errorDetails=None,):
+ self.result = result
+ self.errorDetails = errorDetails
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.BOOL:
+ self.result = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.errorDetails = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ValidatorResult')
+ if self.result is not None:
+ oprot.writeFieldBegin('result', TType.BOOL, 1)
+ oprot.writeBool(self.result)
+ oprot.writeFieldEnd()
+ if self.errorDetails is not None:
+ oprot.writeFieldBegin('errorDetails', TType.STRING, 2)
+ oprot.writeString(self.errorDetails.encode('utf-8') if sys.version_info[0] == 2 else self.errorDetails)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.result is None:
+ raise TProtocolException(message='Required field result is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class ValidationResults(object):
+ """
+ Attributes:
+ - validationState
+ - validationResultList
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.BOOL, 'validationState', None, None, ), # 1
+ (2, TType.LIST, 'validationResultList', (TType.STRUCT, (ValidatorResult, ValidatorResult.thrift_spec), False), None, ), # 2
+ )
+
+ def __init__(self, validationState=None, validationResultList=None,):
+ self.validationState = validationState
+ self.validationResultList = validationResultList
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.BOOL:
+ self.validationState = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.LIST:
+ self.validationResultList = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in range(_size0):
+ _elem5 = ValidatorResult()
+ _elem5.read(iprot)
+ self.validationResultList.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ValidationResults')
+ if self.validationState is not None:
+ oprot.writeFieldBegin('validationState', TType.BOOL, 1)
+ oprot.writeBool(self.validationState)
+ oprot.writeFieldEnd()
+ if self.validationResultList is not None:
+ oprot.writeFieldBegin('validationResultList', TType.LIST, 2)
+ oprot.writeListBegin(TType.STRUCT, len(self.validationResultList))
+ for iter6 in self.validationResultList:
+ iter6.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.validationState is None:
+ raise TProtocolException(message='Required field validationState is unset!')
+ if self.validationResultList is None:
+ raise TProtocolException(message='Required field validationResultList is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
class LaunchValidationException(TException):
- """
- Attributes:
- - validationResult
- - errorMessage
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRUCT, 'validationResult', (ValidationResults, ValidationResults.thrift_spec), None, ), # 1
- (2, TType.STRING, 'errorMessage', None, None, ), # 2
- )
-
- def __init__(self, validationResult=None, errorMessage=None,):
- self.validationResult = validationResult
- self.errorMessage = errorMessage
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRUCT:
- self.validationResult = ValidationResults()
- self.validationResult.read(iprot)
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.errorMessage = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('LaunchValidationException')
- if self.validationResult is not None:
- oprot.writeFieldBegin('validationResult', TType.STRUCT, 1)
- self.validationResult.write(oprot)
- oprot.writeFieldEnd()
- if self.errorMessage is not None:
- oprot.writeFieldBegin('errorMessage', TType.STRING, 2)
- oprot.writeString(self.errorMessage)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.validationResult is None:
- raise TProtocol.TProtocolException(message='Required field validationResult is unset!')
- return
-
-
- def __str__(self):
- return repr(self)
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.validationResult)
- value = (value * 31) ^ hash(self.errorMessage)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+ """
+ Attributes:
+ - validationResult
+ - errorMessage
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRUCT, 'validationResult', (ValidationResults, ValidationResults.thrift_spec), None, ), # 1
+ (2, TType.STRING, 'errorMessage', 'UTF8', None, ), # 2
+ )
+
+ def __init__(self, validationResult=None, errorMessage=None,):
+ self.validationResult = validationResult
+ self.errorMessage = errorMessage
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRUCT:
+ self.validationResult = ValidationResults()
+ self.validationResult.read(iprot)
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.errorMessage = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('LaunchValidationException')
+ if self.validationResult is not None:
+ oprot.writeFieldBegin('validationResult', TType.STRUCT, 1)
+ self.validationResult.write(oprot)
+ oprot.writeFieldEnd()
+ if self.errorMessage is not None:
+ oprot.writeFieldBegin('errorMessage', TType.STRING, 2)
+ oprot.writeString(self.errorMessage.encode('utf-8') if sys.version_info[0] == 2 else self.errorMessage)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.validationResult is None:
+ raise TProtocolException(message='Required field validationResult is unset!')
+ return
+
+ def __str__(self):
+ return repr(self)
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
class AiravataSystemException(TException):
- """
- This exception is thrown by Airavata Services when a call fails as a result of
- a problem in the service that could not be changed through client's action.
-
- airavataErrorType: The message type indicating the error that occurred.
- must be one of the values of AiravataErrorType.
-
- message: This may contain additional information about the error
-
-
- Attributes:
- - airavataErrorType
- - message
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'airavataErrorType', None, None, ), # 1
- (2, TType.STRING, 'message', None, None, ), # 2
- )
-
- def __init__(self, airavataErrorType=None, message=None,):
- self.airavataErrorType = airavataErrorType
- self.message = message
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.airavataErrorType = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.message = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('AiravataSystemException')
- if self.airavataErrorType is not None:
- oprot.writeFieldBegin('airavataErrorType', TType.I32, 1)
- oprot.writeI32(self.airavataErrorType)
- oprot.writeFieldEnd()
- if self.message is not None:
- oprot.writeFieldBegin('message', TType.STRING, 2)
- oprot.writeString(self.message)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.airavataErrorType is None:
- raise TProtocol.TProtocolException(message='Required field airavataErrorType is unset!')
- return
-
-
- def __str__(self):
- return repr(self)
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.airavataErrorType)
- value = (value * 31) ^ hash(self.message)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+ """
+ This exception is thrown by Airavata Services when a call fails as a result of
+ a problem in the service that could not be changed through client's action.
+
+ airavataErrorType: The message type indicating the error that occurred.
+ must be one of the values of AiravataErrorType.
+
+ message: This may contain additional information about the error
+
+
+ Attributes:
+ - airavataErrorType
+ - message
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'airavataErrorType', None, None, ), # 1
+ (2, TType.STRING, 'message', 'UTF8', None, ), # 2
+ )
+
+ def __init__(self, airavataErrorType=None, message=None,):
+ self.airavataErrorType = airavataErrorType
+ self.message = message
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.airavataErrorType = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.message = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('AiravataSystemException')
+ if self.airavataErrorType is not None:
+ oprot.writeFieldBegin('airavataErrorType', TType.I32, 1)
+ oprot.writeI32(self.airavataErrorType)
+ oprot.writeFieldEnd()
+ if self.message is not None:
+ oprot.writeFieldBegin('message', TType.STRING, 2)
+ oprot.writeString(self.message.encode('utf-8') if sys.version_info[0] == 2 else self.message)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.airavataErrorType is None:
+ raise TProtocolException(message='Required field airavataErrorType is unset!')
+ return
+
+ def __str__(self):
+ return repr(self)
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
[11/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/PasswordCredential.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/PasswordCredential.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/PasswordCredential.java
index f7d5db0..bb3d291 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/PasswordCredential.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/PasswordCredential.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.credential.store;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
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");
@@ -63,19 +36,16 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
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 PasswordCredentialStandardSchemeFactory());
- schemes.put(TupleScheme.class, new PasswordCredentialTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new PasswordCredentialStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new PasswordCredentialTupleSchemeFactory();
- private String gatewayId; // required
- private String portalUserName; // required
- private String loginUserName; // required
- private String password; // required
- private String description; // optional
+ private java.lang.String gatewayId; // required
+ private java.lang.String portalUserName; // required
+ private java.lang.String loginUserName; // required
+ private java.lang.String password; // required
+ private java.lang.String description; // optional
private long persistedTime; // optional
- private String token; // optional
+ private java.lang.String token; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -87,10 +57,10 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
PERSISTED_TIME((short)6, "persistedTime"),
TOKEN((short)7, "token");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -125,21 +95,21 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -148,7 +118,7 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -157,9 +127,9 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
private static final int __PERSISTEDTIME_ISSET_ID = 0;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.DESCRIPTION,_Fields.PERSISTED_TIME,_Fields.TOKEN};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.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.PORTAL_USER_NAME, new org.apache.thrift.meta_data.FieldMetaData("portalUserName", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -174,7 +144,7 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
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);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(PasswordCredential.class, metaDataMap);
}
@@ -182,10 +152,10 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
}
public PasswordCredential(
- String gatewayId,
- String portalUserName,
- String loginUserName,
- String password)
+ java.lang.String gatewayId,
+ java.lang.String portalUserName,
+ java.lang.String loginUserName,
+ java.lang.String password)
{
this();
this.gatewayId = gatewayId;
@@ -236,11 +206,11 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
this.token = null;
}
- public String getGatewayId() {
+ public java.lang.String getGatewayId() {
return this.gatewayId;
}
- public void setGatewayId(String gatewayId) {
+ public void setGatewayId(java.lang.String gatewayId) {
this.gatewayId = gatewayId;
}
@@ -259,11 +229,11 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
}
}
- public String getPortalUserName() {
+ public java.lang.String getPortalUserName() {
return this.portalUserName;
}
- public void setPortalUserName(String portalUserName) {
+ public void setPortalUserName(java.lang.String portalUserName) {
this.portalUserName = portalUserName;
}
@@ -282,11 +252,11 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
}
}
- public String getLoginUserName() {
+ public java.lang.String getLoginUserName() {
return this.loginUserName;
}
- public void setLoginUserName(String loginUserName) {
+ public void setLoginUserName(java.lang.String loginUserName) {
this.loginUserName = loginUserName;
}
@@ -305,11 +275,11 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
}
}
- public String getPassword() {
+ public java.lang.String getPassword() {
return this.password;
}
- public void setPassword(String password) {
+ public void setPassword(java.lang.String password) {
this.password = password;
}
@@ -328,11 +298,11 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
}
}
- public String getDescription() {
+ public java.lang.String getDescription() {
return this.description;
}
- public void setDescription(String description) {
+ public void setDescription(java.lang.String description) {
this.description = description;
}
@@ -361,23 +331,23 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
}
public void unsetPersistedTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.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);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID);
}
public void setPersistedTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID, value);
}
- public String getToken() {
+ public java.lang.String getToken() {
return this.token;
}
- public void setToken(String token) {
+ public void setToken(java.lang.String token) {
this.token = token;
}
@@ -396,13 +366,13 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case GATEWAY_ID:
if (value == null) {
unsetGatewayId();
} else {
- setGatewayId((String)value);
+ setGatewayId((java.lang.String)value);
}
break;
@@ -410,7 +380,7 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
if (value == null) {
unsetPortalUserName();
} else {
- setPortalUserName((String)value);
+ setPortalUserName((java.lang.String)value);
}
break;
@@ -418,7 +388,7 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
if (value == null) {
unsetLoginUserName();
} else {
- setLoginUserName((String)value);
+ setLoginUserName((java.lang.String)value);
}
break;
@@ -426,7 +396,7 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
if (value == null) {
unsetPassword();
} else {
- setPassword((String)value);
+ setPassword((java.lang.String)value);
}
break;
@@ -434,7 +404,7 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
if (value == null) {
unsetDescription();
} else {
- setDescription((String)value);
+ setDescription((java.lang.String)value);
}
break;
@@ -442,7 +412,7 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
if (value == null) {
unsetPersistedTime();
} else {
- setPersistedTime((Long)value);
+ setPersistedTime((java.lang.Long)value);
}
break;
@@ -450,14 +420,14 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
if (value == null) {
unsetToken();
} else {
- setToken((String)value);
+ setToken((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case GATEWAY_ID:
return getGatewayId();
@@ -481,13 +451,13 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
return getToken();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -506,11 +476,11 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
case TOKEN:
return isSetToken();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof PasswordCredential)
@@ -521,6 +491,8 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
public boolean equals(PasswordCredential that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_gatewayId = true && this.isSetGatewayId();
boolean that_present_gatewayId = true && that.isSetGatewayId();
@@ -590,44 +562,37 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_gatewayId = true && (isSetGatewayId());
- list.add(present_gatewayId);
- if (present_gatewayId)
- list.add(gatewayId);
-
- boolean present_portalUserName = true && (isSetPortalUserName());
- list.add(present_portalUserName);
- if (present_portalUserName)
- list.add(portalUserName);
-
- boolean present_loginUserName = true && (isSetLoginUserName());
- list.add(present_loginUserName);
- if (present_loginUserName)
- list.add(loginUserName);
-
- boolean present_password = true && (isSetPassword());
- list.add(present_password);
- if (present_password)
- list.add(password);
-
- boolean present_description = true && (isSetDescription());
- list.add(present_description);
- if (present_description)
- list.add(description);
-
- boolean present_persistedTime = true && (isSetPersistedTime());
- list.add(present_persistedTime);
- if (present_persistedTime)
- list.add(persistedTime);
-
- boolean present_token = true && (isSetToken());
- list.add(present_token);
- if (present_token)
- list.add(token);
-
- return list.hashCode();
+ int hashCode = 1;
+
+ hashCode = hashCode * 8191 + ((isSetGatewayId()) ? 131071 : 524287);
+ if (isSetGatewayId())
+ hashCode = hashCode * 8191 + gatewayId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetPortalUserName()) ? 131071 : 524287);
+ if (isSetPortalUserName())
+ hashCode = hashCode * 8191 + portalUserName.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetLoginUserName()) ? 131071 : 524287);
+ if (isSetLoginUserName())
+ hashCode = hashCode * 8191 + loginUserName.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetPassword()) ? 131071 : 524287);
+ if (isSetPassword())
+ hashCode = hashCode * 8191 + password.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetDescription()) ? 131071 : 524287);
+ if (isSetDescription())
+ hashCode = hashCode * 8191 + description.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetPersistedTime()) ? 131071 : 524287);
+ if (isSetPersistedTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(persistedTime);
+
+ hashCode = hashCode * 8191 + ((isSetToken()) ? 131071 : 524287);
+ if (isSetToken())
+ hashCode = hashCode * 8191 + token.hashCode();
+
+ return hashCode;
}
@Override
@@ -638,7 +603,7 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(other.isSetGatewayId());
+ lastComparison = java.lang.Boolean.valueOf(isSetGatewayId()).compareTo(other.isSetGatewayId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -648,7 +613,7 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPortalUserName()).compareTo(other.isSetPortalUserName());
+ lastComparison = java.lang.Boolean.valueOf(isSetPortalUserName()).compareTo(other.isSetPortalUserName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -658,7 +623,7 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetLoginUserName()).compareTo(other.isSetLoginUserName());
+ lastComparison = java.lang.Boolean.valueOf(isSetLoginUserName()).compareTo(other.isSetLoginUserName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -668,7 +633,7 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPassword()).compareTo(other.isSetPassword());
+ lastComparison = java.lang.Boolean.valueOf(isSetPassword()).compareTo(other.isSetPassword());
if (lastComparison != 0) {
return lastComparison;
}
@@ -678,7 +643,7 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -688,7 +653,7 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPersistedTime()).compareTo(other.isSetPersistedTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetPersistedTime()).compareTo(other.isSetPersistedTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -698,7 +663,7 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetToken()).compareTo(other.isSetToken());
+ lastComparison = java.lang.Boolean.valueOf(isSetToken()).compareTo(other.isSetToken());
if (lastComparison != 0) {
return lastComparison;
}
@@ -716,16 +681,16 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("PasswordCredential(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("PasswordCredential(");
boolean first = true;
sb.append("gatewayId:");
@@ -818,7 +783,7 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -828,13 +793,13 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
}
}
- private static class PasswordCredentialStandardSchemeFactory implements SchemeFactory {
+ private static class PasswordCredentialStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public PasswordCredentialStandardScheme getScheme() {
return new PasswordCredentialStandardScheme();
}
}
- private static class PasswordCredentialStandardScheme extends StandardScheme<PasswordCredential> {
+ private static class PasswordCredentialStandardScheme extends org.apache.thrift.scheme.StandardScheme<PasswordCredential> {
public void read(org.apache.thrift.protocol.TProtocol iprot, PasswordCredential struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -960,22 +925,22 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
}
- private static class PasswordCredentialTupleSchemeFactory implements SchemeFactory {
+ private static class PasswordCredentialTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public PasswordCredentialTupleScheme getScheme() {
return new PasswordCredentialTupleScheme();
}
}
- private static class PasswordCredentialTupleScheme extends TupleScheme<PasswordCredential> {
+ private static class PasswordCredentialTupleScheme extends org.apache.thrift.scheme.TupleScheme<PasswordCredential> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, PasswordCredential struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.gatewayId);
oprot.writeString(struct.portalUserName);
oprot.writeString(struct.loginUserName);
oprot.writeString(struct.password);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetDescription()) {
optionals.set(0);
}
@@ -999,7 +964,7 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, PasswordCredential struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.gatewayId = iprot.readString();
struct.setGatewayIdIsSet(true);
struct.portalUserName = iprot.readString();
@@ -1008,7 +973,7 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
struct.setLoginUserNameIsSet(true);
struct.password = iprot.readString();
struct.setPasswordIsSet(true);
- BitSet incoming = iprot.readBitSet(3);
+ java.util.BitSet incoming = iprot.readBitSet(3);
if (incoming.get(0)) {
struct.description = iprot.readString();
struct.setDescriptionIsSet(true);
@@ -1024,5 +989,8 @@ public class PasswordCredential implements org.apache.thrift.TBase<PasswordCrede
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/SSHCredential.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/SSHCredential.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/SSHCredential.java
index 670fc7e..9fa86d3 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/SSHCredential.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/SSHCredential.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.credential.store;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
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");
@@ -65,20 +38,17 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
private static final org.apache.thrift.protocol.TField DESCRIPTION_FIELD_DESC = new org.apache.thrift.protocol.TField("description", org.apache.thrift.protocol.TType.STRING, (short)8);
private static final org.apache.thrift.protocol.TField CREDENTIAL_OWNER_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("credentialOwnerType", org.apache.thrift.protocol.TType.I32, (short)9);
- 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());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new SSHCredentialStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new SSHCredentialTupleSchemeFactory();
- private String gatewayId; // required
- private String username; // required
- private String passphrase; // optional
- private String publicKey; // optional
- private String privateKey; // optional
+ private java.lang.String gatewayId; // required
+ private java.lang.String username; // required
+ private java.lang.String passphrase; // optional
+ private java.lang.String publicKey; // optional
+ private java.lang.String privateKey; // optional
private long persistedTime; // optional
- private String token; // optional
- private String description; // optional
+ private java.lang.String token; // optional
+ private java.lang.String description; // optional
private CredentialOwnerType credentialOwnerType; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
@@ -97,10 +67,10 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
*/
CREDENTIAL_OWNER_TYPE((short)9, "credentialOwnerType");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -139,21 +109,21 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -162,7 +132,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -171,9 +141,9 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
private static final int __PERSISTEDTIME_ISSET_ID = 0;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.PASSPHRASE,_Fields.PUBLIC_KEY,_Fields.PRIVATE_KEY,_Fields.PERSISTED_TIME,_Fields.TOKEN,_Fields.DESCRIPTION,_Fields.CREDENTIAL_OWNER_TYPE};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.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,
@@ -192,7 +162,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.CREDENTIAL_OWNER_TYPE, new org.apache.thrift.meta_data.FieldMetaData("credentialOwnerType", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, CredentialOwnerType.class)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(SSHCredential.class, metaDataMap);
}
@@ -202,8 +172,8 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
}
public SSHCredential(
- String gatewayId,
- String username)
+ java.lang.String gatewayId,
+ java.lang.String username)
{
this();
this.gatewayId = gatewayId;
@@ -261,11 +231,11 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
}
- public String getGatewayId() {
+ public java.lang.String getGatewayId() {
return this.gatewayId;
}
- public void setGatewayId(String gatewayId) {
+ public void setGatewayId(java.lang.String gatewayId) {
this.gatewayId = gatewayId;
}
@@ -284,11 +254,11 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
}
}
- public String getUsername() {
+ public java.lang.String getUsername() {
return this.username;
}
- public void setUsername(String username) {
+ public void setUsername(java.lang.String username) {
this.username = username;
}
@@ -307,11 +277,11 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
}
}
- public String getPassphrase() {
+ public java.lang.String getPassphrase() {
return this.passphrase;
}
- public void setPassphrase(String passphrase) {
+ public void setPassphrase(java.lang.String passphrase) {
this.passphrase = passphrase;
}
@@ -330,11 +300,11 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
}
}
- public String getPublicKey() {
+ public java.lang.String getPublicKey() {
return this.publicKey;
}
- public void setPublicKey(String publicKey) {
+ public void setPublicKey(java.lang.String publicKey) {
this.publicKey = publicKey;
}
@@ -353,11 +323,11 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
}
}
- public String getPrivateKey() {
+ public java.lang.String getPrivateKey() {
return this.privateKey;
}
- public void setPrivateKey(String privateKey) {
+ public void setPrivateKey(java.lang.String privateKey) {
this.privateKey = privateKey;
}
@@ -386,23 +356,23 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
}
public void unsetPersistedTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.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);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID);
}
public void setPersistedTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __PERSISTEDTIME_ISSET_ID, value);
}
- public String getToken() {
+ public java.lang.String getToken() {
return this.token;
}
- public void setToken(String token) {
+ public void setToken(java.lang.String token) {
this.token = token;
}
@@ -421,11 +391,11 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
}
}
- public String getDescription() {
+ public java.lang.String getDescription() {
return this.description;
}
- public void setDescription(String description) {
+ public void setDescription(java.lang.String description) {
this.description = description;
}
@@ -475,13 +445,13 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case GATEWAY_ID:
if (value == null) {
unsetGatewayId();
} else {
- setGatewayId((String)value);
+ setGatewayId((java.lang.String)value);
}
break;
@@ -489,7 +459,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
if (value == null) {
unsetUsername();
} else {
- setUsername((String)value);
+ setUsername((java.lang.String)value);
}
break;
@@ -497,7 +467,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
if (value == null) {
unsetPassphrase();
} else {
- setPassphrase((String)value);
+ setPassphrase((java.lang.String)value);
}
break;
@@ -505,7 +475,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
if (value == null) {
unsetPublicKey();
} else {
- setPublicKey((String)value);
+ setPublicKey((java.lang.String)value);
}
break;
@@ -513,7 +483,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
if (value == null) {
unsetPrivateKey();
} else {
- setPrivateKey((String)value);
+ setPrivateKey((java.lang.String)value);
}
break;
@@ -521,7 +491,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
if (value == null) {
unsetPersistedTime();
} else {
- setPersistedTime((Long)value);
+ setPersistedTime((java.lang.Long)value);
}
break;
@@ -529,7 +499,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
if (value == null) {
unsetToken();
} else {
- setToken((String)value);
+ setToken((java.lang.String)value);
}
break;
@@ -537,7 +507,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
if (value == null) {
unsetDescription();
} else {
- setDescription((String)value);
+ setDescription((java.lang.String)value);
}
break;
@@ -552,7 +522,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case GATEWAY_ID:
return getGatewayId();
@@ -582,13 +552,13 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
return getCredentialOwnerType();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -611,11 +581,11 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
case CREDENTIAL_OWNER_TYPE:
return isSetCredentialOwnerType();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof SSHCredential)
@@ -626,6 +596,8 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
public boolean equals(SSHCredential that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_gatewayId = true && this.isSetGatewayId();
boolean that_present_gatewayId = true && that.isSetGatewayId();
@@ -713,54 +685,45 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_gatewayId = true && (isSetGatewayId());
- list.add(present_gatewayId);
- if (present_gatewayId)
- list.add(gatewayId);
+ hashCode = hashCode * 8191 + ((isSetGatewayId()) ? 131071 : 524287);
+ if (isSetGatewayId())
+ hashCode = hashCode * 8191 + gatewayId.hashCode();
- boolean present_username = true && (isSetUsername());
- list.add(present_username);
- if (present_username)
- list.add(username);
+ hashCode = hashCode * 8191 + ((isSetUsername()) ? 131071 : 524287);
+ if (isSetUsername())
+ hashCode = hashCode * 8191 + username.hashCode();
- boolean present_passphrase = true && (isSetPassphrase());
- list.add(present_passphrase);
- if (present_passphrase)
- list.add(passphrase);
+ hashCode = hashCode * 8191 + ((isSetPassphrase()) ? 131071 : 524287);
+ if (isSetPassphrase())
+ hashCode = hashCode * 8191 + passphrase.hashCode();
- boolean present_publicKey = true && (isSetPublicKey());
- list.add(present_publicKey);
- if (present_publicKey)
- list.add(publicKey);
+ hashCode = hashCode * 8191 + ((isSetPublicKey()) ? 131071 : 524287);
+ if (isSetPublicKey())
+ hashCode = hashCode * 8191 + publicKey.hashCode();
- boolean present_privateKey = true && (isSetPrivateKey());
- list.add(present_privateKey);
- if (present_privateKey)
- list.add(privateKey);
+ hashCode = hashCode * 8191 + ((isSetPrivateKey()) ? 131071 : 524287);
+ if (isSetPrivateKey())
+ hashCode = hashCode * 8191 + privateKey.hashCode();
- boolean present_persistedTime = true && (isSetPersistedTime());
- list.add(present_persistedTime);
- if (present_persistedTime)
- list.add(persistedTime);
+ hashCode = hashCode * 8191 + ((isSetPersistedTime()) ? 131071 : 524287);
+ if (isSetPersistedTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(persistedTime);
- boolean present_token = true && (isSetToken());
- list.add(present_token);
- if (present_token)
- list.add(token);
+ hashCode = hashCode * 8191 + ((isSetToken()) ? 131071 : 524287);
+ if (isSetToken())
+ hashCode = hashCode * 8191 + token.hashCode();
- boolean present_description = true && (isSetDescription());
- list.add(present_description);
- if (present_description)
- list.add(description);
+ hashCode = hashCode * 8191 + ((isSetDescription()) ? 131071 : 524287);
+ if (isSetDescription())
+ hashCode = hashCode * 8191 + description.hashCode();
- boolean present_credentialOwnerType = true && (isSetCredentialOwnerType());
- list.add(present_credentialOwnerType);
- if (present_credentialOwnerType)
- list.add(credentialOwnerType.getValue());
+ hashCode = hashCode * 8191 + ((isSetCredentialOwnerType()) ? 131071 : 524287);
+ if (isSetCredentialOwnerType())
+ hashCode = hashCode * 8191 + credentialOwnerType.getValue();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -771,7 +734,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(other.isSetGatewayId());
+ lastComparison = java.lang.Boolean.valueOf(isSetGatewayId()).compareTo(other.isSetGatewayId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -781,7 +744,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUsername()).compareTo(other.isSetUsername());
+ lastComparison = java.lang.Boolean.valueOf(isSetUsername()).compareTo(other.isSetUsername());
if (lastComparison != 0) {
return lastComparison;
}
@@ -791,7 +754,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPassphrase()).compareTo(other.isSetPassphrase());
+ lastComparison = java.lang.Boolean.valueOf(isSetPassphrase()).compareTo(other.isSetPassphrase());
if (lastComparison != 0) {
return lastComparison;
}
@@ -801,7 +764,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPublicKey()).compareTo(other.isSetPublicKey());
+ lastComparison = java.lang.Boolean.valueOf(isSetPublicKey()).compareTo(other.isSetPublicKey());
if (lastComparison != 0) {
return lastComparison;
}
@@ -811,7 +774,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPrivateKey()).compareTo(other.isSetPrivateKey());
+ lastComparison = java.lang.Boolean.valueOf(isSetPrivateKey()).compareTo(other.isSetPrivateKey());
if (lastComparison != 0) {
return lastComparison;
}
@@ -821,7 +784,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPersistedTime()).compareTo(other.isSetPersistedTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetPersistedTime()).compareTo(other.isSetPersistedTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -831,7 +794,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetToken()).compareTo(other.isSetToken());
+ lastComparison = java.lang.Boolean.valueOf(isSetToken()).compareTo(other.isSetToken());
if (lastComparison != 0) {
return lastComparison;
}
@@ -841,7 +804,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -851,7 +814,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCredentialOwnerType()).compareTo(other.isSetCredentialOwnerType());
+ lastComparison = java.lang.Boolean.valueOf(isSetCredentialOwnerType()).compareTo(other.isSetCredentialOwnerType());
if (lastComparison != 0) {
return lastComparison;
}
@@ -869,16 +832,16 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("SSHCredential(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("SSHCredential(");
boolean first = true;
sb.append("gatewayId:");
@@ -987,7 +950,7 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -997,13 +960,13 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
}
}
- private static class SSHCredentialStandardSchemeFactory implements SchemeFactory {
+ private static class SSHCredentialStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public SSHCredentialStandardScheme getScheme() {
return new SSHCredentialStandardScheme();
}
}
- private static class SSHCredentialStandardScheme extends StandardScheme<SSHCredential> {
+ private static class SSHCredentialStandardScheme extends org.apache.thrift.scheme.StandardScheme<SSHCredential> {
public void read(org.apache.thrift.protocol.TProtocol iprot, SSHCredential struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1163,20 +1126,20 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
}
- private static class SSHCredentialTupleSchemeFactory implements SchemeFactory {
+ private static class SSHCredentialTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public SSHCredentialTupleScheme getScheme() {
return new SSHCredentialTupleScheme();
}
}
- private static class SSHCredentialTupleScheme extends TupleScheme<SSHCredential> {
+ private static class SSHCredentialTupleScheme extends org.apache.thrift.scheme.TupleScheme<SSHCredential> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, SSHCredential struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.gatewayId);
oprot.writeString(struct.username);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetPassphrase()) {
optionals.set(0);
}
@@ -1224,12 +1187,12 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, SSHCredential struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.gatewayId = iprot.readString();
struct.setGatewayIdIsSet(true);
struct.username = iprot.readString();
struct.setUsernameIsSet(true);
- BitSet incoming = iprot.readBitSet(7);
+ java.util.BitSet incoming = iprot.readBitSet(7);
if (incoming.get(0)) {
struct.passphrase = iprot.readString();
struct.setPassphraseIsSet(true);
@@ -1261,5 +1224,8 @@ public class SSHCredential implements org.apache.thrift.TBase<SSHCredential, SSH
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/SummaryType.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/SummaryType.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/SummaryType.java
index 7451f89..240dec7 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/SummaryType.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/SummaryType.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/credential_store_data_modelsConstants.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/credential_store_data_modelsConstants.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/credential_store_data_modelsConstants.java
index d4b1dd0..73ad1fb 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/credential_store_data_modelsConstants.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/credential/store/credential_store_data_modelsConstants.java
@@ -16,43 +16,16 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.credential.store;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
public class credential_store_data_modelsConstants {
- public static final String DEFAULT_ID = "DO_NOT_SET_AT_CLIENTS";
+ public static final java.lang.String DEFAULT_ID = "DO_NOT_SET_AT_CLIENTS";
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/DMType.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/DMType.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/DMType.java
index 5ff84bd..1dc9d36 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/DMType.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/DMType.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/DataMovementInterface.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/DataMovementInterface.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/DataMovementInterface.java
index b9678e0..3c50586 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/DataMovementInterface.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/DataMovementInterface.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.data.movement;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Data Movement Interfaces
*
@@ -61,7 +34,7 @@ import org.slf4j.LoggerFactory;
* Lower the numerical number, higher the priority
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class DataMovementInterface implements org.apache.thrift.TBase<DataMovementInterface, DataMovementInterface._Fields>, java.io.Serializable, Cloneable, Comparable<DataMovementInterface> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("DataMovementInterface");
@@ -69,13 +42,10 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
private static final org.apache.thrift.protocol.TField DATA_MOVEMENT_PROTOCOL_FIELD_DESC = new org.apache.thrift.protocol.TField("dataMovementProtocol", org.apache.thrift.protocol.TType.I32, (short)2);
private static final org.apache.thrift.protocol.TField PRIORITY_ORDER_FIELD_DESC = new org.apache.thrift.protocol.TField("priorityOrder", org.apache.thrift.protocol.TType.I32, (short)3);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new DataMovementInterfaceStandardSchemeFactory());
- schemes.put(TupleScheme.class, new DataMovementInterfaceTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new DataMovementInterfaceStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new DataMovementInterfaceTupleSchemeFactory();
- private String dataMovementInterfaceId; // required
+ private java.lang.String dataMovementInterfaceId; // required
private DataMovementProtocol dataMovementProtocol; // required
private int priorityOrder; // required
@@ -89,10 +59,10 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
DATA_MOVEMENT_PROTOCOL((short)2, "dataMovementProtocol"),
PRIORITY_ORDER((short)3, "priorityOrder");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -119,21 +89,21 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -142,7 +112,7 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -150,16 +120,16 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
// isset id assignments
private static final int __PRIORITYORDER_ISSET_ID = 0;
private byte __isset_bitfield = 0;
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.DATA_MOVEMENT_INTERFACE_ID, new org.apache.thrift.meta_data.FieldMetaData("dataMovementInterfaceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.DATA_MOVEMENT_PROTOCOL, new org.apache.thrift.meta_data.FieldMetaData("dataMovementProtocol", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, DataMovementProtocol.class)));
tmpMap.put(_Fields.PRIORITY_ORDER, new org.apache.thrift.meta_data.FieldMetaData("priorityOrder", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(DataMovementInterface.class, metaDataMap);
}
@@ -169,7 +139,7 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
}
public DataMovementInterface(
- String dataMovementInterfaceId,
+ java.lang.String dataMovementInterfaceId,
DataMovementProtocol dataMovementProtocol,
int priorityOrder)
{
@@ -206,11 +176,11 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
}
- public String getDataMovementInterfaceId() {
+ public java.lang.String getDataMovementInterfaceId() {
return this.dataMovementInterfaceId;
}
- public void setDataMovementInterfaceId(String dataMovementInterfaceId) {
+ public void setDataMovementInterfaceId(java.lang.String dataMovementInterfaceId) {
this.dataMovementInterfaceId = dataMovementInterfaceId;
}
@@ -270,25 +240,25 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
}
public void unsetPriorityOrder() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PRIORITYORDER_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __PRIORITYORDER_ISSET_ID);
}
/** Returns true if field priorityOrder is set (has been assigned a value) and false otherwise */
public boolean isSetPriorityOrder() {
- return EncodingUtils.testBit(__isset_bitfield, __PRIORITYORDER_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __PRIORITYORDER_ISSET_ID);
}
public void setPriorityOrderIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PRIORITYORDER_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __PRIORITYORDER_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case DATA_MOVEMENT_INTERFACE_ID:
if (value == null) {
unsetDataMovementInterfaceId();
} else {
- setDataMovementInterfaceId((String)value);
+ setDataMovementInterfaceId((java.lang.String)value);
}
break;
@@ -304,14 +274,14 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
if (value == null) {
unsetPriorityOrder();
} else {
- setPriorityOrder((Integer)value);
+ setPriorityOrder((java.lang.Integer)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case DATA_MOVEMENT_INTERFACE_ID:
return getDataMovementInterfaceId();
@@ -323,13 +293,13 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
return getPriorityOrder();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -340,11 +310,11 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
case PRIORITY_ORDER:
return isSetPriorityOrder();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof DataMovementInterface)
@@ -355,6 +325,8 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
public boolean equals(DataMovementInterface that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_dataMovementInterfaceId = true && this.isSetDataMovementInterfaceId();
boolean that_present_dataMovementInterfaceId = true && that.isSetDataMovementInterfaceId();
@@ -388,24 +360,19 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_dataMovementInterfaceId = true && (isSetDataMovementInterfaceId());
- list.add(present_dataMovementInterfaceId);
- if (present_dataMovementInterfaceId)
- list.add(dataMovementInterfaceId);
+ hashCode = hashCode * 8191 + ((isSetDataMovementInterfaceId()) ? 131071 : 524287);
+ if (isSetDataMovementInterfaceId())
+ hashCode = hashCode * 8191 + dataMovementInterfaceId.hashCode();
- boolean present_dataMovementProtocol = true && (isSetDataMovementProtocol());
- list.add(present_dataMovementProtocol);
- if (present_dataMovementProtocol)
- list.add(dataMovementProtocol.getValue());
+ hashCode = hashCode * 8191 + ((isSetDataMovementProtocol()) ? 131071 : 524287);
+ if (isSetDataMovementProtocol())
+ hashCode = hashCode * 8191 + dataMovementProtocol.getValue();
- boolean present_priorityOrder = true;
- list.add(present_priorityOrder);
- if (present_priorityOrder)
- list.add(priorityOrder);
+ hashCode = hashCode * 8191 + priorityOrder;
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -416,7 +383,7 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetDataMovementInterfaceId()).compareTo(other.isSetDataMovementInterfaceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetDataMovementInterfaceId()).compareTo(other.isSetDataMovementInterfaceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -426,7 +393,7 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDataMovementProtocol()).compareTo(other.isSetDataMovementProtocol());
+ lastComparison = java.lang.Boolean.valueOf(isSetDataMovementProtocol()).compareTo(other.isSetDataMovementProtocol());
if (lastComparison != 0) {
return lastComparison;
}
@@ -436,7 +403,7 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPriorityOrder()).compareTo(other.isSetPriorityOrder());
+ lastComparison = java.lang.Boolean.valueOf(isSetPriorityOrder()).compareTo(other.isSetPriorityOrder());
if (lastComparison != 0) {
return lastComparison;
}
@@ -454,16 +421,16 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("DataMovementInterface(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("DataMovementInterface(");
boolean first = true;
sb.append("dataMovementInterfaceId:");
@@ -514,7 +481,7 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -524,13 +491,13 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
}
}
- private static class DataMovementInterfaceStandardSchemeFactory implements SchemeFactory {
+ private static class DataMovementInterfaceStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public DataMovementInterfaceStandardScheme getScheme() {
return new DataMovementInterfaceStandardScheme();
}
}
- private static class DataMovementInterfaceStandardScheme extends StandardScheme<DataMovementInterface> {
+ private static class DataMovementInterfaceStandardScheme extends org.apache.thrift.scheme.StandardScheme<DataMovementInterface> {
public void read(org.apache.thrift.protocol.TProtocol iprot, DataMovementInterface struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -598,17 +565,17 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
}
- private static class DataMovementInterfaceTupleSchemeFactory implements SchemeFactory {
+ private static class DataMovementInterfaceTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public DataMovementInterfaceTupleScheme getScheme() {
return new DataMovementInterfaceTupleScheme();
}
}
- private static class DataMovementInterfaceTupleScheme extends TupleScheme<DataMovementInterface> {
+ private static class DataMovementInterfaceTupleScheme extends org.apache.thrift.scheme.TupleScheme<DataMovementInterface> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, DataMovementInterface struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.dataMovementInterfaceId);
oprot.writeI32(struct.dataMovementProtocol.getValue());
oprot.writeI32(struct.priorityOrder);
@@ -616,7 +583,7 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, DataMovementInterface struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.dataMovementInterfaceId = iprot.readString();
struct.setDataMovementInterfaceIdIsSet(true);
struct.dataMovementProtocol = org.apache.airavata.model.data.movement.DataMovementProtocol.findByValue(iprot.readI32());
@@ -626,5 +593,8 @@ public class DataMovementInterface implements org.apache.thrift.TBase<DataMoveme
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/DataMovementProtocol.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/DataMovementProtocol.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/DataMovementProtocol.java
index 627b91b..127b4fa 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/DataMovementProtocol.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/movement/DataMovementProtocol.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
[29/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/user/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/user/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/user/ttypes.py
index 14b8baa..cf4f080 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/user/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/user/ttypes.py
@@ -1,817 +1,777 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.commons.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class Status:
- ACTIVE = 0
- CONFIRMED = 1
- APPROVED = 2
- DELETED = 3
- DUPLICATE = 4
- GRACE_PERIOD = 5
- INVITED = 6
- DENIED = 7
- PENDING = 8
- PENDING_APPROVAL = 9
- PENDING_CONFIRMATION = 10
- SUSPENDED = 11
- DECLINED = 12
- EXPIRED = 13
-
- _VALUES_TO_NAMES = {
- 0: "ACTIVE",
- 1: "CONFIRMED",
- 2: "APPROVED",
- 3: "DELETED",
- 4: "DUPLICATE",
- 5: "GRACE_PERIOD",
- 6: "INVITED",
- 7: "DENIED",
- 8: "PENDING",
- 9: "PENDING_APPROVAL",
- 10: "PENDING_CONFIRMATION",
- 11: "SUSPENDED",
- 12: "DECLINED",
- 13: "EXPIRED",
- }
-
- _NAMES_TO_VALUES = {
- "ACTIVE": 0,
- "CONFIRMED": 1,
- "APPROVED": 2,
- "DELETED": 3,
- "DUPLICATE": 4,
- "GRACE_PERIOD": 5,
- "INVITED": 6,
- "DENIED": 7,
- "PENDING": 8,
- "PENDING_APPROVAL": 9,
- "PENDING_CONFIRMATION": 10,
- "SUSPENDED": 11,
- "DECLINED": 12,
- "EXPIRED": 13,
- }
-
-class USCitizenship:
- """
- U.S. Citizen (see: http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)
-
- """
- US_CITIZEN = 0
- US_PERMANENT_RESIDENT = 1
- OTHER_NON_US_CITIZEN = 2
-
- _VALUES_TO_NAMES = {
- 0: "US_CITIZEN",
- 1: "US_PERMANENT_RESIDENT",
- 2: "OTHER_NON_US_CITIZEN",
- }
-
- _NAMES_TO_VALUES = {
- "US_CITIZEN": 0,
- "US_PERMANENT_RESIDENT": 1,
- "OTHER_NON_US_CITIZEN": 2,
- }
-
-class ethnicity:
- """
- Hispanic or Latino - a person of Mexican, Puerto Rican, Cuban, South or
- Central American, or other Spanish culture or origin, regardless of race.
-
- """
- HISPANIC_LATINO = 0
- NOT_HISPANIC_LATINO = 1
-
- _VALUES_TO_NAMES = {
- 0: "HISPANIC_LATINO",
- 1: "NOT_HISPANIC_LATINO",
- }
-
- _NAMES_TO_VALUES = {
- "HISPANIC_LATINO": 0,
- "NOT_HISPANIC_LATINO": 1,
- }
-
-class race:
- """
- * Asian - a person having origins in any of the original peoples of the Far East,
- * Southeast Asia, or the Indian subcontinent including, for example, Cambodia,
- * China, India, Japan, Korea, Malaysia, Pakistan, the Philippine Islands,
- * Thailand, and Vietnam.
- * American Indian or Alaskan Native - a person having origins in any of the original
- * peoples of North and South America (including Central America), and who maintains
- * tribal affiliation or community attachment.
- * Black or African American - a person having origins in any of the black racial groups
- * of Africa.
- * Native Hawaiian or Pacific Islander - a person having origins in any of the original
- * peoples of Hawaii, Guan, Samoa, or other Pacific Islands.
- * White - a person having origins in any of the original peoples of Europe, the Middle East, or North Africa.
- *
- """
- ASIAN = 0
- AMERICAN_INDIAN_OR_ALASKAN_NATIVE = 1
- BLACK_OR_AFRICAN_AMERICAN = 2
- NATIVE_HAWAIIAN_OR_PACIFIC_ISLANDER = 3
- WHITE = 4
-
- _VALUES_TO_NAMES = {
- 0: "ASIAN",
- 1: "AMERICAN_INDIAN_OR_ALASKAN_NATIVE",
- 2: "BLACK_OR_AFRICAN_AMERICAN",
- 3: "NATIVE_HAWAIIAN_OR_PACIFIC_ISLANDER",
- 4: "WHITE",
- }
-
- _NAMES_TO_VALUES = {
- "ASIAN": 0,
- "AMERICAN_INDIAN_OR_ALASKAN_NATIVE": 1,
- "BLACK_OR_AFRICAN_AMERICAN": 2,
- "NATIVE_HAWAIIAN_OR_PACIFIC_ISLANDER": 3,
- "WHITE": 4,
- }
-
-class disability:
- HEARING_IMAPAIRED = 0
- VISUAL_IMPAIRED = 1
- MOBILITY_OR_ORTHOPEDIC_IMPAIRMENT = 2
- OTHER_IMPAIRMENT = 3
-
- _VALUES_TO_NAMES = {
- 0: "HEARING_IMAPAIRED",
- 1: "VISUAL_IMPAIRED",
- 2: "MOBILITY_OR_ORTHOPEDIC_IMPAIRMENT",
- 3: "OTHER_IMPAIRMENT",
- }
-
- _NAMES_TO_VALUES = {
- "HEARING_IMAPAIRED": 0,
- "VISUAL_IMPAIRED": 1,
- "MOBILITY_OR_ORTHOPEDIC_IMPAIRMENT": 2,
- "OTHER_IMPAIRMENT": 3,
- }
-
-
-class NSFDemographics:
- """
- A structure holding the NSF Demographic information.
-
-
-
- Attributes:
- - airavataInternalUserId
- - gender
- - usCitizenship
- - ethnicities
- - races
- - disabilities
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'airavataInternalUserId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.STRING, 'gender', None, None, ), # 2
- (3, TType.I32, 'usCitizenship', None, None, ), # 3
- (4, TType.LIST, 'ethnicities', (TType.I32,None), None, ), # 4
- (5, TType.LIST, 'races', (TType.I32,None), None, ), # 5
- (6, TType.LIST, 'disabilities', (TType.I32,None), None, ), # 6
- )
-
- def __init__(self, airavataInternalUserId=thrift_spec[1][4], gender=None, usCitizenship=None, ethnicities=None, races=None, disabilities=None,):
- self.airavataInternalUserId = airavataInternalUserId
- self.gender = gender
- self.usCitizenship = usCitizenship
- self.ethnicities = ethnicities
- self.races = races
- self.disabilities = disabilities
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.airavataInternalUserId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.gender = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.I32:
- self.usCitizenship = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.LIST:
- self.ethnicities = []
- (_etype3, _size0) = iprot.readListBegin()
- for _i4 in xrange(_size0):
- _elem5 = iprot.readI32()
- self.ethnicities.append(_elem5)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.LIST:
- self.races = []
- (_etype9, _size6) = iprot.readListBegin()
- for _i10 in xrange(_size6):
- _elem11 = iprot.readI32()
- self.races.append(_elem11)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.LIST:
- self.disabilities = []
- (_etype15, _size12) = iprot.readListBegin()
- for _i16 in xrange(_size12):
- _elem17 = iprot.readI32()
- self.disabilities.append(_elem17)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('NSFDemographics')
- if self.airavataInternalUserId is not None:
- oprot.writeFieldBegin('airavataInternalUserId', TType.STRING, 1)
- oprot.writeString(self.airavataInternalUserId)
- oprot.writeFieldEnd()
- if self.gender is not None:
- oprot.writeFieldBegin('gender', TType.STRING, 2)
- oprot.writeString(self.gender)
- oprot.writeFieldEnd()
- if self.usCitizenship is not None:
- oprot.writeFieldBegin('usCitizenship', TType.I32, 3)
- oprot.writeI32(self.usCitizenship)
- oprot.writeFieldEnd()
- if self.ethnicities is not None:
- oprot.writeFieldBegin('ethnicities', TType.LIST, 4)
- oprot.writeListBegin(TType.I32, len(self.ethnicities))
- for iter18 in self.ethnicities:
- oprot.writeI32(iter18)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.races is not None:
- oprot.writeFieldBegin('races', TType.LIST, 5)
- oprot.writeListBegin(TType.I32, len(self.races))
- for iter19 in self.races:
- oprot.writeI32(iter19)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.disabilities is not None:
- oprot.writeFieldBegin('disabilities', TType.LIST, 6)
- oprot.writeListBegin(TType.I32, len(self.disabilities))
- for iter20 in self.disabilities:
- oprot.writeI32(iter20)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.airavataInternalUserId is None:
- raise TProtocol.TProtocolException(message='Required field airavataInternalUserId is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.airavataInternalUserId)
- value = (value * 31) ^ hash(self.gender)
- value = (value * 31) ^ hash(self.usCitizenship)
- value = (value * 31) ^ hash(self.ethnicities)
- value = (value * 31) ^ hash(self.races)
- value = (value * 31) ^ hash(self.disabilities)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class UserProfile:
- """
- * A structure holding the user profile and its child models.
- *
- * Notes:
- * The model does not include passwords as it is assumed an external identity provider is used to authenticate user.
- * References:
- * NSF Demographic Information - http://www.nsf.gov/pubs/2000/00form1225/00form1225.doc
- * LDAP Schema - https://tools.ietf.org/html/rfc4519
- * SCIM 2.0 - https://tools.ietf.org/html/rfc7643
- *
- * userModelVersion:
- * Version number of profile
- *
- * airavataInternalUserId:
- * internal to Airavata, not intended to be used outside of the Airavata platform or possibly by gateways
- * (that is, never shown to users), never reassigned, REQUIRED
- *
- * userId:
- * Externally assertable unique identifier. SAML (primarly in higher education, academic) tends to keep
- * user name less opaque. OpenID Connect maintains them to be opaque.
- *
- * firstName, middleName, lastName:
- * First and Last names as assertede by the user
- *
- * namePrefix, nameSuffix:
- * prefix and suffix to the users name as asserted by the user
- *
- * emails:
- * Email identifier are Verified, REQUIRED and MULTIVALUED
- *
- * userName:
- * Name-based identifiers can be multivalues. To keep it simple, Airavata will make it a string.
- * In the future these can be enumerated as:
- * Official name (as asserted possibly by some external identity provider)
- * Prefered name (as asserted or suggested by user directly)
- * Components:
- * givenName
- * surname (familyName)
- * displayName (often asserted by user to handle things like middle names, suffix, prefix, and the like)
- *
- * orcidId: ORCID ID - http://orcid.org/about/what-is-orcid)
- *
- * phones: Telephone MULTIVALUED
- *
- * country: Country of Residance
- *
- * nationality Countries of citizenship
- *
- * comments:
- * Free-form information (treated as opaque by Airavata and simply passed to resource).
- *
- * labeledURI:
- * Google Scholar, Web of Science, ACS, e.t.c
- *
- * timeZone:
- * User’s preferred timezone - IANA Timezone Databases - http://www.iana.org/time-zones.
- *
-
- Attributes:
- - userModelVersion
- - airavataInternalUserId
- - userId
- - gatewayId
- - emails
- - firstName
- - lastName
- - middleName
- - namePrefix
- - nameSuffix
- - orcidId
- - phones
- - country
- - nationality
- - homeOrganization
- - orginationAffiliation
- - creationTime
- - lastAccessTime
- - validUntil
- - State
- - comments
- - labeledURI
- - gpgKey
- - timeZone
- - nsfDemographics
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'userModelVersion', None, "1.0", ), # 1
- (2, TType.STRING, 'airavataInternalUserId', None, "DO_NOT_SET_AT_CLIENTS", ), # 2
- (3, TType.STRING, 'userId', None, None, ), # 3
- (4, TType.STRING, 'gatewayId', None, None, ), # 4
- (5, TType.LIST, 'emails', (TType.STRING,None), None, ), # 5
- (6, TType.STRING, 'firstName', None, None, ), # 6
- (7, TType.STRING, 'lastName', None, None, ), # 7
- (8, TType.STRING, 'middleName', None, None, ), # 8
- (9, TType.STRING, 'namePrefix', None, None, ), # 9
- (10, TType.STRING, 'nameSuffix', None, None, ), # 10
- (11, TType.STRING, 'orcidId', None, None, ), # 11
- (12, TType.LIST, 'phones', (TType.STRING,None), None, ), # 12
- (13, TType.STRING, 'country', None, None, ), # 13
- (14, TType.LIST, 'nationality', (TType.STRING,None), None, ), # 14
- (15, TType.STRING, 'homeOrganization', None, None, ), # 15
- (16, TType.STRING, 'orginationAffiliation', None, None, ), # 16
- (17, TType.I64, 'creationTime', None, None, ), # 17
- (18, TType.I64, 'lastAccessTime', None, None, ), # 18
- (19, TType.I64, 'validUntil', None, None, ), # 19
- (20, TType.I32, 'State', None, None, ), # 20
- (21, TType.STRING, 'comments', None, None, ), # 21
- (22, TType.LIST, 'labeledURI', (TType.STRING,None), None, ), # 22
- (23, TType.STRING, 'gpgKey', None, None, ), # 23
- (24, TType.STRING, 'timeZone', None, None, ), # 24
- (25, TType.STRUCT, 'nsfDemographics', (NSFDemographics, NSFDemographics.thrift_spec), None, ), # 25
- )
-
- def __init__(self, userModelVersion=thrift_spec[1][4], airavataInternalUserId=thrift_spec[2][4], userId=None, gatewayId=None, emails=None, firstName=None, lastName=None, middleName=None, namePrefix=None, nameSuffix=None, orcidId=None, phones=None, country=None, nationality=None, homeOrganization=None, orginationAffiliation=None, creationTime=None, lastAccessTime=None, validUntil=None, State=None, comments=None, labeledURI=None, gpgKey=None, timeZone=None, nsfDemographics=None,):
- self.userModelVersion = userModelVersion
- self.airavataInternalUserId = airavataInternalUserId
- self.userId = userId
- self.gatewayId = gatewayId
- self.emails = emails
- self.firstName = firstName
- self.lastName = lastName
- self.middleName = middleName
- self.namePrefix = namePrefix
- self.nameSuffix = nameSuffix
- self.orcidId = orcidId
- self.phones = phones
- self.country = country
- self.nationality = nationality
- self.homeOrganization = homeOrganization
- self.orginationAffiliation = orginationAffiliation
- self.creationTime = creationTime
- self.lastAccessTime = lastAccessTime
- self.validUntil = validUntil
- self.State = State
- self.comments = comments
- self.labeledURI = labeledURI
- self.gpgKey = gpgKey
- self.timeZone = timeZone
- self.nsfDemographics = nsfDemographics
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.userModelVersion = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.airavataInternalUserId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.userId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.LIST:
- self.emails = []
- (_etype24, _size21) = iprot.readListBegin()
- for _i25 in xrange(_size21):
- _elem26 = iprot.readString()
- self.emails.append(_elem26)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.firstName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.STRING:
- self.lastName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.STRING:
- self.middleName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.STRING:
- self.namePrefix = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.STRING:
- self.nameSuffix = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 11:
- if ftype == TType.STRING:
- self.orcidId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 12:
- if ftype == TType.LIST:
- self.phones = []
- (_etype30, _size27) = iprot.readListBegin()
- for _i31 in xrange(_size27):
- _elem32 = iprot.readString()
- self.phones.append(_elem32)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 13:
- if ftype == TType.STRING:
- self.country = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 14:
- if ftype == TType.LIST:
- self.nationality = []
- (_etype36, _size33) = iprot.readListBegin()
- for _i37 in xrange(_size33):
- _elem38 = iprot.readString()
- self.nationality.append(_elem38)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 15:
- if ftype == TType.STRING:
- self.homeOrganization = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 16:
- if ftype == TType.STRING:
- self.orginationAffiliation = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 17:
- if ftype == TType.I64:
- self.creationTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 18:
- if ftype == TType.I64:
- self.lastAccessTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 19:
- if ftype == TType.I64:
- self.validUntil = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 20:
- if ftype == TType.I32:
- self.State = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 21:
- if ftype == TType.STRING:
- self.comments = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 22:
- if ftype == TType.LIST:
- self.labeledURI = []
- (_etype42, _size39) = iprot.readListBegin()
- for _i43 in xrange(_size39):
- _elem44 = iprot.readString()
- self.labeledURI.append(_elem44)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 23:
- if ftype == TType.STRING:
- self.gpgKey = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 24:
- if ftype == TType.STRING:
- self.timeZone = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 25:
- if ftype == TType.STRUCT:
- self.nsfDemographics = NSFDemographics()
- self.nsfDemographics.read(iprot)
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('UserProfile')
- if self.userModelVersion is not None:
- oprot.writeFieldBegin('userModelVersion', TType.STRING, 1)
- oprot.writeString(self.userModelVersion)
- oprot.writeFieldEnd()
- if self.airavataInternalUserId is not None:
- oprot.writeFieldBegin('airavataInternalUserId', TType.STRING, 2)
- oprot.writeString(self.airavataInternalUserId)
- oprot.writeFieldEnd()
- if self.userId is not None:
- oprot.writeFieldBegin('userId', TType.STRING, 3)
- oprot.writeString(self.userId)
- oprot.writeFieldEnd()
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 4)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- if self.emails is not None:
- oprot.writeFieldBegin('emails', TType.LIST, 5)
- oprot.writeListBegin(TType.STRING, len(self.emails))
- for iter45 in self.emails:
- oprot.writeString(iter45)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.firstName is not None:
- oprot.writeFieldBegin('firstName', TType.STRING, 6)
- oprot.writeString(self.firstName)
- oprot.writeFieldEnd()
- if self.lastName is not None:
- oprot.writeFieldBegin('lastName', TType.STRING, 7)
- oprot.writeString(self.lastName)
- oprot.writeFieldEnd()
- if self.middleName is not None:
- oprot.writeFieldBegin('middleName', TType.STRING, 8)
- oprot.writeString(self.middleName)
- oprot.writeFieldEnd()
- if self.namePrefix is not None:
- oprot.writeFieldBegin('namePrefix', TType.STRING, 9)
- oprot.writeString(self.namePrefix)
- oprot.writeFieldEnd()
- if self.nameSuffix is not None:
- oprot.writeFieldBegin('nameSuffix', TType.STRING, 10)
- oprot.writeString(self.nameSuffix)
- oprot.writeFieldEnd()
- if self.orcidId is not None:
- oprot.writeFieldBegin('orcidId', TType.STRING, 11)
- oprot.writeString(self.orcidId)
- oprot.writeFieldEnd()
- if self.phones is not None:
- oprot.writeFieldBegin('phones', TType.LIST, 12)
- oprot.writeListBegin(TType.STRING, len(self.phones))
- for iter46 in self.phones:
- oprot.writeString(iter46)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.country is not None:
- oprot.writeFieldBegin('country', TType.STRING, 13)
- oprot.writeString(self.country)
- oprot.writeFieldEnd()
- if self.nationality is not None:
- oprot.writeFieldBegin('nationality', TType.LIST, 14)
- oprot.writeListBegin(TType.STRING, len(self.nationality))
- for iter47 in self.nationality:
- oprot.writeString(iter47)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.homeOrganization is not None:
- oprot.writeFieldBegin('homeOrganization', TType.STRING, 15)
- oprot.writeString(self.homeOrganization)
- oprot.writeFieldEnd()
- if self.orginationAffiliation is not None:
- oprot.writeFieldBegin('orginationAffiliation', TType.STRING, 16)
- oprot.writeString(self.orginationAffiliation)
- oprot.writeFieldEnd()
- if self.creationTime is not None:
- oprot.writeFieldBegin('creationTime', TType.I64, 17)
- oprot.writeI64(self.creationTime)
- oprot.writeFieldEnd()
- if self.lastAccessTime is not None:
- oprot.writeFieldBegin('lastAccessTime', TType.I64, 18)
- oprot.writeI64(self.lastAccessTime)
- oprot.writeFieldEnd()
- if self.validUntil is not None:
- oprot.writeFieldBegin('validUntil', TType.I64, 19)
- oprot.writeI64(self.validUntil)
- oprot.writeFieldEnd()
- if self.State is not None:
- oprot.writeFieldBegin('State', TType.I32, 20)
- oprot.writeI32(self.State)
- oprot.writeFieldEnd()
- if self.comments is not None:
- oprot.writeFieldBegin('comments', TType.STRING, 21)
- oprot.writeString(self.comments)
- oprot.writeFieldEnd()
- if self.labeledURI is not None:
- oprot.writeFieldBegin('labeledURI', TType.LIST, 22)
- oprot.writeListBegin(TType.STRING, len(self.labeledURI))
- for iter48 in self.labeledURI:
- oprot.writeString(iter48)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.gpgKey is not None:
- oprot.writeFieldBegin('gpgKey', TType.STRING, 23)
- oprot.writeString(self.gpgKey)
- oprot.writeFieldEnd()
- if self.timeZone is not None:
- oprot.writeFieldBegin('timeZone', TType.STRING, 24)
- oprot.writeString(self.timeZone)
- oprot.writeFieldEnd()
- if self.nsfDemographics is not None:
- oprot.writeFieldBegin('nsfDemographics', TType.STRUCT, 25)
- self.nsfDemographics.write(oprot)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.userModelVersion is None:
- raise TProtocol.TProtocolException(message='Required field userModelVersion is unset!')
- if self.airavataInternalUserId is None:
- raise TProtocol.TProtocolException(message='Required field airavataInternalUserId is unset!')
- if self.userId is None:
- raise TProtocol.TProtocolException(message='Required field userId is unset!')
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- if self.emails is None:
- raise TProtocol.TProtocolException(message='Required field emails is unset!')
- if self.firstName is None:
- raise TProtocol.TProtocolException(message='Required field firstName is unset!')
- if self.lastName is None:
- raise TProtocol.TProtocolException(message='Required field lastName is unset!')
- if self.creationTime is None:
- raise TProtocol.TProtocolException(message='Required field creationTime is unset!')
- if self.lastAccessTime is None:
- raise TProtocol.TProtocolException(message='Required field lastAccessTime is unset!')
- if self.validUntil is None:
- raise TProtocol.TProtocolException(message='Required field validUntil is unset!')
- if self.State is None:
- raise TProtocol.TProtocolException(message='Required field State is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.userModelVersion)
- value = (value * 31) ^ hash(self.airavataInternalUserId)
- value = (value * 31) ^ hash(self.userId)
- value = (value * 31) ^ hash(self.gatewayId)
- value = (value * 31) ^ hash(self.emails)
- value = (value * 31) ^ hash(self.firstName)
- value = (value * 31) ^ hash(self.lastName)
- value = (value * 31) ^ hash(self.middleName)
- value = (value * 31) ^ hash(self.namePrefix)
- value = (value * 31) ^ hash(self.nameSuffix)
- value = (value * 31) ^ hash(self.orcidId)
- value = (value * 31) ^ hash(self.phones)
- value = (value * 31) ^ hash(self.country)
- value = (value * 31) ^ hash(self.nationality)
- value = (value * 31) ^ hash(self.homeOrganization)
- value = (value * 31) ^ hash(self.orginationAffiliation)
- value = (value * 31) ^ hash(self.creationTime)
- value = (value * 31) ^ hash(self.lastAccessTime)
- value = (value * 31) ^ hash(self.validUntil)
- value = (value * 31) ^ hash(self.State)
- value = (value * 31) ^ hash(self.comments)
- value = (value * 31) ^ hash(self.labeledURI)
- value = (value * 31) ^ hash(self.gpgKey)
- value = (value * 31) ^ hash(self.timeZone)
- value = (value * 31) ^ hash(self.nsfDemographics)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class Status(object):
+ ACTIVE = 0
+ CONFIRMED = 1
+ APPROVED = 2
+ DELETED = 3
+ DUPLICATE = 4
+ GRACE_PERIOD = 5
+ INVITED = 6
+ DENIED = 7
+ PENDING = 8
+ PENDING_APPROVAL = 9
+ PENDING_CONFIRMATION = 10
+ SUSPENDED = 11
+ DECLINED = 12
+ EXPIRED = 13
+
+ _VALUES_TO_NAMES = {
+ 0: "ACTIVE",
+ 1: "CONFIRMED",
+ 2: "APPROVED",
+ 3: "DELETED",
+ 4: "DUPLICATE",
+ 5: "GRACE_PERIOD",
+ 6: "INVITED",
+ 7: "DENIED",
+ 8: "PENDING",
+ 9: "PENDING_APPROVAL",
+ 10: "PENDING_CONFIRMATION",
+ 11: "SUSPENDED",
+ 12: "DECLINED",
+ 13: "EXPIRED",
+ }
+
+ _NAMES_TO_VALUES = {
+ "ACTIVE": 0,
+ "CONFIRMED": 1,
+ "APPROVED": 2,
+ "DELETED": 3,
+ "DUPLICATE": 4,
+ "GRACE_PERIOD": 5,
+ "INVITED": 6,
+ "DENIED": 7,
+ "PENDING": 8,
+ "PENDING_APPROVAL": 9,
+ "PENDING_CONFIRMATION": 10,
+ "SUSPENDED": 11,
+ "DECLINED": 12,
+ "EXPIRED": 13,
+ }
+
+
+class USCitizenship(object):
+ """
+ U.S. Citizen (see: http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)
+
+ """
+ US_CITIZEN = 0
+ US_PERMANENT_RESIDENT = 1
+ OTHER_NON_US_CITIZEN = 2
+
+ _VALUES_TO_NAMES = {
+ 0: "US_CITIZEN",
+ 1: "US_PERMANENT_RESIDENT",
+ 2: "OTHER_NON_US_CITIZEN",
+ }
+
+ _NAMES_TO_VALUES = {
+ "US_CITIZEN": 0,
+ "US_PERMANENT_RESIDENT": 1,
+ "OTHER_NON_US_CITIZEN": 2,
+ }
+
+
+class ethnicity(object):
+ """
+ Hispanic or Latino - a person of Mexican, Puerto Rican, Cuban, South or
+ Central American, or other Spanish culture or origin, regardless of race.
+
+ """
+ HISPANIC_LATINO = 0
+ NOT_HISPANIC_LATINO = 1
+
+ _VALUES_TO_NAMES = {
+ 0: "HISPANIC_LATINO",
+ 1: "NOT_HISPANIC_LATINO",
+ }
+
+ _NAMES_TO_VALUES = {
+ "HISPANIC_LATINO": 0,
+ "NOT_HISPANIC_LATINO": 1,
+ }
+
+
+class race(object):
+ """
+ * Asian - a person having origins in any of the original peoples of the Far East,
+ * Southeast Asia, or the Indian subcontinent including, for example, Cambodia,
+ * China, India, Japan, Korea, Malaysia, Pakistan, the Philippine Islands,
+ * Thailand, and Vietnam.
+ * American Indian or Alaskan Native - a person having origins in any of the original
+ * peoples of North and South America (including Central America), and who maintains
+ * tribal affiliation or community attachment.
+ * Black or African American - a person having origins in any of the black racial groups
+ * of Africa.
+ * Native Hawaiian or Pacific Islander - a person having origins in any of the original
+ * peoples of Hawaii, Guan, Samoa, or other Pacific Islands.
+ * White - a person having origins in any of the original peoples of Europe, the Middle East, or North Africa.
+ *
+ """
+ ASIAN = 0
+ AMERICAN_INDIAN_OR_ALASKAN_NATIVE = 1
+ BLACK_OR_AFRICAN_AMERICAN = 2
+ NATIVE_HAWAIIAN_OR_PACIFIC_ISLANDER = 3
+ WHITE = 4
+
+ _VALUES_TO_NAMES = {
+ 0: "ASIAN",
+ 1: "AMERICAN_INDIAN_OR_ALASKAN_NATIVE",
+ 2: "BLACK_OR_AFRICAN_AMERICAN",
+ 3: "NATIVE_HAWAIIAN_OR_PACIFIC_ISLANDER",
+ 4: "WHITE",
+ }
+
+ _NAMES_TO_VALUES = {
+ "ASIAN": 0,
+ "AMERICAN_INDIAN_OR_ALASKAN_NATIVE": 1,
+ "BLACK_OR_AFRICAN_AMERICAN": 2,
+ "NATIVE_HAWAIIAN_OR_PACIFIC_ISLANDER": 3,
+ "WHITE": 4,
+ }
+
+
+class disability(object):
+ HEARING_IMAPAIRED = 0
+ VISUAL_IMPAIRED = 1
+ MOBILITY_OR_ORTHOPEDIC_IMPAIRMENT = 2
+ OTHER_IMPAIRMENT = 3
+
+ _VALUES_TO_NAMES = {
+ 0: "HEARING_IMAPAIRED",
+ 1: "VISUAL_IMPAIRED",
+ 2: "MOBILITY_OR_ORTHOPEDIC_IMPAIRMENT",
+ 3: "OTHER_IMPAIRMENT",
+ }
+
+ _NAMES_TO_VALUES = {
+ "HEARING_IMAPAIRED": 0,
+ "VISUAL_IMPAIRED": 1,
+ "MOBILITY_OR_ORTHOPEDIC_IMPAIRMENT": 2,
+ "OTHER_IMPAIRMENT": 3,
+ }
+
+
+class NSFDemographics(object):
+ """
+ A structure holding the NSF Demographic information.
+
+
+
+ Attributes:
+ - airavataInternalUserId
+ - gender
+ - usCitizenship
+ - ethnicities
+ - races
+ - disabilities
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'airavataInternalUserId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.STRING, 'gender', 'UTF8', None, ), # 2
+ (3, TType.I32, 'usCitizenship', None, None, ), # 3
+ (4, TType.LIST, 'ethnicities', (TType.I32, None, False), None, ), # 4
+ (5, TType.LIST, 'races', (TType.I32, None, False), None, ), # 5
+ (6, TType.LIST, 'disabilities', (TType.I32, None, False), None, ), # 6
+ )
+
+ def __init__(self, airavataInternalUserId=thrift_spec[1][4], gender=None, usCitizenship=None, ethnicities=None, races=None, disabilities=None,):
+ self.airavataInternalUserId = airavataInternalUserId
+ self.gender = gender
+ self.usCitizenship = usCitizenship
+ self.ethnicities = ethnicities
+ self.races = races
+ self.disabilities = disabilities
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.airavataInternalUserId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.gender = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I32:
+ self.usCitizenship = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.LIST:
+ self.ethnicities = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in range(_size0):
+ _elem5 = iprot.readI32()
+ self.ethnicities.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.LIST:
+ self.races = []
+ (_etype9, _size6) = iprot.readListBegin()
+ for _i10 in range(_size6):
+ _elem11 = iprot.readI32()
+ self.races.append(_elem11)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.LIST:
+ self.disabilities = []
+ (_etype15, _size12) = iprot.readListBegin()
+ for _i16 in range(_size12):
+ _elem17 = iprot.readI32()
+ self.disabilities.append(_elem17)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('NSFDemographics')
+ if self.airavataInternalUserId is not None:
+ oprot.writeFieldBegin('airavataInternalUserId', TType.STRING, 1)
+ oprot.writeString(self.airavataInternalUserId.encode('utf-8') if sys.version_info[0] == 2 else self.airavataInternalUserId)
+ oprot.writeFieldEnd()
+ if self.gender is not None:
+ oprot.writeFieldBegin('gender', TType.STRING, 2)
+ oprot.writeString(self.gender.encode('utf-8') if sys.version_info[0] == 2 else self.gender)
+ oprot.writeFieldEnd()
+ if self.usCitizenship is not None:
+ oprot.writeFieldBegin('usCitizenship', TType.I32, 3)
+ oprot.writeI32(self.usCitizenship)
+ oprot.writeFieldEnd()
+ if self.ethnicities is not None:
+ oprot.writeFieldBegin('ethnicities', TType.LIST, 4)
+ oprot.writeListBegin(TType.I32, len(self.ethnicities))
+ for iter18 in self.ethnicities:
+ oprot.writeI32(iter18)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.races is not None:
+ oprot.writeFieldBegin('races', TType.LIST, 5)
+ oprot.writeListBegin(TType.I32, len(self.races))
+ for iter19 in self.races:
+ oprot.writeI32(iter19)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.disabilities is not None:
+ oprot.writeFieldBegin('disabilities', TType.LIST, 6)
+ oprot.writeListBegin(TType.I32, len(self.disabilities))
+ for iter20 in self.disabilities:
+ oprot.writeI32(iter20)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.airavataInternalUserId is None:
+ raise TProtocolException(message='Required field airavataInternalUserId is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class UserProfile(object):
+ """
+ * A structure holding the user profile and its child models.
+ *
+ * Notes:
+ * The model does not include passwords as it is assumed an external identity provider is used to authenticate user.
+ * References:
+ * NSF Demographic Information - http://www.nsf.gov/pubs/2000/00form1225/00form1225.doc
+ * LDAP Schema - https://tools.ietf.org/html/rfc4519
+ * SCIM 2.0 - https://tools.ietf.org/html/rfc7643
+ *
+ * userModelVersion:
+ * Version number of profile
+ *
+ * airavataInternalUserId:
+ * internal to Airavata, not intended to be used outside of the Airavata platform or possibly by gateways
+ * (that is, never shown to users), never reassigned, REQUIRED
+ *
+ * userId:
+ * Externally assertable unique identifier. SAML (primarly in higher education, academic) tends to keep
+ * user name less opaque. OpenID Connect maintains them to be opaque.
+ *
+ * firstName, middleName, lastName:
+ * First and Last names as assertede by the user
+ *
+ * namePrefix, nameSuffix:
+ * prefix and suffix to the users name as asserted by the user
+ *
+ * emails:
+ * Email identifier are Verified, REQUIRED and MULTIVALUED
+ *
+ * userName:
+ * Name-based identifiers can be multivalues. To keep it simple, Airavata will make it a string.
+ * In the future these can be enumerated as:
+ * Official name (as asserted possibly by some external identity provider)
+ * Prefered name (as asserted or suggested by user directly)
+ * Components:
+ * givenName
+ * surname (familyName)
+ * displayName (often asserted by user to handle things like middle names, suffix, prefix, and the like)
+ *
+ * orcidId: ORCID ID - http://orcid.org/about/what-is-orcid)
+ *
+ * phones: Telephone MULTIVALUED
+ *
+ * country: Country of Residance
+ *
+ * nationality Countries of citizenship
+ *
+ * comments:
+ * Free-form information (treated as opaque by Airavata and simply passed to resource).
+ *
+ * labeledURI:
+ * Google Scholar, Web of Science, ACS, e.t.c
+ *
+ * timeZone:
+ * User’s preferred timezone - IANA Timezone Databases - http://www.iana.org/time-zones.
+ *
+
+ Attributes:
+ - userModelVersion
+ - airavataInternalUserId
+ - userId
+ - gatewayId
+ - emails
+ - firstName
+ - lastName
+ - middleName
+ - namePrefix
+ - nameSuffix
+ - orcidId
+ - phones
+ - country
+ - nationality
+ - homeOrganization
+ - orginationAffiliation
+ - creationTime
+ - lastAccessTime
+ - validUntil
+ - State
+ - comments
+ - labeledURI
+ - gpgKey
+ - timeZone
+ - nsfDemographics
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'userModelVersion', 'UTF8', "1.0", ), # 1
+ (2, TType.STRING, 'airavataInternalUserId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 2
+ (3, TType.STRING, 'userId', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'gatewayId', 'UTF8', None, ), # 4
+ (5, TType.LIST, 'emails', (TType.STRING, 'UTF8', False), None, ), # 5
+ (6, TType.STRING, 'firstName', 'UTF8', None, ), # 6
+ (7, TType.STRING, 'lastName', 'UTF8', None, ), # 7
+ (8, TType.STRING, 'middleName', 'UTF8', None, ), # 8
+ (9, TType.STRING, 'namePrefix', 'UTF8', None, ), # 9
+ (10, TType.STRING, 'nameSuffix', 'UTF8', None, ), # 10
+ (11, TType.STRING, 'orcidId', 'UTF8', None, ), # 11
+ (12, TType.LIST, 'phones', (TType.STRING, 'UTF8', False), None, ), # 12
+ (13, TType.STRING, 'country', 'UTF8', None, ), # 13
+ (14, TType.LIST, 'nationality', (TType.STRING, 'UTF8', False), None, ), # 14
+ (15, TType.STRING, 'homeOrganization', 'UTF8', None, ), # 15
+ (16, TType.STRING, 'orginationAffiliation', 'UTF8', None, ), # 16
+ (17, TType.I64, 'creationTime', None, None, ), # 17
+ (18, TType.I64, 'lastAccessTime', None, None, ), # 18
+ (19, TType.I64, 'validUntil', None, None, ), # 19
+ (20, TType.I32, 'State', None, None, ), # 20
+ (21, TType.STRING, 'comments', 'UTF8', None, ), # 21
+ (22, TType.LIST, 'labeledURI', (TType.STRING, 'UTF8', False), None, ), # 22
+ (23, TType.STRING, 'gpgKey', 'UTF8', None, ), # 23
+ (24, TType.STRING, 'timeZone', 'UTF8', None, ), # 24
+ (25, TType.STRUCT, 'nsfDemographics', (NSFDemographics, NSFDemographics.thrift_spec), None, ), # 25
+ )
+
+ def __init__(self, userModelVersion=thrift_spec[1][4], airavataInternalUserId=thrift_spec[2][4], userId=None, gatewayId=None, emails=None, firstName=None, lastName=None, middleName=None, namePrefix=None, nameSuffix=None, orcidId=None, phones=None, country=None, nationality=None, homeOrganization=None, orginationAffiliation=None, creationTime=None, lastAccessTime=None, validUntil=None, State=None, comments=None, labeledURI=None, gpgKey=None, timeZone=None, nsfDemographics=None,):
+ self.userModelVersion = userModelVersion
+ self.airavataInternalUserId = airavataInternalUserId
+ self.userId = userId
+ self.gatewayId = gatewayId
+ self.emails = emails
+ self.firstName = firstName
+ self.lastName = lastName
+ self.middleName = middleName
+ self.namePrefix = namePrefix
+ self.nameSuffix = nameSuffix
+ self.orcidId = orcidId
+ self.phones = phones
+ self.country = country
+ self.nationality = nationality
+ self.homeOrganization = homeOrganization
+ self.orginationAffiliation = orginationAffiliation
+ self.creationTime = creationTime
+ self.lastAccessTime = lastAccessTime
+ self.validUntil = validUntil
+ self.State = State
+ self.comments = comments
+ self.labeledURI = labeledURI
+ self.gpgKey = gpgKey
+ self.timeZone = timeZone
+ self.nsfDemographics = nsfDemographics
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.userModelVersion = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.airavataInternalUserId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.userId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.LIST:
+ self.emails = []
+ (_etype24, _size21) = iprot.readListBegin()
+ for _i25 in range(_size21):
+ _elem26 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ self.emails.append(_elem26)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.firstName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.STRING:
+ self.lastName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.STRING:
+ self.middleName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.STRING:
+ self.namePrefix = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.STRING:
+ self.nameSuffix = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 11:
+ if ftype == TType.STRING:
+ self.orcidId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 12:
+ if ftype == TType.LIST:
+ self.phones = []
+ (_etype30, _size27) = iprot.readListBegin()
+ for _i31 in range(_size27):
+ _elem32 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ self.phones.append(_elem32)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 13:
+ if ftype == TType.STRING:
+ self.country = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 14:
+ if ftype == TType.LIST:
+ self.nationality = []
+ (_etype36, _size33) = iprot.readListBegin()
+ for _i37 in range(_size33):
+ _elem38 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ self.nationality.append(_elem38)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 15:
+ if ftype == TType.STRING:
+ self.homeOrganization = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 16:
+ if ftype == TType.STRING:
+ self.orginationAffiliation = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 17:
+ if ftype == TType.I64:
+ self.creationTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 18:
+ if ftype == TType.I64:
+ self.lastAccessTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 19:
+ if ftype == TType.I64:
+ self.validUntil = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 20:
+ if ftype == TType.I32:
+ self.State = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 21:
+ if ftype == TType.STRING:
+ self.comments = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 22:
+ if ftype == TType.LIST:
+ self.labeledURI = []
+ (_etype42, _size39) = iprot.readListBegin()
+ for _i43 in range(_size39):
+ _elem44 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ self.labeledURI.append(_elem44)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 23:
+ if ftype == TType.STRING:
+ self.gpgKey = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 24:
+ if ftype == TType.STRING:
+ self.timeZone = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 25:
+ if ftype == TType.STRUCT:
+ self.nsfDemographics = NSFDemographics()
+ self.nsfDemographics.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('UserProfile')
+ if self.userModelVersion is not None:
+ oprot.writeFieldBegin('userModelVersion', TType.STRING, 1)
+ oprot.writeString(self.userModelVersion.encode('utf-8') if sys.version_info[0] == 2 else self.userModelVersion)
+ oprot.writeFieldEnd()
+ if self.airavataInternalUserId is not None:
+ oprot.writeFieldBegin('airavataInternalUserId', TType.STRING, 2)
+ oprot.writeString(self.airavataInternalUserId.encode('utf-8') if sys.version_info[0] == 2 else self.airavataInternalUserId)
+ oprot.writeFieldEnd()
+ if self.userId is not None:
+ oprot.writeFieldBegin('userId', TType.STRING, 3)
+ oprot.writeString(self.userId.encode('utf-8') if sys.version_info[0] == 2 else self.userId)
+ oprot.writeFieldEnd()
+ if self.gatewayId is not None:
+ oprot.writeFieldBegin('gatewayId', TType.STRING, 4)
+ oprot.writeString(self.gatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayId)
+ oprot.writeFieldEnd()
+ if self.emails is not None:
+ oprot.writeFieldBegin('emails', TType.LIST, 5)
+ oprot.writeListBegin(TType.STRING, len(self.emails))
+ for iter45 in self.emails:
+ oprot.writeString(iter45.encode('utf-8') if sys.version_info[0] == 2 else iter45)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.firstName is not None:
+ oprot.writeFieldBegin('firstName', TType.STRING, 6)
+ oprot.writeString(self.firstName.encode('utf-8') if sys.version_info[0] == 2 else self.firstName)
+ oprot.writeFieldEnd()
+ if self.lastName is not None:
+ oprot.writeFieldBegin('lastName', TType.STRING, 7)
+ oprot.writeString(self.lastName.encode('utf-8') if sys.version_info[0] == 2 else self.lastName)
+ oprot.writeFieldEnd()
+ if self.middleName is not None:
+ oprot.writeFieldBegin('middleName', TType.STRING, 8)
+ oprot.writeString(self.middleName.encode('utf-8') if sys.version_info[0] == 2 else self.middleName)
+ oprot.writeFieldEnd()
+ if self.namePrefix is not None:
+ oprot.writeFieldBegin('namePrefix', TType.STRING, 9)
+ oprot.writeString(self.namePrefix.encode('utf-8') if sys.version_info[0] == 2 else self.namePrefix)
+ oprot.writeFieldEnd()
+ if self.nameSuffix is not None:
+ oprot.writeFieldBegin('nameSuffix', TType.STRING, 10)
+ oprot.writeString(self.nameSuffix.encode('utf-8') if sys.version_info[0] == 2 else self.nameSuffix)
+ oprot.writeFieldEnd()
+ if self.orcidId is not None:
+ oprot.writeFieldBegin('orcidId', TType.STRING, 11)
+ oprot.writeString(self.orcidId.encode('utf-8') if sys.version_info[0] == 2 else self.orcidId)
+ oprot.writeFieldEnd()
+ if self.phones is not None:
+ oprot.writeFieldBegin('phones', TType.LIST, 12)
+ oprot.writeListBegin(TType.STRING, len(self.phones))
+ for iter46 in self.phones:
+ oprot.writeString(iter46.encode('utf-8') if sys.version_info[0] == 2 else iter46)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.country is not None:
+ oprot.writeFieldBegin('country', TType.STRING, 13)
+ oprot.writeString(self.country.encode('utf-8') if sys.version_info[0] == 2 else self.country)
+ oprot.writeFieldEnd()
+ if self.nationality is not None:
+ oprot.writeFieldBegin('nationality', TType.LIST, 14)
+ oprot.writeListBegin(TType.STRING, len(self.nationality))
+ for iter47 in self.nationality:
+ oprot.writeString(iter47.encode('utf-8') if sys.version_info[0] == 2 else iter47)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.homeOrganization is not None:
+ oprot.writeFieldBegin('homeOrganization', TType.STRING, 15)
+ oprot.writeString(self.homeOrganization.encode('utf-8') if sys.version_info[0] == 2 else self.homeOrganization)
+ oprot.writeFieldEnd()
+ if self.orginationAffiliation is not None:
+ oprot.writeFieldBegin('orginationAffiliation', TType.STRING, 16)
+ oprot.writeString(self.orginationAffiliation.encode('utf-8') if sys.version_info[0] == 2 else self.orginationAffiliation)
+ oprot.writeFieldEnd()
+ if self.creationTime is not None:
+ oprot.writeFieldBegin('creationTime', TType.I64, 17)
+ oprot.writeI64(self.creationTime)
+ oprot.writeFieldEnd()
+ if self.lastAccessTime is not None:
+ oprot.writeFieldBegin('lastAccessTime', TType.I64, 18)
+ oprot.writeI64(self.lastAccessTime)
+ oprot.writeFieldEnd()
+ if self.validUntil is not None:
+ oprot.writeFieldBegin('validUntil', TType.I64, 19)
+ oprot.writeI64(self.validUntil)
+ oprot.writeFieldEnd()
+ if self.State is not None:
+ oprot.writeFieldBegin('State', TType.I32, 20)
+ oprot.writeI32(self.State)
+ oprot.writeFieldEnd()
+ if self.comments is not None:
+ oprot.writeFieldBegin('comments', TType.STRING, 21)
+ oprot.writeString(self.comments.encode('utf-8') if sys.version_info[0] == 2 else self.comments)
+ oprot.writeFieldEnd()
+ if self.labeledURI is not None:
+ oprot.writeFieldBegin('labeledURI', TType.LIST, 22)
+ oprot.writeListBegin(TType.STRING, len(self.labeledURI))
+ for iter48 in self.labeledURI:
+ oprot.writeString(iter48.encode('utf-8') if sys.version_info[0] == 2 else iter48)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.gpgKey is not None:
+ oprot.writeFieldBegin('gpgKey', TType.STRING, 23)
+ oprot.writeString(self.gpgKey.encode('utf-8') if sys.version_info[0] == 2 else self.gpgKey)
+ oprot.writeFieldEnd()
+ if self.timeZone is not None:
+ oprot.writeFieldBegin('timeZone', TType.STRING, 24)
+ oprot.writeString(self.timeZone.encode('utf-8') if sys.version_info[0] == 2 else self.timeZone)
+ oprot.writeFieldEnd()
+ if self.nsfDemographics is not None:
+ oprot.writeFieldBegin('nsfDemographics', TType.STRUCT, 25)
+ self.nsfDemographics.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.userModelVersion is None:
+ raise TProtocolException(message='Required field userModelVersion is unset!')
+ if self.airavataInternalUserId is None:
+ raise TProtocolException(message='Required field airavataInternalUserId is unset!')
+ if self.userId is None:
+ raise TProtocolException(message='Required field userId is unset!')
+ if self.gatewayId is None:
+ raise TProtocolException(message='Required field gatewayId is unset!')
+ if self.emails is None:
+ raise TProtocolException(message='Required field emails is unset!')
+ if self.firstName is None:
+ raise TProtocolException(message='Required field firstName is unset!')
+ if self.lastName is None:
+ raise TProtocolException(message='Required field lastName is unset!')
+ if self.creationTime is None:
+ raise TProtocolException(message='Required field creationTime is unset!')
+ if self.lastAccessTime is None:
+ raise TProtocolException(message='Required field lastAccessTime is unset!')
+ if self.validUntil is None:
+ raise TProtocolException(message='Required field validUntil is unset!')
+ if self.State is None:
+ raise TProtocolException(message='Required field State is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workflow/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workflow/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workflow/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workflow/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/workflow/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
[13/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/ErrorModel.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/ErrorModel.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/ErrorModel.java
index 2adadf4..178f05d 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/ErrorModel.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/ErrorModel.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.commons;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorModel._Fields>, java.io.Serializable, Cloneable, Comparable<ErrorModel> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ErrorModel");
@@ -62,18 +35,15 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
private static final org.apache.thrift.protocol.TField TRANSIENT_OR_PERSISTENT_FIELD_DESC = new org.apache.thrift.protocol.TField("transientOrPersistent", org.apache.thrift.protocol.TType.BOOL, (short)5);
private static final org.apache.thrift.protocol.TField ROOT_CAUSE_ERROR_ID_LIST_FIELD_DESC = new org.apache.thrift.protocol.TField("rootCauseErrorIdList", org.apache.thrift.protocol.TType.LIST, (short)6);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new ErrorModelStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ErrorModelTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ErrorModelStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ErrorModelTupleSchemeFactory();
- private String errorId; // required
+ private java.lang.String errorId; // required
private long creationTime; // optional
- private String actualErrorMessage; // optional
- private String userFriendlyMessage; // optional
+ private java.lang.String actualErrorMessage; // optional
+ private java.lang.String userFriendlyMessage; // optional
private boolean transientOrPersistent; // optional
- private List<String> rootCauseErrorIdList; // optional
+ private java.util.List<java.lang.String> rootCauseErrorIdList; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -84,10 +54,10 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
TRANSIENT_OR_PERSISTENT((short)5, "transientOrPersistent"),
ROOT_CAUSE_ERROR_ID_LIST((short)6, "rootCauseErrorIdList");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -120,21 +90,21 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -143,7 +113,7 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -153,9 +123,9 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
private static final int __TRANSIENTORPERSISTENT_ISSET_ID = 1;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.CREATION_TIME,_Fields.ACTUAL_ERROR_MESSAGE,_Fields.USER_FRIENDLY_MESSAGE,_Fields.TRANSIENT_OR_PERSISTENT,_Fields.ROOT_CAUSE_ERROR_ID_LIST};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.ERROR_ID, new org.apache.thrift.meta_data.FieldMetaData("errorId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.CREATION_TIME, new org.apache.thrift.meta_data.FieldMetaData("creationTime", org.apache.thrift.TFieldRequirementType.OPTIONAL,
@@ -169,7 +139,7 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
tmpMap.put(_Fields.ROOT_CAUSE_ERROR_ID_LIST, new org.apache.thrift.meta_data.FieldMetaData("rootCauseErrorIdList", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ErrorModel.class, metaDataMap);
}
@@ -181,7 +151,7 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
}
public ErrorModel(
- String errorId)
+ java.lang.String errorId)
{
this();
this.errorId = errorId;
@@ -204,7 +174,7 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
}
this.transientOrPersistent = other.transientOrPersistent;
if (other.isSetRootCauseErrorIdList()) {
- List<String> __this__rootCauseErrorIdList = new ArrayList<String>(other.rootCauseErrorIdList);
+ java.util.List<java.lang.String> __this__rootCauseErrorIdList = new java.util.ArrayList<java.lang.String>(other.rootCauseErrorIdList);
this.rootCauseErrorIdList = __this__rootCauseErrorIdList;
}
}
@@ -226,11 +196,11 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
this.rootCauseErrorIdList = null;
}
- public String getErrorId() {
+ public java.lang.String getErrorId() {
return this.errorId;
}
- public void setErrorId(String errorId) {
+ public void setErrorId(java.lang.String errorId) {
this.errorId = errorId;
}
@@ -259,23 +229,23 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
}
public void unsetCreationTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
}
/** Returns true if field creationTime is set (has been assigned a value) and false otherwise */
public boolean isSetCreationTime() {
- return EncodingUtils.testBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
}
public void setCreationTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __CREATIONTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __CREATIONTIME_ISSET_ID, value);
}
- public String getActualErrorMessage() {
+ public java.lang.String getActualErrorMessage() {
return this.actualErrorMessage;
}
- public void setActualErrorMessage(String actualErrorMessage) {
+ public void setActualErrorMessage(java.lang.String actualErrorMessage) {
this.actualErrorMessage = actualErrorMessage;
}
@@ -294,11 +264,11 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
}
}
- public String getUserFriendlyMessage() {
+ public java.lang.String getUserFriendlyMessage() {
return this.userFriendlyMessage;
}
- public void setUserFriendlyMessage(String userFriendlyMessage) {
+ public void setUserFriendlyMessage(java.lang.String userFriendlyMessage) {
this.userFriendlyMessage = userFriendlyMessage;
}
@@ -327,38 +297,38 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
}
public void unsetTransientOrPersistent() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __TRANSIENTORPERSISTENT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __TRANSIENTORPERSISTENT_ISSET_ID);
}
/** Returns true if field transientOrPersistent is set (has been assigned a value) and false otherwise */
public boolean isSetTransientOrPersistent() {
- return EncodingUtils.testBit(__isset_bitfield, __TRANSIENTORPERSISTENT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __TRANSIENTORPERSISTENT_ISSET_ID);
}
public void setTransientOrPersistentIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __TRANSIENTORPERSISTENT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __TRANSIENTORPERSISTENT_ISSET_ID, value);
}
public int getRootCauseErrorIdListSize() {
return (this.rootCauseErrorIdList == null) ? 0 : this.rootCauseErrorIdList.size();
}
- public java.util.Iterator<String> getRootCauseErrorIdListIterator() {
+ public java.util.Iterator<java.lang.String> getRootCauseErrorIdListIterator() {
return (this.rootCauseErrorIdList == null) ? null : this.rootCauseErrorIdList.iterator();
}
- public void addToRootCauseErrorIdList(String elem) {
+ public void addToRootCauseErrorIdList(java.lang.String elem) {
if (this.rootCauseErrorIdList == null) {
- this.rootCauseErrorIdList = new ArrayList<String>();
+ this.rootCauseErrorIdList = new java.util.ArrayList<java.lang.String>();
}
this.rootCauseErrorIdList.add(elem);
}
- public List<String> getRootCauseErrorIdList() {
+ public java.util.List<java.lang.String> getRootCauseErrorIdList() {
return this.rootCauseErrorIdList;
}
- public void setRootCauseErrorIdList(List<String> rootCauseErrorIdList) {
+ public void setRootCauseErrorIdList(java.util.List<java.lang.String> rootCauseErrorIdList) {
this.rootCauseErrorIdList = rootCauseErrorIdList;
}
@@ -377,13 +347,13 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case ERROR_ID:
if (value == null) {
unsetErrorId();
} else {
- setErrorId((String)value);
+ setErrorId((java.lang.String)value);
}
break;
@@ -391,7 +361,7 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
if (value == null) {
unsetCreationTime();
} else {
- setCreationTime((Long)value);
+ setCreationTime((java.lang.Long)value);
}
break;
@@ -399,7 +369,7 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
if (value == null) {
unsetActualErrorMessage();
} else {
- setActualErrorMessage((String)value);
+ setActualErrorMessage((java.lang.String)value);
}
break;
@@ -407,7 +377,7 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
if (value == null) {
unsetUserFriendlyMessage();
} else {
- setUserFriendlyMessage((String)value);
+ setUserFriendlyMessage((java.lang.String)value);
}
break;
@@ -415,7 +385,7 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
if (value == null) {
unsetTransientOrPersistent();
} else {
- setTransientOrPersistent((Boolean)value);
+ setTransientOrPersistent((java.lang.Boolean)value);
}
break;
@@ -423,14 +393,14 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
if (value == null) {
unsetRootCauseErrorIdList();
} else {
- setRootCauseErrorIdList((List<String>)value);
+ setRootCauseErrorIdList((java.util.List<java.lang.String>)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case ERROR_ID:
return getErrorId();
@@ -451,13 +421,13 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
return getRootCauseErrorIdList();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -474,11 +444,11 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
case ROOT_CAUSE_ERROR_ID_LIST:
return isSetRootCauseErrorIdList();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ErrorModel)
@@ -489,6 +459,8 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
public boolean equals(ErrorModel that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_errorId = true && this.isSetErrorId();
boolean that_present_errorId = true && that.isSetErrorId();
@@ -549,39 +521,33 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_errorId = true && (isSetErrorId());
- list.add(present_errorId);
- if (present_errorId)
- list.add(errorId);
+ hashCode = hashCode * 8191 + ((isSetErrorId()) ? 131071 : 524287);
+ if (isSetErrorId())
+ hashCode = hashCode * 8191 + errorId.hashCode();
- boolean present_creationTime = true && (isSetCreationTime());
- list.add(present_creationTime);
- if (present_creationTime)
- list.add(creationTime);
+ hashCode = hashCode * 8191 + ((isSetCreationTime()) ? 131071 : 524287);
+ if (isSetCreationTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(creationTime);
- boolean present_actualErrorMessage = true && (isSetActualErrorMessage());
- list.add(present_actualErrorMessage);
- if (present_actualErrorMessage)
- list.add(actualErrorMessage);
+ hashCode = hashCode * 8191 + ((isSetActualErrorMessage()) ? 131071 : 524287);
+ if (isSetActualErrorMessage())
+ hashCode = hashCode * 8191 + actualErrorMessage.hashCode();
- boolean present_userFriendlyMessage = true && (isSetUserFriendlyMessage());
- list.add(present_userFriendlyMessage);
- if (present_userFriendlyMessage)
- list.add(userFriendlyMessage);
+ hashCode = hashCode * 8191 + ((isSetUserFriendlyMessage()) ? 131071 : 524287);
+ if (isSetUserFriendlyMessage())
+ hashCode = hashCode * 8191 + userFriendlyMessage.hashCode();
- boolean present_transientOrPersistent = true && (isSetTransientOrPersistent());
- list.add(present_transientOrPersistent);
- if (present_transientOrPersistent)
- list.add(transientOrPersistent);
+ hashCode = hashCode * 8191 + ((isSetTransientOrPersistent()) ? 131071 : 524287);
+ if (isSetTransientOrPersistent())
+ hashCode = hashCode * 8191 + ((transientOrPersistent) ? 131071 : 524287);
- boolean present_rootCauseErrorIdList = true && (isSetRootCauseErrorIdList());
- list.add(present_rootCauseErrorIdList);
- if (present_rootCauseErrorIdList)
- list.add(rootCauseErrorIdList);
+ hashCode = hashCode * 8191 + ((isSetRootCauseErrorIdList()) ? 131071 : 524287);
+ if (isSetRootCauseErrorIdList())
+ hashCode = hashCode * 8191 + rootCauseErrorIdList.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -592,7 +558,7 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetErrorId()).compareTo(other.isSetErrorId());
+ lastComparison = java.lang.Boolean.valueOf(isSetErrorId()).compareTo(other.isSetErrorId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -602,7 +568,7 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCreationTime()).compareTo(other.isSetCreationTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetCreationTime()).compareTo(other.isSetCreationTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -612,7 +578,7 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetActualErrorMessage()).compareTo(other.isSetActualErrorMessage());
+ lastComparison = java.lang.Boolean.valueOf(isSetActualErrorMessage()).compareTo(other.isSetActualErrorMessage());
if (lastComparison != 0) {
return lastComparison;
}
@@ -622,7 +588,7 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUserFriendlyMessage()).compareTo(other.isSetUserFriendlyMessage());
+ lastComparison = java.lang.Boolean.valueOf(isSetUserFriendlyMessage()).compareTo(other.isSetUserFriendlyMessage());
if (lastComparison != 0) {
return lastComparison;
}
@@ -632,7 +598,7 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetTransientOrPersistent()).compareTo(other.isSetTransientOrPersistent());
+ lastComparison = java.lang.Boolean.valueOf(isSetTransientOrPersistent()).compareTo(other.isSetTransientOrPersistent());
if (lastComparison != 0) {
return lastComparison;
}
@@ -642,7 +608,7 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetRootCauseErrorIdList()).compareTo(other.isSetRootCauseErrorIdList());
+ lastComparison = java.lang.Boolean.valueOf(isSetRootCauseErrorIdList()).compareTo(other.isSetRootCauseErrorIdList());
if (lastComparison != 0) {
return lastComparison;
}
@@ -660,16 +626,16 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ErrorModel(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ErrorModel(");
boolean first = true;
sb.append("errorId:");
@@ -742,7 +708,7 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -752,13 +718,13 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
}
}
- private static class ErrorModelStandardSchemeFactory implements SchemeFactory {
+ private static class ErrorModelStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ErrorModelStandardScheme getScheme() {
return new ErrorModelStandardScheme();
}
}
- private static class ErrorModelStandardScheme extends StandardScheme<ErrorModel> {
+ private static class ErrorModelStandardScheme extends org.apache.thrift.scheme.StandardScheme<ErrorModel> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ErrorModel struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -814,8 +780,8 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list0 = iprot.readListBegin();
- struct.rootCauseErrorIdList = new ArrayList<String>(_list0.size);
- String _elem1;
+ struct.rootCauseErrorIdList = new java.util.ArrayList<java.lang.String>(_list0.size);
+ java.lang.String _elem1;
for (int _i2 = 0; _i2 < _list0.size; ++_i2)
{
_elem1 = iprot.readString();
@@ -875,7 +841,7 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
oprot.writeFieldBegin(ROOT_CAUSE_ERROR_ID_LIST_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.rootCauseErrorIdList.size()));
- for (String _iter3 : struct.rootCauseErrorIdList)
+ for (java.lang.String _iter3 : struct.rootCauseErrorIdList)
{
oprot.writeString(_iter3);
}
@@ -890,19 +856,19 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
}
- private static class ErrorModelTupleSchemeFactory implements SchemeFactory {
+ private static class ErrorModelTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ErrorModelTupleScheme getScheme() {
return new ErrorModelTupleScheme();
}
}
- private static class ErrorModelTupleScheme extends TupleScheme<ErrorModel> {
+ private static class ErrorModelTupleScheme extends org.apache.thrift.scheme.TupleScheme<ErrorModel> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ErrorModel struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.errorId);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetCreationTime()) {
optionals.set(0);
}
@@ -934,7 +900,7 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
if (struct.isSetRootCauseErrorIdList()) {
{
oprot.writeI32(struct.rootCauseErrorIdList.size());
- for (String _iter4 : struct.rootCauseErrorIdList)
+ for (java.lang.String _iter4 : struct.rootCauseErrorIdList)
{
oprot.writeString(_iter4);
}
@@ -944,10 +910,10 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ErrorModel struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.errorId = iprot.readString();
struct.setErrorIdIsSet(true);
- BitSet incoming = iprot.readBitSet(5);
+ java.util.BitSet incoming = iprot.readBitSet(5);
if (incoming.get(0)) {
struct.creationTime = iprot.readI64();
struct.setCreationTimeIsSet(true);
@@ -967,8 +933,8 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
if (incoming.get(4)) {
{
org.apache.thrift.protocol.TList _list5 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.rootCauseErrorIdList = new ArrayList<String>(_list5.size);
- String _elem6;
+ struct.rootCauseErrorIdList = new java.util.ArrayList<java.lang.String>(_list5.size);
+ java.lang.String _elem6;
for (int _i7 = 0; _i7 < _list5.size; ++_i7)
{
_elem6 = iprot.readString();
@@ -980,5 +946,8 @@ public class ErrorModel implements org.apache.thrift.TBase<ErrorModel, ErrorMode
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/ValidationResults.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/ValidationResults.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/ValidationResults.java
index 154f28c..c8a3508 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/ValidationResults.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/ValidationResults.java
@@ -16,66 +16,36 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.commons;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class ValidationResults implements org.apache.thrift.TBase<ValidationResults, ValidationResults._Fields>, java.io.Serializable, Cloneable, Comparable<ValidationResults> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ValidationResults");
private static final org.apache.thrift.protocol.TField VALIDATION_STATE_FIELD_DESC = new org.apache.thrift.protocol.TField("validationState", org.apache.thrift.protocol.TType.BOOL, (short)1);
private static final org.apache.thrift.protocol.TField VALIDATION_RESULT_LIST_FIELD_DESC = new org.apache.thrift.protocol.TField("validationResultList", org.apache.thrift.protocol.TType.LIST, (short)2);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new ValidationResultsStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ValidationResultsTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ValidationResultsStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ValidationResultsTupleSchemeFactory();
private boolean validationState; // required
- private List<ValidatorResult> validationResultList; // required
+ private java.util.List<ValidatorResult> validationResultList; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
VALIDATION_STATE((short)1, "validationState"),
VALIDATION_RESULT_LIST((short)2, "validationResultList");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -100,21 +70,21 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -123,7 +93,7 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -131,15 +101,15 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
// isset id assignments
private static final int __VALIDATIONSTATE_ISSET_ID = 0;
private byte __isset_bitfield = 0;
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.VALIDATION_STATE, new org.apache.thrift.meta_data.FieldMetaData("validationState", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
tmpMap.put(_Fields.VALIDATION_RESULT_LIST, new org.apache.thrift.meta_data.FieldMetaData("validationResultList", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ValidatorResult.class))));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ValidationResults.class, metaDataMap);
}
@@ -148,7 +118,7 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
public ValidationResults(
boolean validationState,
- List<ValidatorResult> validationResultList)
+ java.util.List<ValidatorResult> validationResultList)
{
this();
this.validationState = validationState;
@@ -163,7 +133,7 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
__isset_bitfield = other.__isset_bitfield;
this.validationState = other.validationState;
if (other.isSetValidationResultList()) {
- List<ValidatorResult> __this__validationResultList = new ArrayList<ValidatorResult>(other.validationResultList.size());
+ java.util.List<ValidatorResult> __this__validationResultList = new java.util.ArrayList<ValidatorResult>(other.validationResultList.size());
for (ValidatorResult other_element : other.validationResultList) {
__this__validationResultList.add(new ValidatorResult(other_element));
}
@@ -192,16 +162,16 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
}
public void unsetValidationState() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __VALIDATIONSTATE_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __VALIDATIONSTATE_ISSET_ID);
}
/** Returns true if field validationState is set (has been assigned a value) and false otherwise */
public boolean isSetValidationState() {
- return EncodingUtils.testBit(__isset_bitfield, __VALIDATIONSTATE_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __VALIDATIONSTATE_ISSET_ID);
}
public void setValidationStateIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __VALIDATIONSTATE_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __VALIDATIONSTATE_ISSET_ID, value);
}
public int getValidationResultListSize() {
@@ -214,16 +184,16 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
public void addToValidationResultList(ValidatorResult elem) {
if (this.validationResultList == null) {
- this.validationResultList = new ArrayList<ValidatorResult>();
+ this.validationResultList = new java.util.ArrayList<ValidatorResult>();
}
this.validationResultList.add(elem);
}
- public List<ValidatorResult> getValidationResultList() {
+ public java.util.List<ValidatorResult> getValidationResultList() {
return this.validationResultList;
}
- public void setValidationResultList(List<ValidatorResult> validationResultList) {
+ public void setValidationResultList(java.util.List<ValidatorResult> validationResultList) {
this.validationResultList = validationResultList;
}
@@ -242,13 +212,13 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case VALIDATION_STATE:
if (value == null) {
unsetValidationState();
} else {
- setValidationState((Boolean)value);
+ setValidationState((java.lang.Boolean)value);
}
break;
@@ -256,14 +226,14 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
if (value == null) {
unsetValidationResultList();
} else {
- setValidationResultList((List<ValidatorResult>)value);
+ setValidationResultList((java.util.List<ValidatorResult>)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case VALIDATION_STATE:
return isValidationState();
@@ -272,13 +242,13 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
return getValidationResultList();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -287,11 +257,11 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
case VALIDATION_RESULT_LIST:
return isSetValidationResultList();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ValidationResults)
@@ -302,6 +272,8 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
public boolean equals(ValidationResults that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_validationState = true;
boolean that_present_validationState = true;
@@ -326,19 +298,15 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_validationState = true;
- list.add(present_validationState);
- if (present_validationState)
- list.add(validationState);
+ hashCode = hashCode * 8191 + ((validationState) ? 131071 : 524287);
- boolean present_validationResultList = true && (isSetValidationResultList());
- list.add(present_validationResultList);
- if (present_validationResultList)
- list.add(validationResultList);
+ hashCode = hashCode * 8191 + ((isSetValidationResultList()) ? 131071 : 524287);
+ if (isSetValidationResultList())
+ hashCode = hashCode * 8191 + validationResultList.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -349,7 +317,7 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetValidationState()).compareTo(other.isSetValidationState());
+ lastComparison = java.lang.Boolean.valueOf(isSetValidationState()).compareTo(other.isSetValidationState());
if (lastComparison != 0) {
return lastComparison;
}
@@ -359,7 +327,7 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetValidationResultList()).compareTo(other.isSetValidationResultList());
+ lastComparison = java.lang.Boolean.valueOf(isSetValidationResultList()).compareTo(other.isSetValidationResultList());
if (lastComparison != 0) {
return lastComparison;
}
@@ -377,16 +345,16 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ValidationResults(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ValidationResults(");
boolean first = true;
sb.append("validationState:");
@@ -425,7 +393,7 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -435,13 +403,13 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
}
}
- private static class ValidationResultsStandardSchemeFactory implements SchemeFactory {
+ private static class ValidationResultsStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ValidationResultsStandardScheme getScheme() {
return new ValidationResultsStandardScheme();
}
}
- private static class ValidationResultsStandardScheme extends StandardScheme<ValidationResults> {
+ private static class ValidationResultsStandardScheme extends org.apache.thrift.scheme.StandardScheme<ValidationResults> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ValidationResults struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -465,7 +433,7 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list8 = iprot.readListBegin();
- struct.validationResultList = new ArrayList<ValidatorResult>(_list8.size);
+ struct.validationResultList = new java.util.ArrayList<ValidatorResult>(_list8.size);
ValidatorResult _elem9;
for (int _i10 = 0; _i10 < _list8.size; ++_i10)
{
@@ -514,17 +482,17 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
}
- private static class ValidationResultsTupleSchemeFactory implements SchemeFactory {
+ private static class ValidationResultsTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ValidationResultsTupleScheme getScheme() {
return new ValidationResultsTupleScheme();
}
}
- private static class ValidationResultsTupleScheme extends TupleScheme<ValidationResults> {
+ private static class ValidationResultsTupleScheme extends org.apache.thrift.scheme.TupleScheme<ValidationResults> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ValidationResults struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeBool(struct.validationState);
{
oprot.writeI32(struct.validationResultList.size());
@@ -537,12 +505,12 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ValidationResults struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.validationState = iprot.readBool();
struct.setValidationStateIsSet(true);
{
org.apache.thrift.protocol.TList _list13 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.validationResultList = new ArrayList<ValidatorResult>(_list13.size);
+ struct.validationResultList = new java.util.ArrayList<ValidatorResult>(_list13.size);
ValidatorResult _elem14;
for (int _i15 = 0; _i15 < _list13.size; ++_i15)
{
@@ -555,5 +523,8 @@ public class ValidationResults implements org.apache.thrift.TBase<ValidationResu
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/ValidatorResult.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/ValidatorResult.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/ValidatorResult.java
index 1ef9ee3..c283846 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/ValidatorResult.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/ValidatorResult.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.commons;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* This data structure can be used to store the validation results
* captured during validation step and during the launchExperiment
@@ -58,31 +31,28 @@ import org.slf4j.LoggerFactory;
* during the experiment launch operation
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult, ValidatorResult._Fields>, java.io.Serializable, Cloneable, Comparable<ValidatorResult> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ValidatorResult");
private static final org.apache.thrift.protocol.TField RESULT_FIELD_DESC = new org.apache.thrift.protocol.TField("result", org.apache.thrift.protocol.TType.BOOL, (short)1);
private static final org.apache.thrift.protocol.TField ERROR_DETAILS_FIELD_DESC = new org.apache.thrift.protocol.TField("errorDetails", org.apache.thrift.protocol.TType.STRING, (short)2);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new ValidatorResultStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ValidatorResultTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ValidatorResultStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ValidatorResultTupleSchemeFactory();
private boolean result; // required
- private String errorDetails; // optional
+ private java.lang.String errorDetails; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
RESULT((short)1, "result"),
ERROR_DETAILS((short)2, "errorDetails");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -107,21 +77,21 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -130,7 +100,7 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -139,14 +109,14 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
private static final int __RESULT_ISSET_ID = 0;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.ERROR_DETAILS};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.RESULT, new org.apache.thrift.meta_data.FieldMetaData("result", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
tmpMap.put(_Fields.ERROR_DETAILS, new org.apache.thrift.meta_data.FieldMetaData("errorDetails", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ValidatorResult.class, metaDataMap);
}
@@ -193,23 +163,23 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
}
public void unsetResult() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __RESULT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __RESULT_ISSET_ID);
}
/** Returns true if field result is set (has been assigned a value) and false otherwise */
public boolean isSetResult() {
- return EncodingUtils.testBit(__isset_bitfield, __RESULT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __RESULT_ISSET_ID);
}
public void setResultIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __RESULT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __RESULT_ISSET_ID, value);
}
- public String getErrorDetails() {
+ public java.lang.String getErrorDetails() {
return this.errorDetails;
}
- public void setErrorDetails(String errorDetails) {
+ public void setErrorDetails(java.lang.String errorDetails) {
this.errorDetails = errorDetails;
}
@@ -228,13 +198,13 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case RESULT:
if (value == null) {
unsetResult();
} else {
- setResult((Boolean)value);
+ setResult((java.lang.Boolean)value);
}
break;
@@ -242,14 +212,14 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
if (value == null) {
unsetErrorDetails();
} else {
- setErrorDetails((String)value);
+ setErrorDetails((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case RESULT:
return isResult();
@@ -258,13 +228,13 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
return getErrorDetails();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -273,11 +243,11 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
case ERROR_DETAILS:
return isSetErrorDetails();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ValidatorResult)
@@ -288,6 +258,8 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
public boolean equals(ValidatorResult that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_result = true;
boolean that_present_result = true;
@@ -312,19 +284,15 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_result = true;
- list.add(present_result);
- if (present_result)
- list.add(result);
+ hashCode = hashCode * 8191 + ((result) ? 131071 : 524287);
- boolean present_errorDetails = true && (isSetErrorDetails());
- list.add(present_errorDetails);
- if (present_errorDetails)
- list.add(errorDetails);
+ hashCode = hashCode * 8191 + ((isSetErrorDetails()) ? 131071 : 524287);
+ if (isSetErrorDetails())
+ hashCode = hashCode * 8191 + errorDetails.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -335,7 +303,7 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetResult()).compareTo(other.isSetResult());
+ lastComparison = java.lang.Boolean.valueOf(isSetResult()).compareTo(other.isSetResult());
if (lastComparison != 0) {
return lastComparison;
}
@@ -345,7 +313,7 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetErrorDetails()).compareTo(other.isSetErrorDetails());
+ lastComparison = java.lang.Boolean.valueOf(isSetErrorDetails()).compareTo(other.isSetErrorDetails());
if (lastComparison != 0) {
return lastComparison;
}
@@ -363,16 +331,16 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ValidatorResult(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ValidatorResult(");
boolean first = true;
sb.append("result:");
@@ -409,7 +377,7 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -419,13 +387,13 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
}
}
- private static class ValidatorResultStandardSchemeFactory implements SchemeFactory {
+ private static class ValidatorResultStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ValidatorResultStandardScheme getScheme() {
return new ValidatorResultStandardScheme();
}
}
- private static class ValidatorResultStandardScheme extends StandardScheme<ValidatorResult> {
+ private static class ValidatorResultStandardScheme extends org.apache.thrift.scheme.StandardScheme<ValidatorResult> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ValidatorResult struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -482,19 +450,19 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
}
- private static class ValidatorResultTupleSchemeFactory implements SchemeFactory {
+ private static class ValidatorResultTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ValidatorResultTupleScheme getScheme() {
return new ValidatorResultTupleScheme();
}
}
- private static class ValidatorResultTupleScheme extends TupleScheme<ValidatorResult> {
+ private static class ValidatorResultTupleScheme extends org.apache.thrift.scheme.TupleScheme<ValidatorResult> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ValidatorResult struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeBool(struct.result);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetErrorDetails()) {
optionals.set(0);
}
@@ -506,10 +474,10 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ValidatorResult struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.result = iprot.readBool();
struct.setResultIsSet(true);
- BitSet incoming = iprot.readBitSet(1);
+ java.util.BitSet incoming = iprot.readBitSet(1);
if (incoming.get(0)) {
struct.errorDetails = iprot.readString();
struct.setErrorDetailsIsSet(true);
@@ -517,5 +485,8 @@ public class ValidatorResult implements org.apache.thrift.TBase<ValidatorResult,
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/airavata_commonsConstants.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/airavata_commonsConstants.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/airavata_commonsConstants.java
index c8be61d..9759c32 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/airavata_commonsConstants.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/commons/airavata_commonsConstants.java
@@ -16,43 +16,16 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.commons;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
public class airavata_commonsConstants {
- public static final String DEFAULT_ID = "DO_NOT_SET_AT_CLIENTS";
+ public static final java.lang.String DEFAULT_ID = "DO_NOT_SET_AT_CLIENTS";
}
[25/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/EdgeModel.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/EdgeModel.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/EdgeModel.java
index 949692b..6262132 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/EdgeModel.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/EdgeModel.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._Fields>, java.io.Serializable, Cloneable, Comparable<EdgeModel> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("EdgeModel");
@@ -60,16 +33,13 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
private static final org.apache.thrift.protocol.TField STATUS_FIELD_DESC = new org.apache.thrift.protocol.TField("status", org.apache.thrift.protocol.TType.STRUCT, (short)3);
private static final org.apache.thrift.protocol.TField DESCRIPTION_FIELD_DESC = new org.apache.thrift.protocol.TField("description", 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 EdgeModelStandardSchemeFactory());
- schemes.put(TupleScheme.class, new EdgeModelTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new EdgeModelStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new EdgeModelTupleSchemeFactory();
- private String edgeId; // required
- private String name; // optional
+ private java.lang.String edgeId; // required
+ private java.lang.String name; // optional
private ComponentStatus status; // optional
- private String description; // optional
+ private java.lang.String description; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -78,10 +48,10 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
STATUS((short)3, "status"),
DESCRIPTION((short)4, "description");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -110,21 +80,21 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -133,16 +103,16 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
private static final _Fields optionals[] = {_Fields.NAME,_Fields.STATUS,_Fields.DESCRIPTION};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.EDGE_ID, new org.apache.thrift.meta_data.FieldMetaData("edgeId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.NAME, new org.apache.thrift.meta_data.FieldMetaData("name", org.apache.thrift.TFieldRequirementType.OPTIONAL,
@@ -151,7 +121,7 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ComponentStatus.class)));
tmpMap.put(_Fields.DESCRIPTION, new org.apache.thrift.meta_data.FieldMetaData("description", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(EdgeModel.class, metaDataMap);
}
@@ -161,7 +131,7 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
}
public EdgeModel(
- String edgeId)
+ java.lang.String edgeId)
{
this();
this.edgeId = edgeId;
@@ -198,11 +168,11 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
this.description = null;
}
- public String getEdgeId() {
+ public java.lang.String getEdgeId() {
return this.edgeId;
}
- public void setEdgeId(String edgeId) {
+ public void setEdgeId(java.lang.String edgeId) {
this.edgeId = edgeId;
}
@@ -221,11 +191,11 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
}
}
- public String getName() {
+ public java.lang.String getName() {
return this.name;
}
- public void setName(String name) {
+ public void setName(java.lang.String name) {
this.name = name;
}
@@ -267,11 +237,11 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
}
}
- public String getDescription() {
+ public java.lang.String getDescription() {
return this.description;
}
- public void setDescription(String description) {
+ public void setDescription(java.lang.String description) {
this.description = description;
}
@@ -290,13 +260,13 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case EDGE_ID:
if (value == null) {
unsetEdgeId();
} else {
- setEdgeId((String)value);
+ setEdgeId((java.lang.String)value);
}
break;
@@ -304,7 +274,7 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
if (value == null) {
unsetName();
} else {
- setName((String)value);
+ setName((java.lang.String)value);
}
break;
@@ -320,14 +290,14 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
if (value == null) {
unsetDescription();
} else {
- setDescription((String)value);
+ setDescription((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case EDGE_ID:
return getEdgeId();
@@ -342,13 +312,13 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
return getDescription();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -361,11 +331,11 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
case DESCRIPTION:
return isSetDescription();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof EdgeModel)
@@ -376,6 +346,8 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
public boolean equals(EdgeModel that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_edgeId = true && this.isSetEdgeId();
boolean that_present_edgeId = true && that.isSetEdgeId();
@@ -418,29 +390,25 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_edgeId = true && (isSetEdgeId());
- list.add(present_edgeId);
- if (present_edgeId)
- list.add(edgeId);
+ hashCode = hashCode * 8191 + ((isSetEdgeId()) ? 131071 : 524287);
+ if (isSetEdgeId())
+ hashCode = hashCode * 8191 + edgeId.hashCode();
- boolean present_name = true && (isSetName());
- list.add(present_name);
- if (present_name)
- list.add(name);
+ hashCode = hashCode * 8191 + ((isSetName()) ? 131071 : 524287);
+ if (isSetName())
+ hashCode = hashCode * 8191 + name.hashCode();
- boolean present_status = true && (isSetStatus());
- list.add(present_status);
- if (present_status)
- list.add(status);
+ hashCode = hashCode * 8191 + ((isSetStatus()) ? 131071 : 524287);
+ if (isSetStatus())
+ hashCode = hashCode * 8191 + status.hashCode();
- boolean present_description = true && (isSetDescription());
- list.add(present_description);
- if (present_description)
- list.add(description);
+ hashCode = hashCode * 8191 + ((isSetDescription()) ? 131071 : 524287);
+ if (isSetDescription())
+ hashCode = hashCode * 8191 + description.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -451,7 +419,7 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetEdgeId()).compareTo(other.isSetEdgeId());
+ lastComparison = java.lang.Boolean.valueOf(isSetEdgeId()).compareTo(other.isSetEdgeId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -461,7 +429,7 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetName()).compareTo(other.isSetName());
+ lastComparison = java.lang.Boolean.valueOf(isSetName()).compareTo(other.isSetName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -471,7 +439,7 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetStatus()).compareTo(other.isSetStatus());
+ lastComparison = java.lang.Boolean.valueOf(isSetStatus()).compareTo(other.isSetStatus());
if (lastComparison != 0) {
return lastComparison;
}
@@ -481,7 +449,7 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -499,16 +467,16 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("EdgeModel(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("EdgeModel(");
boolean first = true;
sb.append("edgeId:");
@@ -572,7 +540,7 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -580,13 +548,13 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
}
}
- private static class EdgeModelStandardSchemeFactory implements SchemeFactory {
+ private static class EdgeModelStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public EdgeModelStandardScheme getScheme() {
return new EdgeModelStandardScheme();
}
}
- private static class EdgeModelStandardScheme extends StandardScheme<EdgeModel> {
+ private static class EdgeModelStandardScheme extends org.apache.thrift.scheme.StandardScheme<EdgeModel> {
public void read(org.apache.thrift.protocol.TProtocol iprot, EdgeModel struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -676,19 +644,19 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
}
- private static class EdgeModelTupleSchemeFactory implements SchemeFactory {
+ private static class EdgeModelTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public EdgeModelTupleScheme getScheme() {
return new EdgeModelTupleScheme();
}
}
- private static class EdgeModelTupleScheme extends TupleScheme<EdgeModel> {
+ private static class EdgeModelTupleScheme extends org.apache.thrift.scheme.TupleScheme<EdgeModel> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, EdgeModel struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.edgeId);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetName()) {
optionals.set(0);
}
@@ -712,10 +680,10 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, EdgeModel struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.edgeId = iprot.readString();
struct.setEdgeIdIsSet(true);
- BitSet incoming = iprot.readBitSet(3);
+ java.util.BitSet incoming = iprot.readBitSet(3);
if (incoming.get(0)) {
struct.name = iprot.readString();
struct.setNameIsSet(true);
@@ -732,5 +700,8 @@ public class EdgeModel implements org.apache.thrift.TBase<EdgeModel, EdgeModel._
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/NodeModel.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/NodeModel.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/NodeModel.java
index ea24faa..9063a00 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/NodeModel.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/NodeModel.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._Fields>, java.io.Serializable, Cloneable, Comparable<NodeModel> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("NodeModel");
@@ -62,18 +35,15 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
private static final org.apache.thrift.protocol.TField STATUS_FIELD_DESC = new org.apache.thrift.protocol.TField("status", org.apache.thrift.protocol.TType.STRUCT, (short)5);
private static final org.apache.thrift.protocol.TField DESCRIPTION_FIELD_DESC = new org.apache.thrift.protocol.TField("description", org.apache.thrift.protocol.TType.STRING, (short)6);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new NodeModelStandardSchemeFactory());
- schemes.put(TupleScheme.class, new NodeModelTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new NodeModelStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new NodeModelTupleSchemeFactory();
- private String nodeId; // required
- private String name; // optional
- private String applicationId; // optional
- private String applicationName; // optional
+ private java.lang.String nodeId; // required
+ private java.lang.String name; // optional
+ private java.lang.String applicationId; // optional
+ private java.lang.String applicationName; // optional
private ComponentStatus status; // optional
- private String description; // optional
+ private java.lang.String description; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -84,10 +54,10 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
STATUS((short)5, "status"),
DESCRIPTION((short)6, "description");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -120,21 +90,21 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -143,16 +113,16 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
private static final _Fields optionals[] = {_Fields.NAME,_Fields.APPLICATION_ID,_Fields.APPLICATION_NAME,_Fields.STATUS,_Fields.DESCRIPTION};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.NODE_ID, new org.apache.thrift.meta_data.FieldMetaData("nodeId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.NAME, new org.apache.thrift.meta_data.FieldMetaData("name", org.apache.thrift.TFieldRequirementType.OPTIONAL,
@@ -165,7 +135,7 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ComponentStatus.class)));
tmpMap.put(_Fields.DESCRIPTION, new org.apache.thrift.meta_data.FieldMetaData("description", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(NodeModel.class, metaDataMap);
}
@@ -175,7 +145,7 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
}
public NodeModel(
- String nodeId)
+ java.lang.String nodeId)
{
this();
this.nodeId = nodeId;
@@ -220,11 +190,11 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
this.description = null;
}
- public String getNodeId() {
+ public java.lang.String getNodeId() {
return this.nodeId;
}
- public void setNodeId(String nodeId) {
+ public void setNodeId(java.lang.String nodeId) {
this.nodeId = nodeId;
}
@@ -243,11 +213,11 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
}
}
- public String getName() {
+ public java.lang.String getName() {
return this.name;
}
- public void setName(String name) {
+ public void setName(java.lang.String name) {
this.name = name;
}
@@ -266,11 +236,11 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
}
}
- public String getApplicationId() {
+ public java.lang.String getApplicationId() {
return this.applicationId;
}
- public void setApplicationId(String applicationId) {
+ public void setApplicationId(java.lang.String applicationId) {
this.applicationId = applicationId;
}
@@ -289,11 +259,11 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
}
}
- public String getApplicationName() {
+ public java.lang.String getApplicationName() {
return this.applicationName;
}
- public void setApplicationName(String applicationName) {
+ public void setApplicationName(java.lang.String applicationName) {
this.applicationName = applicationName;
}
@@ -335,11 +305,11 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
}
}
- public String getDescription() {
+ public java.lang.String getDescription() {
return this.description;
}
- public void setDescription(String description) {
+ public void setDescription(java.lang.String description) {
this.description = description;
}
@@ -358,13 +328,13 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case NODE_ID:
if (value == null) {
unsetNodeId();
} else {
- setNodeId((String)value);
+ setNodeId((java.lang.String)value);
}
break;
@@ -372,7 +342,7 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
if (value == null) {
unsetName();
} else {
- setName((String)value);
+ setName((java.lang.String)value);
}
break;
@@ -380,7 +350,7 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
if (value == null) {
unsetApplicationId();
} else {
- setApplicationId((String)value);
+ setApplicationId((java.lang.String)value);
}
break;
@@ -388,7 +358,7 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
if (value == null) {
unsetApplicationName();
} else {
- setApplicationName((String)value);
+ setApplicationName((java.lang.String)value);
}
break;
@@ -404,14 +374,14 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
if (value == null) {
unsetDescription();
} else {
- setDescription((String)value);
+ setDescription((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case NODE_ID:
return getNodeId();
@@ -432,13 +402,13 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
return getDescription();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -455,11 +425,11 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
case DESCRIPTION:
return isSetDescription();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof NodeModel)
@@ -470,6 +440,8 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
public boolean equals(NodeModel that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_nodeId = true && this.isSetNodeId();
boolean that_present_nodeId = true && that.isSetNodeId();
@@ -530,39 +502,33 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_nodeId = true && (isSetNodeId());
- list.add(present_nodeId);
- if (present_nodeId)
- list.add(nodeId);
+ hashCode = hashCode * 8191 + ((isSetNodeId()) ? 131071 : 524287);
+ if (isSetNodeId())
+ hashCode = hashCode * 8191 + nodeId.hashCode();
- boolean present_name = true && (isSetName());
- list.add(present_name);
- if (present_name)
- list.add(name);
+ hashCode = hashCode * 8191 + ((isSetName()) ? 131071 : 524287);
+ if (isSetName())
+ hashCode = hashCode * 8191 + name.hashCode();
- boolean present_applicationId = true && (isSetApplicationId());
- list.add(present_applicationId);
- if (present_applicationId)
- list.add(applicationId);
+ hashCode = hashCode * 8191 + ((isSetApplicationId()) ? 131071 : 524287);
+ if (isSetApplicationId())
+ hashCode = hashCode * 8191 + applicationId.hashCode();
- boolean present_applicationName = true && (isSetApplicationName());
- list.add(present_applicationName);
- if (present_applicationName)
- list.add(applicationName);
+ hashCode = hashCode * 8191 + ((isSetApplicationName()) ? 131071 : 524287);
+ if (isSetApplicationName())
+ hashCode = hashCode * 8191 + applicationName.hashCode();
- boolean present_status = true && (isSetStatus());
- list.add(present_status);
- if (present_status)
- list.add(status);
+ hashCode = hashCode * 8191 + ((isSetStatus()) ? 131071 : 524287);
+ if (isSetStatus())
+ hashCode = hashCode * 8191 + status.hashCode();
- boolean present_description = true && (isSetDescription());
- list.add(present_description);
- if (present_description)
- list.add(description);
+ hashCode = hashCode * 8191 + ((isSetDescription()) ? 131071 : 524287);
+ if (isSetDescription())
+ hashCode = hashCode * 8191 + description.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -573,7 +539,7 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetNodeId()).compareTo(other.isSetNodeId());
+ lastComparison = java.lang.Boolean.valueOf(isSetNodeId()).compareTo(other.isSetNodeId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -583,7 +549,7 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetName()).compareTo(other.isSetName());
+ lastComparison = java.lang.Boolean.valueOf(isSetName()).compareTo(other.isSetName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -593,7 +559,7 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetApplicationId()).compareTo(other.isSetApplicationId());
+ lastComparison = java.lang.Boolean.valueOf(isSetApplicationId()).compareTo(other.isSetApplicationId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -603,7 +569,7 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetApplicationName()).compareTo(other.isSetApplicationName());
+ lastComparison = java.lang.Boolean.valueOf(isSetApplicationName()).compareTo(other.isSetApplicationName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -613,7 +579,7 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetStatus()).compareTo(other.isSetStatus());
+ lastComparison = java.lang.Boolean.valueOf(isSetStatus()).compareTo(other.isSetStatus());
if (lastComparison != 0) {
return lastComparison;
}
@@ -623,7 +589,7 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -641,16 +607,16 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("NodeModel(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("NodeModel(");
boolean first = true;
sb.append("nodeId:");
@@ -734,7 +700,7 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -742,13 +708,13 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
}
}
- private static class NodeModelStandardSchemeFactory implements SchemeFactory {
+ private static class NodeModelStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public NodeModelStandardScheme getScheme() {
return new NodeModelStandardScheme();
}
}
- private static class NodeModelStandardScheme extends StandardScheme<NodeModel> {
+ private static class NodeModelStandardScheme extends org.apache.thrift.scheme.StandardScheme<NodeModel> {
public void read(org.apache.thrift.protocol.TProtocol iprot, NodeModel struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -868,19 +834,19 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
}
- private static class NodeModelTupleSchemeFactory implements SchemeFactory {
+ private static class NodeModelTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public NodeModelTupleScheme getScheme() {
return new NodeModelTupleScheme();
}
}
- private static class NodeModelTupleScheme extends TupleScheme<NodeModel> {
+ private static class NodeModelTupleScheme extends org.apache.thrift.scheme.TupleScheme<NodeModel> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, NodeModel struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.nodeId);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetName()) {
optionals.set(0);
}
@@ -916,10 +882,10 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, NodeModel struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.nodeId = iprot.readString();
struct.setNodeIdIsSet(true);
- BitSet incoming = iprot.readBitSet(5);
+ java.util.BitSet incoming = iprot.readBitSet(5);
if (incoming.get(0)) {
struct.name = iprot.readString();
struct.setNameIsSet(true);
@@ -944,5 +910,8 @@ public class NodeModel implements org.apache.thrift.TBase<NodeModel, NodeModel._
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/PortModel.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/PortModel.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/PortModel.java
index 54b3391..f619cbf 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/PortModel.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/PortModel.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._Fields>, java.io.Serializable, Cloneable, Comparable<PortModel> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("PortModel");
@@ -61,17 +34,14 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
private static final org.apache.thrift.protocol.TField VALUE_FIELD_DESC = new org.apache.thrift.protocol.TField("value", org.apache.thrift.protocol.TType.STRING, (short)4);
private static final org.apache.thrift.protocol.TField DESCRIPTION_FIELD_DESC = new org.apache.thrift.protocol.TField("description", org.apache.thrift.protocol.TType.STRING, (short)5);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new PortModelStandardSchemeFactory());
- schemes.put(TupleScheme.class, new PortModelTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new PortModelStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new PortModelTupleSchemeFactory();
- private String portId; // required
- private String name; // optional
+ private java.lang.String portId; // required
+ private java.lang.String name; // optional
private ComponentStatus status; // optional
- private String value; // optional
- private String description; // optional
+ private java.lang.String value; // optional
+ private java.lang.String description; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -81,10 +51,10 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
VALUE((short)4, "value"),
DESCRIPTION((short)5, "description");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -115,21 +85,21 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -138,16 +108,16 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
private static final _Fields optionals[] = {_Fields.NAME,_Fields.STATUS,_Fields.VALUE,_Fields.DESCRIPTION};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.PORT_ID, new org.apache.thrift.meta_data.FieldMetaData("portId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.NAME, new org.apache.thrift.meta_data.FieldMetaData("name", org.apache.thrift.TFieldRequirementType.OPTIONAL,
@@ -158,7 +128,7 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.DESCRIPTION, new org.apache.thrift.meta_data.FieldMetaData("description", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(PortModel.class, metaDataMap);
}
@@ -168,7 +138,7 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
}
public PortModel(
- String portId)
+ java.lang.String portId)
{
this();
this.portId = portId;
@@ -209,11 +179,11 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
this.description = null;
}
- public String getPortId() {
+ public java.lang.String getPortId() {
return this.portId;
}
- public void setPortId(String portId) {
+ public void setPortId(java.lang.String portId) {
this.portId = portId;
}
@@ -232,11 +202,11 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
}
}
- public String getName() {
+ public java.lang.String getName() {
return this.name;
}
- public void setName(String name) {
+ public void setName(java.lang.String name) {
this.name = name;
}
@@ -278,11 +248,11 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
}
}
- public String getValue() {
+ public java.lang.String getValue() {
return this.value;
}
- public void setValue(String value) {
+ public void setValue(java.lang.String value) {
this.value = value;
}
@@ -301,11 +271,11 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
}
}
- public String getDescription() {
+ public java.lang.String getDescription() {
return this.description;
}
- public void setDescription(String description) {
+ public void setDescription(java.lang.String description) {
this.description = description;
}
@@ -324,13 +294,13 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case PORT_ID:
if (value == null) {
unsetPortId();
} else {
- setPortId((String)value);
+ setPortId((java.lang.String)value);
}
break;
@@ -338,7 +308,7 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
if (value == null) {
unsetName();
} else {
- setName((String)value);
+ setName((java.lang.String)value);
}
break;
@@ -354,7 +324,7 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
if (value == null) {
unsetValue();
} else {
- setValue((String)value);
+ setValue((java.lang.String)value);
}
break;
@@ -362,14 +332,14 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
if (value == null) {
unsetDescription();
} else {
- setDescription((String)value);
+ setDescription((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case PORT_ID:
return getPortId();
@@ -387,13 +357,13 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
return getDescription();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -408,11 +378,11 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
case DESCRIPTION:
return isSetDescription();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof PortModel)
@@ -423,6 +393,8 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
public boolean equals(PortModel that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_portId = true && this.isSetPortId();
boolean that_present_portId = true && that.isSetPortId();
@@ -474,34 +446,29 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_portId = true && (isSetPortId());
- list.add(present_portId);
- if (present_portId)
- list.add(portId);
+ hashCode = hashCode * 8191 + ((isSetPortId()) ? 131071 : 524287);
+ if (isSetPortId())
+ hashCode = hashCode * 8191 + portId.hashCode();
- boolean present_name = true && (isSetName());
- list.add(present_name);
- if (present_name)
- list.add(name);
+ hashCode = hashCode * 8191 + ((isSetName()) ? 131071 : 524287);
+ if (isSetName())
+ hashCode = hashCode * 8191 + name.hashCode();
- boolean present_status = true && (isSetStatus());
- list.add(present_status);
- if (present_status)
- list.add(status);
+ hashCode = hashCode * 8191 + ((isSetStatus()) ? 131071 : 524287);
+ if (isSetStatus())
+ hashCode = hashCode * 8191 + status.hashCode();
- boolean present_value = true && (isSetValue());
- list.add(present_value);
- if (present_value)
- list.add(value);
+ hashCode = hashCode * 8191 + ((isSetValue()) ? 131071 : 524287);
+ if (isSetValue())
+ hashCode = hashCode * 8191 + value.hashCode();
- boolean present_description = true && (isSetDescription());
- list.add(present_description);
- if (present_description)
- list.add(description);
+ hashCode = hashCode * 8191 + ((isSetDescription()) ? 131071 : 524287);
+ if (isSetDescription())
+ hashCode = hashCode * 8191 + description.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -512,7 +479,7 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetPortId()).compareTo(other.isSetPortId());
+ lastComparison = java.lang.Boolean.valueOf(isSetPortId()).compareTo(other.isSetPortId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -522,7 +489,7 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetName()).compareTo(other.isSetName());
+ lastComparison = java.lang.Boolean.valueOf(isSetName()).compareTo(other.isSetName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -532,7 +499,7 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetStatus()).compareTo(other.isSetStatus());
+ lastComparison = java.lang.Boolean.valueOf(isSetStatus()).compareTo(other.isSetStatus());
if (lastComparison != 0) {
return lastComparison;
}
@@ -542,7 +509,7 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetValue()).compareTo(other.isSetValue());
+ lastComparison = java.lang.Boolean.valueOf(isSetValue()).compareTo(other.isSetValue());
if (lastComparison != 0) {
return lastComparison;
}
@@ -552,7 +519,7 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -570,16 +537,16 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("PortModel(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("PortModel(");
boolean first = true;
sb.append("portId:");
@@ -653,7 +620,7 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -661,13 +628,13 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
}
}
- private static class PortModelStandardSchemeFactory implements SchemeFactory {
+ private static class PortModelStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public PortModelStandardScheme getScheme() {
return new PortModelStandardScheme();
}
}
- private static class PortModelStandardScheme extends StandardScheme<PortModel> {
+ private static class PortModelStandardScheme extends org.apache.thrift.scheme.StandardScheme<PortModel> {
public void read(org.apache.thrift.protocol.TProtocol iprot, PortModel struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -772,19 +739,19 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
}
- private static class PortModelTupleSchemeFactory implements SchemeFactory {
+ private static class PortModelTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public PortModelTupleScheme getScheme() {
return new PortModelTupleScheme();
}
}
- private static class PortModelTupleScheme extends TupleScheme<PortModel> {
+ private static class PortModelTupleScheme extends org.apache.thrift.scheme.TupleScheme<PortModel> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, PortModel struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.portId);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetName()) {
optionals.set(0);
}
@@ -814,10 +781,10 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, PortModel struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.portId = iprot.readString();
struct.setPortIdIsSet(true);
- BitSet incoming = iprot.readBitSet(4);
+ java.util.BitSet incoming = iprot.readBitSet(4);
if (incoming.get(0)) {
struct.name = iprot.readString();
struct.setNameIsSet(true);
@@ -838,5 +805,8 @@ public class PortModel implements org.apache.thrift.TBase<PortModel, PortModel._
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
[49/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-api-stubs/src/main/java/org/apache/airavata/api/airavata_apiConstants.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-api-stubs/src/main/java/org/apache/airavata/api/airavata_apiConstants.java b/airavata-api/airavata-api-stubs/src/main/java/org/apache/airavata/api/airavata_apiConstants.java
index f8e87d8..fbb2e2f 100644
--- a/airavata-api/airavata-api-stubs/src/main/java/org/apache/airavata/api/airavata_apiConstants.java
+++ b/airavata-api/airavata-api-stubs/src/main/java/org/apache/airavata/api/airavata_apiConstants.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.api;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
public class airavata_apiConstants {
/**
@@ -67,6 +40,6 @@ public class airavata_apiConstants {
* in a change to major/minor version numbers.
*
*/
- public static final String AIRAVATA_API_VERSION = "0.17.0";
+ public static final java.lang.String AIRAVATA_API_VERSION = "0.17.0";
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Airavata.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Airavata.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Airavata.php
index 18bfcf5..f191dac 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Airavata.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Airavata.php
@@ -1,7 +1,7 @@
<?php
namespace Airavata\API;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
@@ -4095,6 +4095,7 @@ interface AiravataIf {
public function getAllGroupsUserBelongs(\Airavata\Model\Security\AuthzToken $authzToken, $userName);
}
+
class AiravataClient implements \Airavata\API\AiravataIf {
protected $input_ = null;
protected $output_ = null;
@@ -15053,6 +15054,7 @@ class AiravataClient implements \Airavata\API\AiravataIf {
}
+
// HELPER FUNCTIONS AND STRUCTURES
class Airavata_getAPIVersion_args {
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Error/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Error/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Error/Types.php
index 0b5258d..97cedfa 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Error/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Error/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\API\Error;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Sharing/SharingRegistryService.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Sharing/SharingRegistryService.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Sharing/SharingRegistryService.php
index ec3afd2..e20d2a7 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Sharing/SharingRegistryService.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Sharing/SharingRegistryService.php
@@ -1,7 +1,7 @@
<?php
namespace Airavata\API\Sharing;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
@@ -550,6 +550,7 @@ interface SharingRegistryServiceIf {
public function userHasAccess($domainId, $userId, $entityId, $permissionTypeId);
}
+
class SharingRegistryServiceClient implements \Airavata\API\Sharing\SharingRegistryServiceIf {
protected $input_ = null;
protected $output_ = null;
@@ -3336,6 +3337,7 @@ class SharingRegistryServiceClient implements \Airavata\API\Sharing\SharingRegis
}
+
// HELPER FUNCTIONS AND STRUCTURES
class SharingRegistryService_createDomain_args {
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Sharing/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Sharing/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Sharing/Types.php
index 56a6860..050b73e 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Sharing/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Sharing/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\API\Sharing;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Types.php
index 84e30af..f1235c6 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/API/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\API;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/AppDeployment/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/AppDeployment/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/AppDeployment/Types.php
index abcb322..32ab54a 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/AppDeployment/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/AppDeployment/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\AppCatalog\AppDeployment;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/AppInterface/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/AppInterface/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/AppInterface/Types.php
index 2477b43..644539f 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/AppInterface/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/AppInterface/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\AppCatalog\AppInterface;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/ComputeResource/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/ComputeResource/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/ComputeResource/Types.php
index 47e6e24..d42d05f 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/ComputeResource/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/ComputeResource/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\AppCatalog\ComputeResource;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/GatewayProfile/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/GatewayProfile/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/GatewayProfile/Types.php
index f0b329d..eaeb533 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/GatewayProfile/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/GatewayProfile/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\AppCatalog\GatewayProfile;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/Parallelism/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/Parallelism/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/Parallelism/Types.php
index e633a53..1b55232 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/Parallelism/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/Parallelism/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\AppCatalog\Parallelism;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/StorageResource/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/StorageResource/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/StorageResource/Types.php
index 93df378..ed1a4f8 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/StorageResource/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/StorageResource/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\AppCatalog\StorageResource;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/UserResourceProfile/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/UserResourceProfile/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/UserResourceProfile/Types.php
index 8ab78a0..1dc625a 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/UserResourceProfile/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/AppCatalog/UserResourceProfile/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\AppCatalog\UserResourceProfile;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Application/Io/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Application/Io/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Application/Io/Types.php
index b8bdf76..c417a5b 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Application/Io/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Application/Io/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Application\Io;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Commons/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Commons/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Commons/Types.php
index ecc9532..2f657fe 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Commons/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Commons/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Commons;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Credential/Store/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Credential/Store/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Credential/Store/Types.php
index 861403d..625b8c7 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Credential/Store/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Credential/Store/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Credential\Store;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Data/Movement/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Data/Movement/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Data/Movement/Types.php
index 274a4a8..6a6c1c1 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Data/Movement/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Data/Movement/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Data\Movement;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Data/Replica/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Data/Replica/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Data/Replica/Types.php
index d6e208e..295c058 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Data/Replica/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Data/Replica/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Data\Replica;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Dbevent/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Dbevent/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Dbevent/Types.php
index bfbc983..0fa98e4 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Dbevent/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Dbevent/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Dbevent;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Experiment/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Experiment/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Experiment/Types.php
index f015ff4..7719ea7 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Experiment/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Experiment/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Experiment;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Group/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Group/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Group/Types.php
index ec7a68e..199e8cf 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Group/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Group/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Group;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Messaging/Event/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Messaging/Event/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Messaging/Event/Types.php
index fed31a4..cb6df57 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Messaging/Event/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Messaging/Event/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Messaging\Event;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Process/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Process/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Process/Types.php
index dc69623..ca80fe5 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Process/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Process/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Process;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Scheduling/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Scheduling/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Scheduling/Types.php
index 9eb8ebb..2e556a4 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Scheduling/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Scheduling/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Scheduling;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Security/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Security/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Security/Types.php
index f388971..ce71bfc 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Security/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Security/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Security;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Sharing/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Sharing/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Sharing/Types.php
index 68acc4f..1e6c4b2 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Sharing/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Sharing/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Sharing;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Status/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Status/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Status/Types.php
index 0a0a23b..a992fd0 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Status/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Status/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Status;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Task/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Task/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Task/Types.php
index 202fde8..5691abf 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Task/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Task/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Task;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Tenant/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Tenant/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Tenant/Types.php
index c1ad4ec..84efc01 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Tenant/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Tenant/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Tenant;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Types.php
index 71d3e01..bbd041b 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/User/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/User/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/User/Types.php
index 493b615..cef4420 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/User/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/User/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\User;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Workspace/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Workspace/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Workspace/Types.php
index 850778a..8a2f3cb 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Workspace/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/Workspace/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Workspace;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/job/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/job/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/job/Types.php
index bb25859..361f278 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/job/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Model/job/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Model\Job;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Iam/Admin/Services/CPI/Error/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Iam/Admin/Services/CPI/Error/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Iam/Admin/Services/CPI/Error/Types.php
index 28fa514..fb73d5a 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Iam/Admin/Services/CPI/Error/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Iam/Admin/Services/CPI/Error/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Service\Iam\Admin\Services\CPI\Error;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Iam/Admin/Services/CPI/IamAdminServices.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Iam/Admin/Services/CPI/IamAdminServices.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Iam/Admin/Services/CPI/IamAdminServices.php
index 963fc80..30f7abd 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Iam/Admin/Services/CPI/IamAdminServices.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Iam/Admin/Services/CPI/IamAdminServices.php
@@ -1,7 +1,7 @@
<?php
namespace Airavata\Service\Iam\Admin\Services\CPI;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
@@ -105,6 +105,7 @@ interface IamAdminServicesIf {
public function getUsersWithRole(\Airavata\Model\Security\AuthzToken $authzToken, $roleName);
}
+
class IamAdminServicesClient implements \Airavata\Service\Iam\Admin\Services\CPI\IamAdminServicesIf {
protected $input_ = null;
protected $output_ = null;
@@ -702,6 +703,7 @@ class IamAdminServicesClient implements \Airavata\Service\Iam\Admin\Services\CPI
}
+
// HELPER FUNCTIONS AND STRUCTURES
class IamAdminServices_getAPIVersion_args {
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Iam/Admin/Services/CPI/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Iam/Admin/Services/CPI/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Iam/Admin/Services/CPI/Types.php
index fb21133..54391ec 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Iam/Admin/Services/CPI/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Iam/Admin/Services/CPI/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Service\Iam\Admin\Services\CPI;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Tenant/CPI/Error/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Tenant/CPI/Error/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Tenant/CPI/Error/Types.php
index 796dbf6..90afbf2 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Tenant/CPI/Error/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Tenant/CPI/Error/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Service\Profile\Tenant\CPI\Error;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Tenant/CPI/TenantProfileService.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Tenant/CPI/TenantProfileService.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Tenant/CPI/TenantProfileService.php
index a1211be..633771e 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Tenant/CPI/TenantProfileService.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Tenant/CPI/TenantProfileService.php
@@ -1,7 +1,7 @@
<?php
namespace Airavata\Service\Profile\Tenant\CPI;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
@@ -84,6 +84,7 @@ interface TenantProfileServiceIf {
public function getAllGatewaysForUser(\Airavata\Model\Security\AuthzToken $authzToken, $requesterUsername);
}
+
class TenantProfileServiceClient implements \Airavata\Service\Profile\Tenant\CPI\TenantProfileServiceIf {
protected $input_ = null;
protected $output_ = null;
@@ -560,6 +561,7 @@ class TenantProfileServiceClient implements \Airavata\Service\Profile\Tenant\CPI
}
+
// HELPER FUNCTIONS AND STRUCTURES
class TenantProfileService_getAPIVersion_args {
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Tenant/CPI/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Tenant/CPI/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Tenant/CPI/Types.php
index 92038a2..41891f4 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Tenant/CPI/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Tenant/CPI/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Service\Profile\Tenant\CPI;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Types.php
index f6eafb7..271a25e 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Service\Profile;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/User/CPI/Error/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/User/CPI/Error/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/User/CPI/Error/Types.php
index b633c38..ab0f081 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/User/CPI/Error/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/User/CPI/Error/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Service\Profile\User\CPI\Error;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/User/CPI/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/User/CPI/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/User/CPI/Types.php
index c5c6626..bceeb65 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/User/CPI/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/User/CPI/Types.php
@@ -2,7 +2,7 @@
namespace Airavata\Service\Profile\User\CPI;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/User/CPI/UserProfileService.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/User/CPI/UserProfileService.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/User/CPI/UserProfileService.php
index 6c773b6..0efa67e 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/User/CPI/UserProfileService.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Airavata/Service/Profile/User/CPI/UserProfileService.php
@@ -1,7 +1,7 @@
<?php
namespace Airavata\Service\Profile\User\CPI;
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
@@ -128,6 +128,7 @@ interface UserProfileServiceIf {
public function doesUserExist(\Airavata\Model\Security\AuthzToken $authzToken, $userId, $gatewayId);
}
+
class UserProfileServiceClient implements \Airavata\Service\Profile\User\CPI\UserProfileServiceIf {
protected $input_ = null;
protected $output_ = null;
@@ -494,6 +495,7 @@ class UserProfileServiceClient implements \Airavata\Service\Profile\User\CPI\Use
}
+
// HELPER FUNCTIONS AND STRUCTURES
class UserProfileService_addUserProfile_args {
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Types.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Types.php b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Types.php
index 0e8e23c..c3f7aeb 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Types.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/lib/Types.php
@@ -1,6 +1,6 @@
<?php
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
[34/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/process/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/process/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/process/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/process/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/process/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/process/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/process/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/process/ttypes.py
index 0ae58fe..1dce0d0 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/process/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/process/ttypes.py
@@ -1,454 +1,420 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.commons.ttypes
import apache.airavata.model.application.io.ttypes
import apache.airavata.model.status.ttypes
import apache.airavata.model.task.ttypes
import apache.airavata.model.scheduling.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-
-class ProcessModel:
- """
- ProcessModel: A structure holding the process details. The infromation is derived based on user provided
- configuration data or system inferred information from scheduling and QoS parameters.
- processDetail:
- A friendly description of the process, usally used to communicate information to users.
+class ProcessModel(object):
+ """
+ ProcessModel: A structure holding the process details. The infromation is derived based on user provided
+ configuration data or system inferred information from scheduling and QoS parameters.
+ processDetail:
+ A friendly description of the process, usally used to communicate information to users.
- Attributes:
- - processId
- - experimentId
- - creationTime
- - lastUpdateTime
- - processStatuses
- - processDetail
- - applicationInterfaceId
- - applicationDeploymentId
- - computeResourceId
- - processInputs
- - processOutputs
- - processResourceSchedule
- - tasks
- - taskDag
- - processErrors
- - gatewayExecutionId
- - enableEmailNotification
- - emailAddresses
- - storageResourceId
- - userDn
- - generateCert
- - experimentDataDir
- - userName
- - useUserCRPref
- """
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'processId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.STRING, 'experimentId', None, None, ), # 2
- (3, TType.I64, 'creationTime', None, None, ), # 3
- (4, TType.I64, 'lastUpdateTime', None, None, ), # 4
- (5, TType.LIST, 'processStatuses', (TType.STRUCT,(apache.airavata.model.status.ttypes.ProcessStatus, apache.airavata.model.status.ttypes.ProcessStatus.thrift_spec)), None, ), # 5
- (6, TType.STRING, 'processDetail', None, None, ), # 6
- (7, TType.STRING, 'applicationInterfaceId', None, None, ), # 7
- (8, TType.STRING, 'applicationDeploymentId', None, None, ), # 8
- (9, TType.STRING, 'computeResourceId', None, None, ), # 9
- (10, TType.LIST, 'processInputs', (TType.STRUCT,(apache.airavata.model.application.io.ttypes.InputDataObjectType, apache.airavata.model.application.io.ttypes.InputDataObjectType.thrift_spec)), None, ), # 10
- (11, TType.LIST, 'processOutputs', (TType.STRUCT,(apache.airavata.model.application.io.ttypes.OutputDataObjectType, apache.airavata.model.application.io.ttypes.OutputDataObjectType.thrift_spec)), None, ), # 11
- (12, TType.STRUCT, 'processResourceSchedule', (apache.airavata.model.scheduling.ttypes.ComputationalResourceSchedulingModel, apache.airavata.model.scheduling.ttypes.ComputationalResourceSchedulingModel.thrift_spec), None, ), # 12
- (13, TType.LIST, 'tasks', (TType.STRUCT,(apache.airavata.model.task.ttypes.TaskModel, apache.airavata.model.task.ttypes.TaskModel.thrift_spec)), None, ), # 13
- (14, TType.STRING, 'taskDag', None, None, ), # 14
- (15, TType.LIST, 'processErrors', (TType.STRUCT,(apache.airavata.model.commons.ttypes.ErrorModel, apache.airavata.model.commons.ttypes.ErrorModel.thrift_spec)), None, ), # 15
- (16, TType.STRING, 'gatewayExecutionId', None, None, ), # 16
- (17, TType.BOOL, 'enableEmailNotification', None, None, ), # 17
- (18, TType.LIST, 'emailAddresses', (TType.STRING,None), None, ), # 18
- (19, TType.STRING, 'storageResourceId', None, None, ), # 19
- (20, TType.STRING, 'userDn', None, None, ), # 20
- (21, TType.BOOL, 'generateCert', None, False, ), # 21
- (22, TType.STRING, 'experimentDataDir', None, None, ), # 22
- (23, TType.STRING, 'userName', None, None, ), # 23
- (24, TType.BOOL, 'useUserCRPref', None, None, ), # 24
- )
- def __init__(self, processId=thrift_spec[1][4], experimentId=None, creationTime=None, lastUpdateTime=None, processStatuses=None, processDetail=None, applicationInterfaceId=None, applicationDeploymentId=None, computeResourceId=None, processInputs=None, processOutputs=None, processResourceSchedule=None, tasks=None, taskDag=None, processErrors=None, gatewayExecutionId=None, enableEmailNotification=None, emailAddresses=None, storageResourceId=None, userDn=None, generateCert=thrift_spec[21][4], experimentDataDir=None, userName=None, useUserCRPref=None,):
- self.processId = processId
- self.experimentId = experimentId
- self.creationTime = creationTime
- self.lastUpdateTime = lastUpdateTime
- self.processStatuses = processStatuses
- self.processDetail = processDetail
- self.applicationInterfaceId = applicationInterfaceId
- self.applicationDeploymentId = applicationDeploymentId
- self.computeResourceId = computeResourceId
- self.processInputs = processInputs
- self.processOutputs = processOutputs
- self.processResourceSchedule = processResourceSchedule
- self.tasks = tasks
- self.taskDag = taskDag
- self.processErrors = processErrors
- self.gatewayExecutionId = gatewayExecutionId
- self.enableEmailNotification = enableEmailNotification
- self.emailAddresses = emailAddresses
- self.storageResourceId = storageResourceId
- self.userDn = userDn
- self.generateCert = generateCert
- self.experimentDataDir = experimentDataDir
- self.userName = userName
- self.useUserCRPref = useUserCRPref
+ Attributes:
+ - processId
+ - experimentId
+ - creationTime
+ - lastUpdateTime
+ - processStatuses
+ - processDetail
+ - applicationInterfaceId
+ - applicationDeploymentId
+ - computeResourceId
+ - processInputs
+ - processOutputs
+ - processResourceSchedule
+ - tasks
+ - taskDag
+ - processErrors
+ - gatewayExecutionId
+ - enableEmailNotification
+ - emailAddresses
+ - storageResourceId
+ - userDn
+ - generateCert
+ - experimentDataDir
+ - userName
+ - useUserCRPref
+ """
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.processId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.experimentId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.I64:
- self.creationTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.I64:
- self.lastUpdateTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.LIST:
- self.processStatuses = []
- (_etype3, _size0) = iprot.readListBegin()
- for _i4 in xrange(_size0):
- _elem5 = apache.airavata.model.status.ttypes.ProcessStatus()
- _elem5.read(iprot)
- self.processStatuses.append(_elem5)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.processDetail = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.STRING:
- self.applicationInterfaceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.STRING:
- self.applicationDeploymentId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.STRING:
- self.computeResourceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.LIST:
- self.processInputs = []
- (_etype9, _size6) = iprot.readListBegin()
- for _i10 in xrange(_size6):
- _elem11 = apache.airavata.model.application.io.ttypes.InputDataObjectType()
- _elem11.read(iprot)
- self.processInputs.append(_elem11)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 11:
- if ftype == TType.LIST:
- self.processOutputs = []
- (_etype15, _size12) = iprot.readListBegin()
- for _i16 in xrange(_size12):
- _elem17 = apache.airavata.model.application.io.ttypes.OutputDataObjectType()
- _elem17.read(iprot)
- self.processOutputs.append(_elem17)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 12:
- if ftype == TType.STRUCT:
- self.processResourceSchedule = apache.airavata.model.scheduling.ttypes.ComputationalResourceSchedulingModel()
- self.processResourceSchedule.read(iprot)
- else:
- iprot.skip(ftype)
- elif fid == 13:
- if ftype == TType.LIST:
- self.tasks = []
- (_etype21, _size18) = iprot.readListBegin()
- for _i22 in xrange(_size18):
- _elem23 = apache.airavata.model.task.ttypes.TaskModel()
- _elem23.read(iprot)
- self.tasks.append(_elem23)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 14:
- if ftype == TType.STRING:
- self.taskDag = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 15:
- if ftype == TType.LIST:
- self.processErrors = []
- (_etype27, _size24) = iprot.readListBegin()
- for _i28 in xrange(_size24):
- _elem29 = apache.airavata.model.commons.ttypes.ErrorModel()
- _elem29.read(iprot)
- self.processErrors.append(_elem29)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 16:
- if ftype == TType.STRING:
- self.gatewayExecutionId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 17:
- if ftype == TType.BOOL:
- self.enableEmailNotification = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 18:
- if ftype == TType.LIST:
- self.emailAddresses = []
- (_etype33, _size30) = iprot.readListBegin()
- for _i34 in xrange(_size30):
- _elem35 = iprot.readString()
- self.emailAddresses.append(_elem35)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 19:
- if ftype == TType.STRING:
- self.storageResourceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 20:
- if ftype == TType.STRING:
- self.userDn = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 21:
- if ftype == TType.BOOL:
- self.generateCert = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 22:
- if ftype == TType.STRING:
- self.experimentDataDir = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 23:
- if ftype == TType.STRING:
- self.userName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 24:
- if ftype == TType.BOOL:
- self.useUserCRPref = iprot.readBool()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'processId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.STRING, 'experimentId', 'UTF8', None, ), # 2
+ (3, TType.I64, 'creationTime', None, None, ), # 3
+ (4, TType.I64, 'lastUpdateTime', None, None, ), # 4
+ (5, TType.LIST, 'processStatuses', (TType.STRUCT, (apache.airavata.model.status.ttypes.ProcessStatus, apache.airavata.model.status.ttypes.ProcessStatus.thrift_spec), False), None, ), # 5
+ (6, TType.STRING, 'processDetail', 'UTF8', None, ), # 6
+ (7, TType.STRING, 'applicationInterfaceId', 'UTF8', None, ), # 7
+ (8, TType.STRING, 'applicationDeploymentId', 'UTF8', None, ), # 8
+ (9, TType.STRING, 'computeResourceId', 'UTF8', None, ), # 9
+ (10, TType.LIST, 'processInputs', (TType.STRUCT, (apache.airavata.model.application.io.ttypes.InputDataObjectType, apache.airavata.model.application.io.ttypes.InputDataObjectType.thrift_spec), False), None, ), # 10
+ (11, TType.LIST, 'processOutputs', (TType.STRUCT, (apache.airavata.model.application.io.ttypes.OutputDataObjectType, apache.airavata.model.application.io.ttypes.OutputDataObjectType.thrift_spec), False), None, ), # 11
+ (12, TType.STRUCT, 'processResourceSchedule', (apache.airavata.model.scheduling.ttypes.ComputationalResourceSchedulingModel, apache.airavata.model.scheduling.ttypes.ComputationalResourceSchedulingModel.thrift_spec), None, ), # 12
+ (13, TType.LIST, 'tasks', (TType.STRUCT, (apache.airavata.model.task.ttypes.TaskModel, apache.airavata.model.task.ttypes.TaskModel.thrift_spec), False), None, ), # 13
+ (14, TType.STRING, 'taskDag', 'UTF8', None, ), # 14
+ (15, TType.LIST, 'processErrors', (TType.STRUCT, (apache.airavata.model.commons.ttypes.ErrorModel, apache.airavata.model.commons.ttypes.ErrorModel.thrift_spec), False), None, ), # 15
+ (16, TType.STRING, 'gatewayExecutionId', 'UTF8', None, ), # 16
+ (17, TType.BOOL, 'enableEmailNotification', None, None, ), # 17
+ (18, TType.LIST, 'emailAddresses', (TType.STRING, 'UTF8', False), None, ), # 18
+ (19, TType.STRING, 'storageResourceId', 'UTF8', None, ), # 19
+ (20, TType.STRING, 'userDn', 'UTF8', None, ), # 20
+ (21, TType.BOOL, 'generateCert', None, False, ), # 21
+ (22, TType.STRING, 'experimentDataDir', 'UTF8', None, ), # 22
+ (23, TType.STRING, 'userName', 'UTF8', None, ), # 23
+ (24, TType.BOOL, 'useUserCRPref', None, None, ), # 24
+ )
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ProcessModel')
- if self.processId is not None:
- oprot.writeFieldBegin('processId', TType.STRING, 1)
- oprot.writeString(self.processId)
- oprot.writeFieldEnd()
- if self.experimentId is not None:
- oprot.writeFieldBegin('experimentId', TType.STRING, 2)
- oprot.writeString(self.experimentId)
- oprot.writeFieldEnd()
- if self.creationTime is not None:
- oprot.writeFieldBegin('creationTime', TType.I64, 3)
- oprot.writeI64(self.creationTime)
- oprot.writeFieldEnd()
- if self.lastUpdateTime is not None:
- oprot.writeFieldBegin('lastUpdateTime', TType.I64, 4)
- oprot.writeI64(self.lastUpdateTime)
- oprot.writeFieldEnd()
- if self.processStatuses is not None:
- oprot.writeFieldBegin('processStatuses', TType.LIST, 5)
- oprot.writeListBegin(TType.STRUCT, len(self.processStatuses))
- for iter36 in self.processStatuses:
- iter36.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.processDetail is not None:
- oprot.writeFieldBegin('processDetail', TType.STRING, 6)
- oprot.writeString(self.processDetail)
- oprot.writeFieldEnd()
- if self.applicationInterfaceId is not None:
- oprot.writeFieldBegin('applicationInterfaceId', TType.STRING, 7)
- oprot.writeString(self.applicationInterfaceId)
- oprot.writeFieldEnd()
- if self.applicationDeploymentId is not None:
- oprot.writeFieldBegin('applicationDeploymentId', TType.STRING, 8)
- oprot.writeString(self.applicationDeploymentId)
- oprot.writeFieldEnd()
- if self.computeResourceId is not None:
- oprot.writeFieldBegin('computeResourceId', TType.STRING, 9)
- oprot.writeString(self.computeResourceId)
- oprot.writeFieldEnd()
- if self.processInputs is not None:
- oprot.writeFieldBegin('processInputs', TType.LIST, 10)
- oprot.writeListBegin(TType.STRUCT, len(self.processInputs))
- for iter37 in self.processInputs:
- iter37.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.processOutputs is not None:
- oprot.writeFieldBegin('processOutputs', TType.LIST, 11)
- oprot.writeListBegin(TType.STRUCT, len(self.processOutputs))
- for iter38 in self.processOutputs:
- iter38.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.processResourceSchedule is not None:
- oprot.writeFieldBegin('processResourceSchedule', TType.STRUCT, 12)
- self.processResourceSchedule.write(oprot)
- oprot.writeFieldEnd()
- if self.tasks is not None:
- oprot.writeFieldBegin('tasks', TType.LIST, 13)
- oprot.writeListBegin(TType.STRUCT, len(self.tasks))
- for iter39 in self.tasks:
- iter39.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.taskDag is not None:
- oprot.writeFieldBegin('taskDag', TType.STRING, 14)
- oprot.writeString(self.taskDag)
- oprot.writeFieldEnd()
- if self.processErrors is not None:
- oprot.writeFieldBegin('processErrors', TType.LIST, 15)
- oprot.writeListBegin(TType.STRUCT, len(self.processErrors))
- for iter40 in self.processErrors:
- iter40.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.gatewayExecutionId is not None:
- oprot.writeFieldBegin('gatewayExecutionId', TType.STRING, 16)
- oprot.writeString(self.gatewayExecutionId)
- oprot.writeFieldEnd()
- if self.enableEmailNotification is not None:
- oprot.writeFieldBegin('enableEmailNotification', TType.BOOL, 17)
- oprot.writeBool(self.enableEmailNotification)
- oprot.writeFieldEnd()
- if self.emailAddresses is not None:
- oprot.writeFieldBegin('emailAddresses', TType.LIST, 18)
- oprot.writeListBegin(TType.STRING, len(self.emailAddresses))
- for iter41 in self.emailAddresses:
- oprot.writeString(iter41)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.storageResourceId is not None:
- oprot.writeFieldBegin('storageResourceId', TType.STRING, 19)
- oprot.writeString(self.storageResourceId)
- oprot.writeFieldEnd()
- if self.userDn is not None:
- oprot.writeFieldBegin('userDn', TType.STRING, 20)
- oprot.writeString(self.userDn)
- oprot.writeFieldEnd()
- if self.generateCert is not None:
- oprot.writeFieldBegin('generateCert', TType.BOOL, 21)
- oprot.writeBool(self.generateCert)
- oprot.writeFieldEnd()
- if self.experimentDataDir is not None:
- oprot.writeFieldBegin('experimentDataDir', TType.STRING, 22)
- oprot.writeString(self.experimentDataDir)
- oprot.writeFieldEnd()
- if self.userName is not None:
- oprot.writeFieldBegin('userName', TType.STRING, 23)
- oprot.writeString(self.userName)
- oprot.writeFieldEnd()
- if self.useUserCRPref is not None:
- oprot.writeFieldBegin('useUserCRPref', TType.BOOL, 24)
- oprot.writeBool(self.useUserCRPref)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
+ def __init__(self, processId=thrift_spec[1][4], experimentId=None, creationTime=None, lastUpdateTime=None, processStatuses=None, processDetail=None, applicationInterfaceId=None, applicationDeploymentId=None, computeResourceId=None, processInputs=None, processOutputs=None, processResourceSchedule=None, tasks=None, taskDag=None, processErrors=None, gatewayExecutionId=None, enableEmailNotification=None, emailAddresses=None, storageResourceId=None, userDn=None, generateCert=thrift_spec[21][4], experimentDataDir=None, userName=None, useUserCRPref=None,):
+ self.processId = processId
+ self.experimentId = experimentId
+ self.creationTime = creationTime
+ self.lastUpdateTime = lastUpdateTime
+ self.processStatuses = processStatuses
+ self.processDetail = processDetail
+ self.applicationInterfaceId = applicationInterfaceId
+ self.applicationDeploymentId = applicationDeploymentId
+ self.computeResourceId = computeResourceId
+ self.processInputs = processInputs
+ self.processOutputs = processOutputs
+ self.processResourceSchedule = processResourceSchedule
+ self.tasks = tasks
+ self.taskDag = taskDag
+ self.processErrors = processErrors
+ self.gatewayExecutionId = gatewayExecutionId
+ self.enableEmailNotification = enableEmailNotification
+ self.emailAddresses = emailAddresses
+ self.storageResourceId = storageResourceId
+ self.userDn = userDn
+ self.generateCert = generateCert
+ self.experimentDataDir = experimentDataDir
+ self.userName = userName
+ self.useUserCRPref = useUserCRPref
- def validate(self):
- if self.processId is None:
- raise TProtocol.TProtocolException(message='Required field processId is unset!')
- if self.experimentId is None:
- raise TProtocol.TProtocolException(message='Required field experimentId is unset!')
- return
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.processId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.experimentId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I64:
+ self.creationTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.I64:
+ self.lastUpdateTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.LIST:
+ self.processStatuses = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in range(_size0):
+ _elem5 = apache.airavata.model.status.ttypes.ProcessStatus()
+ _elem5.read(iprot)
+ self.processStatuses.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.processDetail = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.STRING:
+ self.applicationInterfaceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.STRING:
+ self.applicationDeploymentId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.STRING:
+ self.computeResourceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.LIST:
+ self.processInputs = []
+ (_etype9, _size6) = iprot.readListBegin()
+ for _i10 in range(_size6):
+ _elem11 = apache.airavata.model.application.io.ttypes.InputDataObjectType()
+ _elem11.read(iprot)
+ self.processInputs.append(_elem11)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 11:
+ if ftype == TType.LIST:
+ self.processOutputs = []
+ (_etype15, _size12) = iprot.readListBegin()
+ for _i16 in range(_size12):
+ _elem17 = apache.airavata.model.application.io.ttypes.OutputDataObjectType()
+ _elem17.read(iprot)
+ self.processOutputs.append(_elem17)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 12:
+ if ftype == TType.STRUCT:
+ self.processResourceSchedule = apache.airavata.model.scheduling.ttypes.ComputationalResourceSchedulingModel()
+ self.processResourceSchedule.read(iprot)
+ else:
+ iprot.skip(ftype)
+ elif fid == 13:
+ if ftype == TType.LIST:
+ self.tasks = []
+ (_etype21, _size18) = iprot.readListBegin()
+ for _i22 in range(_size18):
+ _elem23 = apache.airavata.model.task.ttypes.TaskModel()
+ _elem23.read(iprot)
+ self.tasks.append(_elem23)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 14:
+ if ftype == TType.STRING:
+ self.taskDag = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 15:
+ if ftype == TType.LIST:
+ self.processErrors = []
+ (_etype27, _size24) = iprot.readListBegin()
+ for _i28 in range(_size24):
+ _elem29 = apache.airavata.model.commons.ttypes.ErrorModel()
+ _elem29.read(iprot)
+ self.processErrors.append(_elem29)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 16:
+ if ftype == TType.STRING:
+ self.gatewayExecutionId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 17:
+ if ftype == TType.BOOL:
+ self.enableEmailNotification = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 18:
+ if ftype == TType.LIST:
+ self.emailAddresses = []
+ (_etype33, _size30) = iprot.readListBegin()
+ for _i34 in range(_size30):
+ _elem35 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ self.emailAddresses.append(_elem35)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 19:
+ if ftype == TType.STRING:
+ self.storageResourceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 20:
+ if ftype == TType.STRING:
+ self.userDn = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 21:
+ if ftype == TType.BOOL:
+ self.generateCert = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 22:
+ if ftype == TType.STRING:
+ self.experimentDataDir = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 23:
+ if ftype == TType.STRING:
+ self.userName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 24:
+ if ftype == TType.BOOL:
+ self.useUserCRPref = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ProcessModel')
+ if self.processId is not None:
+ oprot.writeFieldBegin('processId', TType.STRING, 1)
+ oprot.writeString(self.processId.encode('utf-8') if sys.version_info[0] == 2 else self.processId)
+ oprot.writeFieldEnd()
+ if self.experimentId is not None:
+ oprot.writeFieldBegin('experimentId', TType.STRING, 2)
+ oprot.writeString(self.experimentId.encode('utf-8') if sys.version_info[0] == 2 else self.experimentId)
+ oprot.writeFieldEnd()
+ if self.creationTime is not None:
+ oprot.writeFieldBegin('creationTime', TType.I64, 3)
+ oprot.writeI64(self.creationTime)
+ oprot.writeFieldEnd()
+ if self.lastUpdateTime is not None:
+ oprot.writeFieldBegin('lastUpdateTime', TType.I64, 4)
+ oprot.writeI64(self.lastUpdateTime)
+ oprot.writeFieldEnd()
+ if self.processStatuses is not None:
+ oprot.writeFieldBegin('processStatuses', TType.LIST, 5)
+ oprot.writeListBegin(TType.STRUCT, len(self.processStatuses))
+ for iter36 in self.processStatuses:
+ iter36.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.processDetail is not None:
+ oprot.writeFieldBegin('processDetail', TType.STRING, 6)
+ oprot.writeString(self.processDetail.encode('utf-8') if sys.version_info[0] == 2 else self.processDetail)
+ oprot.writeFieldEnd()
+ if self.applicationInterfaceId is not None:
+ oprot.writeFieldBegin('applicationInterfaceId', TType.STRING, 7)
+ oprot.writeString(self.applicationInterfaceId.encode('utf-8') if sys.version_info[0] == 2 else self.applicationInterfaceId)
+ oprot.writeFieldEnd()
+ if self.applicationDeploymentId is not None:
+ oprot.writeFieldBegin('applicationDeploymentId', TType.STRING, 8)
+ oprot.writeString(self.applicationDeploymentId.encode('utf-8') if sys.version_info[0] == 2 else self.applicationDeploymentId)
+ oprot.writeFieldEnd()
+ if self.computeResourceId is not None:
+ oprot.writeFieldBegin('computeResourceId', TType.STRING, 9)
+ oprot.writeString(self.computeResourceId.encode('utf-8') if sys.version_info[0] == 2 else self.computeResourceId)
+ oprot.writeFieldEnd()
+ if self.processInputs is not None:
+ oprot.writeFieldBegin('processInputs', TType.LIST, 10)
+ oprot.writeListBegin(TType.STRUCT, len(self.processInputs))
+ for iter37 in self.processInputs:
+ iter37.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.processOutputs is not None:
+ oprot.writeFieldBegin('processOutputs', TType.LIST, 11)
+ oprot.writeListBegin(TType.STRUCT, len(self.processOutputs))
+ for iter38 in self.processOutputs:
+ iter38.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.processResourceSchedule is not None:
+ oprot.writeFieldBegin('processResourceSchedule', TType.STRUCT, 12)
+ self.processResourceSchedule.write(oprot)
+ oprot.writeFieldEnd()
+ if self.tasks is not None:
+ oprot.writeFieldBegin('tasks', TType.LIST, 13)
+ oprot.writeListBegin(TType.STRUCT, len(self.tasks))
+ for iter39 in self.tasks:
+ iter39.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.taskDag is not None:
+ oprot.writeFieldBegin('taskDag', TType.STRING, 14)
+ oprot.writeString(self.taskDag.encode('utf-8') if sys.version_info[0] == 2 else self.taskDag)
+ oprot.writeFieldEnd()
+ if self.processErrors is not None:
+ oprot.writeFieldBegin('processErrors', TType.LIST, 15)
+ oprot.writeListBegin(TType.STRUCT, len(self.processErrors))
+ for iter40 in self.processErrors:
+ iter40.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.gatewayExecutionId is not None:
+ oprot.writeFieldBegin('gatewayExecutionId', TType.STRING, 16)
+ oprot.writeString(self.gatewayExecutionId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayExecutionId)
+ oprot.writeFieldEnd()
+ if self.enableEmailNotification is not None:
+ oprot.writeFieldBegin('enableEmailNotification', TType.BOOL, 17)
+ oprot.writeBool(self.enableEmailNotification)
+ oprot.writeFieldEnd()
+ if self.emailAddresses is not None:
+ oprot.writeFieldBegin('emailAddresses', TType.LIST, 18)
+ oprot.writeListBegin(TType.STRING, len(self.emailAddresses))
+ for iter41 in self.emailAddresses:
+ oprot.writeString(iter41.encode('utf-8') if sys.version_info[0] == 2 else iter41)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.storageResourceId is not None:
+ oprot.writeFieldBegin('storageResourceId', TType.STRING, 19)
+ oprot.writeString(self.storageResourceId.encode('utf-8') if sys.version_info[0] == 2 else self.storageResourceId)
+ oprot.writeFieldEnd()
+ if self.userDn is not None:
+ oprot.writeFieldBegin('userDn', TType.STRING, 20)
+ oprot.writeString(self.userDn.encode('utf-8') if sys.version_info[0] == 2 else self.userDn)
+ oprot.writeFieldEnd()
+ if self.generateCert is not None:
+ oprot.writeFieldBegin('generateCert', TType.BOOL, 21)
+ oprot.writeBool(self.generateCert)
+ oprot.writeFieldEnd()
+ if self.experimentDataDir is not None:
+ oprot.writeFieldBegin('experimentDataDir', TType.STRING, 22)
+ oprot.writeString(self.experimentDataDir.encode('utf-8') if sys.version_info[0] == 2 else self.experimentDataDir)
+ oprot.writeFieldEnd()
+ if self.userName is not None:
+ oprot.writeFieldBegin('userName', TType.STRING, 23)
+ oprot.writeString(self.userName.encode('utf-8') if sys.version_info[0] == 2 else self.userName)
+ oprot.writeFieldEnd()
+ if self.useUserCRPref is not None:
+ oprot.writeFieldBegin('useUserCRPref', TType.BOOL, 24)
+ oprot.writeBool(self.useUserCRPref)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.processId)
- value = (value * 31) ^ hash(self.experimentId)
- value = (value * 31) ^ hash(self.creationTime)
- value = (value * 31) ^ hash(self.lastUpdateTime)
- value = (value * 31) ^ hash(self.processStatuses)
- value = (value * 31) ^ hash(self.processDetail)
- value = (value * 31) ^ hash(self.applicationInterfaceId)
- value = (value * 31) ^ hash(self.applicationDeploymentId)
- value = (value * 31) ^ hash(self.computeResourceId)
- value = (value * 31) ^ hash(self.processInputs)
- value = (value * 31) ^ hash(self.processOutputs)
- value = (value * 31) ^ hash(self.processResourceSchedule)
- value = (value * 31) ^ hash(self.tasks)
- value = (value * 31) ^ hash(self.taskDag)
- value = (value * 31) ^ hash(self.processErrors)
- value = (value * 31) ^ hash(self.gatewayExecutionId)
- value = (value * 31) ^ hash(self.enableEmailNotification)
- value = (value * 31) ^ hash(self.emailAddresses)
- value = (value * 31) ^ hash(self.storageResourceId)
- value = (value * 31) ^ hash(self.userDn)
- value = (value * 31) ^ hash(self.generateCert)
- value = (value * 31) ^ hash(self.experimentDataDir)
- value = (value * 31) ^ hash(self.userName)
- value = (value * 31) ^ hash(self.useUserCRPref)
- return value
+ def validate(self):
+ if self.processId is None:
+ raise TProtocolException(message='Required field processId is unset!')
+ if self.experimentId is None:
+ raise TProtocolException(message='Required field experimentId is unset!')
+ return
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
- def __ne__(self, other):
- return not (self == other)
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/scheduling/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/scheduling/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/scheduling/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/scheduling/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/scheduling/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/scheduling/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/scheduling/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/scheduling/ttypes.py
index 6fb231b..fcdae4c 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/scheduling/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/scheduling/ttypes.py
@@ -1,230 +1,209 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-class ComputationalResourceSchedulingModel:
- """
- ComputationalResourceSchedulingModel:
-
-
-
- Attributes:
- - resourceHostId
- - totalCPUCount
- - nodeCount
- - numberOfThreads
- - queueName
- - wallTimeLimit
- - totalPhysicalMemory
- - chessisNumber
- - staticWorkingDir
- - overrideLoginUserName
- - overrideScratchLocation
- - overrideAllocationProjectNumber
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'resourceHostId', None, None, ), # 1
- (2, TType.I32, 'totalCPUCount', None, None, ), # 2
- (3, TType.I32, 'nodeCount', None, None, ), # 3
- (4, TType.I32, 'numberOfThreads', None, None, ), # 4
- (5, TType.STRING, 'queueName', None, None, ), # 5
- (6, TType.I32, 'wallTimeLimit', None, None, ), # 6
- (7, TType.I32, 'totalPhysicalMemory', None, None, ), # 7
- (8, TType.STRING, 'chessisNumber', None, None, ), # 8
- (9, TType.STRING, 'staticWorkingDir', None, None, ), # 9
- (10, TType.STRING, 'overrideLoginUserName', None, None, ), # 10
- (11, TType.STRING, 'overrideScratchLocation', None, None, ), # 11
- (12, TType.STRING, 'overrideAllocationProjectNumber', None, None, ), # 12
- )
-
- def __init__(self, resourceHostId=None, totalCPUCount=None, nodeCount=None, numberOfThreads=None, queueName=None, wallTimeLimit=None, totalPhysicalMemory=None, chessisNumber=None, staticWorkingDir=None, overrideLoginUserName=None, overrideScratchLocation=None, overrideAllocationProjectNumber=None,):
- self.resourceHostId = resourceHostId
- self.totalCPUCount = totalCPUCount
- self.nodeCount = nodeCount
- self.numberOfThreads = numberOfThreads
- self.queueName = queueName
- self.wallTimeLimit = wallTimeLimit
- self.totalPhysicalMemory = totalPhysicalMemory
- self.chessisNumber = chessisNumber
- self.staticWorkingDir = staticWorkingDir
- self.overrideLoginUserName = overrideLoginUserName
- self.overrideScratchLocation = overrideScratchLocation
- self.overrideAllocationProjectNumber = overrideAllocationProjectNumber
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.resourceHostId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.totalCPUCount = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.I32:
- self.nodeCount = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.I32:
- self.numberOfThreads = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.queueName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.I32:
- self.wallTimeLimit = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.I32:
- self.totalPhysicalMemory = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.STRING:
- self.chessisNumber = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.STRING:
- self.staticWorkingDir = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.STRING:
- self.overrideLoginUserName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 11:
- if ftype == TType.STRING:
- self.overrideScratchLocation = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 12:
- if ftype == TType.STRING:
- self.overrideAllocationProjectNumber = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ComputationalResourceSchedulingModel')
- if self.resourceHostId is not None:
- oprot.writeFieldBegin('resourceHostId', TType.STRING, 1)
- oprot.writeString(self.resourceHostId)
- oprot.writeFieldEnd()
- if self.totalCPUCount is not None:
- oprot.writeFieldBegin('totalCPUCount', TType.I32, 2)
- oprot.writeI32(self.totalCPUCount)
- oprot.writeFieldEnd()
- if self.nodeCount is not None:
- oprot.writeFieldBegin('nodeCount', TType.I32, 3)
- oprot.writeI32(self.nodeCount)
- oprot.writeFieldEnd()
- if self.numberOfThreads is not None:
- oprot.writeFieldBegin('numberOfThreads', TType.I32, 4)
- oprot.writeI32(self.numberOfThreads)
- oprot.writeFieldEnd()
- if self.queueName is not None:
- oprot.writeFieldBegin('queueName', TType.STRING, 5)
- oprot.writeString(self.queueName)
- oprot.writeFieldEnd()
- if self.wallTimeLimit is not None:
- oprot.writeFieldBegin('wallTimeLimit', TType.I32, 6)
- oprot.writeI32(self.wallTimeLimit)
- oprot.writeFieldEnd()
- if self.totalPhysicalMemory is not None:
- oprot.writeFieldBegin('totalPhysicalMemory', TType.I32, 7)
- oprot.writeI32(self.totalPhysicalMemory)
- oprot.writeFieldEnd()
- if self.chessisNumber is not None:
- oprot.writeFieldBegin('chessisNumber', TType.STRING, 8)
- oprot.writeString(self.chessisNumber)
- oprot.writeFieldEnd()
- if self.staticWorkingDir is not None:
- oprot.writeFieldBegin('staticWorkingDir', TType.STRING, 9)
- oprot.writeString(self.staticWorkingDir)
- oprot.writeFieldEnd()
- if self.overrideLoginUserName is not None:
- oprot.writeFieldBegin('overrideLoginUserName', TType.STRING, 10)
- oprot.writeString(self.overrideLoginUserName)
- oprot.writeFieldEnd()
- if self.overrideScratchLocation is not None:
- oprot.writeFieldBegin('overrideScratchLocation', TType.STRING, 11)
- oprot.writeString(self.overrideScratchLocation)
- oprot.writeFieldEnd()
- if self.overrideAllocationProjectNumber is not None:
- oprot.writeFieldBegin('overrideAllocationProjectNumber', TType.STRING, 12)
- oprot.writeString(self.overrideAllocationProjectNumber)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.resourceHostId)
- value = (value * 31) ^ hash(self.totalCPUCount)
- value = (value * 31) ^ hash(self.nodeCount)
- value = (value * 31) ^ hash(self.numberOfThreads)
- value = (value * 31) ^ hash(self.queueName)
- value = (value * 31) ^ hash(self.wallTimeLimit)
- value = (value * 31) ^ hash(self.totalPhysicalMemory)
- value = (value * 31) ^ hash(self.chessisNumber)
- value = (value * 31) ^ hash(self.staticWorkingDir)
- value = (value * 31) ^ hash(self.overrideLoginUserName)
- value = (value * 31) ^ hash(self.overrideScratchLocation)
- value = (value * 31) ^ hash(self.overrideAllocationProjectNumber)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+class ComputationalResourceSchedulingModel(object):
+ """
+ ComputationalResourceSchedulingModel:
+
+
+
+ Attributes:
+ - resourceHostId
+ - totalCPUCount
+ - nodeCount
+ - numberOfThreads
+ - queueName
+ - wallTimeLimit
+ - totalPhysicalMemory
+ - chessisNumber
+ - staticWorkingDir
+ - overrideLoginUserName
+ - overrideScratchLocation
+ - overrideAllocationProjectNumber
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'resourceHostId', 'UTF8', None, ), # 1
+ (2, TType.I32, 'totalCPUCount', None, None, ), # 2
+ (3, TType.I32, 'nodeCount', None, None, ), # 3
+ (4, TType.I32, 'numberOfThreads', None, None, ), # 4
+ (5, TType.STRING, 'queueName', 'UTF8', None, ), # 5
+ (6, TType.I32, 'wallTimeLimit', None, None, ), # 6
+ (7, TType.I32, 'totalPhysicalMemory', None, None, ), # 7
+ (8, TType.STRING, 'chessisNumber', 'UTF8', None, ), # 8
+ (9, TType.STRING, 'staticWorkingDir', 'UTF8', None, ), # 9
+ (10, TType.STRING, 'overrideLoginUserName', 'UTF8', None, ), # 10
+ (11, TType.STRING, 'overrideScratchLocation', 'UTF8', None, ), # 11
+ (12, TType.STRING, 'overrideAllocationProjectNumber', 'UTF8', None, ), # 12
+ )
+
+ def __init__(self, resourceHostId=None, totalCPUCount=None, nodeCount=None, numberOfThreads=None, queueName=None, wallTimeLimit=None, totalPhysicalMemory=None, chessisNumber=None, staticWorkingDir=None, overrideLoginUserName=None, overrideScratchLocation=None, overrideAllocationProjectNumber=None,):
+ self.resourceHostId = resourceHostId
+ self.totalCPUCount = totalCPUCount
+ self.nodeCount = nodeCount
+ self.numberOfThreads = numberOfThreads
+ self.queueName = queueName
+ self.wallTimeLimit = wallTimeLimit
+ self.totalPhysicalMemory = totalPhysicalMemory
+ self.chessisNumber = chessisNumber
+ self.staticWorkingDir = staticWorkingDir
+ self.overrideLoginUserName = overrideLoginUserName
+ self.overrideScratchLocation = overrideScratchLocation
+ self.overrideAllocationProjectNumber = overrideAllocationProjectNumber
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.resourceHostId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I32:
+ self.totalCPUCount = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I32:
+ self.nodeCount = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.I32:
+ self.numberOfThreads = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRING:
+ self.queueName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.I32:
+ self.wallTimeLimit = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.I32:
+ self.totalPhysicalMemory = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.STRING:
+ self.chessisNumber = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.STRING:
+ self.staticWorkingDir = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.STRING:
+ self.overrideLoginUserName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 11:
+ if ftype == TType.STRING:
+ self.overrideScratchLocation = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 12:
+ if ftype == TType.STRING:
+ self.overrideAllocationProjectNumber = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ComputationalResourceSchedulingModel')
+ if self.resourceHostId is not None:
+ oprot.writeFieldBegin('resourceHostId', TType.STRING, 1)
+ oprot.writeString(self.resourceHostId.encode('utf-8') if sys.version_info[0] == 2 else self.resourceHostId)
+ oprot.writeFieldEnd()
+ if self.totalCPUCount is not None:
+ oprot.writeFieldBegin('totalCPUCount', TType.I32, 2)
+ oprot.writeI32(self.totalCPUCount)
+ oprot.writeFieldEnd()
+ if self.nodeCount is not None:
+ oprot.writeFieldBegin('nodeCount', TType.I32, 3)
+ oprot.writeI32(self.nodeCount)
+ oprot.writeFieldEnd()
+ if self.numberOfThreads is not None:
+ oprot.writeFieldBegin('numberOfThreads', TType.I32, 4)
+ oprot.writeI32(self.numberOfThreads)
+ oprot.writeFieldEnd()
+ if self.queueName is not None:
+ oprot.writeFieldBegin('queueName', TType.STRING, 5)
+ oprot.writeString(self.queueName.encode('utf-8') if sys.version_info[0] == 2 else self.queueName)
+ oprot.writeFieldEnd()
+ if self.wallTimeLimit is not None:
+ oprot.writeFieldBegin('wallTimeLimit', TType.I32, 6)
+ oprot.writeI32(self.wallTimeLimit)
+ oprot.writeFieldEnd()
+ if self.totalPhysicalMemory is not None:
+ oprot.writeFieldBegin('totalPhysicalMemory', TType.I32, 7)
+ oprot.writeI32(self.totalPhysicalMemory)
+ oprot.writeFieldEnd()
+ if self.chessisNumber is not None:
+ oprot.writeFieldBegin('chessisNumber', TType.STRING, 8)
+ oprot.writeString(self.chessisNumber.encode('utf-8') if sys.version_info[0] == 2 else self.chessisNumber)
+ oprot.writeFieldEnd()
+ if self.staticWorkingDir is not None:
+ oprot.writeFieldBegin('staticWorkingDir', TType.STRING, 9)
+ oprot.writeString(self.staticWorkingDir.encode('utf-8') if sys.version_info[0] == 2 else self.staticWorkingDir)
+ oprot.writeFieldEnd()
+ if self.overrideLoginUserName is not None:
+ oprot.writeFieldBegin('overrideLoginUserName', TType.STRING, 10)
+ oprot.writeString(self.overrideLoginUserName.encode('utf-8') if sys.version_info[0] == 2 else self.overrideLoginUserName)
+ oprot.writeFieldEnd()
+ if self.overrideScratchLocation is not None:
+ oprot.writeFieldBegin('overrideScratchLocation', TType.STRING, 11)
+ oprot.writeString(self.overrideScratchLocation.encode('utf-8') if sys.version_info[0] == 2 else self.overrideScratchLocation)
+ oprot.writeFieldEnd()
+ if self.overrideAllocationProjectNumber is not None:
+ oprot.writeFieldBegin('overrideAllocationProjectNumber', TType.STRING, 12)
+ oprot.writeString(self.overrideAllocationProjectNumber.encode('utf-8') if sys.version_info[0] == 2 else self.overrideAllocationProjectNumber)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/security/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/security/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/security/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/security/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/security/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/security/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/security/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/security/ttypes.py
index 74c50e7..596f6ed 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/security/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/security/ttypes.py
@@ -1,108 +1,97 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
+class AuthzToken(object):
+ """
+ Attributes:
+ - accessToken
+ - claimsMap
+ """
-class AuthzToken:
- """
- Attributes:
- - accessToken
- - claimsMap
- """
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'accessToken', 'UTF8', None, ), # 1
+ (2, TType.MAP, 'claimsMap', (TType.STRING, 'UTF8', TType.STRING, 'UTF8', False), None, ), # 2
+ )
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'accessToken', None, None, ), # 1
- (2, TType.MAP, 'claimsMap', (TType.STRING,None,TType.STRING,None), None, ), # 2
- )
+ def __init__(self, accessToken=None, claimsMap=None,):
+ self.accessToken = accessToken
+ self.claimsMap = claimsMap
- def __init__(self, accessToken=None, claimsMap=None,):
- self.accessToken = accessToken
- self.claimsMap = claimsMap
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.accessToken = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.MAP:
+ self.claimsMap = {}
+ (_ktype1, _vtype2, _size0) = iprot.readMapBegin()
+ for _i4 in range(_size0):
+ _key5 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ _val6 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ self.claimsMap[_key5] = _val6
+ iprot.readMapEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.accessToken = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.MAP:
- self.claimsMap = {}
- (_ktype1, _vtype2, _size0 ) = iprot.readMapBegin()
- for _i4 in xrange(_size0):
- _key5 = iprot.readString()
- _val6 = iprot.readString()
- self.claimsMap[_key5] = _val6
- iprot.readMapEnd()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('AuthzToken')
+ if self.accessToken is not None:
+ oprot.writeFieldBegin('accessToken', TType.STRING, 1)
+ oprot.writeString(self.accessToken.encode('utf-8') if sys.version_info[0] == 2 else self.accessToken)
+ oprot.writeFieldEnd()
+ if self.claimsMap is not None:
+ oprot.writeFieldBegin('claimsMap', TType.MAP, 2)
+ oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.claimsMap))
+ for kiter7, viter8 in self.claimsMap.items():
+ oprot.writeString(kiter7.encode('utf-8') if sys.version_info[0] == 2 else kiter7)
+ oprot.writeString(viter8.encode('utf-8') if sys.version_info[0] == 2 else viter8)
+ oprot.writeMapEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('AuthzToken')
- if self.accessToken is not None:
- oprot.writeFieldBegin('accessToken', TType.STRING, 1)
- oprot.writeString(self.accessToken)
- oprot.writeFieldEnd()
- if self.claimsMap is not None:
- oprot.writeFieldBegin('claimsMap', TType.MAP, 2)
- oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.claimsMap))
- for kiter7,viter8 in self.claimsMap.items():
- oprot.writeString(kiter7)
- oprot.writeString(viter8)
- oprot.writeMapEnd()
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
+ def validate(self):
+ if self.accessToken is None:
+ raise TProtocolException(message='Required field accessToken is unset!')
+ return
- def validate(self):
- if self.accessToken is None:
- raise TProtocol.TProtocolException(message='Required field accessToken is unset!')
- return
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.accessToken)
- value = (value * 31) ^ hash(self.claimsMap)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/sharing/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/sharing/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/sharing/constants.py
index 68ebfe8..f4184ce 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/sharing/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/sharing/constants.py
@@ -1,12 +1,13 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
DO_NOT_SET_AT_CLIENTS_ID = "DO_NOT_SET_AT_CLIENTS_ID"
[37/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/experiment/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/experiment/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/experiment/ttypes.py
index 9144a24..e4e2e45 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/experiment/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/experiment/ttypes.py
@@ -1,1132 +1,1061 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.commons.ttypes
import apache.airavata.model.application.io.ttypes
import apache.airavata.model.scheduling.ttypes
import apache.airavata.model.status.ttypes
import apache.airavata.model.process.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class ExperimentType:
- SINGLE_APPLICATION = 0
- WORKFLOW = 1
-
- _VALUES_TO_NAMES = {
- 0: "SINGLE_APPLICATION",
- 1: "WORKFLOW",
- }
-
- _NAMES_TO_VALUES = {
- "SINGLE_APPLICATION": 0,
- "WORKFLOW": 1,
- }
-
-class ExperimentSearchFields:
- EXPERIMENT_NAME = 0
- EXPERIMENT_DESC = 1
- APPLICATION_ID = 2
- FROM_DATE = 3
- TO_DATE = 4
- STATUS = 5
- PROJECT_ID = 6
-
- _VALUES_TO_NAMES = {
- 0: "EXPERIMENT_NAME",
- 1: "EXPERIMENT_DESC",
- 2: "APPLICATION_ID",
- 3: "FROM_DATE",
- 4: "TO_DATE",
- 5: "STATUS",
- 6: "PROJECT_ID",
- }
-
- _NAMES_TO_VALUES = {
- "EXPERIMENT_NAME": 0,
- "EXPERIMENT_DESC": 1,
- "APPLICATION_ID": 2,
- "FROM_DATE": 3,
- "TO_DATE": 4,
- "STATUS": 5,
- "PROJECT_ID": 6,
- }
-
-class ProjectSearchFields:
- PROJECT_NAME = 0
- PROJECT_DESCRIPTION = 1
-
- _VALUES_TO_NAMES = {
- 0: "PROJECT_NAME",
- 1: "PROJECT_DESCRIPTION",
- }
-
- _NAMES_TO_VALUES = {
- "PROJECT_NAME": 0,
- "PROJECT_DESCRIPTION": 1,
- }
-
-
-class UserConfigurationDataModel:
- """
- A structure holding the experiment configuration.
-
-
-
- Attributes:
- - airavataAutoSchedule
- - overrideManualScheduledParams
- - shareExperimentPublicly
- - computationalResourceScheduling
- - throttleResources
- - userDN
- - generateCert
- - storageId
- - experimentDataDir
- - useUserCRPref
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.BOOL, 'airavataAutoSchedule', None, False, ), # 1
- (2, TType.BOOL, 'overrideManualScheduledParams', None, False, ), # 2
- (3, TType.BOOL, 'shareExperimentPublicly', None, False, ), # 3
- (4, TType.STRUCT, 'computationalResourceScheduling', (apache.airavata.model.scheduling.ttypes.ComputationalResourceSchedulingModel, apache.airavata.model.scheduling.ttypes.ComputationalResourceSchedulingModel.thrift_spec), None, ), # 4
- (5, TType.BOOL, 'throttleResources', None, False, ), # 5
- (6, TType.STRING, 'userDN', None, None, ), # 6
- (7, TType.BOOL, 'generateCert', None, False, ), # 7
- (8, TType.STRING, 'storageId', None, None, ), # 8
- (9, TType.STRING, 'experimentDataDir', None, None, ), # 9
- (10, TType.BOOL, 'useUserCRPref', None, None, ), # 10
- )
-
- def __init__(self, airavataAutoSchedule=thrift_spec[1][4], overrideManualScheduledParams=thrift_spec[2][4], shareExperimentPublicly=thrift_spec[3][4], computationalResourceScheduling=None, throttleResources=thrift_spec[5][4], userDN=None, generateCert=thrift_spec[7][4], storageId=None, experimentDataDir=None, useUserCRPref=None,):
- self.airavataAutoSchedule = airavataAutoSchedule
- self.overrideManualScheduledParams = overrideManualScheduledParams
- self.shareExperimentPublicly = shareExperimentPublicly
- self.computationalResourceScheduling = computationalResourceScheduling
- self.throttleResources = throttleResources
- self.userDN = userDN
- self.generateCert = generateCert
- self.storageId = storageId
- self.experimentDataDir = experimentDataDir
- self.useUserCRPref = useUserCRPref
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.BOOL:
- self.airavataAutoSchedule = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.BOOL:
- self.overrideManualScheduledParams = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.BOOL:
- self.shareExperimentPublicly = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRUCT:
- self.computationalResourceScheduling = apache.airavata.model.scheduling.ttypes.ComputationalResourceSchedulingModel()
- self.computationalResourceScheduling.read(iprot)
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.BOOL:
- self.throttleResources = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.userDN = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.BOOL:
- self.generateCert = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.STRING:
- self.storageId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.STRING:
- self.experimentDataDir = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.BOOL:
- self.useUserCRPref = iprot.readBool()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('UserConfigurationDataModel')
- if self.airavataAutoSchedule is not None:
- oprot.writeFieldBegin('airavataAutoSchedule', TType.BOOL, 1)
- oprot.writeBool(self.airavataAutoSchedule)
- oprot.writeFieldEnd()
- if self.overrideManualScheduledParams is not None:
- oprot.writeFieldBegin('overrideManualScheduledParams', TType.BOOL, 2)
- oprot.writeBool(self.overrideManualScheduledParams)
- oprot.writeFieldEnd()
- if self.shareExperimentPublicly is not None:
- oprot.writeFieldBegin('shareExperimentPublicly', TType.BOOL, 3)
- oprot.writeBool(self.shareExperimentPublicly)
- oprot.writeFieldEnd()
- if self.computationalResourceScheduling is not None:
- oprot.writeFieldBegin('computationalResourceScheduling', TType.STRUCT, 4)
- self.computationalResourceScheduling.write(oprot)
- oprot.writeFieldEnd()
- if self.throttleResources is not None:
- oprot.writeFieldBegin('throttleResources', TType.BOOL, 5)
- oprot.writeBool(self.throttleResources)
- oprot.writeFieldEnd()
- if self.userDN is not None:
- oprot.writeFieldBegin('userDN', TType.STRING, 6)
- oprot.writeString(self.userDN)
- oprot.writeFieldEnd()
- if self.generateCert is not None:
- oprot.writeFieldBegin('generateCert', TType.BOOL, 7)
- oprot.writeBool(self.generateCert)
- oprot.writeFieldEnd()
- if self.storageId is not None:
- oprot.writeFieldBegin('storageId', TType.STRING, 8)
- oprot.writeString(self.storageId)
- oprot.writeFieldEnd()
- if self.experimentDataDir is not None:
- oprot.writeFieldBegin('experimentDataDir', TType.STRING, 9)
- oprot.writeString(self.experimentDataDir)
- oprot.writeFieldEnd()
- if self.useUserCRPref is not None:
- oprot.writeFieldBegin('useUserCRPref', TType.BOOL, 10)
- oprot.writeBool(self.useUserCRPref)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.airavataAutoSchedule is None:
- raise TProtocol.TProtocolException(message='Required field airavataAutoSchedule is unset!')
- if self.overrideManualScheduledParams is None:
- raise TProtocol.TProtocolException(message='Required field overrideManualScheduledParams is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.airavataAutoSchedule)
- value = (value * 31) ^ hash(self.overrideManualScheduledParams)
- value = (value * 31) ^ hash(self.shareExperimentPublicly)
- value = (value * 31) ^ hash(self.computationalResourceScheduling)
- value = (value * 31) ^ hash(self.throttleResources)
- value = (value * 31) ^ hash(self.userDN)
- value = (value * 31) ^ hash(self.generateCert)
- value = (value * 31) ^ hash(self.storageId)
- value = (value * 31) ^ hash(self.experimentDataDir)
- value = (value * 31) ^ hash(self.useUserCRPref)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ExperimentModel:
- """
- A structure holding the experiment metadata and its child models.
-
- userName:
- The user name of the targeted gateway end user on whose behalf the experiment is being created.
- the associated gateway identity can only be inferred from the security hand-shake so as to avoid
- authorized Airavata Clients mimicking an unauthorized request. If a gateway is not registered with
- Airavata, an authorization exception is thrown.
-
- experimentName:
- The name of the experiment as defined by the user. The name need not be unique as uniqueness is enforced
- by the generated experiment id.
-
- experimentDescription:
- The verbose description of the experiment. This is an optional parameter.
-
- Attributes:
- - experimentId
- - projectId
- - gatewayId
- - experimentType
- - userName
- - experimentName
- - creationTime
- - description
- - executionId
- - gatewayExecutionId
- - gatewayInstanceId
- - enableEmailNotification
- - emailAddresses
- - userConfigurationData
- - experimentInputs
- - experimentOutputs
- - experimentStatus
- - errors
- - processes
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'experimentId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.STRING, 'projectId', None, None, ), # 2
- (3, TType.STRING, 'gatewayId', None, None, ), # 3
- (4, TType.I32, 'experimentType', None, 0, ), # 4
- (5, TType.STRING, 'userName', None, None, ), # 5
- (6, TType.STRING, 'experimentName', None, None, ), # 6
- (7, TType.I64, 'creationTime', None, None, ), # 7
- (8, TType.STRING, 'description', None, None, ), # 8
- (9, TType.STRING, 'executionId', None, None, ), # 9
- (10, TType.STRING, 'gatewayExecutionId', None, None, ), # 10
- (11, TType.STRING, 'gatewayInstanceId', None, None, ), # 11
- (12, TType.BOOL, 'enableEmailNotification', None, None, ), # 12
- (13, TType.LIST, 'emailAddresses', (TType.STRING,None), None, ), # 13
- (14, TType.STRUCT, 'userConfigurationData', (UserConfigurationDataModel, UserConfigurationDataModel.thrift_spec), None, ), # 14
- (15, TType.LIST, 'experimentInputs', (TType.STRUCT,(apache.airavata.model.application.io.ttypes.InputDataObjectType, apache.airavata.model.application.io.ttypes.InputDataObjectType.thrift_spec)), None, ), # 15
- (16, TType.LIST, 'experimentOutputs', (TType.STRUCT,(apache.airavata.model.application.io.ttypes.OutputDataObjectType, apache.airavata.model.application.io.ttypes.OutputDataObjectType.thrift_spec)), None, ), # 16
- (17, TType.LIST, 'experimentStatus', (TType.STRUCT,(apache.airavata.model.status.ttypes.ExperimentStatus, apache.airavata.model.status.ttypes.ExperimentStatus.thrift_spec)), None, ), # 17
- (18, TType.LIST, 'errors', (TType.STRUCT,(apache.airavata.model.commons.ttypes.ErrorModel, apache.airavata.model.commons.ttypes.ErrorModel.thrift_spec)), None, ), # 18
- (19, TType.LIST, 'processes', (TType.STRUCT,(apache.airavata.model.process.ttypes.ProcessModel, apache.airavata.model.process.ttypes.ProcessModel.thrift_spec)), None, ), # 19
- )
-
- def __init__(self, experimentId=thrift_spec[1][4], projectId=None, gatewayId=None, experimentType=thrift_spec[4][4], userName=None, experimentName=None, creationTime=None, description=None, executionId=None, gatewayExecutionId=None, gatewayInstanceId=None, enableEmailNotification=None, emailAddresses=None, userConfigurationData=None, experimentInputs=None, experimentOutputs=None, experimentStatus=None, errors=None, processes=None,):
- self.experimentId = experimentId
- self.projectId = projectId
- self.gatewayId = gatewayId
- self.experimentType = experimentType
- self.userName = userName
- self.experimentName = experimentName
- self.creationTime = creationTime
- self.description = description
- self.executionId = executionId
- self.gatewayExecutionId = gatewayExecutionId
- self.gatewayInstanceId = gatewayInstanceId
- self.enableEmailNotification = enableEmailNotification
- self.emailAddresses = emailAddresses
- self.userConfigurationData = userConfigurationData
- self.experimentInputs = experimentInputs
- self.experimentOutputs = experimentOutputs
- self.experimentStatus = experimentStatus
- self.errors = errors
- self.processes = processes
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.experimentId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.projectId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.I32:
- self.experimentType = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.userName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.experimentName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.I64:
- self.creationTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.STRING:
- self.description = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.STRING:
- self.executionId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.STRING:
- self.gatewayExecutionId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 11:
- if ftype == TType.STRING:
- self.gatewayInstanceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 12:
- if ftype == TType.BOOL:
- self.enableEmailNotification = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 13:
- if ftype == TType.LIST:
- self.emailAddresses = []
- (_etype3, _size0) = iprot.readListBegin()
- for _i4 in xrange(_size0):
- _elem5 = iprot.readString()
- self.emailAddresses.append(_elem5)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 14:
- if ftype == TType.STRUCT:
- self.userConfigurationData = UserConfigurationDataModel()
- self.userConfigurationData.read(iprot)
- else:
- iprot.skip(ftype)
- elif fid == 15:
- if ftype == TType.LIST:
- self.experimentInputs = []
- (_etype9, _size6) = iprot.readListBegin()
- for _i10 in xrange(_size6):
- _elem11 = apache.airavata.model.application.io.ttypes.InputDataObjectType()
- _elem11.read(iprot)
- self.experimentInputs.append(_elem11)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 16:
- if ftype == TType.LIST:
- self.experimentOutputs = []
- (_etype15, _size12) = iprot.readListBegin()
- for _i16 in xrange(_size12):
- _elem17 = apache.airavata.model.application.io.ttypes.OutputDataObjectType()
- _elem17.read(iprot)
- self.experimentOutputs.append(_elem17)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 17:
- if ftype == TType.LIST:
- self.experimentStatus = []
- (_etype21, _size18) = iprot.readListBegin()
- for _i22 in xrange(_size18):
- _elem23 = apache.airavata.model.status.ttypes.ExperimentStatus()
- _elem23.read(iprot)
- self.experimentStatus.append(_elem23)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 18:
- if ftype == TType.LIST:
- self.errors = []
- (_etype27, _size24) = iprot.readListBegin()
- for _i28 in xrange(_size24):
- _elem29 = apache.airavata.model.commons.ttypes.ErrorModel()
- _elem29.read(iprot)
- self.errors.append(_elem29)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 19:
- if ftype == TType.LIST:
- self.processes = []
- (_etype33, _size30) = iprot.readListBegin()
- for _i34 in xrange(_size30):
- _elem35 = apache.airavata.model.process.ttypes.ProcessModel()
- _elem35.read(iprot)
- self.processes.append(_elem35)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ExperimentModel')
- if self.experimentId is not None:
- oprot.writeFieldBegin('experimentId', TType.STRING, 1)
- oprot.writeString(self.experimentId)
- oprot.writeFieldEnd()
- if self.projectId is not None:
- oprot.writeFieldBegin('projectId', TType.STRING, 2)
- oprot.writeString(self.projectId)
- oprot.writeFieldEnd()
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 3)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- if self.experimentType is not None:
- oprot.writeFieldBegin('experimentType', TType.I32, 4)
- oprot.writeI32(self.experimentType)
- oprot.writeFieldEnd()
- if self.userName is not None:
- oprot.writeFieldBegin('userName', TType.STRING, 5)
- oprot.writeString(self.userName)
- oprot.writeFieldEnd()
- if self.experimentName is not None:
- oprot.writeFieldBegin('experimentName', TType.STRING, 6)
- oprot.writeString(self.experimentName)
- oprot.writeFieldEnd()
- if self.creationTime is not None:
- oprot.writeFieldBegin('creationTime', TType.I64, 7)
- oprot.writeI64(self.creationTime)
- oprot.writeFieldEnd()
- if self.description is not None:
- oprot.writeFieldBegin('description', TType.STRING, 8)
- oprot.writeString(self.description)
- oprot.writeFieldEnd()
- if self.executionId is not None:
- oprot.writeFieldBegin('executionId', TType.STRING, 9)
- oprot.writeString(self.executionId)
- oprot.writeFieldEnd()
- if self.gatewayExecutionId is not None:
- oprot.writeFieldBegin('gatewayExecutionId', TType.STRING, 10)
- oprot.writeString(self.gatewayExecutionId)
- oprot.writeFieldEnd()
- if self.gatewayInstanceId is not None:
- oprot.writeFieldBegin('gatewayInstanceId', TType.STRING, 11)
- oprot.writeString(self.gatewayInstanceId)
- oprot.writeFieldEnd()
- if self.enableEmailNotification is not None:
- oprot.writeFieldBegin('enableEmailNotification', TType.BOOL, 12)
- oprot.writeBool(self.enableEmailNotification)
- oprot.writeFieldEnd()
- if self.emailAddresses is not None:
- oprot.writeFieldBegin('emailAddresses', TType.LIST, 13)
- oprot.writeListBegin(TType.STRING, len(self.emailAddresses))
- for iter36 in self.emailAddresses:
- oprot.writeString(iter36)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.userConfigurationData is not None:
- oprot.writeFieldBegin('userConfigurationData', TType.STRUCT, 14)
- self.userConfigurationData.write(oprot)
- oprot.writeFieldEnd()
- if self.experimentInputs is not None:
- oprot.writeFieldBegin('experimentInputs', TType.LIST, 15)
- oprot.writeListBegin(TType.STRUCT, len(self.experimentInputs))
- for iter37 in self.experimentInputs:
- iter37.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.experimentOutputs is not None:
- oprot.writeFieldBegin('experimentOutputs', TType.LIST, 16)
- oprot.writeListBegin(TType.STRUCT, len(self.experimentOutputs))
- for iter38 in self.experimentOutputs:
- iter38.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.experimentStatus is not None:
- oprot.writeFieldBegin('experimentStatus', TType.LIST, 17)
- oprot.writeListBegin(TType.STRUCT, len(self.experimentStatus))
- for iter39 in self.experimentStatus:
- iter39.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.errors is not None:
- oprot.writeFieldBegin('errors', TType.LIST, 18)
- oprot.writeListBegin(TType.STRUCT, len(self.errors))
- for iter40 in self.errors:
- iter40.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.processes is not None:
- oprot.writeFieldBegin('processes', TType.LIST, 19)
- oprot.writeListBegin(TType.STRUCT, len(self.processes))
- for iter41 in self.processes:
- iter41.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.experimentId is None:
- raise TProtocol.TProtocolException(message='Required field experimentId is unset!')
- if self.projectId is None:
- raise TProtocol.TProtocolException(message='Required field projectId is unset!')
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- if self.experimentType is None:
- raise TProtocol.TProtocolException(message='Required field experimentType is unset!')
- if self.userName is None:
- raise TProtocol.TProtocolException(message='Required field userName is unset!')
- if self.experimentName is None:
- raise TProtocol.TProtocolException(message='Required field experimentName is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.experimentId)
- value = (value * 31) ^ hash(self.projectId)
- value = (value * 31) ^ hash(self.gatewayId)
- value = (value * 31) ^ hash(self.experimentType)
- value = (value * 31) ^ hash(self.userName)
- value = (value * 31) ^ hash(self.experimentName)
- value = (value * 31) ^ hash(self.creationTime)
- value = (value * 31) ^ hash(self.description)
- value = (value * 31) ^ hash(self.executionId)
- value = (value * 31) ^ hash(self.gatewayExecutionId)
- value = (value * 31) ^ hash(self.gatewayInstanceId)
- value = (value * 31) ^ hash(self.enableEmailNotification)
- value = (value * 31) ^ hash(self.emailAddresses)
- value = (value * 31) ^ hash(self.userConfigurationData)
- value = (value * 31) ^ hash(self.experimentInputs)
- value = (value * 31) ^ hash(self.experimentOutputs)
- value = (value * 31) ^ hash(self.experimentStatus)
- value = (value * 31) ^ hash(self.errors)
- value = (value * 31) ^ hash(self.processes)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ExperimentSummaryModel:
- """
- Attributes:
- - experimentId
- - projectId
- - gatewayId
- - creationTime
- - userName
- - name
- - description
- - executionId
- - resourceHostId
- - experimentStatus
- - statusUpdateTime
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'experimentId', None, None, ), # 1
- (2, TType.STRING, 'projectId', None, None, ), # 2
- (3, TType.STRING, 'gatewayId', None, None, ), # 3
- (4, TType.I64, 'creationTime', None, None, ), # 4
- (5, TType.STRING, 'userName', None, None, ), # 5
- (6, TType.STRING, 'name', None, None, ), # 6
- (7, TType.STRING, 'description', None, None, ), # 7
- (8, TType.STRING, 'executionId', None, None, ), # 8
- (9, TType.STRING, 'resourceHostId', None, None, ), # 9
- (10, TType.STRING, 'experimentStatus', None, None, ), # 10
- None, # 11
- (12, TType.I64, 'statusUpdateTime', None, None, ), # 12
- )
-
- def __init__(self, experimentId=None, projectId=None, gatewayId=None, creationTime=None, userName=None, name=None, description=None, executionId=None, resourceHostId=None, experimentStatus=None, statusUpdateTime=None,):
- self.experimentId = experimentId
- self.projectId = projectId
- self.gatewayId = gatewayId
- self.creationTime = creationTime
- self.userName = userName
- self.name = name
- self.description = description
- self.executionId = executionId
- self.resourceHostId = resourceHostId
- self.experimentStatus = experimentStatus
- self.statusUpdateTime = statusUpdateTime
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.experimentId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.projectId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.gatewayId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.I64:
- self.creationTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.userName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.name = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.STRING:
- self.description = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.STRING:
- self.executionId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.STRING:
- self.resourceHostId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.STRING:
- self.experimentStatus = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 12:
- if ftype == TType.I64:
- self.statusUpdateTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ExperimentSummaryModel')
- if self.experimentId is not None:
- oprot.writeFieldBegin('experimentId', TType.STRING, 1)
- oprot.writeString(self.experimentId)
- oprot.writeFieldEnd()
- if self.projectId is not None:
- oprot.writeFieldBegin('projectId', TType.STRING, 2)
- oprot.writeString(self.projectId)
- oprot.writeFieldEnd()
- if self.gatewayId is not None:
- oprot.writeFieldBegin('gatewayId', TType.STRING, 3)
- oprot.writeString(self.gatewayId)
- oprot.writeFieldEnd()
- if self.creationTime is not None:
- oprot.writeFieldBegin('creationTime', TType.I64, 4)
- oprot.writeI64(self.creationTime)
- oprot.writeFieldEnd()
- if self.userName is not None:
- oprot.writeFieldBegin('userName', TType.STRING, 5)
- oprot.writeString(self.userName)
- oprot.writeFieldEnd()
- if self.name is not None:
- oprot.writeFieldBegin('name', TType.STRING, 6)
- oprot.writeString(self.name)
- oprot.writeFieldEnd()
- if self.description is not None:
- oprot.writeFieldBegin('description', TType.STRING, 7)
- oprot.writeString(self.description)
- oprot.writeFieldEnd()
- if self.executionId is not None:
- oprot.writeFieldBegin('executionId', TType.STRING, 8)
- oprot.writeString(self.executionId)
- oprot.writeFieldEnd()
- if self.resourceHostId is not None:
- oprot.writeFieldBegin('resourceHostId', TType.STRING, 9)
- oprot.writeString(self.resourceHostId)
- oprot.writeFieldEnd()
- if self.experimentStatus is not None:
- oprot.writeFieldBegin('experimentStatus', TType.STRING, 10)
- oprot.writeString(self.experimentStatus)
- oprot.writeFieldEnd()
- if self.statusUpdateTime is not None:
- oprot.writeFieldBegin('statusUpdateTime', TType.I64, 12)
- oprot.writeI64(self.statusUpdateTime)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.experimentId is None:
- raise TProtocol.TProtocolException(message='Required field experimentId is unset!')
- if self.projectId is None:
- raise TProtocol.TProtocolException(message='Required field projectId is unset!')
- if self.gatewayId is None:
- raise TProtocol.TProtocolException(message='Required field gatewayId is unset!')
- if self.userName is None:
- raise TProtocol.TProtocolException(message='Required field userName is unset!')
- if self.name is None:
- raise TProtocol.TProtocolException(message='Required field name is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.experimentId)
- value = (value * 31) ^ hash(self.projectId)
- value = (value * 31) ^ hash(self.gatewayId)
- value = (value * 31) ^ hash(self.creationTime)
- value = (value * 31) ^ hash(self.userName)
- value = (value * 31) ^ hash(self.name)
- value = (value * 31) ^ hash(self.description)
- value = (value * 31) ^ hash(self.executionId)
- value = (value * 31) ^ hash(self.resourceHostId)
- value = (value * 31) ^ hash(self.experimentStatus)
- value = (value * 31) ^ hash(self.statusUpdateTime)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ExperimentStatistics:
- """
- Attributes:
- - allExperimentCount
- - completedExperimentCount
- - cancelledExperimentCount
- - failedExperimentCount
- - createdExperimentCount
- - runningExperimentCount
- - allExperiments
- - completedExperiments
- - failedExperiments
- - cancelledExperiments
- - createdExperiments
- - runningExperiments
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'allExperimentCount', None, None, ), # 1
- (2, TType.I32, 'completedExperimentCount', None, None, ), # 2
- (3, TType.I32, 'cancelledExperimentCount', None, None, ), # 3
- (4, TType.I32, 'failedExperimentCount', None, None, ), # 4
- (5, TType.I32, 'createdExperimentCount', None, None, ), # 5
- (6, TType.I32, 'runningExperimentCount', None, None, ), # 6
- (7, TType.LIST, 'allExperiments', (TType.STRUCT,(ExperimentSummaryModel, ExperimentSummaryModel.thrift_spec)), None, ), # 7
- (8, TType.LIST, 'completedExperiments', (TType.STRUCT,(ExperimentSummaryModel, ExperimentSummaryModel.thrift_spec)), None, ), # 8
- (9, TType.LIST, 'failedExperiments', (TType.STRUCT,(ExperimentSummaryModel, ExperimentSummaryModel.thrift_spec)), None, ), # 9
- (10, TType.LIST, 'cancelledExperiments', (TType.STRUCT,(ExperimentSummaryModel, ExperimentSummaryModel.thrift_spec)), None, ), # 10
- (11, TType.LIST, 'createdExperiments', (TType.STRUCT,(ExperimentSummaryModel, ExperimentSummaryModel.thrift_spec)), None, ), # 11
- (12, TType.LIST, 'runningExperiments', (TType.STRUCT,(ExperimentSummaryModel, ExperimentSummaryModel.thrift_spec)), None, ), # 12
- )
-
- def __init__(self, allExperimentCount=None, completedExperimentCount=None, cancelledExperimentCount=None, failedExperimentCount=None, createdExperimentCount=None, runningExperimentCount=None, allExperiments=None, completedExperiments=None, failedExperiments=None, cancelledExperiments=None, createdExperiments=None, runningExperiments=None,):
- self.allExperimentCount = allExperimentCount
- self.completedExperimentCount = completedExperimentCount
- self.cancelledExperimentCount = cancelledExperimentCount
- self.failedExperimentCount = failedExperimentCount
- self.createdExperimentCount = createdExperimentCount
- self.runningExperimentCount = runningExperimentCount
- self.allExperiments = allExperiments
- self.completedExperiments = completedExperiments
- self.failedExperiments = failedExperiments
- self.cancelledExperiments = cancelledExperiments
- self.createdExperiments = createdExperiments
- self.runningExperiments = runningExperiments
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.allExperimentCount = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.completedExperimentCount = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.I32:
- self.cancelledExperimentCount = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.I32:
- self.failedExperimentCount = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I32:
- self.createdExperimentCount = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.I32:
- self.runningExperimentCount = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.LIST:
- self.allExperiments = []
- (_etype45, _size42) = iprot.readListBegin()
- for _i46 in xrange(_size42):
- _elem47 = ExperimentSummaryModel()
- _elem47.read(iprot)
- self.allExperiments.append(_elem47)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.LIST:
- self.completedExperiments = []
- (_etype51, _size48) = iprot.readListBegin()
- for _i52 in xrange(_size48):
- _elem53 = ExperimentSummaryModel()
- _elem53.read(iprot)
- self.completedExperiments.append(_elem53)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.LIST:
- self.failedExperiments = []
- (_etype57, _size54) = iprot.readListBegin()
- for _i58 in xrange(_size54):
- _elem59 = ExperimentSummaryModel()
- _elem59.read(iprot)
- self.failedExperiments.append(_elem59)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.LIST:
- self.cancelledExperiments = []
- (_etype63, _size60) = iprot.readListBegin()
- for _i64 in xrange(_size60):
- _elem65 = ExperimentSummaryModel()
- _elem65.read(iprot)
- self.cancelledExperiments.append(_elem65)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 11:
- if ftype == TType.LIST:
- self.createdExperiments = []
- (_etype69, _size66) = iprot.readListBegin()
- for _i70 in xrange(_size66):
- _elem71 = ExperimentSummaryModel()
- _elem71.read(iprot)
- self.createdExperiments.append(_elem71)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 12:
- if ftype == TType.LIST:
- self.runningExperiments = []
- (_etype75, _size72) = iprot.readListBegin()
- for _i76 in xrange(_size72):
- _elem77 = ExperimentSummaryModel()
- _elem77.read(iprot)
- self.runningExperiments.append(_elem77)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ExperimentStatistics')
- if self.allExperimentCount is not None:
- oprot.writeFieldBegin('allExperimentCount', TType.I32, 1)
- oprot.writeI32(self.allExperimentCount)
- oprot.writeFieldEnd()
- if self.completedExperimentCount is not None:
- oprot.writeFieldBegin('completedExperimentCount', TType.I32, 2)
- oprot.writeI32(self.completedExperimentCount)
- oprot.writeFieldEnd()
- if self.cancelledExperimentCount is not None:
- oprot.writeFieldBegin('cancelledExperimentCount', TType.I32, 3)
- oprot.writeI32(self.cancelledExperimentCount)
- oprot.writeFieldEnd()
- if self.failedExperimentCount is not None:
- oprot.writeFieldBegin('failedExperimentCount', TType.I32, 4)
- oprot.writeI32(self.failedExperimentCount)
- oprot.writeFieldEnd()
- if self.createdExperimentCount is not None:
- oprot.writeFieldBegin('createdExperimentCount', TType.I32, 5)
- oprot.writeI32(self.createdExperimentCount)
- oprot.writeFieldEnd()
- if self.runningExperimentCount is not None:
- oprot.writeFieldBegin('runningExperimentCount', TType.I32, 6)
- oprot.writeI32(self.runningExperimentCount)
- oprot.writeFieldEnd()
- if self.allExperiments is not None:
- oprot.writeFieldBegin('allExperiments', TType.LIST, 7)
- oprot.writeListBegin(TType.STRUCT, len(self.allExperiments))
- for iter78 in self.allExperiments:
- iter78.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.completedExperiments is not None:
- oprot.writeFieldBegin('completedExperiments', TType.LIST, 8)
- oprot.writeListBegin(TType.STRUCT, len(self.completedExperiments))
- for iter79 in self.completedExperiments:
- iter79.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.failedExperiments is not None:
- oprot.writeFieldBegin('failedExperiments', TType.LIST, 9)
- oprot.writeListBegin(TType.STRUCT, len(self.failedExperiments))
- for iter80 in self.failedExperiments:
- iter80.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.cancelledExperiments is not None:
- oprot.writeFieldBegin('cancelledExperiments', TType.LIST, 10)
- oprot.writeListBegin(TType.STRUCT, len(self.cancelledExperiments))
- for iter81 in self.cancelledExperiments:
- iter81.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.createdExperiments is not None:
- oprot.writeFieldBegin('createdExperiments', TType.LIST, 11)
- oprot.writeListBegin(TType.STRUCT, len(self.createdExperiments))
- for iter82 in self.createdExperiments:
- iter82.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.runningExperiments is not None:
- oprot.writeFieldBegin('runningExperiments', TType.LIST, 12)
- oprot.writeListBegin(TType.STRUCT, len(self.runningExperiments))
- for iter83 in self.runningExperiments:
- iter83.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.allExperimentCount is None:
- raise TProtocol.TProtocolException(message='Required field allExperimentCount is unset!')
- if self.completedExperimentCount is None:
- raise TProtocol.TProtocolException(message='Required field completedExperimentCount is unset!')
- if self.failedExperimentCount is None:
- raise TProtocol.TProtocolException(message='Required field failedExperimentCount is unset!')
- if self.createdExperimentCount is None:
- raise TProtocol.TProtocolException(message='Required field createdExperimentCount is unset!')
- if self.runningExperimentCount is None:
- raise TProtocol.TProtocolException(message='Required field runningExperimentCount is unset!')
- if self.allExperiments is None:
- raise TProtocol.TProtocolException(message='Required field allExperiments is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.allExperimentCount)
- value = (value * 31) ^ hash(self.completedExperimentCount)
- value = (value * 31) ^ hash(self.cancelledExperimentCount)
- value = (value * 31) ^ hash(self.failedExperimentCount)
- value = (value * 31) ^ hash(self.createdExperimentCount)
- value = (value * 31) ^ hash(self.runningExperimentCount)
- value = (value * 31) ^ hash(self.allExperiments)
- value = (value * 31) ^ hash(self.completedExperiments)
- value = (value * 31) ^ hash(self.failedExperiments)
- value = (value * 31) ^ hash(self.cancelledExperiments)
- value = (value * 31) ^ hash(self.createdExperiments)
- value = (value * 31) ^ hash(self.runningExperiments)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
- def __ne__(self, other):
- return not (self == other)
+class ExperimentType(object):
+ SINGLE_APPLICATION = 0
+ WORKFLOW = 1
+
+ _VALUES_TO_NAMES = {
+ 0: "SINGLE_APPLICATION",
+ 1: "WORKFLOW",
+ }
+
+ _NAMES_TO_VALUES = {
+ "SINGLE_APPLICATION": 0,
+ "WORKFLOW": 1,
+ }
+
+
+class ExperimentSearchFields(object):
+ EXPERIMENT_NAME = 0
+ EXPERIMENT_DESC = 1
+ APPLICATION_ID = 2
+ FROM_DATE = 3
+ TO_DATE = 4
+ STATUS = 5
+ PROJECT_ID = 6
+
+ _VALUES_TO_NAMES = {
+ 0: "EXPERIMENT_NAME",
+ 1: "EXPERIMENT_DESC",
+ 2: "APPLICATION_ID",
+ 3: "FROM_DATE",
+ 4: "TO_DATE",
+ 5: "STATUS",
+ 6: "PROJECT_ID",
+ }
+
+ _NAMES_TO_VALUES = {
+ "EXPERIMENT_NAME": 0,
+ "EXPERIMENT_DESC": 1,
+ "APPLICATION_ID": 2,
+ "FROM_DATE": 3,
+ "TO_DATE": 4,
+ "STATUS": 5,
+ "PROJECT_ID": 6,
+ }
+
+
+class ProjectSearchFields(object):
+ PROJECT_NAME = 0
+ PROJECT_DESCRIPTION = 1
+
+ _VALUES_TO_NAMES = {
+ 0: "PROJECT_NAME",
+ 1: "PROJECT_DESCRIPTION",
+ }
+
+ _NAMES_TO_VALUES = {
+ "PROJECT_NAME": 0,
+ "PROJECT_DESCRIPTION": 1,
+ }
+
+
+class UserConfigurationDataModel(object):
+ """
+ A structure holding the experiment configuration.
+
+
+
+ Attributes:
+ - airavataAutoSchedule
+ - overrideManualScheduledParams
+ - shareExperimentPublicly
+ - computationalResourceScheduling
+ - throttleResources
+ - userDN
+ - generateCert
+ - storageId
+ - experimentDataDir
+ - useUserCRPref
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.BOOL, 'airavataAutoSchedule', None, False, ), # 1
+ (2, TType.BOOL, 'overrideManualScheduledParams', None, False, ), # 2
+ (3, TType.BOOL, 'shareExperimentPublicly', None, False, ), # 3
+ (4, TType.STRUCT, 'computationalResourceScheduling', (apache.airavata.model.scheduling.ttypes.ComputationalResourceSchedulingModel, apache.airavata.model.scheduling.ttypes.ComputationalResourceSchedulingModel.thrift_spec), None, ), # 4
+ (5, TType.BOOL, 'throttleResources', None, False, ), # 5
+ (6, TType.STRING, 'userDN', 'UTF8', None, ), # 6
+ (7, TType.BOOL, 'generateCert', None, False, ), # 7
+ (8, TType.STRING, 'storageId', 'UTF8', None, ), # 8
+ (9, TType.STRING, 'experimentDataDir', 'UTF8', None, ), # 9
+ (10, TType.BOOL, 'useUserCRPref', None, None, ), # 10
+ )
+
+ def __init__(self, airavataAutoSchedule=thrift_spec[1][4], overrideManualScheduledParams=thrift_spec[2][4], shareExperimentPublicly=thrift_spec[3][4], computationalResourceScheduling=None, throttleResources=thrift_spec[5][4], userDN=None, generateCert=thrift_spec[7][4], storageId=None, experimentDataDir=None, useUserCRPref=None,):
+ self.airavataAutoSchedule = airavataAutoSchedule
+ self.overrideManualScheduledParams = overrideManualScheduledParams
+ self.shareExperimentPublicly = shareExperimentPublicly
+ self.computationalResourceScheduling = computationalResourceScheduling
+ self.throttleResources = throttleResources
+ self.userDN = userDN
+ self.generateCert = generateCert
+ self.storageId = storageId
+ self.experimentDataDir = experimentDataDir
+ self.useUserCRPref = useUserCRPref
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.BOOL:
+ self.airavataAutoSchedule = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.BOOL:
+ self.overrideManualScheduledParams = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.BOOL:
+ self.shareExperimentPublicly = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRUCT:
+ self.computationalResourceScheduling = apache.airavata.model.scheduling.ttypes.ComputationalResourceSchedulingModel()
+ self.computationalResourceScheduling.read(iprot)
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.BOOL:
+ self.throttleResources = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.userDN = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.BOOL:
+ self.generateCert = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.STRING:
+ self.storageId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.STRING:
+ self.experimentDataDir = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.BOOL:
+ self.useUserCRPref = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('UserConfigurationDataModel')
+ if self.airavataAutoSchedule is not None:
+ oprot.writeFieldBegin('airavataAutoSchedule', TType.BOOL, 1)
+ oprot.writeBool(self.airavataAutoSchedule)
+ oprot.writeFieldEnd()
+ if self.overrideManualScheduledParams is not None:
+ oprot.writeFieldBegin('overrideManualScheduledParams', TType.BOOL, 2)
+ oprot.writeBool(self.overrideManualScheduledParams)
+ oprot.writeFieldEnd()
+ if self.shareExperimentPublicly is not None:
+ oprot.writeFieldBegin('shareExperimentPublicly', TType.BOOL, 3)
+ oprot.writeBool(self.shareExperimentPublicly)
+ oprot.writeFieldEnd()
+ if self.computationalResourceScheduling is not None:
+ oprot.writeFieldBegin('computationalResourceScheduling', TType.STRUCT, 4)
+ self.computationalResourceScheduling.write(oprot)
+ oprot.writeFieldEnd()
+ if self.throttleResources is not None:
+ oprot.writeFieldBegin('throttleResources', TType.BOOL, 5)
+ oprot.writeBool(self.throttleResources)
+ oprot.writeFieldEnd()
+ if self.userDN is not None:
+ oprot.writeFieldBegin('userDN', TType.STRING, 6)
+ oprot.writeString(self.userDN.encode('utf-8') if sys.version_info[0] == 2 else self.userDN)
+ oprot.writeFieldEnd()
+ if self.generateCert is not None:
+ oprot.writeFieldBegin('generateCert', TType.BOOL, 7)
+ oprot.writeBool(self.generateCert)
+ oprot.writeFieldEnd()
+ if self.storageId is not None:
+ oprot.writeFieldBegin('storageId', TType.STRING, 8)
+ oprot.writeString(self.storageId.encode('utf-8') if sys.version_info[0] == 2 else self.storageId)
+ oprot.writeFieldEnd()
+ if self.experimentDataDir is not None:
+ oprot.writeFieldBegin('experimentDataDir', TType.STRING, 9)
+ oprot.writeString(self.experimentDataDir.encode('utf-8') if sys.version_info[0] == 2 else self.experimentDataDir)
+ oprot.writeFieldEnd()
+ if self.useUserCRPref is not None:
+ oprot.writeFieldBegin('useUserCRPref', TType.BOOL, 10)
+ oprot.writeBool(self.useUserCRPref)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.airavataAutoSchedule is None:
+ raise TProtocolException(message='Required field airavataAutoSchedule is unset!')
+ if self.overrideManualScheduledParams is None:
+ raise TProtocolException(message='Required field overrideManualScheduledParams is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class ExperimentModel(object):
+ """
+ A structure holding the experiment metadata and its child models.
+
+ userName:
+ The user name of the targeted gateway end user on whose behalf the experiment is being created.
+ the associated gateway identity can only be inferred from the security hand-shake so as to avoid
+ authorized Airavata Clients mimicking an unauthorized request. If a gateway is not registered with
+ Airavata, an authorization exception is thrown.
+
+ experimentName:
+ The name of the experiment as defined by the user. The name need not be unique as uniqueness is enforced
+ by the generated experiment id.
+
+ experimentDescription:
+ The verbose description of the experiment. This is an optional parameter.
+
+ Attributes:
+ - experimentId
+ - projectId
+ - gatewayId
+ - experimentType
+ - userName
+ - experimentName
+ - creationTime
+ - description
+ - executionId
+ - gatewayExecutionId
+ - gatewayInstanceId
+ - enableEmailNotification
+ - emailAddresses
+ - userConfigurationData
+ - experimentInputs
+ - experimentOutputs
+ - experimentStatus
+ - errors
+ - processes
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'experimentId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.STRING, 'projectId', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'gatewayId', 'UTF8', None, ), # 3
+ (4, TType.I32, 'experimentType', None, 0, ), # 4
+ (5, TType.STRING, 'userName', 'UTF8', None, ), # 5
+ (6, TType.STRING, 'experimentName', 'UTF8', None, ), # 6
+ (7, TType.I64, 'creationTime', None, None, ), # 7
+ (8, TType.STRING, 'description', 'UTF8', None, ), # 8
+ (9, TType.STRING, 'executionId', 'UTF8', None, ), # 9
+ (10, TType.STRING, 'gatewayExecutionId', 'UTF8', None, ), # 10
+ (11, TType.STRING, 'gatewayInstanceId', 'UTF8', None, ), # 11
+ (12, TType.BOOL, 'enableEmailNotification', None, None, ), # 12
+ (13, TType.LIST, 'emailAddresses', (TType.STRING, 'UTF8', False), None, ), # 13
+ (14, TType.STRUCT, 'userConfigurationData', (UserConfigurationDataModel, UserConfigurationDataModel.thrift_spec), None, ), # 14
+ (15, TType.LIST, 'experimentInputs', (TType.STRUCT, (apache.airavata.model.application.io.ttypes.InputDataObjectType, apache.airavata.model.application.io.ttypes.InputDataObjectType.thrift_spec), False), None, ), # 15
+ (16, TType.LIST, 'experimentOutputs', (TType.STRUCT, (apache.airavata.model.application.io.ttypes.OutputDataObjectType, apache.airavata.model.application.io.ttypes.OutputDataObjectType.thrift_spec), False), None, ), # 16
+ (17, TType.LIST, 'experimentStatus', (TType.STRUCT, (apache.airavata.model.status.ttypes.ExperimentStatus, apache.airavata.model.status.ttypes.ExperimentStatus.thrift_spec), False), None, ), # 17
+ (18, TType.LIST, 'errors', (TType.STRUCT, (apache.airavata.model.commons.ttypes.ErrorModel, apache.airavata.model.commons.ttypes.ErrorModel.thrift_spec), False), None, ), # 18
+ (19, TType.LIST, 'processes', (TType.STRUCT, (apache.airavata.model.process.ttypes.ProcessModel, apache.airavata.model.process.ttypes.ProcessModel.thrift_spec), False), None, ), # 19
+ )
+
+ def __init__(self, experimentId=thrift_spec[1][4], projectId=None, gatewayId=None, experimentType=thrift_spec[4][4], userName=None, experimentName=None, creationTime=None, description=None, executionId=None, gatewayExecutionId=None, gatewayInstanceId=None, enableEmailNotification=None, emailAddresses=None, userConfigurationData=None, experimentInputs=None, experimentOutputs=None, experimentStatus=None, errors=None, processes=None,):
+ self.experimentId = experimentId
+ self.projectId = projectId
+ self.gatewayId = gatewayId
+ self.experimentType = experimentType
+ self.userName = userName
+ self.experimentName = experimentName
+ self.creationTime = creationTime
+ self.description = description
+ self.executionId = executionId
+ self.gatewayExecutionId = gatewayExecutionId
+ self.gatewayInstanceId = gatewayInstanceId
+ self.enableEmailNotification = enableEmailNotification
+ self.emailAddresses = emailAddresses
+ self.userConfigurationData = userConfigurationData
+ self.experimentInputs = experimentInputs
+ self.experimentOutputs = experimentOutputs
+ self.experimentStatus = experimentStatus
+ self.errors = errors
+ self.processes = processes
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.experimentId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.projectId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.I32:
+ self.experimentType = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRING:
+ self.userName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.experimentName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.I64:
+ self.creationTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.STRING:
+ self.description = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.STRING:
+ self.executionId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.STRING:
+ self.gatewayExecutionId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 11:
+ if ftype == TType.STRING:
+ self.gatewayInstanceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 12:
+ if ftype == TType.BOOL:
+ self.enableEmailNotification = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 13:
+ if ftype == TType.LIST:
+ self.emailAddresses = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in range(_size0):
+ _elem5 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ self.emailAddresses.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 14:
+ if ftype == TType.STRUCT:
+ self.userConfigurationData = UserConfigurationDataModel()
+ self.userConfigurationData.read(iprot)
+ else:
+ iprot.skip(ftype)
+ elif fid == 15:
+ if ftype == TType.LIST:
+ self.experimentInputs = []
+ (_etype9, _size6) = iprot.readListBegin()
+ for _i10 in range(_size6):
+ _elem11 = apache.airavata.model.application.io.ttypes.InputDataObjectType()
+ _elem11.read(iprot)
+ self.experimentInputs.append(_elem11)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 16:
+ if ftype == TType.LIST:
+ self.experimentOutputs = []
+ (_etype15, _size12) = iprot.readListBegin()
+ for _i16 in range(_size12):
+ _elem17 = apache.airavata.model.application.io.ttypes.OutputDataObjectType()
+ _elem17.read(iprot)
+ self.experimentOutputs.append(_elem17)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 17:
+ if ftype == TType.LIST:
+ self.experimentStatus = []
+ (_etype21, _size18) = iprot.readListBegin()
+ for _i22 in range(_size18):
+ _elem23 = apache.airavata.model.status.ttypes.ExperimentStatus()
+ _elem23.read(iprot)
+ self.experimentStatus.append(_elem23)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 18:
+ if ftype == TType.LIST:
+ self.errors = []
+ (_etype27, _size24) = iprot.readListBegin()
+ for _i28 in range(_size24):
+ _elem29 = apache.airavata.model.commons.ttypes.ErrorModel()
+ _elem29.read(iprot)
+ self.errors.append(_elem29)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 19:
+ if ftype == TType.LIST:
+ self.processes = []
+ (_etype33, _size30) = iprot.readListBegin()
+ for _i34 in range(_size30):
+ _elem35 = apache.airavata.model.process.ttypes.ProcessModel()
+ _elem35.read(iprot)
+ self.processes.append(_elem35)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ExperimentModel')
+ if self.experimentId is not None:
+ oprot.writeFieldBegin('experimentId', TType.STRING, 1)
+ oprot.writeString(self.experimentId.encode('utf-8') if sys.version_info[0] == 2 else self.experimentId)
+ oprot.writeFieldEnd()
+ if self.projectId is not None:
+ oprot.writeFieldBegin('projectId', TType.STRING, 2)
+ oprot.writeString(self.projectId.encode('utf-8') if sys.version_info[0] == 2 else self.projectId)
+ oprot.writeFieldEnd()
+ if self.gatewayId is not None:
+ oprot.writeFieldBegin('gatewayId', TType.STRING, 3)
+ oprot.writeString(self.gatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayId)
+ oprot.writeFieldEnd()
+ if self.experimentType is not None:
+ oprot.writeFieldBegin('experimentType', TType.I32, 4)
+ oprot.writeI32(self.experimentType)
+ oprot.writeFieldEnd()
+ if self.userName is not None:
+ oprot.writeFieldBegin('userName', TType.STRING, 5)
+ oprot.writeString(self.userName.encode('utf-8') if sys.version_info[0] == 2 else self.userName)
+ oprot.writeFieldEnd()
+ if self.experimentName is not None:
+ oprot.writeFieldBegin('experimentName', TType.STRING, 6)
+ oprot.writeString(self.experimentName.encode('utf-8') if sys.version_info[0] == 2 else self.experimentName)
+ oprot.writeFieldEnd()
+ if self.creationTime is not None:
+ oprot.writeFieldBegin('creationTime', TType.I64, 7)
+ oprot.writeI64(self.creationTime)
+ oprot.writeFieldEnd()
+ if self.description is not None:
+ oprot.writeFieldBegin('description', TType.STRING, 8)
+ oprot.writeString(self.description.encode('utf-8') if sys.version_info[0] == 2 else self.description)
+ oprot.writeFieldEnd()
+ if self.executionId is not None:
+ oprot.writeFieldBegin('executionId', TType.STRING, 9)
+ oprot.writeString(self.executionId.encode('utf-8') if sys.version_info[0] == 2 else self.executionId)
+ oprot.writeFieldEnd()
+ if self.gatewayExecutionId is not None:
+ oprot.writeFieldBegin('gatewayExecutionId', TType.STRING, 10)
+ oprot.writeString(self.gatewayExecutionId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayExecutionId)
+ oprot.writeFieldEnd()
+ if self.gatewayInstanceId is not None:
+ oprot.writeFieldBegin('gatewayInstanceId', TType.STRING, 11)
+ oprot.writeString(self.gatewayInstanceId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayInstanceId)
+ oprot.writeFieldEnd()
+ if self.enableEmailNotification is not None:
+ oprot.writeFieldBegin('enableEmailNotification', TType.BOOL, 12)
+ oprot.writeBool(self.enableEmailNotification)
+ oprot.writeFieldEnd()
+ if self.emailAddresses is not None:
+ oprot.writeFieldBegin('emailAddresses', TType.LIST, 13)
+ oprot.writeListBegin(TType.STRING, len(self.emailAddresses))
+ for iter36 in self.emailAddresses:
+ oprot.writeString(iter36.encode('utf-8') if sys.version_info[0] == 2 else iter36)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.userConfigurationData is not None:
+ oprot.writeFieldBegin('userConfigurationData', TType.STRUCT, 14)
+ self.userConfigurationData.write(oprot)
+ oprot.writeFieldEnd()
+ if self.experimentInputs is not None:
+ oprot.writeFieldBegin('experimentInputs', TType.LIST, 15)
+ oprot.writeListBegin(TType.STRUCT, len(self.experimentInputs))
+ for iter37 in self.experimentInputs:
+ iter37.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.experimentOutputs is not None:
+ oprot.writeFieldBegin('experimentOutputs', TType.LIST, 16)
+ oprot.writeListBegin(TType.STRUCT, len(self.experimentOutputs))
+ for iter38 in self.experimentOutputs:
+ iter38.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.experimentStatus is not None:
+ oprot.writeFieldBegin('experimentStatus', TType.LIST, 17)
+ oprot.writeListBegin(TType.STRUCT, len(self.experimentStatus))
+ for iter39 in self.experimentStatus:
+ iter39.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.errors is not None:
+ oprot.writeFieldBegin('errors', TType.LIST, 18)
+ oprot.writeListBegin(TType.STRUCT, len(self.errors))
+ for iter40 in self.errors:
+ iter40.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.processes is not None:
+ oprot.writeFieldBegin('processes', TType.LIST, 19)
+ oprot.writeListBegin(TType.STRUCT, len(self.processes))
+ for iter41 in self.processes:
+ iter41.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.experimentId is None:
+ raise TProtocolException(message='Required field experimentId is unset!')
+ if self.projectId is None:
+ raise TProtocolException(message='Required field projectId is unset!')
+ if self.gatewayId is None:
+ raise TProtocolException(message='Required field gatewayId is unset!')
+ if self.experimentType is None:
+ raise TProtocolException(message='Required field experimentType is unset!')
+ if self.userName is None:
+ raise TProtocolException(message='Required field userName is unset!')
+ if self.experimentName is None:
+ raise TProtocolException(message='Required field experimentName is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class ExperimentSummaryModel(object):
+ """
+ Attributes:
+ - experimentId
+ - projectId
+ - gatewayId
+ - creationTime
+ - userName
+ - name
+ - description
+ - executionId
+ - resourceHostId
+ - experimentStatus
+ - statusUpdateTime
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'experimentId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'projectId', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'gatewayId', 'UTF8', None, ), # 3
+ (4, TType.I64, 'creationTime', None, None, ), # 4
+ (5, TType.STRING, 'userName', 'UTF8', None, ), # 5
+ (6, TType.STRING, 'name', 'UTF8', None, ), # 6
+ (7, TType.STRING, 'description', 'UTF8', None, ), # 7
+ (8, TType.STRING, 'executionId', 'UTF8', None, ), # 8
+ (9, TType.STRING, 'resourceHostId', 'UTF8', None, ), # 9
+ (10, TType.STRING, 'experimentStatus', 'UTF8', None, ), # 10
+ None, # 11
+ (12, TType.I64, 'statusUpdateTime', None, None, ), # 12
+ )
+
+ def __init__(self, experimentId=None, projectId=None, gatewayId=None, creationTime=None, userName=None, name=None, description=None, executionId=None, resourceHostId=None, experimentStatus=None, statusUpdateTime=None,):
+ self.experimentId = experimentId
+ self.projectId = projectId
+ self.gatewayId = gatewayId
+ self.creationTime = creationTime
+ self.userName = userName
+ self.name = name
+ self.description = description
+ self.executionId = executionId
+ self.resourceHostId = resourceHostId
+ self.experimentStatus = experimentStatus
+ self.statusUpdateTime = statusUpdateTime
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.experimentId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.projectId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.gatewayId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.I64:
+ self.creationTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRING:
+ self.userName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.name = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.STRING:
+ self.description = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.STRING:
+ self.executionId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.STRING:
+ self.resourceHostId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.STRING:
+ self.experimentStatus = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 12:
+ if ftype == TType.I64:
+ self.statusUpdateTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ExperimentSummaryModel')
+ if self.experimentId is not None:
+ oprot.writeFieldBegin('experimentId', TType.STRING, 1)
+ oprot.writeString(self.experimentId.encode('utf-8') if sys.version_info[0] == 2 else self.experimentId)
+ oprot.writeFieldEnd()
+ if self.projectId is not None:
+ oprot.writeFieldBegin('projectId', TType.STRING, 2)
+ oprot.writeString(self.projectId.encode('utf-8') if sys.version_info[0] == 2 else self.projectId)
+ oprot.writeFieldEnd()
+ if self.gatewayId is not None:
+ oprot.writeFieldBegin('gatewayId', TType.STRING, 3)
+ oprot.writeString(self.gatewayId.encode('utf-8') if sys.version_info[0] == 2 else self.gatewayId)
+ oprot.writeFieldEnd()
+ if self.creationTime is not None:
+ oprot.writeFieldBegin('creationTime', TType.I64, 4)
+ oprot.writeI64(self.creationTime)
+ oprot.writeFieldEnd()
+ if self.userName is not None:
+ oprot.writeFieldBegin('userName', TType.STRING, 5)
+ oprot.writeString(self.userName.encode('utf-8') if sys.version_info[0] == 2 else self.userName)
+ oprot.writeFieldEnd()
+ if self.name is not None:
+ oprot.writeFieldBegin('name', TType.STRING, 6)
+ oprot.writeString(self.name.encode('utf-8') if sys.version_info[0] == 2 else self.name)
+ oprot.writeFieldEnd()
+ if self.description is not None:
+ oprot.writeFieldBegin('description', TType.STRING, 7)
+ oprot.writeString(self.description.encode('utf-8') if sys.version_info[0] == 2 else self.description)
+ oprot.writeFieldEnd()
+ if self.executionId is not None:
+ oprot.writeFieldBegin('executionId', TType.STRING, 8)
+ oprot.writeString(self.executionId.encode('utf-8') if sys.version_info[0] == 2 else self.executionId)
+ oprot.writeFieldEnd()
+ if self.resourceHostId is not None:
+ oprot.writeFieldBegin('resourceHostId', TType.STRING, 9)
+ oprot.writeString(self.resourceHostId.encode('utf-8') if sys.version_info[0] == 2 else self.resourceHostId)
+ oprot.writeFieldEnd()
+ if self.experimentStatus is not None:
+ oprot.writeFieldBegin('experimentStatus', TType.STRING, 10)
+ oprot.writeString(self.experimentStatus.encode('utf-8') if sys.version_info[0] == 2 else self.experimentStatus)
+ oprot.writeFieldEnd()
+ if self.statusUpdateTime is not None:
+ oprot.writeFieldBegin('statusUpdateTime', TType.I64, 12)
+ oprot.writeI64(self.statusUpdateTime)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.experimentId is None:
+ raise TProtocolException(message='Required field experimentId is unset!')
+ if self.projectId is None:
+ raise TProtocolException(message='Required field projectId is unset!')
+ if self.gatewayId is None:
+ raise TProtocolException(message='Required field gatewayId is unset!')
+ if self.userName is None:
+ raise TProtocolException(message='Required field userName is unset!')
+ if self.name is None:
+ raise TProtocolException(message='Required field name is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class ExperimentStatistics(object):
+ """
+ Attributes:
+ - allExperimentCount
+ - completedExperimentCount
+ - cancelledExperimentCount
+ - failedExperimentCount
+ - createdExperimentCount
+ - runningExperimentCount
+ - allExperiments
+ - completedExperiments
+ - failedExperiments
+ - cancelledExperiments
+ - createdExperiments
+ - runningExperiments
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'allExperimentCount', None, None, ), # 1
+ (2, TType.I32, 'completedExperimentCount', None, None, ), # 2
+ (3, TType.I32, 'cancelledExperimentCount', None, None, ), # 3
+ (4, TType.I32, 'failedExperimentCount', None, None, ), # 4
+ (5, TType.I32, 'createdExperimentCount', None, None, ), # 5
+ (6, TType.I32, 'runningExperimentCount', None, None, ), # 6
+ (7, TType.LIST, 'allExperiments', (TType.STRUCT, (ExperimentSummaryModel, ExperimentSummaryModel.thrift_spec), False), None, ), # 7
+ (8, TType.LIST, 'completedExperiments', (TType.STRUCT, (ExperimentSummaryModel, ExperimentSummaryModel.thrift_spec), False), None, ), # 8
+ (9, TType.LIST, 'failedExperiments', (TType.STRUCT, (ExperimentSummaryModel, ExperimentSummaryModel.thrift_spec), False), None, ), # 9
+ (10, TType.LIST, 'cancelledExperiments', (TType.STRUCT, (ExperimentSummaryModel, ExperimentSummaryModel.thrift_spec), False), None, ), # 10
+ (11, TType.LIST, 'createdExperiments', (TType.STRUCT, (ExperimentSummaryModel, ExperimentSummaryModel.thrift_spec), False), None, ), # 11
+ (12, TType.LIST, 'runningExperiments', (TType.STRUCT, (ExperimentSummaryModel, ExperimentSummaryModel.thrift_spec), False), None, ), # 12
+ )
+
+ def __init__(self, allExperimentCount=None, completedExperimentCount=None, cancelledExperimentCount=None, failedExperimentCount=None, createdExperimentCount=None, runningExperimentCount=None, allExperiments=None, completedExperiments=None, failedExperiments=None, cancelledExperiments=None, createdExperiments=None, runningExperiments=None,):
+ self.allExperimentCount = allExperimentCount
+ self.completedExperimentCount = completedExperimentCount
+ self.cancelledExperimentCount = cancelledExperimentCount
+ self.failedExperimentCount = failedExperimentCount
+ self.createdExperimentCount = createdExperimentCount
+ self.runningExperimentCount = runningExperimentCount
+ self.allExperiments = allExperiments
+ self.completedExperiments = completedExperiments
+ self.failedExperiments = failedExperiments
+ self.cancelledExperiments = cancelledExperiments
+ self.createdExperiments = createdExperiments
+ self.runningExperiments = runningExperiments
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.allExperimentCount = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I32:
+ self.completedExperimentCount = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I32:
+ self.cancelledExperimentCount = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.I32:
+ self.failedExperimentCount = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.I32:
+ self.createdExperimentCount = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.I32:
+ self.runningExperimentCount = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.LIST:
+ self.allExperiments = []
+ (_etype45, _size42) = iprot.readListBegin()
+ for _i46 in range(_size42):
+ _elem47 = ExperimentSummaryModel()
+ _elem47.read(iprot)
+ self.allExperiments.append(_elem47)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.LIST:
+ self.completedExperiments = []
+ (_etype51, _size48) = iprot.readListBegin()
+ for _i52 in range(_size48):
+ _elem53 = ExperimentSummaryModel()
+ _elem53.read(iprot)
+ self.completedExperiments.append(_elem53)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.LIST:
+ self.failedExperiments = []
+ (_etype57, _size54) = iprot.readListBegin()
+ for _i58 in range(_size54):
+ _elem59 = ExperimentSummaryModel()
+ _elem59.read(iprot)
+ self.failedExperiments.append(_elem59)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.LIST:
+ self.cancelledExperiments = []
+ (_etype63, _size60) = iprot.readListBegin()
+ for _i64 in range(_size60):
+ _elem65 = ExperimentSummaryModel()
+ _elem65.
<TRUNCATED>
[17/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/gatewayprofile/ComputeResourcePreference.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/gatewayprofile/ComputeResourcePreference.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/gatewayprofile/ComputeResourcePreference.java
index b1c092b..50d368c 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/gatewayprofile/ComputeResourcePreference.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/gatewayprofile/ComputeResourcePreference.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.gatewayprofile;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Gateway specific preferences for a Computer Resource
*
@@ -85,7 +58,7 @@ import org.slf4j.LoggerFactory;
* default credential store.
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class ComputeResourcePreference implements org.apache.thrift.TBase<ComputeResourcePreference, ComputeResourcePreference._Fields>, java.io.Serializable, Cloneable, Comparable<ComputeResourcePreference> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ComputeResourcePreference");
@@ -104,24 +77,21 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
private static final org.apache.thrift.protocol.TField RESERVATION_START_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("reservationStartTime", org.apache.thrift.protocol.TType.I64, (short)13);
private static final org.apache.thrift.protocol.TField RESERVATION_END_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("reservationEndTime", org.apache.thrift.protocol.TType.I64, (short)14);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new ComputeResourcePreferenceStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ComputeResourcePreferenceTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ComputeResourcePreferenceStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ComputeResourcePreferenceTupleSchemeFactory();
- private String computeResourceId; // required
+ private java.lang.String computeResourceId; // required
private boolean overridebyAiravata; // required
- private String loginUserName; // optional
+ private java.lang.String loginUserName; // optional
private org.apache.airavata.model.appcatalog.computeresource.JobSubmissionProtocol preferredJobSubmissionProtocol; // optional
private org.apache.airavata.model.data.movement.DataMovementProtocol preferredDataMovementProtocol; // optional
- private String preferredBatchQueue; // optional
- private String scratchLocation; // optional
- private String allocationProjectNumber; // optional
- private String resourceSpecificCredentialStoreToken; // optional
- private String usageReportingGatewayId; // optional
- private String qualityOfService; // optional
- private String reservation; // optional
+ private java.lang.String preferredBatchQueue; // optional
+ private java.lang.String scratchLocation; // optional
+ private java.lang.String allocationProjectNumber; // optional
+ private java.lang.String resourceSpecificCredentialStoreToken; // optional
+ private java.lang.String usageReportingGatewayId; // optional
+ private java.lang.String qualityOfService; // optional
+ private java.lang.String reservation; // optional
private long reservationStartTime; // optional
private long reservationEndTime; // optional
@@ -150,10 +120,10 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
RESERVATION_START_TIME((short)13, "reservationStartTime"),
RESERVATION_END_TIME((short)14, "reservationEndTime");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -202,21 +172,21 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -225,7 +195,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -236,9 +206,9 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
private static final int __RESERVATIONENDTIME_ISSET_ID = 2;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.LOGIN_USER_NAME,_Fields.PREFERRED_JOB_SUBMISSION_PROTOCOL,_Fields.PREFERRED_DATA_MOVEMENT_PROTOCOL,_Fields.PREFERRED_BATCH_QUEUE,_Fields.SCRATCH_LOCATION,_Fields.ALLOCATION_PROJECT_NUMBER,_Fields.RESOURCE_SPECIFIC_CREDENTIAL_STORE_TOKEN,_Fields.USAGE_REPORTING_GATEWAY_ID,_Fields.QUALITY_OF_SERVICE,_Fields.RESERVATION,_Fields.RESERVATION_START_TIME,_Fields.RESERVATION_END_TIME};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.COMPUTE_RESOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("computeResourceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.OVERRIDEBY_AIRAVATA, new org.apache.thrift.meta_data.FieldMetaData("overridebyAiravata", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -267,7 +237,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
tmpMap.put(_Fields.RESERVATION_END_TIME, new org.apache.thrift.meta_data.FieldMetaData("reservationEndTime", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ComputeResourcePreference.class, metaDataMap);
}
@@ -277,7 +247,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
}
public ComputeResourcePreference(
- String computeResourceId,
+ java.lang.String computeResourceId,
boolean overridebyAiravata)
{
this();
@@ -354,11 +324,11 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
this.reservationEndTime = 0;
}
- public String getComputeResourceId() {
+ public java.lang.String getComputeResourceId() {
return this.computeResourceId;
}
- public void setComputeResourceId(String computeResourceId) {
+ public void setComputeResourceId(java.lang.String computeResourceId) {
this.computeResourceId = computeResourceId;
}
@@ -387,23 +357,23 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
}
public void unsetOverridebyAiravata() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __OVERRIDEBYAIRAVATA_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __OVERRIDEBYAIRAVATA_ISSET_ID);
}
/** Returns true if field overridebyAiravata is set (has been assigned a value) and false otherwise */
public boolean isSetOverridebyAiravata() {
- return EncodingUtils.testBit(__isset_bitfield, __OVERRIDEBYAIRAVATA_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __OVERRIDEBYAIRAVATA_ISSET_ID);
}
public void setOverridebyAiravataIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __OVERRIDEBYAIRAVATA_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __OVERRIDEBYAIRAVATA_ISSET_ID, value);
}
- public String getLoginUserName() {
+ public java.lang.String getLoginUserName() {
return this.loginUserName;
}
- public void setLoginUserName(String loginUserName) {
+ public void setLoginUserName(java.lang.String loginUserName) {
this.loginUserName = loginUserName;
}
@@ -484,11 +454,11 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
}
}
- public String getPreferredBatchQueue() {
+ public java.lang.String getPreferredBatchQueue() {
return this.preferredBatchQueue;
}
- public void setPreferredBatchQueue(String preferredBatchQueue) {
+ public void setPreferredBatchQueue(java.lang.String preferredBatchQueue) {
this.preferredBatchQueue = preferredBatchQueue;
}
@@ -507,11 +477,11 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
}
}
- public String getScratchLocation() {
+ public java.lang.String getScratchLocation() {
return this.scratchLocation;
}
- public void setScratchLocation(String scratchLocation) {
+ public void setScratchLocation(java.lang.String scratchLocation) {
this.scratchLocation = scratchLocation;
}
@@ -530,11 +500,11 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
}
}
- public String getAllocationProjectNumber() {
+ public java.lang.String getAllocationProjectNumber() {
return this.allocationProjectNumber;
}
- public void setAllocationProjectNumber(String allocationProjectNumber) {
+ public void setAllocationProjectNumber(java.lang.String allocationProjectNumber) {
this.allocationProjectNumber = allocationProjectNumber;
}
@@ -553,11 +523,11 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
}
}
- public String getResourceSpecificCredentialStoreToken() {
+ public java.lang.String getResourceSpecificCredentialStoreToken() {
return this.resourceSpecificCredentialStoreToken;
}
- public void setResourceSpecificCredentialStoreToken(String resourceSpecificCredentialStoreToken) {
+ public void setResourceSpecificCredentialStoreToken(java.lang.String resourceSpecificCredentialStoreToken) {
this.resourceSpecificCredentialStoreToken = resourceSpecificCredentialStoreToken;
}
@@ -576,11 +546,11 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
}
}
- public String getUsageReportingGatewayId() {
+ public java.lang.String getUsageReportingGatewayId() {
return this.usageReportingGatewayId;
}
- public void setUsageReportingGatewayId(String usageReportingGatewayId) {
+ public void setUsageReportingGatewayId(java.lang.String usageReportingGatewayId) {
this.usageReportingGatewayId = usageReportingGatewayId;
}
@@ -599,11 +569,11 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
}
}
- public String getQualityOfService() {
+ public java.lang.String getQualityOfService() {
return this.qualityOfService;
}
- public void setQualityOfService(String qualityOfService) {
+ public void setQualityOfService(java.lang.String qualityOfService) {
this.qualityOfService = qualityOfService;
}
@@ -622,11 +592,11 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
}
}
- public String getReservation() {
+ public java.lang.String getReservation() {
return this.reservation;
}
- public void setReservation(String reservation) {
+ public void setReservation(java.lang.String reservation) {
this.reservation = reservation;
}
@@ -655,16 +625,16 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
}
public void unsetReservationStartTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __RESERVATIONSTARTTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __RESERVATIONSTARTTIME_ISSET_ID);
}
/** Returns true if field reservationStartTime is set (has been assigned a value) and false otherwise */
public boolean isSetReservationStartTime() {
- return EncodingUtils.testBit(__isset_bitfield, __RESERVATIONSTARTTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __RESERVATIONSTARTTIME_ISSET_ID);
}
public void setReservationStartTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __RESERVATIONSTARTTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __RESERVATIONSTARTTIME_ISSET_ID, value);
}
public long getReservationEndTime() {
@@ -677,25 +647,25 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
}
public void unsetReservationEndTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __RESERVATIONENDTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __RESERVATIONENDTIME_ISSET_ID);
}
/** Returns true if field reservationEndTime is set (has been assigned a value) and false otherwise */
public boolean isSetReservationEndTime() {
- return EncodingUtils.testBit(__isset_bitfield, __RESERVATIONENDTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __RESERVATIONENDTIME_ISSET_ID);
}
public void setReservationEndTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __RESERVATIONENDTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __RESERVATIONENDTIME_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case COMPUTE_RESOURCE_ID:
if (value == null) {
unsetComputeResourceId();
} else {
- setComputeResourceId((String)value);
+ setComputeResourceId((java.lang.String)value);
}
break;
@@ -703,7 +673,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
if (value == null) {
unsetOverridebyAiravata();
} else {
- setOverridebyAiravata((Boolean)value);
+ setOverridebyAiravata((java.lang.Boolean)value);
}
break;
@@ -711,7 +681,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
if (value == null) {
unsetLoginUserName();
} else {
- setLoginUserName((String)value);
+ setLoginUserName((java.lang.String)value);
}
break;
@@ -735,7 +705,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
if (value == null) {
unsetPreferredBatchQueue();
} else {
- setPreferredBatchQueue((String)value);
+ setPreferredBatchQueue((java.lang.String)value);
}
break;
@@ -743,7 +713,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
if (value == null) {
unsetScratchLocation();
} else {
- setScratchLocation((String)value);
+ setScratchLocation((java.lang.String)value);
}
break;
@@ -751,7 +721,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
if (value == null) {
unsetAllocationProjectNumber();
} else {
- setAllocationProjectNumber((String)value);
+ setAllocationProjectNumber((java.lang.String)value);
}
break;
@@ -759,7 +729,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
if (value == null) {
unsetResourceSpecificCredentialStoreToken();
} else {
- setResourceSpecificCredentialStoreToken((String)value);
+ setResourceSpecificCredentialStoreToken((java.lang.String)value);
}
break;
@@ -767,7 +737,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
if (value == null) {
unsetUsageReportingGatewayId();
} else {
- setUsageReportingGatewayId((String)value);
+ setUsageReportingGatewayId((java.lang.String)value);
}
break;
@@ -775,7 +745,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
if (value == null) {
unsetQualityOfService();
} else {
- setQualityOfService((String)value);
+ setQualityOfService((java.lang.String)value);
}
break;
@@ -783,7 +753,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
if (value == null) {
unsetReservation();
} else {
- setReservation((String)value);
+ setReservation((java.lang.String)value);
}
break;
@@ -791,7 +761,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
if (value == null) {
unsetReservationStartTime();
} else {
- setReservationStartTime((Long)value);
+ setReservationStartTime((java.lang.Long)value);
}
break;
@@ -799,14 +769,14 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
if (value == null) {
unsetReservationEndTime();
} else {
- setReservationEndTime((Long)value);
+ setReservationEndTime((java.lang.Long)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case COMPUTE_RESOURCE_ID:
return getComputeResourceId();
@@ -851,13 +821,13 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
return getReservationEndTime();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -890,11 +860,11 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
case RESERVATION_END_TIME:
return isSetReservationEndTime();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof ComputeResourcePreference)
@@ -905,6 +875,8 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
public boolean equals(ComputeResourcePreference that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_computeResourceId = true && this.isSetComputeResourceId();
boolean that_present_computeResourceId = true && that.isSetComputeResourceId();
@@ -1037,79 +1009,63 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_computeResourceId = true && (isSetComputeResourceId());
- list.add(present_computeResourceId);
- if (present_computeResourceId)
- list.add(computeResourceId);
-
- boolean present_overridebyAiravata = true;
- list.add(present_overridebyAiravata);
- if (present_overridebyAiravata)
- list.add(overridebyAiravata);
-
- boolean present_loginUserName = true && (isSetLoginUserName());
- list.add(present_loginUserName);
- if (present_loginUserName)
- list.add(loginUserName);
-
- boolean present_preferredJobSubmissionProtocol = true && (isSetPreferredJobSubmissionProtocol());
- list.add(present_preferredJobSubmissionProtocol);
- if (present_preferredJobSubmissionProtocol)
- list.add(preferredJobSubmissionProtocol.getValue());
-
- boolean present_preferredDataMovementProtocol = true && (isSetPreferredDataMovementProtocol());
- list.add(present_preferredDataMovementProtocol);
- if (present_preferredDataMovementProtocol)
- list.add(preferredDataMovementProtocol.getValue());
-
- boolean present_preferredBatchQueue = true && (isSetPreferredBatchQueue());
- list.add(present_preferredBatchQueue);
- if (present_preferredBatchQueue)
- list.add(preferredBatchQueue);
-
- boolean present_scratchLocation = true && (isSetScratchLocation());
- list.add(present_scratchLocation);
- if (present_scratchLocation)
- list.add(scratchLocation);
-
- boolean present_allocationProjectNumber = true && (isSetAllocationProjectNumber());
- list.add(present_allocationProjectNumber);
- if (present_allocationProjectNumber)
- list.add(allocationProjectNumber);
-
- boolean present_resourceSpecificCredentialStoreToken = true && (isSetResourceSpecificCredentialStoreToken());
- list.add(present_resourceSpecificCredentialStoreToken);
- if (present_resourceSpecificCredentialStoreToken)
- list.add(resourceSpecificCredentialStoreToken);
-
- boolean present_usageReportingGatewayId = true && (isSetUsageReportingGatewayId());
- list.add(present_usageReportingGatewayId);
- if (present_usageReportingGatewayId)
- list.add(usageReportingGatewayId);
-
- boolean present_qualityOfService = true && (isSetQualityOfService());
- list.add(present_qualityOfService);
- if (present_qualityOfService)
- list.add(qualityOfService);
-
- boolean present_reservation = true && (isSetReservation());
- list.add(present_reservation);
- if (present_reservation)
- list.add(reservation);
-
- boolean present_reservationStartTime = true && (isSetReservationStartTime());
- list.add(present_reservationStartTime);
- if (present_reservationStartTime)
- list.add(reservationStartTime);
-
- boolean present_reservationEndTime = true && (isSetReservationEndTime());
- list.add(present_reservationEndTime);
- if (present_reservationEndTime)
- list.add(reservationEndTime);
-
- return list.hashCode();
+ int hashCode = 1;
+
+ hashCode = hashCode * 8191 + ((isSetComputeResourceId()) ? 131071 : 524287);
+ if (isSetComputeResourceId())
+ hashCode = hashCode * 8191 + computeResourceId.hashCode();
+
+ hashCode = hashCode * 8191 + ((overridebyAiravata) ? 131071 : 524287);
+
+ hashCode = hashCode * 8191 + ((isSetLoginUserName()) ? 131071 : 524287);
+ if (isSetLoginUserName())
+ hashCode = hashCode * 8191 + loginUserName.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetPreferredJobSubmissionProtocol()) ? 131071 : 524287);
+ if (isSetPreferredJobSubmissionProtocol())
+ hashCode = hashCode * 8191 + preferredJobSubmissionProtocol.getValue();
+
+ hashCode = hashCode * 8191 + ((isSetPreferredDataMovementProtocol()) ? 131071 : 524287);
+ if (isSetPreferredDataMovementProtocol())
+ hashCode = hashCode * 8191 + preferredDataMovementProtocol.getValue();
+
+ hashCode = hashCode * 8191 + ((isSetPreferredBatchQueue()) ? 131071 : 524287);
+ if (isSetPreferredBatchQueue())
+ hashCode = hashCode * 8191 + preferredBatchQueue.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetScratchLocation()) ? 131071 : 524287);
+ if (isSetScratchLocation())
+ hashCode = hashCode * 8191 + scratchLocation.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetAllocationProjectNumber()) ? 131071 : 524287);
+ if (isSetAllocationProjectNumber())
+ hashCode = hashCode * 8191 + allocationProjectNumber.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetResourceSpecificCredentialStoreToken()) ? 131071 : 524287);
+ if (isSetResourceSpecificCredentialStoreToken())
+ hashCode = hashCode * 8191 + resourceSpecificCredentialStoreToken.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetUsageReportingGatewayId()) ? 131071 : 524287);
+ if (isSetUsageReportingGatewayId())
+ hashCode = hashCode * 8191 + usageReportingGatewayId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetQualityOfService()) ? 131071 : 524287);
+ if (isSetQualityOfService())
+ hashCode = hashCode * 8191 + qualityOfService.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetReservation()) ? 131071 : 524287);
+ if (isSetReservation())
+ hashCode = hashCode * 8191 + reservation.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetReservationStartTime()) ? 131071 : 524287);
+ if (isSetReservationStartTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(reservationStartTime);
+
+ hashCode = hashCode * 8191 + ((isSetReservationEndTime()) ? 131071 : 524287);
+ if (isSetReservationEndTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(reservationEndTime);
+
+ return hashCode;
}
@Override
@@ -1120,7 +1076,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetComputeResourceId()).compareTo(other.isSetComputeResourceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetComputeResourceId()).compareTo(other.isSetComputeResourceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1130,7 +1086,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetOverridebyAiravata()).compareTo(other.isSetOverridebyAiravata());
+ lastComparison = java.lang.Boolean.valueOf(isSetOverridebyAiravata()).compareTo(other.isSetOverridebyAiravata());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1140,7 +1096,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetLoginUserName()).compareTo(other.isSetLoginUserName());
+ lastComparison = java.lang.Boolean.valueOf(isSetLoginUserName()).compareTo(other.isSetLoginUserName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1150,7 +1106,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPreferredJobSubmissionProtocol()).compareTo(other.isSetPreferredJobSubmissionProtocol());
+ lastComparison = java.lang.Boolean.valueOf(isSetPreferredJobSubmissionProtocol()).compareTo(other.isSetPreferredJobSubmissionProtocol());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1160,7 +1116,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPreferredDataMovementProtocol()).compareTo(other.isSetPreferredDataMovementProtocol());
+ lastComparison = java.lang.Boolean.valueOf(isSetPreferredDataMovementProtocol()).compareTo(other.isSetPreferredDataMovementProtocol());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1170,7 +1126,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetPreferredBatchQueue()).compareTo(other.isSetPreferredBatchQueue());
+ lastComparison = java.lang.Boolean.valueOf(isSetPreferredBatchQueue()).compareTo(other.isSetPreferredBatchQueue());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1180,7 +1136,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetScratchLocation()).compareTo(other.isSetScratchLocation());
+ lastComparison = java.lang.Boolean.valueOf(isSetScratchLocation()).compareTo(other.isSetScratchLocation());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1190,7 +1146,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAllocationProjectNumber()).compareTo(other.isSetAllocationProjectNumber());
+ lastComparison = java.lang.Boolean.valueOf(isSetAllocationProjectNumber()).compareTo(other.isSetAllocationProjectNumber());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1200,7 +1156,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetResourceSpecificCredentialStoreToken()).compareTo(other.isSetResourceSpecificCredentialStoreToken());
+ lastComparison = java.lang.Boolean.valueOf(isSetResourceSpecificCredentialStoreToken()).compareTo(other.isSetResourceSpecificCredentialStoreToken());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1210,7 +1166,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUsageReportingGatewayId()).compareTo(other.isSetUsageReportingGatewayId());
+ lastComparison = java.lang.Boolean.valueOf(isSetUsageReportingGatewayId()).compareTo(other.isSetUsageReportingGatewayId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1220,7 +1176,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetQualityOfService()).compareTo(other.isSetQualityOfService());
+ lastComparison = java.lang.Boolean.valueOf(isSetQualityOfService()).compareTo(other.isSetQualityOfService());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1230,7 +1186,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetReservation()).compareTo(other.isSetReservation());
+ lastComparison = java.lang.Boolean.valueOf(isSetReservation()).compareTo(other.isSetReservation());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1240,7 +1196,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetReservationStartTime()).compareTo(other.isSetReservationStartTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetReservationStartTime()).compareTo(other.isSetReservationStartTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1250,7 +1206,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetReservationEndTime()).compareTo(other.isSetReservationEndTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetReservationEndTime()).compareTo(other.isSetReservationEndTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1268,16 +1224,16 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ComputeResourcePreference(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ComputeResourcePreference(");
boolean first = true;
sb.append("computeResourceId:");
@@ -1428,7 +1384,7 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -1438,13 +1394,13 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
}
}
- private static class ComputeResourcePreferenceStandardSchemeFactory implements SchemeFactory {
+ private static class ComputeResourcePreferenceStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ComputeResourcePreferenceStandardScheme getScheme() {
return new ComputeResourcePreferenceStandardScheme();
}
}
- private static class ComputeResourcePreferenceStandardScheme extends StandardScheme<ComputeResourcePreference> {
+ private static class ComputeResourcePreferenceStandardScheme extends org.apache.thrift.scheme.StandardScheme<ComputeResourcePreference> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ComputeResourcePreference struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1675,20 +1631,20 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
}
- private static class ComputeResourcePreferenceTupleSchemeFactory implements SchemeFactory {
+ private static class ComputeResourcePreferenceTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ComputeResourcePreferenceTupleScheme getScheme() {
return new ComputeResourcePreferenceTupleScheme();
}
}
- private static class ComputeResourcePreferenceTupleScheme extends TupleScheme<ComputeResourcePreference> {
+ private static class ComputeResourcePreferenceTupleScheme extends org.apache.thrift.scheme.TupleScheme<ComputeResourcePreference> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ComputeResourcePreference struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.computeResourceId);
oprot.writeBool(struct.overridebyAiravata);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetLoginUserName()) {
optionals.set(0);
}
@@ -1766,12 +1722,12 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ComputeResourcePreference struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.computeResourceId = iprot.readString();
struct.setComputeResourceIdIsSet(true);
struct.overridebyAiravata = iprot.readBool();
struct.setOverridebyAiravataIsSet(true);
- BitSet incoming = iprot.readBitSet(12);
+ java.util.BitSet incoming = iprot.readBitSet(12);
if (incoming.get(0)) {
struct.loginUserName = iprot.readString();
struct.setLoginUserNameIsSet(true);
@@ -1823,5 +1779,8 @@ public class ComputeResourcePreference implements org.apache.thrift.TBase<Comput
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/gatewayprofile/GatewayResourceProfile.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/gatewayprofile/GatewayResourceProfile.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/gatewayprofile/GatewayResourceProfile.java
index 31f33f6..cb2f0fb 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/gatewayprofile/GatewayResourceProfile.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/gatewayprofile/GatewayResourceProfile.java
@@ -16,41 +16,14 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.gatewayprofile;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Gateway Resource Profile
*
@@ -68,7 +41,7 @@ import org.slf4j.LoggerFactory;
* identityServerPwdCredToken:
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayResourceProfile, GatewayResourceProfile._Fields>, java.io.Serializable, Cloneable, Comparable<GatewayResourceProfile> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("GatewayResourceProfile");
@@ -79,18 +52,15 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
private static final org.apache.thrift.protocol.TField IDENTITY_SERVER_TENANT_FIELD_DESC = new org.apache.thrift.protocol.TField("identityServerTenant", org.apache.thrift.protocol.TType.STRING, (short)5);
private static final org.apache.thrift.protocol.TField IDENTITY_SERVER_PWD_CRED_TOKEN_FIELD_DESC = new org.apache.thrift.protocol.TField("identityServerPwdCredToken", org.apache.thrift.protocol.TType.STRING, (short)6);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new GatewayResourceProfileStandardSchemeFactory());
- schemes.put(TupleScheme.class, new GatewayResourceProfileTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new GatewayResourceProfileStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new GatewayResourceProfileTupleSchemeFactory();
- private String gatewayID; // required
- private String credentialStoreToken; // optional
- private List<ComputeResourcePreference> computeResourcePreferences; // optional
- private List<StoragePreference> storagePreferences; // optional
- private String identityServerTenant; // optional
- private String identityServerPwdCredToken; // optional
+ private java.lang.String gatewayID; // required
+ private java.lang.String credentialStoreToken; // optional
+ private java.util.List<ComputeResourcePreference> computeResourcePreferences; // optional
+ private java.util.List<StoragePreference> storagePreferences; // optional
+ private java.lang.String identityServerTenant; // optional
+ private java.lang.String identityServerPwdCredToken; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -101,10 +71,10 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
IDENTITY_SERVER_TENANT((short)5, "identityServerTenant"),
IDENTITY_SERVER_PWD_CRED_TOKEN((short)6, "identityServerPwdCredToken");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -137,21 +107,21 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -160,16 +130,16 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
private static final _Fields optionals[] = {_Fields.CREDENTIAL_STORE_TOKEN,_Fields.COMPUTE_RESOURCE_PREFERENCES,_Fields.STORAGE_PREFERENCES,_Fields.IDENTITY_SERVER_TENANT,_Fields.IDENTITY_SERVER_PWD_CRED_TOKEN};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.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.CREDENTIAL_STORE_TOKEN, new org.apache.thrift.meta_data.FieldMetaData("credentialStoreToken", org.apache.thrift.TFieldRequirementType.OPTIONAL,
@@ -184,7 +154,7 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.IDENTITY_SERVER_PWD_CRED_TOKEN, new org.apache.thrift.meta_data.FieldMetaData("identityServerPwdCredToken", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(GatewayResourceProfile.class, metaDataMap);
}
@@ -192,7 +162,7 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
}
public GatewayResourceProfile(
- String gatewayID)
+ java.lang.String gatewayID)
{
this();
this.gatewayID = gatewayID;
@@ -209,14 +179,14 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
this.credentialStoreToken = other.credentialStoreToken;
}
if (other.isSetComputeResourcePreferences()) {
- List<ComputeResourcePreference> __this__computeResourcePreferences = new ArrayList<ComputeResourcePreference>(other.computeResourcePreferences.size());
+ java.util.List<ComputeResourcePreference> __this__computeResourcePreferences = new java.util.ArrayList<ComputeResourcePreference>(other.computeResourcePreferences.size());
for (ComputeResourcePreference other_element : other.computeResourcePreferences) {
__this__computeResourcePreferences.add(new ComputeResourcePreference(other_element));
}
this.computeResourcePreferences = __this__computeResourcePreferences;
}
if (other.isSetStoragePreferences()) {
- List<StoragePreference> __this__storagePreferences = new ArrayList<StoragePreference>(other.storagePreferences.size());
+ java.util.List<StoragePreference> __this__storagePreferences = new java.util.ArrayList<StoragePreference>(other.storagePreferences.size());
for (StoragePreference other_element : other.storagePreferences) {
__this__storagePreferences.add(new StoragePreference(other_element));
}
@@ -244,11 +214,11 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
this.identityServerPwdCredToken = null;
}
- public String getGatewayID() {
+ public java.lang.String getGatewayID() {
return this.gatewayID;
}
- public void setGatewayID(String gatewayID) {
+ public void setGatewayID(java.lang.String gatewayID) {
this.gatewayID = gatewayID;
}
@@ -267,11 +237,11 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
}
}
- public String getCredentialStoreToken() {
+ public java.lang.String getCredentialStoreToken() {
return this.credentialStoreToken;
}
- public void setCredentialStoreToken(String credentialStoreToken) {
+ public void setCredentialStoreToken(java.lang.String credentialStoreToken) {
this.credentialStoreToken = credentialStoreToken;
}
@@ -300,16 +270,16 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
public void addToComputeResourcePreferences(ComputeResourcePreference elem) {
if (this.computeResourcePreferences == null) {
- this.computeResourcePreferences = new ArrayList<ComputeResourcePreference>();
+ this.computeResourcePreferences = new java.util.ArrayList<ComputeResourcePreference>();
}
this.computeResourcePreferences.add(elem);
}
- public List<ComputeResourcePreference> getComputeResourcePreferences() {
+ public java.util.List<ComputeResourcePreference> getComputeResourcePreferences() {
return this.computeResourcePreferences;
}
- public void setComputeResourcePreferences(List<ComputeResourcePreference> computeResourcePreferences) {
+ public void setComputeResourcePreferences(java.util.List<ComputeResourcePreference> computeResourcePreferences) {
this.computeResourcePreferences = computeResourcePreferences;
}
@@ -338,16 +308,16 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
public void addToStoragePreferences(StoragePreference elem) {
if (this.storagePreferences == null) {
- this.storagePreferences = new ArrayList<StoragePreference>();
+ this.storagePreferences = new java.util.ArrayList<StoragePreference>();
}
this.storagePreferences.add(elem);
}
- public List<StoragePreference> getStoragePreferences() {
+ public java.util.List<StoragePreference> getStoragePreferences() {
return this.storagePreferences;
}
- public void setStoragePreferences(List<StoragePreference> storagePreferences) {
+ public void setStoragePreferences(java.util.List<StoragePreference> storagePreferences) {
this.storagePreferences = storagePreferences;
}
@@ -366,11 +336,11 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
}
}
- public String getIdentityServerTenant() {
+ public java.lang.String getIdentityServerTenant() {
return this.identityServerTenant;
}
- public void setIdentityServerTenant(String identityServerTenant) {
+ public void setIdentityServerTenant(java.lang.String identityServerTenant) {
this.identityServerTenant = identityServerTenant;
}
@@ -389,11 +359,11 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
}
}
- public String getIdentityServerPwdCredToken() {
+ public java.lang.String getIdentityServerPwdCredToken() {
return this.identityServerPwdCredToken;
}
- public void setIdentityServerPwdCredToken(String identityServerPwdCredToken) {
+ public void setIdentityServerPwdCredToken(java.lang.String identityServerPwdCredToken) {
this.identityServerPwdCredToken = identityServerPwdCredToken;
}
@@ -412,13 +382,13 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case GATEWAY_ID:
if (value == null) {
unsetGatewayID();
} else {
- setGatewayID((String)value);
+ setGatewayID((java.lang.String)value);
}
break;
@@ -426,7 +396,7 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
if (value == null) {
unsetCredentialStoreToken();
} else {
- setCredentialStoreToken((String)value);
+ setCredentialStoreToken((java.lang.String)value);
}
break;
@@ -434,7 +404,7 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
if (value == null) {
unsetComputeResourcePreferences();
} else {
- setComputeResourcePreferences((List<ComputeResourcePreference>)value);
+ setComputeResourcePreferences((java.util.List<ComputeResourcePreference>)value);
}
break;
@@ -442,7 +412,7 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
if (value == null) {
unsetStoragePreferences();
} else {
- setStoragePreferences((List<StoragePreference>)value);
+ setStoragePreferences((java.util.List<StoragePreference>)value);
}
break;
@@ -450,7 +420,7 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
if (value == null) {
unsetIdentityServerTenant();
} else {
- setIdentityServerTenant((String)value);
+ setIdentityServerTenant((java.lang.String)value);
}
break;
@@ -458,14 +428,14 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
if (value == null) {
unsetIdentityServerPwdCredToken();
} else {
- setIdentityServerPwdCredToken((String)value);
+ setIdentityServerPwdCredToken((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case GATEWAY_ID:
return getGatewayID();
@@ -486,13 +456,13 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
return getIdentityServerPwdCredToken();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -509,11 +479,11 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
case IDENTITY_SERVER_PWD_CRED_TOKEN:
return isSetIdentityServerPwdCredToken();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof GatewayResourceProfile)
@@ -524,6 +494,8 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
public boolean equals(GatewayResourceProfile that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_gatewayID = true && this.isSetGatewayID();
boolean that_present_gatewayID = true && that.isSetGatewayID();
@@ -584,39 +556,33 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_gatewayID = true && (isSetGatewayID());
- list.add(present_gatewayID);
- if (present_gatewayID)
- list.add(gatewayID);
-
- boolean present_credentialStoreToken = true && (isSetCredentialStoreToken());
- list.add(present_credentialStoreToken);
- if (present_credentialStoreToken)
- list.add(credentialStoreToken);
-
- boolean present_computeResourcePreferences = true && (isSetComputeResourcePreferences());
- list.add(present_computeResourcePreferences);
- if (present_computeResourcePreferences)
- list.add(computeResourcePreferences);
-
- boolean present_storagePreferences = true && (isSetStoragePreferences());
- list.add(present_storagePreferences);
- if (present_storagePreferences)
- list.add(storagePreferences);
-
- boolean present_identityServerTenant = true && (isSetIdentityServerTenant());
- list.add(present_identityServerTenant);
- if (present_identityServerTenant)
- list.add(identityServerTenant);
-
- boolean present_identityServerPwdCredToken = true && (isSetIdentityServerPwdCredToken());
- list.add(present_identityServerPwdCredToken);
- if (present_identityServerPwdCredToken)
- list.add(identityServerPwdCredToken);
-
- return list.hashCode();
+ int hashCode = 1;
+
+ hashCode = hashCode * 8191 + ((isSetGatewayID()) ? 131071 : 524287);
+ if (isSetGatewayID())
+ hashCode = hashCode * 8191 + gatewayID.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetCredentialStoreToken()) ? 131071 : 524287);
+ if (isSetCredentialStoreToken())
+ hashCode = hashCode * 8191 + credentialStoreToken.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetComputeResourcePreferences()) ? 131071 : 524287);
+ if (isSetComputeResourcePreferences())
+ hashCode = hashCode * 8191 + computeResourcePreferences.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetStoragePreferences()) ? 131071 : 524287);
+ if (isSetStoragePreferences())
+ hashCode = hashCode * 8191 + storagePreferences.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetIdentityServerTenant()) ? 131071 : 524287);
+ if (isSetIdentityServerTenant())
+ hashCode = hashCode * 8191 + identityServerTenant.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetIdentityServerPwdCredToken()) ? 131071 : 524287);
+ if (isSetIdentityServerPwdCredToken())
+ hashCode = hashCode * 8191 + identityServerPwdCredToken.hashCode();
+
+ return hashCode;
}
@Override
@@ -627,7 +593,7 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetGatewayID()).compareTo(other.isSetGatewayID());
+ lastComparison = java.lang.Boolean.valueOf(isSetGatewayID()).compareTo(other.isSetGatewayID());
if (lastComparison != 0) {
return lastComparison;
}
@@ -637,7 +603,7 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCredentialStoreToken()).compareTo(other.isSetCredentialStoreToken());
+ lastComparison = java.lang.Boolean.valueOf(isSetCredentialStoreToken()).compareTo(other.isSetCredentialStoreToken());
if (lastComparison != 0) {
return lastComparison;
}
@@ -647,7 +613,7 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetComputeResourcePreferences()).compareTo(other.isSetComputeResourcePreferences());
+ lastComparison = java.lang.Boolean.valueOf(isSetComputeResourcePreferences()).compareTo(other.isSetComputeResourcePreferences());
if (lastComparison != 0) {
return lastComparison;
}
@@ -657,7 +623,7 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetStoragePreferences()).compareTo(other.isSetStoragePreferences());
+ lastComparison = java.lang.Boolean.valueOf(isSetStoragePreferences()).compareTo(other.isSetStoragePreferences());
if (lastComparison != 0) {
return lastComparison;
}
@@ -667,7 +633,7 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetIdentityServerTenant()).compareTo(other.isSetIdentityServerTenant());
+ lastComparison = java.lang.Boolean.valueOf(isSetIdentityServerTenant()).compareTo(other.isSetIdentityServerTenant());
if (lastComparison != 0) {
return lastComparison;
}
@@ -677,7 +643,7 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetIdentityServerPwdCredToken()).compareTo(other.isSetIdentityServerPwdCredToken());
+ lastComparison = java.lang.Boolean.valueOf(isSetIdentityServerPwdCredToken()).compareTo(other.isSetIdentityServerPwdCredToken());
if (lastComparison != 0) {
return lastComparison;
}
@@ -695,16 +661,16 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("GatewayResourceProfile(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("GatewayResourceProfile(");
boolean first = true;
sb.append("gatewayID:");
@@ -785,7 +751,7 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -793,13 +759,13 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
}
}
- private static class GatewayResourceProfileStandardSchemeFactory implements SchemeFactory {
+ private static class GatewayResourceProfileStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public GatewayResourceProfileStandardScheme getScheme() {
return new GatewayResourceProfileStandardScheme();
}
}
- private static class GatewayResourceProfileStandardScheme extends StandardScheme<GatewayResourceProfile> {
+ private static class GatewayResourceProfileStandardScheme extends org.apache.thrift.scheme.StandardScheme<GatewayResourceProfile> {
public void read(org.apache.thrift.protocol.TProtocol iprot, GatewayResourceProfile struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -831,7 +797,7 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list0 = iprot.readListBegin();
- struct.computeResourcePreferences = new ArrayList<ComputeResourcePreference>(_list0.size);
+ struct.computeResourcePreferences = new java.util.ArrayList<ComputeResourcePreference>(_list0.size);
ComputeResourcePreference _elem1;
for (int _i2 = 0; _i2 < _list0.size; ++_i2)
{
@@ -850,7 +816,7 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list3 = iprot.readListBegin();
- struct.storagePreferences = new ArrayList<StoragePreference>(_list3.size);
+ struct.storagePreferences = new java.util.ArrayList<StoragePreference>(_list3.size);
StoragePreference _elem4;
for (int _i5 = 0; _i5 < _list3.size; ++_i5)
{
@@ -954,19 +920,19 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
}
- private static class GatewayResourceProfileTupleSchemeFactory implements SchemeFactory {
+ private static class GatewayResourceProfileTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public GatewayResourceProfileTupleScheme getScheme() {
return new GatewayResourceProfileTupleScheme();
}
}
- private static class GatewayResourceProfileTupleScheme extends TupleScheme<GatewayResourceProfile> {
+ private static class GatewayResourceProfileTupleScheme extends org.apache.thrift.scheme.TupleScheme<GatewayResourceProfile> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, GatewayResourceProfile struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.gatewayID);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetCredentialStoreToken()) {
optionals.set(0);
}
@@ -1014,10 +980,10 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, GatewayResourceProfile struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.gatewayID = iprot.readString();
struct.setGatewayIDIsSet(true);
- BitSet incoming = iprot.readBitSet(5);
+ java.util.BitSet incoming = iprot.readBitSet(5);
if (incoming.get(0)) {
struct.credentialStoreToken = iprot.readString();
struct.setCredentialStoreTokenIsSet(true);
@@ -1025,7 +991,7 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
if (incoming.get(1)) {
{
org.apache.thrift.protocol.TList _list10 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.computeResourcePreferences = new ArrayList<ComputeResourcePreference>(_list10.size);
+ struct.computeResourcePreferences = new java.util.ArrayList<ComputeResourcePreference>(_list10.size);
ComputeResourcePreference _elem11;
for (int _i12 = 0; _i12 < _list10.size; ++_i12)
{
@@ -1039,7 +1005,7 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
if (incoming.get(2)) {
{
org.apache.thrift.protocol.TList _list13 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.storagePreferences = new ArrayList<StoragePreference>(_list13.size);
+ struct.storagePreferences = new java.util.ArrayList<StoragePreference>(_list13.size);
StoragePreference _elem14;
for (int _i15 = 0; _i15 < _list13.size; ++_i15)
{
@@ -1061,5 +1027,8 @@ public class GatewayResourceProfile implements org.apache.thrift.TBase<GatewayRe
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
[21/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/BatchQueue.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/BatchQueue.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/BatchQueue.java
index 550971d..a0d495e 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/BatchQueue.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/BatchQueue.java
@@ -16,48 +16,21 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.computeresource;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Batch Queue Information on SuperComputers
*
* maxRunTime:
* Maximum allowed run time in hours.
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueue._Fields>, java.io.Serializable, Cloneable, Comparable<BatchQueue> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("BatchQueue");
@@ -75,14 +48,11 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
private static final org.apache.thrift.protocol.TField QUEUE_SPECIFIC_MACROS_FIELD_DESC = new org.apache.thrift.protocol.TField("queueSpecificMacros", org.apache.thrift.protocol.TType.STRING, (short)12);
private static final org.apache.thrift.protocol.TField IS_DEFAULT_QUEUE_FIELD_DESC = new org.apache.thrift.protocol.TField("isDefaultQueue", org.apache.thrift.protocol.TType.BOOL, (short)13);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new BatchQueueStandardSchemeFactory());
- schemes.put(TupleScheme.class, new BatchQueueTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new BatchQueueStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new BatchQueueTupleSchemeFactory();
- private String queueName; // required
- private String queueDescription; // optional
+ private java.lang.String queueName; // required
+ private java.lang.String queueDescription; // optional
private int maxRunTime; // optional
private int maxNodes; // optional
private int maxProcessors; // optional
@@ -92,7 +62,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
private int defaultNodeCount; // optional
private int defaultCPUCount; // optional
private int defaultWalltime; // optional
- private String queueSpecificMacros; // optional
+ private java.lang.String queueSpecificMacros; // optional
private boolean isDefaultQueue; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
@@ -111,10 +81,10 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
QUEUE_SPECIFIC_MACROS((short)12, "queueSpecificMacros"),
IS_DEFAULT_QUEUE((short)13, "isDefaultQueue");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -161,21 +131,21 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -184,7 +154,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -202,9 +172,9 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
private static final int __ISDEFAULTQUEUE_ISSET_ID = 9;
private short __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.QUEUE_DESCRIPTION,_Fields.MAX_RUN_TIME,_Fields.MAX_NODES,_Fields.MAX_PROCESSORS,_Fields.MAX_JOBS_IN_QUEUE,_Fields.MAX_MEMORY,_Fields.CPU_PER_NODE,_Fields.DEFAULT_NODE_COUNT,_Fields.DEFAULT_CPUCOUNT,_Fields.DEFAULT_WALLTIME,_Fields.QUEUE_SPECIFIC_MACROS,_Fields.IS_DEFAULT_QUEUE};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.QUEUE_NAME, new org.apache.thrift.meta_data.FieldMetaData("queueName", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.QUEUE_DESCRIPTION, new org.apache.thrift.meta_data.FieldMetaData("queueDescription", org.apache.thrift.TFieldRequirementType.OPTIONAL,
@@ -231,7 +201,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.IS_DEFAULT_QUEUE, new org.apache.thrift.meta_data.FieldMetaData("isDefaultQueue", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(BatchQueue.class, metaDataMap);
}
@@ -239,7 +209,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
}
public BatchQueue(
- String queueName)
+ java.lang.String queueName)
{
this();
this.queueName = queueName;
@@ -302,11 +272,11 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
this.isDefaultQueue = false;
}
- public String getQueueName() {
+ public java.lang.String getQueueName() {
return this.queueName;
}
- public void setQueueName(String queueName) {
+ public void setQueueName(java.lang.String queueName) {
this.queueName = queueName;
}
@@ -325,11 +295,11 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
}
}
- public String getQueueDescription() {
+ public java.lang.String getQueueDescription() {
return this.queueDescription;
}
- public void setQueueDescription(String queueDescription) {
+ public void setQueueDescription(java.lang.String queueDescription) {
this.queueDescription = queueDescription;
}
@@ -358,16 +328,16 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
}
public void unsetMaxRunTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __MAXRUNTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __MAXRUNTIME_ISSET_ID);
}
/** Returns true if field maxRunTime is set (has been assigned a value) and false otherwise */
public boolean isSetMaxRunTime() {
- return EncodingUtils.testBit(__isset_bitfield, __MAXRUNTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __MAXRUNTIME_ISSET_ID);
}
public void setMaxRunTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __MAXRUNTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __MAXRUNTIME_ISSET_ID, value);
}
public int getMaxNodes() {
@@ -380,16 +350,16 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
}
public void unsetMaxNodes() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __MAXNODES_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __MAXNODES_ISSET_ID);
}
/** Returns true if field maxNodes is set (has been assigned a value) and false otherwise */
public boolean isSetMaxNodes() {
- return EncodingUtils.testBit(__isset_bitfield, __MAXNODES_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __MAXNODES_ISSET_ID);
}
public void setMaxNodesIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __MAXNODES_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __MAXNODES_ISSET_ID, value);
}
public int getMaxProcessors() {
@@ -402,16 +372,16 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
}
public void unsetMaxProcessors() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __MAXPROCESSORS_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __MAXPROCESSORS_ISSET_ID);
}
/** Returns true if field maxProcessors is set (has been assigned a value) and false otherwise */
public boolean isSetMaxProcessors() {
- return EncodingUtils.testBit(__isset_bitfield, __MAXPROCESSORS_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __MAXPROCESSORS_ISSET_ID);
}
public void setMaxProcessorsIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __MAXPROCESSORS_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __MAXPROCESSORS_ISSET_ID, value);
}
public int getMaxJobsInQueue() {
@@ -424,16 +394,16 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
}
public void unsetMaxJobsInQueue() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __MAXJOBSINQUEUE_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __MAXJOBSINQUEUE_ISSET_ID);
}
/** Returns true if field maxJobsInQueue is set (has been assigned a value) and false otherwise */
public boolean isSetMaxJobsInQueue() {
- return EncodingUtils.testBit(__isset_bitfield, __MAXJOBSINQUEUE_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __MAXJOBSINQUEUE_ISSET_ID);
}
public void setMaxJobsInQueueIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __MAXJOBSINQUEUE_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __MAXJOBSINQUEUE_ISSET_ID, value);
}
public int getMaxMemory() {
@@ -446,16 +416,16 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
}
public void unsetMaxMemory() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __MAXMEMORY_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __MAXMEMORY_ISSET_ID);
}
/** Returns true if field maxMemory is set (has been assigned a value) and false otherwise */
public boolean isSetMaxMemory() {
- return EncodingUtils.testBit(__isset_bitfield, __MAXMEMORY_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __MAXMEMORY_ISSET_ID);
}
public void setMaxMemoryIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __MAXMEMORY_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __MAXMEMORY_ISSET_ID, value);
}
public int getCpuPerNode() {
@@ -468,16 +438,16 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
}
public void unsetCpuPerNode() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __CPUPERNODE_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __CPUPERNODE_ISSET_ID);
}
/** Returns true if field cpuPerNode is set (has been assigned a value) and false otherwise */
public boolean isSetCpuPerNode() {
- return EncodingUtils.testBit(__isset_bitfield, __CPUPERNODE_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __CPUPERNODE_ISSET_ID);
}
public void setCpuPerNodeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __CPUPERNODE_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __CPUPERNODE_ISSET_ID, value);
}
public int getDefaultNodeCount() {
@@ -490,16 +460,16 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
}
public void unsetDefaultNodeCount() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID);
}
/** Returns true if field defaultNodeCount is set (has been assigned a value) and false otherwise */
public boolean isSetDefaultNodeCount() {
- return EncodingUtils.testBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID);
}
public void setDefaultNodeCountIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __DEFAULTNODECOUNT_ISSET_ID, value);
}
public int getDefaultCPUCount() {
@@ -512,16 +482,16 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
}
public void unsetDefaultCPUCount() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID);
}
/** Returns true if field defaultCPUCount is set (has been assigned a value) and false otherwise */
public boolean isSetDefaultCPUCount() {
- return EncodingUtils.testBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID);
}
public void setDefaultCPUCountIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __DEFAULTCPUCOUNT_ISSET_ID, value);
}
public int getDefaultWalltime() {
@@ -534,23 +504,23 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
}
public void unsetDefaultWalltime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID);
}
/** Returns true if field defaultWalltime is set (has been assigned a value) and false otherwise */
public boolean isSetDefaultWalltime() {
- return EncodingUtils.testBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID);
}
public void setDefaultWalltimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __DEFAULTWALLTIME_ISSET_ID, value);
}
- public String getQueueSpecificMacros() {
+ public java.lang.String getQueueSpecificMacros() {
return this.queueSpecificMacros;
}
- public void setQueueSpecificMacros(String queueSpecificMacros) {
+ public void setQueueSpecificMacros(java.lang.String queueSpecificMacros) {
this.queueSpecificMacros = queueSpecificMacros;
}
@@ -579,25 +549,25 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
}
public void unsetIsDefaultQueue() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ISDEFAULTQUEUE_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ISDEFAULTQUEUE_ISSET_ID);
}
/** Returns true if field isDefaultQueue is set (has been assigned a value) and false otherwise */
public boolean isSetIsDefaultQueue() {
- return EncodingUtils.testBit(__isset_bitfield, __ISDEFAULTQUEUE_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ISDEFAULTQUEUE_ISSET_ID);
}
public void setIsDefaultQueueIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ISDEFAULTQUEUE_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ISDEFAULTQUEUE_ISSET_ID, value);
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case QUEUE_NAME:
if (value == null) {
unsetQueueName();
} else {
- setQueueName((String)value);
+ setQueueName((java.lang.String)value);
}
break;
@@ -605,7 +575,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
if (value == null) {
unsetQueueDescription();
} else {
- setQueueDescription((String)value);
+ setQueueDescription((java.lang.String)value);
}
break;
@@ -613,7 +583,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
if (value == null) {
unsetMaxRunTime();
} else {
- setMaxRunTime((Integer)value);
+ setMaxRunTime((java.lang.Integer)value);
}
break;
@@ -621,7 +591,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
if (value == null) {
unsetMaxNodes();
} else {
- setMaxNodes((Integer)value);
+ setMaxNodes((java.lang.Integer)value);
}
break;
@@ -629,7 +599,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
if (value == null) {
unsetMaxProcessors();
} else {
- setMaxProcessors((Integer)value);
+ setMaxProcessors((java.lang.Integer)value);
}
break;
@@ -637,7 +607,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
if (value == null) {
unsetMaxJobsInQueue();
} else {
- setMaxJobsInQueue((Integer)value);
+ setMaxJobsInQueue((java.lang.Integer)value);
}
break;
@@ -645,7 +615,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
if (value == null) {
unsetMaxMemory();
} else {
- setMaxMemory((Integer)value);
+ setMaxMemory((java.lang.Integer)value);
}
break;
@@ -653,7 +623,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
if (value == null) {
unsetCpuPerNode();
} else {
- setCpuPerNode((Integer)value);
+ setCpuPerNode((java.lang.Integer)value);
}
break;
@@ -661,7 +631,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
if (value == null) {
unsetDefaultNodeCount();
} else {
- setDefaultNodeCount((Integer)value);
+ setDefaultNodeCount((java.lang.Integer)value);
}
break;
@@ -669,7 +639,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
if (value == null) {
unsetDefaultCPUCount();
} else {
- setDefaultCPUCount((Integer)value);
+ setDefaultCPUCount((java.lang.Integer)value);
}
break;
@@ -677,7 +647,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
if (value == null) {
unsetDefaultWalltime();
} else {
- setDefaultWalltime((Integer)value);
+ setDefaultWalltime((java.lang.Integer)value);
}
break;
@@ -685,7 +655,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
if (value == null) {
unsetQueueSpecificMacros();
} else {
- setQueueSpecificMacros((String)value);
+ setQueueSpecificMacros((java.lang.String)value);
}
break;
@@ -693,14 +663,14 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
if (value == null) {
unsetIsDefaultQueue();
} else {
- setIsDefaultQueue((Boolean)value);
+ setIsDefaultQueue((java.lang.Boolean)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case QUEUE_NAME:
return getQueueName();
@@ -742,13 +712,13 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
return isIsDefaultQueue();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -779,11 +749,11 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
case IS_DEFAULT_QUEUE:
return isSetIsDefaultQueue();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof BatchQueue)
@@ -794,6 +764,8 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
public boolean equals(BatchQueue that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_queueName = true && this.isSetQueueName();
boolean that_present_queueName = true && that.isSetQueueName();
@@ -917,74 +889,61 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_queueName = true && (isSetQueueName());
- list.add(present_queueName);
- if (present_queueName)
- list.add(queueName);
-
- boolean present_queueDescription = true && (isSetQueueDescription());
- list.add(present_queueDescription);
- if (present_queueDescription)
- list.add(queueDescription);
-
- boolean present_maxRunTime = true && (isSetMaxRunTime());
- list.add(present_maxRunTime);
- if (present_maxRunTime)
- list.add(maxRunTime);
-
- boolean present_maxNodes = true && (isSetMaxNodes());
- list.add(present_maxNodes);
- if (present_maxNodes)
- list.add(maxNodes);
-
- boolean present_maxProcessors = true && (isSetMaxProcessors());
- list.add(present_maxProcessors);
- if (present_maxProcessors)
- list.add(maxProcessors);
-
- boolean present_maxJobsInQueue = true && (isSetMaxJobsInQueue());
- list.add(present_maxJobsInQueue);
- if (present_maxJobsInQueue)
- list.add(maxJobsInQueue);
-
- boolean present_maxMemory = true && (isSetMaxMemory());
- list.add(present_maxMemory);
- if (present_maxMemory)
- list.add(maxMemory);
-
- boolean present_cpuPerNode = true && (isSetCpuPerNode());
- list.add(present_cpuPerNode);
- if (present_cpuPerNode)
- list.add(cpuPerNode);
-
- boolean present_defaultNodeCount = true && (isSetDefaultNodeCount());
- list.add(present_defaultNodeCount);
- if (present_defaultNodeCount)
- list.add(defaultNodeCount);
-
- boolean present_defaultCPUCount = true && (isSetDefaultCPUCount());
- list.add(present_defaultCPUCount);
- if (present_defaultCPUCount)
- list.add(defaultCPUCount);
-
- boolean present_defaultWalltime = true && (isSetDefaultWalltime());
- list.add(present_defaultWalltime);
- if (present_defaultWalltime)
- list.add(defaultWalltime);
-
- boolean present_queueSpecificMacros = true && (isSetQueueSpecificMacros());
- list.add(present_queueSpecificMacros);
- if (present_queueSpecificMacros)
- list.add(queueSpecificMacros);
-
- boolean present_isDefaultQueue = true && (isSetIsDefaultQueue());
- list.add(present_isDefaultQueue);
- if (present_isDefaultQueue)
- list.add(isDefaultQueue);
-
- return list.hashCode();
+ int hashCode = 1;
+
+ hashCode = hashCode * 8191 + ((isSetQueueName()) ? 131071 : 524287);
+ if (isSetQueueName())
+ hashCode = hashCode * 8191 + queueName.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetQueueDescription()) ? 131071 : 524287);
+ if (isSetQueueDescription())
+ hashCode = hashCode * 8191 + queueDescription.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetMaxRunTime()) ? 131071 : 524287);
+ if (isSetMaxRunTime())
+ hashCode = hashCode * 8191 + maxRunTime;
+
+ hashCode = hashCode * 8191 + ((isSetMaxNodes()) ? 131071 : 524287);
+ if (isSetMaxNodes())
+ hashCode = hashCode * 8191 + maxNodes;
+
+ hashCode = hashCode * 8191 + ((isSetMaxProcessors()) ? 131071 : 524287);
+ if (isSetMaxProcessors())
+ hashCode = hashCode * 8191 + maxProcessors;
+
+ hashCode = hashCode * 8191 + ((isSetMaxJobsInQueue()) ? 131071 : 524287);
+ if (isSetMaxJobsInQueue())
+ hashCode = hashCode * 8191 + maxJobsInQueue;
+
+ hashCode = hashCode * 8191 + ((isSetMaxMemory()) ? 131071 : 524287);
+ if (isSetMaxMemory())
+ hashCode = hashCode * 8191 + maxMemory;
+
+ hashCode = hashCode * 8191 + ((isSetCpuPerNode()) ? 131071 : 524287);
+ if (isSetCpuPerNode())
+ hashCode = hashCode * 8191 + cpuPerNode;
+
+ hashCode = hashCode * 8191 + ((isSetDefaultNodeCount()) ? 131071 : 524287);
+ if (isSetDefaultNodeCount())
+ hashCode = hashCode * 8191 + defaultNodeCount;
+
+ hashCode = hashCode * 8191 + ((isSetDefaultCPUCount()) ? 131071 : 524287);
+ if (isSetDefaultCPUCount())
+ hashCode = hashCode * 8191 + defaultCPUCount;
+
+ hashCode = hashCode * 8191 + ((isSetDefaultWalltime()) ? 131071 : 524287);
+ if (isSetDefaultWalltime())
+ hashCode = hashCode * 8191 + defaultWalltime;
+
+ hashCode = hashCode * 8191 + ((isSetQueueSpecificMacros()) ? 131071 : 524287);
+ if (isSetQueueSpecificMacros())
+ hashCode = hashCode * 8191 + queueSpecificMacros.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetIsDefaultQueue()) ? 131071 : 524287);
+ if (isSetIsDefaultQueue())
+ hashCode = hashCode * 8191 + ((isDefaultQueue) ? 131071 : 524287);
+
+ return hashCode;
}
@Override
@@ -995,7 +954,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetQueueName()).compareTo(other.isSetQueueName());
+ lastComparison = java.lang.Boolean.valueOf(isSetQueueName()).compareTo(other.isSetQueueName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1005,7 +964,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetQueueDescription()).compareTo(other.isSetQueueDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetQueueDescription()).compareTo(other.isSetQueueDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1015,7 +974,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetMaxRunTime()).compareTo(other.isSetMaxRunTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetMaxRunTime()).compareTo(other.isSetMaxRunTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1025,7 +984,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetMaxNodes()).compareTo(other.isSetMaxNodes());
+ lastComparison = java.lang.Boolean.valueOf(isSetMaxNodes()).compareTo(other.isSetMaxNodes());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1035,7 +994,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetMaxProcessors()).compareTo(other.isSetMaxProcessors());
+ lastComparison = java.lang.Boolean.valueOf(isSetMaxProcessors()).compareTo(other.isSetMaxProcessors());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1045,7 +1004,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetMaxJobsInQueue()).compareTo(other.isSetMaxJobsInQueue());
+ lastComparison = java.lang.Boolean.valueOf(isSetMaxJobsInQueue()).compareTo(other.isSetMaxJobsInQueue());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1055,7 +1014,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetMaxMemory()).compareTo(other.isSetMaxMemory());
+ lastComparison = java.lang.Boolean.valueOf(isSetMaxMemory()).compareTo(other.isSetMaxMemory());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1065,7 +1024,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCpuPerNode()).compareTo(other.isSetCpuPerNode());
+ lastComparison = java.lang.Boolean.valueOf(isSetCpuPerNode()).compareTo(other.isSetCpuPerNode());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1075,7 +1034,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDefaultNodeCount()).compareTo(other.isSetDefaultNodeCount());
+ lastComparison = java.lang.Boolean.valueOf(isSetDefaultNodeCount()).compareTo(other.isSetDefaultNodeCount());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1085,7 +1044,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDefaultCPUCount()).compareTo(other.isSetDefaultCPUCount());
+ lastComparison = java.lang.Boolean.valueOf(isSetDefaultCPUCount()).compareTo(other.isSetDefaultCPUCount());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1095,7 +1054,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDefaultWalltime()).compareTo(other.isSetDefaultWalltime());
+ lastComparison = java.lang.Boolean.valueOf(isSetDefaultWalltime()).compareTo(other.isSetDefaultWalltime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1105,7 +1064,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetQueueSpecificMacros()).compareTo(other.isSetQueueSpecificMacros());
+ lastComparison = java.lang.Boolean.valueOf(isSetQueueSpecificMacros()).compareTo(other.isSetQueueSpecificMacros());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1115,7 +1074,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetIsDefaultQueue()).compareTo(other.isSetIsDefaultQueue());
+ lastComparison = java.lang.Boolean.valueOf(isSetIsDefaultQueue()).compareTo(other.isSetIsDefaultQueue());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1133,16 +1092,16 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("BatchQueue(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("BatchQueue(");
boolean first = true;
sb.append("queueName:");
@@ -1253,7 +1212,7 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -1263,13 +1222,13 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
}
}
- private static class BatchQueueStandardSchemeFactory implements SchemeFactory {
+ private static class BatchQueueStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public BatchQueueStandardScheme getScheme() {
return new BatchQueueStandardScheme();
}
}
- private static class BatchQueueStandardScheme extends StandardScheme<BatchQueue> {
+ private static class BatchQueueStandardScheme extends org.apache.thrift.scheme.StandardScheme<BatchQueue> {
public void read(org.apache.thrift.protocol.TProtocol iprot, BatchQueue struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1473,19 +1432,19 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
}
- private static class BatchQueueTupleSchemeFactory implements SchemeFactory {
+ private static class BatchQueueTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public BatchQueueTupleScheme getScheme() {
return new BatchQueueTupleScheme();
}
}
- private static class BatchQueueTupleScheme extends TupleScheme<BatchQueue> {
+ private static class BatchQueueTupleScheme extends org.apache.thrift.scheme.TupleScheme<BatchQueue> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, BatchQueue struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.queueName);
- BitSet optionals = new BitSet();
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetQueueDescription()) {
optionals.set(0);
}
@@ -1563,10 +1522,10 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, BatchQueue struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.queueName = iprot.readString();
struct.setQueueNameIsSet(true);
- BitSet incoming = iprot.readBitSet(12);
+ java.util.BitSet incoming = iprot.readBitSet(12);
if (incoming.get(0)) {
struct.queueDescription = iprot.readString();
struct.setQueueDescriptionIsSet(true);
@@ -1618,5 +1577,8 @@ public class BatchQueue implements org.apache.thrift.TBase<BatchQueue, BatchQueu
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/CloudJobSubmission.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/CloudJobSubmission.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/CloudJobSubmission.java
index 7d540de..ac6b0f9 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/CloudJobSubmission.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/appcatalog/computeresource/CloudJobSubmission.java
@@ -16,47 +16,20 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.appcatalog.computeresource;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
/**
* Cloud Job Submission
*
*
*/
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmission, CloudJobSubmission._Fields>, java.io.Serializable, Cloneable, Comparable<CloudJobSubmission> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("CloudJobSubmission");
@@ -67,18 +40,15 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
private static final org.apache.thrift.protocol.TField PROVIDER_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("providerName", org.apache.thrift.protocol.TType.I32, (short)5);
private static final org.apache.thrift.protocol.TField USER_ACCOUNT_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("userAccountName", org.apache.thrift.protocol.TType.STRING, (short)6);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new CloudJobSubmissionStandardSchemeFactory());
- schemes.put(TupleScheme.class, new CloudJobSubmissionTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new CloudJobSubmissionStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new CloudJobSubmissionTupleSchemeFactory();
- private String jobSubmissionInterfaceId; // required
+ private java.lang.String jobSubmissionInterfaceId; // required
private org.apache.airavata.model.data.movement.SecurityProtocol securityProtocol; // required
- private String nodeId; // required
- private String executableType; // required
+ private java.lang.String nodeId; // required
+ private java.lang.String executableType; // required
private ProviderName providerName; // required
- private String userAccountName; // required
+ private java.lang.String userAccountName; // required
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -97,10 +67,10 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
PROVIDER_NAME((short)5, "providerName"),
USER_ACCOUNT_NAME((short)6, "userAccountName");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -133,21 +103,21 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -156,15 +126,15 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
// isset id assignments
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.JOB_SUBMISSION_INTERFACE_ID, new org.apache.thrift.meta_data.FieldMetaData("jobSubmissionInterfaceId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.SECURITY_PROTOCOL, new org.apache.thrift.meta_data.FieldMetaData("securityProtocol", org.apache.thrift.TFieldRequirementType.REQUIRED,
@@ -177,7 +147,7 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, ProviderName.class)));
tmpMap.put(_Fields.USER_ACCOUNT_NAME, new org.apache.thrift.meta_data.FieldMetaData("userAccountName", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(CloudJobSubmission.class, metaDataMap);
}
@@ -187,12 +157,12 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
}
public CloudJobSubmission(
- String jobSubmissionInterfaceId,
+ java.lang.String jobSubmissionInterfaceId,
org.apache.airavata.model.data.movement.SecurityProtocol securityProtocol,
- String nodeId,
- String executableType,
+ java.lang.String nodeId,
+ java.lang.String executableType,
ProviderName providerName,
- String userAccountName)
+ java.lang.String userAccountName)
{
this();
this.jobSubmissionInterfaceId = jobSubmissionInterfaceId;
@@ -242,11 +212,11 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
this.userAccountName = null;
}
- public String getJobSubmissionInterfaceId() {
+ public java.lang.String getJobSubmissionInterfaceId() {
return this.jobSubmissionInterfaceId;
}
- public void setJobSubmissionInterfaceId(String jobSubmissionInterfaceId) {
+ public void setJobSubmissionInterfaceId(java.lang.String jobSubmissionInterfaceId) {
this.jobSubmissionInterfaceId = jobSubmissionInterfaceId;
}
@@ -296,11 +266,11 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
}
}
- public String getNodeId() {
+ public java.lang.String getNodeId() {
return this.nodeId;
}
- public void setNodeId(String nodeId) {
+ public void setNodeId(java.lang.String nodeId) {
this.nodeId = nodeId;
}
@@ -319,11 +289,11 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
}
}
- public String getExecutableType() {
+ public java.lang.String getExecutableType() {
return this.executableType;
}
- public void setExecutableType(String executableType) {
+ public void setExecutableType(java.lang.String executableType) {
this.executableType = executableType;
}
@@ -373,11 +343,11 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
}
}
- public String getUserAccountName() {
+ public java.lang.String getUserAccountName() {
return this.userAccountName;
}
- public void setUserAccountName(String userAccountName) {
+ public void setUserAccountName(java.lang.String userAccountName) {
this.userAccountName = userAccountName;
}
@@ -396,13 +366,13 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case JOB_SUBMISSION_INTERFACE_ID:
if (value == null) {
unsetJobSubmissionInterfaceId();
} else {
- setJobSubmissionInterfaceId((String)value);
+ setJobSubmissionInterfaceId((java.lang.String)value);
}
break;
@@ -418,7 +388,7 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
if (value == null) {
unsetNodeId();
} else {
- setNodeId((String)value);
+ setNodeId((java.lang.String)value);
}
break;
@@ -426,7 +396,7 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
if (value == null) {
unsetExecutableType();
} else {
- setExecutableType((String)value);
+ setExecutableType((java.lang.String)value);
}
break;
@@ -442,14 +412,14 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
if (value == null) {
unsetUserAccountName();
} else {
- setUserAccountName((String)value);
+ setUserAccountName((java.lang.String)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case JOB_SUBMISSION_INTERFACE_ID:
return getJobSubmissionInterfaceId();
@@ -470,13 +440,13 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
return getUserAccountName();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -493,11 +463,11 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
case USER_ACCOUNT_NAME:
return isSetUserAccountName();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof CloudJobSubmission)
@@ -508,6 +478,8 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
public boolean equals(CloudJobSubmission that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_jobSubmissionInterfaceId = true && this.isSetJobSubmissionInterfaceId();
boolean that_present_jobSubmissionInterfaceId = true && that.isSetJobSubmissionInterfaceId();
@@ -568,39 +540,33 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_jobSubmissionInterfaceId = true && (isSetJobSubmissionInterfaceId());
- list.add(present_jobSubmissionInterfaceId);
- if (present_jobSubmissionInterfaceId)
- list.add(jobSubmissionInterfaceId);
+ hashCode = hashCode * 8191 + ((isSetJobSubmissionInterfaceId()) ? 131071 : 524287);
+ if (isSetJobSubmissionInterfaceId())
+ hashCode = hashCode * 8191 + jobSubmissionInterfaceId.hashCode();
- boolean present_securityProtocol = true && (isSetSecurityProtocol());
- list.add(present_securityProtocol);
- if (present_securityProtocol)
- list.add(securityProtocol.getValue());
+ hashCode = hashCode * 8191 + ((isSetSecurityProtocol()) ? 131071 : 524287);
+ if (isSetSecurityProtocol())
+ hashCode = hashCode * 8191 + securityProtocol.getValue();
- boolean present_nodeId = true && (isSetNodeId());
- list.add(present_nodeId);
- if (present_nodeId)
- list.add(nodeId);
+ hashCode = hashCode * 8191 + ((isSetNodeId()) ? 131071 : 524287);
+ if (isSetNodeId())
+ hashCode = hashCode * 8191 + nodeId.hashCode();
- boolean present_executableType = true && (isSetExecutableType());
- list.add(present_executableType);
- if (present_executableType)
- list.add(executableType);
+ hashCode = hashCode * 8191 + ((isSetExecutableType()) ? 131071 : 524287);
+ if (isSetExecutableType())
+ hashCode = hashCode * 8191 + executableType.hashCode();
- boolean present_providerName = true && (isSetProviderName());
- list.add(present_providerName);
- if (present_providerName)
- list.add(providerName.getValue());
+ hashCode = hashCode * 8191 + ((isSetProviderName()) ? 131071 : 524287);
+ if (isSetProviderName())
+ hashCode = hashCode * 8191 + providerName.getValue();
- boolean present_userAccountName = true && (isSetUserAccountName());
- list.add(present_userAccountName);
- if (present_userAccountName)
- list.add(userAccountName);
+ hashCode = hashCode * 8191 + ((isSetUserAccountName()) ? 131071 : 524287);
+ if (isSetUserAccountName())
+ hashCode = hashCode * 8191 + userAccountName.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -611,7 +577,7 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetJobSubmissionInterfaceId()).compareTo(other.isSetJobSubmissionInterfaceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetJobSubmissionInterfaceId()).compareTo(other.isSetJobSubmissionInterfaceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -621,7 +587,7 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetSecurityProtocol()).compareTo(other.isSetSecurityProtocol());
+ lastComparison = java.lang.Boolean.valueOf(isSetSecurityProtocol()).compareTo(other.isSetSecurityProtocol());
if (lastComparison != 0) {
return lastComparison;
}
@@ -631,7 +597,7 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetNodeId()).compareTo(other.isSetNodeId());
+ lastComparison = java.lang.Boolean.valueOf(isSetNodeId()).compareTo(other.isSetNodeId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -641,7 +607,7 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetExecutableType()).compareTo(other.isSetExecutableType());
+ lastComparison = java.lang.Boolean.valueOf(isSetExecutableType()).compareTo(other.isSetExecutableType());
if (lastComparison != 0) {
return lastComparison;
}
@@ -651,7 +617,7 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetProviderName()).compareTo(other.isSetProviderName());
+ lastComparison = java.lang.Boolean.valueOf(isSetProviderName()).compareTo(other.isSetProviderName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -661,7 +627,7 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetUserAccountName()).compareTo(other.isSetUserAccountName());
+ lastComparison = java.lang.Boolean.valueOf(isSetUserAccountName()).compareTo(other.isSetUserAccountName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -679,16 +645,16 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("CloudJobSubmission(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("CloudJobSubmission(");
boolean first = true;
sb.append("jobSubmissionInterfaceId:");
@@ -779,7 +745,7 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
} catch (org.apache.thrift.TException te) {
@@ -787,13 +753,13 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
}
}
- private static class CloudJobSubmissionStandardSchemeFactory implements SchemeFactory {
+ private static class CloudJobSubmissionStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public CloudJobSubmissionStandardScheme getScheme() {
return new CloudJobSubmissionStandardScheme();
}
}
- private static class CloudJobSubmissionStandardScheme extends StandardScheme<CloudJobSubmission> {
+ private static class CloudJobSubmissionStandardScheme extends org.apache.thrift.scheme.StandardScheme<CloudJobSubmission> {
public void read(org.apache.thrift.protocol.TProtocol iprot, CloudJobSubmission struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -902,17 +868,17 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
}
- private static class CloudJobSubmissionTupleSchemeFactory implements SchemeFactory {
+ private static class CloudJobSubmissionTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public CloudJobSubmissionTupleScheme getScheme() {
return new CloudJobSubmissionTupleScheme();
}
}
- private static class CloudJobSubmissionTupleScheme extends TupleScheme<CloudJobSubmission> {
+ private static class CloudJobSubmissionTupleScheme extends org.apache.thrift.scheme.TupleScheme<CloudJobSubmission> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, CloudJobSubmission struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeString(struct.jobSubmissionInterfaceId);
oprot.writeI32(struct.securityProtocol.getValue());
oprot.writeString(struct.nodeId);
@@ -923,7 +889,7 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, CloudJobSubmission struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.jobSubmissionInterfaceId = iprot.readString();
struct.setJobSubmissionInterfaceIdIsSet(true);
struct.securityProtocol = org.apache.airavata.model.data.movement.SecurityProtocol.findByValue(iprot.readI32());
@@ -939,5 +905,8 @@ public class CloudJobSubmission implements org.apache.thrift.TBase<CloudJobSubmi
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
[36/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/group/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/group/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/group/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/group/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/group/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/group/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/group/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/group/ttypes.py
index 996700b..17632e6 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/group/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/group/ttypes.py
@@ -1,182 +1,169 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.commons.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class ResourceType:
- PROJECT = 0
- EXPERIMENT = 1
- DATA = 2
- OTHER = 3
-
- _VALUES_TO_NAMES = {
- 0: "PROJECT",
- 1: "EXPERIMENT",
- 2: "DATA",
- 3: "OTHER",
- }
-
- _NAMES_TO_VALUES = {
- "PROJECT": 0,
- "EXPERIMENT": 1,
- "DATA": 2,
- "OTHER": 3,
- }
-
-class ResourcePermissionType:
- WRITE = 0
- READ = 1
- OWNER = 2
-
- _VALUES_TO_NAMES = {
- 0: "WRITE",
- 1: "READ",
- 2: "OWNER",
- }
-
- _NAMES_TO_VALUES = {
- "WRITE": 0,
- "READ": 1,
- "OWNER": 2,
- }
-
-
-class GroupModel:
- """
- Attributes:
- - id
- - name
- - ownerId
- - description
- - members
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'id', None, None, ), # 1
- (2, TType.STRING, 'name', None, None, ), # 2
- (3, TType.STRING, 'ownerId', None, None, ), # 3
- (4, TType.STRING, 'description', None, None, ), # 4
- (5, TType.LIST, 'members', (TType.STRING,None), None, ), # 5
- )
-
- def __init__(self, id=None, name=None, ownerId=None, description=None, members=None,):
- self.id = id
- self.name = name
- self.ownerId = ownerId
- self.description = description
- self.members = members
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.id = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.name = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.ownerId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.description = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.LIST:
- self.members = []
- (_etype3, _size0) = iprot.readListBegin()
- for _i4 in xrange(_size0):
- _elem5 = iprot.readString()
- self.members.append(_elem5)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('GroupModel')
- if self.id is not None:
- oprot.writeFieldBegin('id', TType.STRING, 1)
- oprot.writeString(self.id)
- oprot.writeFieldEnd()
- if self.name is not None:
- oprot.writeFieldBegin('name', TType.STRING, 2)
- oprot.writeString(self.name)
- oprot.writeFieldEnd()
- if self.ownerId is not None:
- oprot.writeFieldBegin('ownerId', TType.STRING, 3)
- oprot.writeString(self.ownerId)
- oprot.writeFieldEnd()
- if self.description is not None:
- oprot.writeFieldBegin('description', TType.STRING, 4)
- oprot.writeString(self.description)
- oprot.writeFieldEnd()
- if self.members is not None:
- oprot.writeFieldBegin('members', TType.LIST, 5)
- oprot.writeListBegin(TType.STRING, len(self.members))
- for iter6 in self.members:
- oprot.writeString(iter6)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.id)
- value = (value * 31) ^ hash(self.name)
- value = (value * 31) ^ hash(self.ownerId)
- value = (value * 31) ^ hash(self.description)
- value = (value * 31) ^ hash(self.members)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class ResourceType(object):
+ PROJECT = 0
+ EXPERIMENT = 1
+ DATA = 2
+ OTHER = 3
+
+ _VALUES_TO_NAMES = {
+ 0: "PROJECT",
+ 1: "EXPERIMENT",
+ 2: "DATA",
+ 3: "OTHER",
+ }
+
+ _NAMES_TO_VALUES = {
+ "PROJECT": 0,
+ "EXPERIMENT": 1,
+ "DATA": 2,
+ "OTHER": 3,
+ }
+
+
+class ResourcePermissionType(object):
+ WRITE = 0
+ READ = 1
+ OWNER = 2
+
+ _VALUES_TO_NAMES = {
+ 0: "WRITE",
+ 1: "READ",
+ 2: "OWNER",
+ }
+
+ _NAMES_TO_VALUES = {
+ "WRITE": 0,
+ "READ": 1,
+ "OWNER": 2,
+ }
+
+
+class GroupModel(object):
+ """
+ Attributes:
+ - id
+ - name
+ - ownerId
+ - description
+ - members
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'id', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'name', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'ownerId', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'description', 'UTF8', None, ), # 4
+ (5, TType.LIST, 'members', (TType.STRING, 'UTF8', False), None, ), # 5
+ )
+
+ def __init__(self, id=None, name=None, ownerId=None, description=None, members=None,):
+ self.id = id
+ self.name = name
+ self.ownerId = ownerId
+ self.description = description
+ self.members = members
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.id = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.name = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.ownerId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.description = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.LIST:
+ self.members = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in range(_size0):
+ _elem5 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ self.members.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('GroupModel')
+ if self.id is not None:
+ oprot.writeFieldBegin('id', TType.STRING, 1)
+ oprot.writeString(self.id.encode('utf-8') if sys.version_info[0] == 2 else self.id)
+ oprot.writeFieldEnd()
+ if self.name is not None:
+ oprot.writeFieldBegin('name', TType.STRING, 2)
+ oprot.writeString(self.name.encode('utf-8') if sys.version_info[0] == 2 else self.name)
+ oprot.writeFieldEnd()
+ if self.ownerId is not None:
+ oprot.writeFieldBegin('ownerId', TType.STRING, 3)
+ oprot.writeString(self.ownerId.encode('utf-8') if sys.version_info[0] == 2 else self.ownerId)
+ oprot.writeFieldEnd()
+ if self.description is not None:
+ oprot.writeFieldBegin('description', TType.STRING, 4)
+ oprot.writeString(self.description.encode('utf-8') if sys.version_info[0] == 2 else self.description)
+ oprot.writeFieldEnd()
+ if self.members is not None:
+ oprot.writeFieldBegin('members', TType.LIST, 5)
+ oprot.writeListBegin(TType.STRING, len(self.members))
+ for iter6 in self.members:
+ oprot.writeString(iter6.encode('utf-8') if sys.version_info[0] == 2 else iter6)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/job/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/job/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/job/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/job/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/job/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/job/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/job/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/job/ttypes.py
index 52478a6..ed4e249 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/job/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/job/ttypes.py
@@ -1,245 +1,223 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.status.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-
-class JobModel:
- """
- Attributes:
- - jobId
- - taskId
- - processId
- - jobDescription
- - creationTime
- - jobStatuses
- - computeResourceConsumed
- - jobName
- - workingDir
- - stdOut
- - stdErr
- - exitCode
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'jobId', None, None, ), # 1
- (2, TType.STRING, 'taskId', None, None, ), # 2
- (3, TType.STRING, 'processId', None, None, ), # 3
- (4, TType.STRING, 'jobDescription', None, None, ), # 4
- (5, TType.I64, 'creationTime', None, None, ), # 5
- (6, TType.LIST, 'jobStatuses', (TType.STRUCT,(apache.airavata.model.status.ttypes.JobStatus, apache.airavata.model.status.ttypes.JobStatus.thrift_spec)), None, ), # 6
- (7, TType.STRING, 'computeResourceConsumed', None, None, ), # 7
- (8, TType.STRING, 'jobName', None, None, ), # 8
- (9, TType.STRING, 'workingDir', None, None, ), # 9
- (10, TType.STRING, 'stdOut', None, None, ), # 10
- (11, TType.STRING, 'stdErr', None, None, ), # 11
- (12, TType.I32, 'exitCode', None, None, ), # 12
- )
-
- def __init__(self, jobId=None, taskId=None, processId=None, jobDescription=None, creationTime=None, jobStatuses=None, computeResourceConsumed=None, jobName=None, workingDir=None, stdOut=None, stdErr=None, exitCode=None,):
- self.jobId = jobId
- self.taskId = taskId
- self.processId = processId
- self.jobDescription = jobDescription
- self.creationTime = creationTime
- self.jobStatuses = jobStatuses
- self.computeResourceConsumed = computeResourceConsumed
- self.jobName = jobName
- self.workingDir = workingDir
- self.stdOut = stdOut
- self.stdErr = stdErr
- self.exitCode = exitCode
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.jobId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.taskId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.processId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.jobDescription = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I64:
- self.creationTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.LIST:
- self.jobStatuses = []
- (_etype3, _size0) = iprot.readListBegin()
- for _i4 in xrange(_size0):
- _elem5 = apache.airavata.model.status.ttypes.JobStatus()
- _elem5.read(iprot)
- self.jobStatuses.append(_elem5)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.STRING:
- self.computeResourceConsumed = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.STRING:
- self.jobName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.STRING:
- self.workingDir = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.STRING:
- self.stdOut = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 11:
- if ftype == TType.STRING:
- self.stdErr = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 12:
- if ftype == TType.I32:
- self.exitCode = iprot.readI32()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('JobModel')
- if self.jobId is not None:
- oprot.writeFieldBegin('jobId', TType.STRING, 1)
- oprot.writeString(self.jobId)
- oprot.writeFieldEnd()
- if self.taskId is not None:
- oprot.writeFieldBegin('taskId', TType.STRING, 2)
- oprot.writeString(self.taskId)
- oprot.writeFieldEnd()
- if self.processId is not None:
- oprot.writeFieldBegin('processId', TType.STRING, 3)
- oprot.writeString(self.processId)
- oprot.writeFieldEnd()
- if self.jobDescription is not None:
- oprot.writeFieldBegin('jobDescription', TType.STRING, 4)
- oprot.writeString(self.jobDescription)
- oprot.writeFieldEnd()
- if self.creationTime is not None:
- oprot.writeFieldBegin('creationTime', TType.I64, 5)
- oprot.writeI64(self.creationTime)
- oprot.writeFieldEnd()
- if self.jobStatuses is not None:
- oprot.writeFieldBegin('jobStatuses', TType.LIST, 6)
- oprot.writeListBegin(TType.STRUCT, len(self.jobStatuses))
- for iter6 in self.jobStatuses:
- iter6.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.computeResourceConsumed is not None:
- oprot.writeFieldBegin('computeResourceConsumed', TType.STRING, 7)
- oprot.writeString(self.computeResourceConsumed)
- oprot.writeFieldEnd()
- if self.jobName is not None:
- oprot.writeFieldBegin('jobName', TType.STRING, 8)
- oprot.writeString(self.jobName)
- oprot.writeFieldEnd()
- if self.workingDir is not None:
- oprot.writeFieldBegin('workingDir', TType.STRING, 9)
- oprot.writeString(self.workingDir)
- oprot.writeFieldEnd()
- if self.stdOut is not None:
- oprot.writeFieldBegin('stdOut', TType.STRING, 10)
- oprot.writeString(self.stdOut)
- oprot.writeFieldEnd()
- if self.stdErr is not None:
- oprot.writeFieldBegin('stdErr', TType.STRING, 11)
- oprot.writeString(self.stdErr)
- oprot.writeFieldEnd()
- if self.exitCode is not None:
- oprot.writeFieldBegin('exitCode', TType.I32, 12)
- oprot.writeI32(self.exitCode)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.jobId is None:
- raise TProtocol.TProtocolException(message='Required field jobId is unset!')
- if self.taskId is None:
- raise TProtocol.TProtocolException(message='Required field taskId is unset!')
- if self.processId is None:
- raise TProtocol.TProtocolException(message='Required field processId is unset!')
- if self.jobDescription is None:
- raise TProtocol.TProtocolException(message='Required field jobDescription is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.jobId)
- value = (value * 31) ^ hash(self.taskId)
- value = (value * 31) ^ hash(self.processId)
- value = (value * 31) ^ hash(self.jobDescription)
- value = (value * 31) ^ hash(self.creationTime)
- value = (value * 31) ^ hash(self.jobStatuses)
- value = (value * 31) ^ hash(self.computeResourceConsumed)
- value = (value * 31) ^ hash(self.jobName)
- value = (value * 31) ^ hash(self.workingDir)
- value = (value * 31) ^ hash(self.stdOut)
- value = (value * 31) ^ hash(self.stdErr)
- value = (value * 31) ^ hash(self.exitCode)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
- def __ne__(self, other):
- return not (self == other)
+class JobModel(object):
+ """
+ Attributes:
+ - jobId
+ - taskId
+ - processId
+ - jobDescription
+ - creationTime
+ - jobStatuses
+ - computeResourceConsumed
+ - jobName
+ - workingDir
+ - stdOut
+ - stdErr
+ - exitCode
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'jobId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'taskId', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'processId', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'jobDescription', 'UTF8', None, ), # 4
+ (5, TType.I64, 'creationTime', None, None, ), # 5
+ (6, TType.LIST, 'jobStatuses', (TType.STRUCT, (apache.airavata.model.status.ttypes.JobStatus, apache.airavata.model.status.ttypes.JobStatus.thrift_spec), False), None, ), # 6
+ (7, TType.STRING, 'computeResourceConsumed', 'UTF8', None, ), # 7
+ (8, TType.STRING, 'jobName', 'UTF8', None, ), # 8
+ (9, TType.STRING, 'workingDir', 'UTF8', None, ), # 9
+ (10, TType.STRING, 'stdOut', 'UTF8', None, ), # 10
+ (11, TType.STRING, 'stdErr', 'UTF8', None, ), # 11
+ (12, TType.I32, 'exitCode', None, None, ), # 12
+ )
+
+ def __init__(self, jobId=None, taskId=None, processId=None, jobDescription=None, creationTime=None, jobStatuses=None, computeResourceConsumed=None, jobName=None, workingDir=None, stdOut=None, stdErr=None, exitCode=None,):
+ self.jobId = jobId
+ self.taskId = taskId
+ self.processId = processId
+ self.jobDescription = jobDescription
+ self.creationTime = creationTime
+ self.jobStatuses = jobStatuses
+ self.computeResourceConsumed = computeResourceConsumed
+ self.jobName = jobName
+ self.workingDir = workingDir
+ self.stdOut = stdOut
+ self.stdErr = stdErr
+ self.exitCode = exitCode
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.jobId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.taskId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.processId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.jobDescription = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.I64:
+ self.creationTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.LIST:
+ self.jobStatuses = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in range(_size0):
+ _elem5 = apache.airavata.model.status.ttypes.JobStatus()
+ _elem5.read(iprot)
+ self.jobStatuses.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.STRING:
+ self.computeResourceConsumed = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.STRING:
+ self.jobName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.STRING:
+ self.workingDir = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.STRING:
+ self.stdOut = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 11:
+ if ftype == TType.STRING:
+ self.stdErr = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 12:
+ if ftype == TType.I32:
+ self.exitCode = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('JobModel')
+ if self.jobId is not None:
+ oprot.writeFieldBegin('jobId', TType.STRING, 1)
+ oprot.writeString(self.jobId.encode('utf-8') if sys.version_info[0] == 2 else self.jobId)
+ oprot.writeFieldEnd()
+ if self.taskId is not None:
+ oprot.writeFieldBegin('taskId', TType.STRING, 2)
+ oprot.writeString(self.taskId.encode('utf-8') if sys.version_info[0] == 2 else self.taskId)
+ oprot.writeFieldEnd()
+ if self.processId is not None:
+ oprot.writeFieldBegin('processId', TType.STRING, 3)
+ oprot.writeString(self.processId.encode('utf-8') if sys.version_info[0] == 2 else self.processId)
+ oprot.writeFieldEnd()
+ if self.jobDescription is not None:
+ oprot.writeFieldBegin('jobDescription', TType.STRING, 4)
+ oprot.writeString(self.jobDescription.encode('utf-8') if sys.version_info[0] == 2 else self.jobDescription)
+ oprot.writeFieldEnd()
+ if self.creationTime is not None:
+ oprot.writeFieldBegin('creationTime', TType.I64, 5)
+ oprot.writeI64(self.creationTime)
+ oprot.writeFieldEnd()
+ if self.jobStatuses is not None:
+ oprot.writeFieldBegin('jobStatuses', TType.LIST, 6)
+ oprot.writeListBegin(TType.STRUCT, len(self.jobStatuses))
+ for iter6 in self.jobStatuses:
+ iter6.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.computeResourceConsumed is not None:
+ oprot.writeFieldBegin('computeResourceConsumed', TType.STRING, 7)
+ oprot.writeString(self.computeResourceConsumed.encode('utf-8') if sys.version_info[0] == 2 else self.computeResourceConsumed)
+ oprot.writeFieldEnd()
+ if self.jobName is not None:
+ oprot.writeFieldBegin('jobName', TType.STRING, 8)
+ oprot.writeString(self.jobName.encode('utf-8') if sys.version_info[0] == 2 else self.jobName)
+ oprot.writeFieldEnd()
+ if self.workingDir is not None:
+ oprot.writeFieldBegin('workingDir', TType.STRING, 9)
+ oprot.writeString(self.workingDir.encode('utf-8') if sys.version_info[0] == 2 else self.workingDir)
+ oprot.writeFieldEnd()
+ if self.stdOut is not None:
+ oprot.writeFieldBegin('stdOut', TType.STRING, 10)
+ oprot.writeString(self.stdOut.encode('utf-8') if sys.version_info[0] == 2 else self.stdOut)
+ oprot.writeFieldEnd()
+ if self.stdErr is not None:
+ oprot.writeFieldBegin('stdErr', TType.STRING, 11)
+ oprot.writeString(self.stdErr.encode('utf-8') if sys.version_info[0] == 2 else self.stdErr)
+ oprot.writeFieldEnd()
+ if self.exitCode is not None:
+ oprot.writeFieldBegin('exitCode', TType.I32, 12)
+ oprot.writeI32(self.exitCode)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.jobId is None:
+ raise TProtocolException(message='Required field jobId is unset!')
+ if self.taskId is None:
+ raise TProtocolException(message='Required field taskId is unset!')
+ if self.processId is None:
+ raise TProtocolException(message='Required field processId is unset!')
+ if self.jobDescription is None:
+ raise TProtocolException(message='Required field jobDescription is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/messaging/event/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/messaging/event/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/messaging/event/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/messaging/event/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/messaging/event/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
[33/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/sharing/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/sharing/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/sharing/ttypes.py
index 81f5788..c1d6071 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/sharing/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/sharing/ttypes.py
@@ -1,1722 +1,1612 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class GroupCardinality:
- """
- <p>This is an system internal enum used to define single user groups and multi users groups. Every user is also
- considered as a group in it's own right for implementation ease</p>
-
- """
- SINGLE_USER = 0
- MULTI_USER = 1
-
- _VALUES_TO_NAMES = {
- 0: "SINGLE_USER",
- 1: "MULTI_USER",
- }
-
- _NAMES_TO_VALUES = {
- "SINGLE_USER": 0,
- "MULTI_USER": 1,
- }
-
-class GroupType:
- """
- <p>Group types can be either user level or domain level groups.</p>
-
- """
- DOMAIN_LEVEL_GROUP = 0
- USER_LEVEL_GROUP = 1
-
- _VALUES_TO_NAMES = {
- 0: "DOMAIN_LEVEL_GROUP",
- 1: "USER_LEVEL_GROUP",
- }
-
- _NAMES_TO_VALUES = {
- "DOMAIN_LEVEL_GROUP": 0,
- "USER_LEVEL_GROUP": 1,
- }
-
-class GroupChildType:
- """
- <p>System internal data type to match group child types</p>
-
- """
- USER = 0
- GROUP = 1
-
- _VALUES_TO_NAMES = {
- 0: "USER",
- 1: "GROUP",
- }
-
- _NAMES_TO_VALUES = {
- "USER": 0,
- "GROUP": 1,
- }
-
-class EntitySearchField:
- """
- <p>This list of fields that can be used to search entities</p>
- <li>NAME : Name of the entity</li>
- <li>DESCRIPTION : Description of the entity</li>
- <li>FULL_TEXT : Full text field of the entity</li>
- <li>PARENT_ENTITY_ID : Parent entity id of the entity</li>
- <li>OWNER_ID : Owner of the entity</li>
- <li>CREATED_TIME : Created time of the entity</li>
- <li>UPDATED_TIME : Updated time of the entity</li>
- <li>SHARED_COUNT : Number of directly shared users and groups</li>
-
- """
- NAME = 0
- DESCRIPTION = 1
- FULL_TEXT = 2
- PARRENT_ENTITY_ID = 3
- OWNER_ID = 4
- PERMISSION_TYPE_ID = 5
- CREATED_TIME = 6
- UPDATED_TIME = 7
- ENTITY_TYPE_ID = 8
- SHARED_COUNT = 9
-
- _VALUES_TO_NAMES = {
- 0: "NAME",
- 1: "DESCRIPTION",
- 2: "FULL_TEXT",
- 3: "PARRENT_ENTITY_ID",
- 4: "OWNER_ID",
- 5: "PERMISSION_TYPE_ID",
- 6: "CREATED_TIME",
- 7: "UPDATED_TIME",
- 8: "ENTITY_TYPE_ID",
- 9: "SHARED_COUNT",
- }
-
- _NAMES_TO_VALUES = {
- "NAME": 0,
- "DESCRIPTION": 1,
- "FULL_TEXT": 2,
- "PARRENT_ENTITY_ID": 3,
- "OWNER_ID": 4,
- "PERMISSION_TYPE_ID": 5,
- "CREATED_TIME": 6,
- "UPDATED_TIME": 7,
- "ENTITY_TYPE_ID": 8,
- "SHARED_COUNT": 9,
- }
-
-class SearchCondition:
- """
- <p>Different search operators that can be used with the entity search fields</p>
- <li>EQUAL : Simply matches for equality. Applicable for name, and parent entity id</li>
- <li>LIKE : Check for the condition %$FIELD% condition. Applicable for name, and description</li>
- <li>FULL_TEXT : Does a full text search. Only applicable for the FULL_TEXT field.</li>
- <li>GTE : Greater than or equal. Only applicable for created time, updated time and shared count.</li>
- <li>LTE : Less than or equal. Only applicable for created time, updated time and shared count.</li>
-
- """
- EQUAL = 0
- LIKE = 1
- FULL_TEXT = 2
- GTE = 3
- LTE = 4
- NOT = 5
-
- _VALUES_TO_NAMES = {
- 0: "EQUAL",
- 1: "LIKE",
- 2: "FULL_TEXT",
- 3: "GTE",
- 4: "LTE",
- 5: "NOT",
- }
-
- _NAMES_TO_VALUES = {
- "EQUAL": 0,
- "LIKE": 1,
- "FULL_TEXT": 2,
- "GTE": 3,
- "LTE": 4,
- "NOT": 5,
- }
-
-class SharingType:
- """
- <p>This is an internal enum type for managing sharings</p>
-
- """
- DIRECT_NON_CASCADING = 0
- DIRECT_CASCADING = 1
- INDIRECT_CASCADING = 2
-
- _VALUES_TO_NAMES = {
- 0: "DIRECT_NON_CASCADING",
- 1: "DIRECT_CASCADING",
- 2: "INDIRECT_CASCADING",
- }
-
- _NAMES_TO_VALUES = {
- "DIRECT_NON_CASCADING": 0,
- "DIRECT_CASCADING": 1,
- "INDIRECT_CASCADING": 2,
- }
-
-
-class Domain:
- """
- <p>Domain is the entity that enables multi-tenency in this componenet. Every tenant will be
- operating separately it's own silo which is identified by the domain id. In the current implementation domain id
- will be same as the domain name</p>
- <li>domainId : Will be generated by the server based on the domain name</li>
- <li><b>name</b> : A single word name that identifies the domain e.g seagrid, ultrascan</li>
- <li>description : A short description for the domain</li>
- <li>createdTime : Will be set by the system</li>
- <li>updatedTime : Will be set by the system</li>
-
-
- Attributes:
- - domainId
- - name
- - description
- - createdTime
- - updatedTime
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'domainId', None, "DO_NOT_SET_AT_CLIENTS_ID", ), # 1
- (2, TType.STRING, 'name', None, None, ), # 2
- (3, TType.STRING, 'description', None, None, ), # 3
- (4, TType.I64, 'createdTime', None, None, ), # 4
- (5, TType.I64, 'updatedTime', None, None, ), # 5
- )
-
- def __init__(self, domainId=thrift_spec[1][4], name=None, description=None, createdTime=None, updatedTime=None,):
- self.domainId = domainId
- self.name = name
- self.description = description
- self.createdTime = createdTime
- self.updatedTime = updatedTime
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.domainId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.name = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.description = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.I64:
- self.createdTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I64:
- self.updatedTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('Domain')
- if self.domainId is not None:
- oprot.writeFieldBegin('domainId', TType.STRING, 1)
- oprot.writeString(self.domainId)
- oprot.writeFieldEnd()
- if self.name is not None:
- oprot.writeFieldBegin('name', TType.STRING, 2)
- oprot.writeString(self.name)
- oprot.writeFieldEnd()
- if self.description is not None:
- oprot.writeFieldBegin('description', TType.STRING, 3)
- oprot.writeString(self.description)
- oprot.writeFieldEnd()
- if self.createdTime is not None:
- oprot.writeFieldBegin('createdTime', TType.I64, 4)
- oprot.writeI64(self.createdTime)
- oprot.writeFieldEnd()
- if self.updatedTime is not None:
- oprot.writeFieldBegin('updatedTime', TType.I64, 5)
- oprot.writeI64(self.updatedTime)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.domainId)
- value = (value * 31) ^ hash(self.name)
- value = (value * 31) ^ hash(self.description)
- value = (value * 31) ^ hash(self.createdTime)
- value = (value * 31) ^ hash(self.updatedTime)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class User:
- """
- <p>User is the model used to register a user in the system. Minimal user information will be required to provide
- regarding the user.</p>
- <li><b>userId</b> : User id provided by the client</li>
- <li><b>domainId</b> : Domain id for that user</li>
- <li><b>userName</b> : User name for the user</li>
- <li><b>firstName</b> : First name of the user</li>
- <li><b>lastName</b> : Last name of the user</li>
- <li><b>email</b> : Email address of the user</li>
- <li>icon : A binary field for storing the user icon</li>
- <li>createdTime : If client provides this value then the system will use it if not the current time will be set</li>
- <li>updatedTime : If client provides this value then the system will use it if not the current time will be set</li>
-
-
- Attributes:
- - userId
- - domainId
- - userName
- - firstName
- - lastName
- - email
- - icon
- - createdTime
- - updatedTime
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'userId', None, None, ), # 1
- (2, TType.STRING, 'domainId', None, None, ), # 2
- (3, TType.STRING, 'userName', None, None, ), # 3
- (4, TType.STRING, 'firstName', None, None, ), # 4
- (5, TType.STRING, 'lastName', None, None, ), # 5
- (6, TType.STRING, 'email', None, None, ), # 6
- (7, TType.STRING, 'icon', None, None, ), # 7
- (8, TType.I64, 'createdTime', None, None, ), # 8
- (9, TType.I64, 'updatedTime', None, None, ), # 9
- )
-
- def __init__(self, userId=None, domainId=None, userName=None, firstName=None, lastName=None, email=None, icon=None, createdTime=None, updatedTime=None,):
- self.userId = userId
- self.domainId = domainId
- self.userName = userName
- self.firstName = firstName
- self.lastName = lastName
- self.email = email
- self.icon = icon
- self.createdTime = createdTime
- self.updatedTime = updatedTime
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.userId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.domainId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.userName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.firstName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.lastName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.email = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.STRING:
- self.icon = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.I64:
- self.createdTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.I64:
- self.updatedTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('User')
- if self.userId is not None:
- oprot.writeFieldBegin('userId', TType.STRING, 1)
- oprot.writeString(self.userId)
- oprot.writeFieldEnd()
- if self.domainId is not None:
- oprot.writeFieldBegin('domainId', TType.STRING, 2)
- oprot.writeString(self.domainId)
- oprot.writeFieldEnd()
- if self.userName is not None:
- oprot.writeFieldBegin('userName', TType.STRING, 3)
- oprot.writeString(self.userName)
- oprot.writeFieldEnd()
- if self.firstName is not None:
- oprot.writeFieldBegin('firstName', TType.STRING, 4)
- oprot.writeString(self.firstName)
- oprot.writeFieldEnd()
- if self.lastName is not None:
- oprot.writeFieldBegin('lastName', TType.STRING, 5)
- oprot.writeString(self.lastName)
- oprot.writeFieldEnd()
- if self.email is not None:
- oprot.writeFieldBegin('email', TType.STRING, 6)
- oprot.writeString(self.email)
- oprot.writeFieldEnd()
- if self.icon is not None:
- oprot.writeFieldBegin('icon', TType.STRING, 7)
- oprot.writeString(self.icon)
- oprot.writeFieldEnd()
- if self.createdTime is not None:
- oprot.writeFieldBegin('createdTime', TType.I64, 8)
- oprot.writeI64(self.createdTime)
- oprot.writeFieldEnd()
- if self.updatedTime is not None:
- oprot.writeFieldBegin('updatedTime', TType.I64, 9)
- oprot.writeI64(self.updatedTime)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.userId)
- value = (value * 31) ^ hash(self.domainId)
- value = (value * 31) ^ hash(self.userName)
- value = (value * 31) ^ hash(self.firstName)
- value = (value * 31) ^ hash(self.lastName)
- value = (value * 31) ^ hash(self.email)
- value = (value * 31) ^ hash(self.icon)
- value = (value * 31) ^ hash(self.createdTime)
- value = (value * 31) ^ hash(self.updatedTime)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class UserGroup:
- """
- <p>User group is a collection of users.</p>
- <li><b>groupId</b> : Group id provided by the client</li>
- <li><b>domainId</b> : Domain id for this user group</li>
- <li><b>name</b> : Name for the user group. should be one word</li>
- <li>description : Short description for the group.</li>
- <li><b>ownerId</b> : Owner id of this group.</li>
- <li><b>groupType</b> : Group type (DOMAIN_LEVEL_GROUP, USER_LEVEL_GROUP)</li>
- <li><b>groupCardinality</b> : Group cardinality (SINGLE_USER, MULTI_USER)</li>
- <li>createdTime : Will be set by the system</li>
- <li>updatedTime : Will be set by the system</li>
-
-
- Attributes:
- - groupId
- - domainId
- - name
- - description
- - ownerId
- - groupType
- - groupCardinality
- - createdTime
- - updatedTime
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'groupId', None, None, ), # 1
- (2, TType.STRING, 'domainId', None, None, ), # 2
- (3, TType.STRING, 'name', None, None, ), # 3
- (4, TType.STRING, 'description', None, None, ), # 4
- (5, TType.STRING, 'ownerId', None, None, ), # 5
- (6, TType.I32, 'groupType', None, None, ), # 6
- (7, TType.I32, 'groupCardinality', None, None, ), # 7
- (8, TType.I64, 'createdTime', None, None, ), # 8
- (9, TType.I64, 'updatedTime', None, None, ), # 9
- )
-
- def __init__(self, groupId=None, domainId=None, name=None, description=None, ownerId=None, groupType=None, groupCardinality=None, createdTime=None, updatedTime=None,):
- self.groupId = groupId
- self.domainId = domainId
- self.name = name
- self.description = description
- self.ownerId = ownerId
- self.groupType = groupType
- self.groupCardinality = groupCardinality
- self.createdTime = createdTime
- self.updatedTime = updatedTime
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.groupId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.domainId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.name = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.description = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.ownerId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.I32:
- self.groupType = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.I32:
- self.groupCardinality = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.I64:
- self.createdTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.I64:
- self.updatedTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('UserGroup')
- if self.groupId is not None:
- oprot.writeFieldBegin('groupId', TType.STRING, 1)
- oprot.writeString(self.groupId)
- oprot.writeFieldEnd()
- if self.domainId is not None:
- oprot.writeFieldBegin('domainId', TType.STRING, 2)
- oprot.writeString(self.domainId)
- oprot.writeFieldEnd()
- if self.name is not None:
- oprot.writeFieldBegin('name', TType.STRING, 3)
- oprot.writeString(self.name)
- oprot.writeFieldEnd()
- if self.description is not None:
- oprot.writeFieldBegin('description', TType.STRING, 4)
- oprot.writeString(self.description)
- oprot.writeFieldEnd()
- if self.ownerId is not None:
- oprot.writeFieldBegin('ownerId', TType.STRING, 5)
- oprot.writeString(self.ownerId)
- oprot.writeFieldEnd()
- if self.groupType is not None:
- oprot.writeFieldBegin('groupType', TType.I32, 6)
- oprot.writeI32(self.groupType)
- oprot.writeFieldEnd()
- if self.groupCardinality is not None:
- oprot.writeFieldBegin('groupCardinality', TType.I32, 7)
- oprot.writeI32(self.groupCardinality)
- oprot.writeFieldEnd()
- if self.createdTime is not None:
- oprot.writeFieldBegin('createdTime', TType.I64, 8)
- oprot.writeI64(self.createdTime)
- oprot.writeFieldEnd()
- if self.updatedTime is not None:
- oprot.writeFieldBegin('updatedTime', TType.I64, 9)
- oprot.writeI64(self.updatedTime)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.groupId)
- value = (value * 31) ^ hash(self.domainId)
- value = (value * 31) ^ hash(self.name)
- value = (value * 31) ^ hash(self.description)
- value = (value * 31) ^ hash(self.ownerId)
- value = (value * 31) ^ hash(self.groupType)
- value = (value * 31) ^ hash(self.groupCardinality)
- value = (value * 31) ^ hash(self.createdTime)
- value = (value * 31) ^ hash(self.updatedTime)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class GroupMembership:
- """
- <p>System internal data type to map group memberships</p>
-
-
- Attributes:
- - parentId
- - childId
- - domainId
- - childType
- - createdTime
- - updatedTime
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'parentId', None, None, ), # 1
- (2, TType.STRING, 'childId', None, None, ), # 2
- (3, TType.STRING, 'domainId', None, None, ), # 3
- (4, TType.I32, 'childType', None, None, ), # 4
- (5, TType.I64, 'createdTime', None, None, ), # 5
- (6, TType.I64, 'updatedTime', None, None, ), # 6
- )
-
- def __init__(self, parentId=None, childId=None, domainId=None, childType=None, createdTime=None, updatedTime=None,):
- self.parentId = parentId
- self.childId = childId
- self.domainId = domainId
- self.childType = childType
- self.createdTime = createdTime
- self.updatedTime = updatedTime
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.parentId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.childId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.domainId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.I32:
- self.childType = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I64:
- self.createdTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.I64:
- self.updatedTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('GroupMembership')
- if self.parentId is not None:
- oprot.writeFieldBegin('parentId', TType.STRING, 1)
- oprot.writeString(self.parentId)
- oprot.writeFieldEnd()
- if self.childId is not None:
- oprot.writeFieldBegin('childId', TType.STRING, 2)
- oprot.writeString(self.childId)
- oprot.writeFieldEnd()
- if self.domainId is not None:
- oprot.writeFieldBegin('domainId', TType.STRING, 3)
- oprot.writeString(self.domainId)
- oprot.writeFieldEnd()
- if self.childType is not None:
- oprot.writeFieldBegin('childType', TType.I32, 4)
- oprot.writeI32(self.childType)
- oprot.writeFieldEnd()
- if self.createdTime is not None:
- oprot.writeFieldBegin('createdTime', TType.I64, 5)
- oprot.writeI64(self.createdTime)
- oprot.writeFieldEnd()
- if self.updatedTime is not None:
- oprot.writeFieldBegin('updatedTime', TType.I64, 6)
- oprot.writeI64(self.updatedTime)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.parentId)
- value = (value * 31) ^ hash(self.childId)
- value = (value * 31) ^ hash(self.domainId)
- value = (value * 31) ^ hash(self.childType)
- value = (value * 31) ^ hash(self.createdTime)
- value = (value * 31) ^ hash(self.updatedTime)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class EntityType:
- """
- <p>client defined entity types</p>
- <li><b>entityTypeId</b> : Entity type id provided by the client</li>
- <li><b>domainId</b> : Domain id of the domain.</li>
- <li><b>name</b> : Name for the entity type. Should be a single word.</li>
- <li>description : Short description for the entity type.</li>
- <li>createdTime : Will be set by the system</li>
- <li>updatedTime : Will be set by the system</li>
-
-
- Attributes:
- - entityTypeId
- - domainId
- - name
- - description
- - createdTime
- - updatedTime
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'entityTypeId', None, None, ), # 1
- (2, TType.STRING, 'domainId', None, None, ), # 2
- (3, TType.STRING, 'name', None, None, ), # 3
- (4, TType.STRING, 'description', None, None, ), # 4
- (5, TType.I64, 'createdTime', None, None, ), # 5
- (6, TType.I64, 'updatedTime', None, None, ), # 6
- )
-
- def __init__(self, entityTypeId=None, domainId=None, name=None, description=None, createdTime=None, updatedTime=None,):
- self.entityTypeId = entityTypeId
- self.domainId = domainId
- self.name = name
- self.description = description
- self.createdTime = createdTime
- self.updatedTime = updatedTime
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.entityTypeId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.domainId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.name = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.description = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I64:
- self.createdTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.I64:
- self.updatedTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('EntityType')
- if self.entityTypeId is not None:
- oprot.writeFieldBegin('entityTypeId', TType.STRING, 1)
- oprot.writeString(self.entityTypeId)
- oprot.writeFieldEnd()
- if self.domainId is not None:
- oprot.writeFieldBegin('domainId', TType.STRING, 2)
- oprot.writeString(self.domainId)
- oprot.writeFieldEnd()
- if self.name is not None:
- oprot.writeFieldBegin('name', TType.STRING, 3)
- oprot.writeString(self.name)
- oprot.writeFieldEnd()
- if self.description is not None:
- oprot.writeFieldBegin('description', TType.STRING, 4)
- oprot.writeString(self.description)
- oprot.writeFieldEnd()
- if self.createdTime is not None:
- oprot.writeFieldBegin('createdTime', TType.I64, 5)
- oprot.writeI64(self.createdTime)
- oprot.writeFieldEnd()
- if self.updatedTime is not None:
- oprot.writeFieldBegin('updatedTime', TType.I64, 6)
- oprot.writeI64(self.updatedTime)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.entityTypeId)
- value = (value * 31) ^ hash(self.domainId)
- value = (value * 31) ^ hash(self.name)
- value = (value * 31) ^ hash(self.description)
- value = (value * 31) ^ hash(self.createdTime)
- value = (value * 31) ^ hash(self.updatedTime)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class SearchCriteria:
- """
- <p>Container object for search criteria</p>
- <li><b>searchField</b> : Entity search field</li>
- <li><b>value</b> : Search value</li>
- <li><b>searchCondition</b> : EQUAL, LIKE etc..</li>
-
-
- Attributes:
- - searchField
- - value
- - searchCondition
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'searchField', None, None, ), # 1
- (2, TType.STRING, 'value', None, None, ), # 2
- (3, TType.I32, 'searchCondition', None, None, ), # 3
- )
-
- def __init__(self, searchField=None, value=None, searchCondition=None,):
- self.searchField = searchField
- self.value = value
- self.searchCondition = searchCondition
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.searchField = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.value = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.I32:
- self.searchCondition = iprot.readI32()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('SearchCriteria')
- if self.searchField is not None:
- oprot.writeFieldBegin('searchField', TType.I32, 1)
- oprot.writeI32(self.searchField)
- oprot.writeFieldEnd()
- if self.value is not None:
- oprot.writeFieldBegin('value', TType.STRING, 2)
- oprot.writeString(self.value)
- oprot.writeFieldEnd()
- if self.searchCondition is not None:
- oprot.writeFieldBegin('searchCondition', TType.I32, 3)
- oprot.writeI32(self.searchCondition)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.searchField)
- value = (value * 31) ^ hash(self.value)
- value = (value * 31) ^ hash(self.searchCondition)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class Entity:
- """
- <p>Entity object which is used to register an entity in the system.</p>
- <li><b>entityId</b> : Entity id provided by the client</li>
- <li><b>domainId</b> : Domain id</li>
- <li><b>entityTypeId</b> : Entity type id</li>
- <li><b>ownerId</b> : Owner id</li>
- <li>parentEntityId : Parent entity id</li>
- <li><b>name</b> : Name</li>
- <li>description : Short description for the entity</li>
- <li>binaryData : Any information stored in binary format</li>
- <li>fullText : A string which will be considered for full text search</li>
- <li><b>originalEntityCreationTime</b> : When registering old records what is the original entity creation time. If not
- set will be default to current time</li>
- <li>createdTime : Will be set by the system</li>
- <li>updatedTime : Will be set by the system</li>
-
-
- Attributes:
- - entityId
- - domainId
- - entityTypeId
- - ownerId
- - parentEntityId
- - name
- - description
- - binaryData
- - fullText
- - sharedCount
- - originalEntityCreationTime
- - createdTime
- - updatedTime
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'entityId', None, None, ), # 1
- (2, TType.STRING, 'domainId', None, None, ), # 2
- (3, TType.STRING, 'entityTypeId', None, None, ), # 3
- (4, TType.STRING, 'ownerId', None, None, ), # 4
- (5, TType.STRING, 'parentEntityId', None, None, ), # 5
- (6, TType.STRING, 'name', None, None, ), # 6
- (7, TType.STRING, 'description', None, None, ), # 7
- (8, TType.STRING, 'binaryData', None, None, ), # 8
- (9, TType.STRING, 'fullText', None, None, ), # 9
- (10, TType.I64, 'sharedCount', None, 0, ), # 10
- (11, TType.I64, 'originalEntityCreationTime', None, None, ), # 11
- (12, TType.I64, 'createdTime', None, None, ), # 12
- (13, TType.I64, 'updatedTime', None, None, ), # 13
- )
-
- def __init__(self, entityId=None, domainId=None, entityTypeId=None, ownerId=None, parentEntityId=None, name=None, description=None, binaryData=None, fullText=None, sharedCount=thrift_spec[10][4], originalEntityCreationTime=None, createdTime=None, updatedTime=None,):
- self.entityId = entityId
- self.domainId = domainId
- self.entityTypeId = entityTypeId
- self.ownerId = ownerId
- self.parentEntityId = parentEntityId
- self.name = name
- self.description = description
- self.binaryData = binaryData
- self.fullText = fullText
- self.sharedCount = sharedCount
- self.originalEntityCreationTime = originalEntityCreationTime
- self.createdTime = createdTime
- self.updatedTime = updatedTime
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.entityId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.domainId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.entityTypeId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.ownerId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.parentEntityId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.name = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.STRING:
- self.description = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.STRING:
- self.binaryData = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.STRING:
- self.fullText = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.I64:
- self.sharedCount = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 11:
- if ftype == TType.I64:
- self.originalEntityCreationTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 12:
- if ftype == TType.I64:
- self.createdTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 13:
- if ftype == TType.I64:
- self.updatedTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('Entity')
- if self.entityId is not None:
- oprot.writeFieldBegin('entityId', TType.STRING, 1)
- oprot.writeString(self.entityId)
- oprot.writeFieldEnd()
- if self.domainId is not None:
- oprot.writeFieldBegin('domainId', TType.STRING, 2)
- oprot.writeString(self.domainId)
- oprot.writeFieldEnd()
- if self.entityTypeId is not None:
- oprot.writeFieldBegin('entityTypeId', TType.STRING, 3)
- oprot.writeString(self.entityTypeId)
- oprot.writeFieldEnd()
- if self.ownerId is not None:
- oprot.writeFieldBegin('ownerId', TType.STRING, 4)
- oprot.writeString(self.ownerId)
- oprot.writeFieldEnd()
- if self.parentEntityId is not None:
- oprot.writeFieldBegin('parentEntityId', TType.STRING, 5)
- oprot.writeString(self.parentEntityId)
- oprot.writeFieldEnd()
- if self.name is not None:
- oprot.writeFieldBegin('name', TType.STRING, 6)
- oprot.writeString(self.name)
- oprot.writeFieldEnd()
- if self.description is not None:
- oprot.writeFieldBegin('description', TType.STRING, 7)
- oprot.writeString(self.description)
- oprot.writeFieldEnd()
- if self.binaryData is not None:
- oprot.writeFieldBegin('binaryData', TType.STRING, 8)
- oprot.writeString(self.binaryData)
- oprot.writeFieldEnd()
- if self.fullText is not None:
- oprot.writeFieldBegin('fullText', TType.STRING, 9)
- oprot.writeString(self.fullText)
- oprot.writeFieldEnd()
- if self.sharedCount is not None:
- oprot.writeFieldBegin('sharedCount', TType.I64, 10)
- oprot.writeI64(self.sharedCount)
- oprot.writeFieldEnd()
- if self.originalEntityCreationTime is not None:
- oprot.writeFieldBegin('originalEntityCreationTime', TType.I64, 11)
- oprot.writeI64(self.originalEntityCreationTime)
- oprot.writeFieldEnd()
- if self.createdTime is not None:
- oprot.writeFieldBegin('createdTime', TType.I64, 12)
- oprot.writeI64(self.createdTime)
- oprot.writeFieldEnd()
- if self.updatedTime is not None:
- oprot.writeFieldBegin('updatedTime', TType.I64, 13)
- oprot.writeI64(self.updatedTime)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.entityId)
- value = (value * 31) ^ hash(self.domainId)
- value = (value * 31) ^ hash(self.entityTypeId)
- value = (value * 31) ^ hash(self.ownerId)
- value = (value * 31) ^ hash(self.parentEntityId)
- value = (value * 31) ^ hash(self.name)
- value = (value * 31) ^ hash(self.description)
- value = (value * 31) ^ hash(self.binaryData)
- value = (value * 31) ^ hash(self.fullText)
- value = (value * 31) ^ hash(self.sharedCount)
- value = (value * 31) ^ hash(self.originalEntityCreationTime)
- value = (value * 31) ^ hash(self.createdTime)
- value = (value * 31) ^ hash(self.updatedTime)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class PermissionType:
- """
- <p>Object for creating client defined permission type</p>
- <li><b>permissionTypeId</b> : Permission type id provided by the client</li>
- <li><b>domainId</b> : Domain id</li>
- <li><b>name</b> : Single word name for the permission</li>
- <li>description : Short description for the permission type</li>
- <li>createdTime : Will be set by the system</li>
- <li>updatedTime : Will be set by the system</li>
-
-
- Attributes:
- - permissionTypeId
- - domainId
- - name
- - description
- - createdTime
- - updatedTime
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'permissionTypeId', None, None, ), # 1
- (2, TType.STRING, 'domainId', None, None, ), # 2
- (3, TType.STRING, 'name', None, None, ), # 3
- (4, TType.STRING, 'description', None, None, ), # 4
- (5, TType.I64, 'createdTime', None, None, ), # 5
- (6, TType.I64, 'updatedTime', None, None, ), # 6
- )
-
- def __init__(self, permissionTypeId=None, domainId=None, name=None, description=None, createdTime=None, updatedTime=None,):
- self.permissionTypeId = permissionTypeId
- self.domainId = domainId
- self.name = name
- self.description = description
- self.createdTime = createdTime
- self.updatedTime = updatedTime
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.permissionTypeId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.domainId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.name = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.description = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I64:
- self.createdTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.I64:
- self.updatedTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('PermissionType')
- if self.permissionTypeId is not None:
- oprot.writeFieldBegin('permissionTypeId', TType.STRING, 1)
- oprot.writeString(self.permissionTypeId)
- oprot.writeFieldEnd()
- if self.domainId is not None:
- oprot.writeFieldBegin('domainId', TType.STRING, 2)
- oprot.writeString(self.domainId)
- oprot.writeFieldEnd()
- if self.name is not None:
- oprot.writeFieldBegin('name', TType.STRING, 3)
- oprot.writeString(self.name)
- oprot.writeFieldEnd()
- if self.description is not None:
- oprot.writeFieldBegin('description', TType.STRING, 4)
- oprot.writeString(self.description)
- oprot.writeFieldEnd()
- if self.createdTime is not None:
- oprot.writeFieldBegin('createdTime', TType.I64, 5)
- oprot.writeI64(self.createdTime)
- oprot.writeFieldEnd()
- if self.updatedTime is not None:
- oprot.writeFieldBegin('updatedTime', TType.I64, 6)
- oprot.writeI64(self.updatedTime)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.permissionTypeId)
- value = (value * 31) ^ hash(self.domainId)
- value = (value * 31) ^ hash(self.name)
- value = (value * 31) ^ hash(self.description)
- value = (value * 31) ^ hash(self.createdTime)
- value = (value * 31) ^ hash(self.updatedTime)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class Sharing:
- """
- <p>This is an internal enum type for managing sharings</p>
-
-
- Attributes:
- - permissionTypeId
- - entityId
- - groupId
- - sharingType
- - domainId
- - inheritedParentId
- - createdTime
- - updatedTime
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'permissionTypeId', None, None, ), # 1
- (2, TType.STRING, 'entityId', None, None, ), # 2
- (3, TType.STRING, 'groupId', None, None, ), # 3
- (4, TType.I32, 'sharingType', None, None, ), # 4
- (5, TType.STRING, 'domainId', None, None, ), # 5
- (6, TType.STRING, 'inheritedParentId', None, None, ), # 6
- (7, TType.I64, 'createdTime', None, None, ), # 7
- (8, TType.I64, 'updatedTime', None, None, ), # 8
- )
-
- def __init__(self, permissionTypeId=None, entityId=None, groupId=None, sharingType=None, domainId=None, inheritedParentId=None, createdTime=None, updatedTime=None,):
- self.permissionTypeId = permissionTypeId
- self.entityId = entityId
- self.groupId = groupId
- self.sharingType = sharingType
- self.domainId = domainId
- self.inheritedParentId = inheritedParentId
- self.createdTime = createdTime
- self.updatedTime = updatedTime
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.permissionTypeId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.entityId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.groupId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.I32:
- self.sharingType = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.STRING:
- self.domainId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.inheritedParentId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.I64:
- self.createdTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.I64:
- self.updatedTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('Sharing')
- if self.permissionTypeId is not None:
- oprot.writeFieldBegin('permissionTypeId', TType.STRING, 1)
- oprot.writeString(self.permissionTypeId)
- oprot.writeFieldEnd()
- if self.entityId is not None:
- oprot.writeFieldBegin('entityId', TType.STRING, 2)
- oprot.writeString(self.entityId)
- oprot.writeFieldEnd()
- if self.groupId is not None:
- oprot.writeFieldBegin('groupId', TType.STRING, 3)
- oprot.writeString(self.groupId)
- oprot.writeFieldEnd()
- if self.sharingType is not None:
- oprot.writeFieldBegin('sharingType', TType.I32, 4)
- oprot.writeI32(self.sharingType)
- oprot.writeFieldEnd()
- if self.domainId is not None:
- oprot.writeFieldBegin('domainId', TType.STRING, 5)
- oprot.writeString(self.domainId)
- oprot.writeFieldEnd()
- if self.inheritedParentId is not None:
- oprot.writeFieldBegin('inheritedParentId', TType.STRING, 6)
- oprot.writeString(self.inheritedParentId)
- oprot.writeFieldEnd()
- if self.createdTime is not None:
- oprot.writeFieldBegin('createdTime', TType.I64, 7)
- oprot.writeI64(self.createdTime)
- oprot.writeFieldEnd()
- if self.updatedTime is not None:
- oprot.writeFieldBegin('updatedTime', TType.I64, 8)
- oprot.writeI64(self.updatedTime)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.permissionTypeId)
- value = (value * 31) ^ hash(self.entityId)
- value = (value * 31) ^ hash(self.groupId)
- value = (value * 31) ^ hash(self.sharingType)
- value = (value * 31) ^ hash(self.domainId)
- value = (value * 31) ^ hash(self.inheritedParentId)
- value = (value * 31) ^ hash(self.createdTime)
- value = (value * 31) ^ hash(self.updatedTime)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class GroupCardinality(object):
+ """
+ <p>This is an system internal enum used to define single user groups and multi users groups. Every user is also
+ considered as a group in it's own right for implementation ease</p>
+
+ """
+ SINGLE_USER = 0
+ MULTI_USER = 1
+
+ _VALUES_TO_NAMES = {
+ 0: "SINGLE_USER",
+ 1: "MULTI_USER",
+ }
+
+ _NAMES_TO_VALUES = {
+ "SINGLE_USER": 0,
+ "MULTI_USER": 1,
+ }
+
+
+class GroupType(object):
+ """
+ <p>Group types can be either user level or domain level groups.</p>
+
+ """
+ DOMAIN_LEVEL_GROUP = 0
+ USER_LEVEL_GROUP = 1
+
+ _VALUES_TO_NAMES = {
+ 0: "DOMAIN_LEVEL_GROUP",
+ 1: "USER_LEVEL_GROUP",
+ }
+
+ _NAMES_TO_VALUES = {
+ "DOMAIN_LEVEL_GROUP": 0,
+ "USER_LEVEL_GROUP": 1,
+ }
+
+
+class GroupChildType(object):
+ """
+ <p>System internal data type to match group child types</p>
+
+ """
+ USER = 0
+ GROUP = 1
+
+ _VALUES_TO_NAMES = {
+ 0: "USER",
+ 1: "GROUP",
+ }
+
+ _NAMES_TO_VALUES = {
+ "USER": 0,
+ "GROUP": 1,
+ }
+
+
+class EntitySearchField(object):
+ """
+ <p>This list of fields that can be used to search entities</p>
+ <li>NAME : Name of the entity</li>
+ <li>DESCRIPTION : Description of the entity</li>
+ <li>FULL_TEXT : Full text field of the entity</li>
+ <li>PARENT_ENTITY_ID : Parent entity id of the entity</li>
+ <li>OWNER_ID : Owner of the entity</li>
+ <li>CREATED_TIME : Created time of the entity</li>
+ <li>UPDATED_TIME : Updated time of the entity</li>
+ <li>SHARED_COUNT : Number of directly shared users and groups</li>
+
+ """
+ NAME = 0
+ DESCRIPTION = 1
+ FULL_TEXT = 2
+ PARRENT_ENTITY_ID = 3
+ OWNER_ID = 4
+ PERMISSION_TYPE_ID = 5
+ CREATED_TIME = 6
+ UPDATED_TIME = 7
+ ENTITY_TYPE_ID = 8
+ SHARED_COUNT = 9
+
+ _VALUES_TO_NAMES = {
+ 0: "NAME",
+ 1: "DESCRIPTION",
+ 2: "FULL_TEXT",
+ 3: "PARRENT_ENTITY_ID",
+ 4: "OWNER_ID",
+ 5: "PERMISSION_TYPE_ID",
+ 6: "CREATED_TIME",
+ 7: "UPDATED_TIME",
+ 8: "ENTITY_TYPE_ID",
+ 9: "SHARED_COUNT",
+ }
+
+ _NAMES_TO_VALUES = {
+ "NAME": 0,
+ "DESCRIPTION": 1,
+ "FULL_TEXT": 2,
+ "PARRENT_ENTITY_ID": 3,
+ "OWNER_ID": 4,
+ "PERMISSION_TYPE_ID": 5,
+ "CREATED_TIME": 6,
+ "UPDATED_TIME": 7,
+ "ENTITY_TYPE_ID": 8,
+ "SHARED_COUNT": 9,
+ }
+
+
+class SearchCondition(object):
+ """
+ <p>Different search operators that can be used with the entity search fields</p>
+ <li>EQUAL : Simply matches for equality. Applicable for name, and parent entity id</li>
+ <li>LIKE : Check for the condition %$FIELD% condition. Applicable for name, and description</li>
+ <li>FULL_TEXT : Does a full text search. Only applicable for the FULL_TEXT field.</li>
+ <li>GTE : Greater than or equal. Only applicable for created time, updated time and shared count.</li>
+ <li>LTE : Less than or equal. Only applicable for created time, updated time and shared count.</li>
+
+ """
+ EQUAL = 0
+ LIKE = 1
+ FULL_TEXT = 2
+ GTE = 3
+ LTE = 4
+ NOT = 5
+
+ _VALUES_TO_NAMES = {
+ 0: "EQUAL",
+ 1: "LIKE",
+ 2: "FULL_TEXT",
+ 3: "GTE",
+ 4: "LTE",
+ 5: "NOT",
+ }
+
+ _NAMES_TO_VALUES = {
+ "EQUAL": 0,
+ "LIKE": 1,
+ "FULL_TEXT": 2,
+ "GTE": 3,
+ "LTE": 4,
+ "NOT": 5,
+ }
+
+
+class SharingType(object):
+ """
+ <p>This is an internal enum type for managing sharings</p>
+
+ """
+ DIRECT_NON_CASCADING = 0
+ DIRECT_CASCADING = 1
+ INDIRECT_CASCADING = 2
+
+ _VALUES_TO_NAMES = {
+ 0: "DIRECT_NON_CASCADING",
+ 1: "DIRECT_CASCADING",
+ 2: "INDIRECT_CASCADING",
+ }
+
+ _NAMES_TO_VALUES = {
+ "DIRECT_NON_CASCADING": 0,
+ "DIRECT_CASCADING": 1,
+ "INDIRECT_CASCADING": 2,
+ }
+
+
+class Domain(object):
+ """
+ <p>Domain is the entity that enables multi-tenency in this componenet. Every tenant will be
+ operating separately it's own silo which is identified by the domain id. In the current implementation domain id
+ will be same as the domain name</p>
+ <li>domainId : Will be generated by the server based on the domain name</li>
+ <li><b>name</b> : A single word name that identifies the domain e.g seagrid, ultrascan</li>
+ <li>description : A short description for the domain</li>
+ <li>createdTime : Will be set by the system</li>
+ <li>updatedTime : Will be set by the system</li>
+
+
+ Attributes:
+ - domainId
+ - name
+ - description
+ - createdTime
+ - updatedTime
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'domainId', 'UTF8', "DO_NOT_SET_AT_CLIENTS_ID", ), # 1
+ (2, TType.STRING, 'name', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'description', 'UTF8', None, ), # 3
+ (4, TType.I64, 'createdTime', None, None, ), # 4
+ (5, TType.I64, 'updatedTime', None, None, ), # 5
+ )
+
+ def __init__(self, domainId=thrift_spec[1][4], name=None, description=None, createdTime=None, updatedTime=None,):
+ self.domainId = domainId
+ self.name = name
+ self.description = description
+ self.createdTime = createdTime
+ self.updatedTime = updatedTime
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.domainId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.name = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.description = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.I64:
+ self.createdTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.I64:
+ self.updatedTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('Domain')
+ if self.domainId is not None:
+ oprot.writeFieldBegin('domainId', TType.STRING, 1)
+ oprot.writeString(self.domainId.encode('utf-8') if sys.version_info[0] == 2 else self.domainId)
+ oprot.writeFieldEnd()
+ if self.name is not None:
+ oprot.writeFieldBegin('name', TType.STRING, 2)
+ oprot.writeString(self.name.encode('utf-8') if sys.version_info[0] == 2 else self.name)
+ oprot.writeFieldEnd()
+ if self.description is not None:
+ oprot.writeFieldBegin('description', TType.STRING, 3)
+ oprot.writeString(self.description.encode('utf-8') if sys.version_info[0] == 2 else self.description)
+ oprot.writeFieldEnd()
+ if self.createdTime is not None:
+ oprot.writeFieldBegin('createdTime', TType.I64, 4)
+ oprot.writeI64(self.createdTime)
+ oprot.writeFieldEnd()
+ if self.updatedTime is not None:
+ oprot.writeFieldBegin('updatedTime', TType.I64, 5)
+ oprot.writeI64(self.updatedTime)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class User(object):
+ """
+ <p>User is the model used to register a user in the system. Minimal user information will be required to provide
+ regarding the user.</p>
+ <li><b>userId</b> : User id provided by the client</li>
+ <li><b>domainId</b> : Domain id for that user</li>
+ <li><b>userName</b> : User name for the user</li>
+ <li><b>firstName</b> : First name of the user</li>
+ <li><b>lastName</b> : Last name of the user</li>
+ <li><b>email</b> : Email address of the user</li>
+ <li>icon : A binary field for storing the user icon</li>
+ <li>createdTime : If client provides this value then the system will use it if not the current time will be set</li>
+ <li>updatedTime : If client provides this value then the system will use it if not the current time will be set</li>
+
+
+ Attributes:
+ - userId
+ - domainId
+ - userName
+ - firstName
+ - lastName
+ - email
+ - icon
+ - createdTime
+ - updatedTime
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'userId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'domainId', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'userName', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'firstName', 'UTF8', None, ), # 4
+ (5, TType.STRING, 'lastName', 'UTF8', None, ), # 5
+ (6, TType.STRING, 'email', 'UTF8', None, ), # 6
+ (7, TType.STRING, 'icon', 'BINARY', None, ), # 7
+ (8, TType.I64, 'createdTime', None, None, ), # 8
+ (9, TType.I64, 'updatedTime', None, None, ), # 9
+ )
+
+ def __init__(self, userId=None, domainId=None, userName=None, firstName=None, lastName=None, email=None, icon=None, createdTime=None, updatedTime=None,):
+ self.userId = userId
+ self.domainId = domainId
+ self.userName = userName
+ self.firstName = firstName
+ self.lastName = lastName
+ self.email = email
+ self.icon = icon
+ self.createdTime = createdTime
+ self.updatedTime = updatedTime
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.userId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.domainId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.userName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.firstName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRING:
+ self.lastName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.email = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.STRING:
+ self.icon = iprot.readBinary()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.I64:
+ self.createdTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.I64:
+ self.updatedTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('User')
+ if self.userId is not None:
+ oprot.writeFieldBegin('userId', TType.STRING, 1)
+ oprot.writeString(self.userId.encode('utf-8') if sys.version_info[0] == 2 else self.userId)
+ oprot.writeFieldEnd()
+ if self.domainId is not None:
+ oprot.writeFieldBegin('domainId', TType.STRING, 2)
+ oprot.writeString(self.domainId.encode('utf-8') if sys.version_info[0] == 2 else self.domainId)
+ oprot.writeFieldEnd()
+ if self.userName is not None:
+ oprot.writeFieldBegin('userName', TType.STRING, 3)
+ oprot.writeString(self.userName.encode('utf-8') if sys.version_info[0] == 2 else self.userName)
+ oprot.writeFieldEnd()
+ if self.firstName is not None:
+ oprot.writeFieldBegin('firstName', TType.STRING, 4)
+ oprot.writeString(self.firstName.encode('utf-8') if sys.version_info[0] == 2 else self.firstName)
+ oprot.writeFieldEnd()
+ if self.lastName is not None:
+ oprot.writeFieldBegin('lastName', TType.STRING, 5)
+ oprot.writeString(self.lastName.encode('utf-8') if sys.version_info[0] == 2 else self.lastName)
+ oprot.writeFieldEnd()
+ if self.email is not None:
+ oprot.writeFieldBegin('email', TType.STRING, 6)
+ oprot.writeString(self.email.encode('utf-8') if sys.version_info[0] == 2 else self.email)
+ oprot.writeFieldEnd()
+ if self.icon is not None:
+ oprot.writeFieldBegin('icon', TType.STRING, 7)
+ oprot.writeBinary(self.icon)
+ oprot.writeFieldEnd()
+ if self.createdTime is not None:
+ oprot.writeFieldBegin('createdTime', TType.I64, 8)
+ oprot.writeI64(self.createdTime)
+ oprot.writeFieldEnd()
+ if self.updatedTime is not None:
+ oprot.writeFieldBegin('updatedTime', TType.I64, 9)
+ oprot.writeI64(self.updatedTime)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class UserGroup(object):
+ """
+ <p>User group is a collection of users.</p>
+ <li><b>groupId</b> : Group id provided by the client</li>
+ <li><b>domainId</b> : Domain id for this user group</li>
+ <li><b>name</b> : Name for the user group. should be one word</li>
+ <li>description : Short description for the group.</li>
+ <li><b>ownerId</b> : Owner id of this group.</li>
+ <li><b>groupType</b> : Group type (DOMAIN_LEVEL_GROUP, USER_LEVEL_GROUP)</li>
+ <li><b>groupCardinality</b> : Group cardinality (SINGLE_USER, MULTI_USER)</li>
+ <li>createdTime : Will be set by the system</li>
+ <li>updatedTime : Will be set by the system</li>
+
+
+ Attributes:
+ - groupId
+ - domainId
+ - name
+ - description
+ - ownerId
+ - groupType
+ - groupCardinality
+ - createdTime
+ - updatedTime
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'groupId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'domainId', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'name', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'description', 'UTF8', None, ), # 4
+ (5, TType.STRING, 'ownerId', 'UTF8', None, ), # 5
+ (6, TType.I32, 'groupType', None, None, ), # 6
+ (7, TType.I32, 'groupCardinality', None, None, ), # 7
+ (8, TType.I64, 'createdTime', None, None, ), # 8
+ (9, TType.I64, 'updatedTime', None, None, ), # 9
+ )
+
+ def __init__(self, groupId=None, domainId=None, name=None, description=None, ownerId=None, groupType=None, groupCardinality=None, createdTime=None, updatedTime=None,):
+ self.groupId = groupId
+ self.domainId = domainId
+ self.name = name
+ self.description = description
+ self.ownerId = ownerId
+ self.groupType = groupType
+ self.groupCardinality = groupCardinality
+ self.createdTime = createdTime
+ self.updatedTime = updatedTime
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.groupId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.domainId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.name = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.description = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.STRING:
+ self.ownerId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.I32:
+ self.groupType = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.I32:
+ self.groupCardinality = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.I64:
+ self.createdTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.I64:
+ self.updatedTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('UserGroup')
+ if self.groupId is not None:
+ oprot.writeFieldBegin('groupId', TType.STRING, 1)
+ oprot.writeString(self.groupId.encode('utf-8') if sys.version_info[0] == 2 else self.groupId)
+ oprot.writeFieldEnd()
+ if self.domainId is not None:
+ oprot.writeFieldBegin('domainId', TType.STRING, 2)
+ oprot.writeString(self.domainId.encode('utf-8') if sys.version_info[0] == 2 else self.domainId)
+ oprot.writeFieldEnd()
+ if self.name is not None:
+ oprot.writeFieldBegin('name', TType.STRING, 3)
+ oprot.writeString(self.name.encode('utf-8') if sys.version_info[0] == 2 else self.name)
+ oprot.writeFieldEnd()
+ if self.description is not None:
+ oprot.writeFieldBegin('description', TType.STRING, 4)
+ oprot.writeString(self.description.encode('utf-8') if sys.version_info[0] == 2 else self.description)
+ oprot.writeFieldEnd()
+ if self.ownerId is not None:
+ oprot.writeFieldBegin('ownerId', TType.STRING, 5)
+ oprot.writeString(self.ownerId.encode('utf-8') if sys.version_info[0] == 2 else self.ownerId)
+ oprot.writeFieldEnd()
+ if self.groupType is not None:
+ oprot.writeFieldBegin('groupType', TType.I32, 6)
+ oprot.writeI32(self.groupType)
+ oprot.writeFieldEnd()
+ if self.groupCardinality is not None:
+ oprot.writeFieldBegin('groupCardinality', TType.I32, 7)
+ oprot.writeI32(self.groupCardinality)
+ oprot.writeFieldEnd()
+ if self.createdTime is not None:
+ oprot.writeFieldBegin('createdTime', TType.I64, 8)
+ oprot.writeI64(self.createdTime)
+ oprot.writeFieldEnd()
+ if self.updatedTime is not None:
+ oprot.writeFieldBegin('updatedTime', TType.I64, 9)
+ oprot.writeI64(self.updatedTime)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class GroupMembership(object):
+ """
+ <p>System internal data type to map group memberships</p>
+
+
+ Attributes:
+ - parentId
+ - childId
+ - domainId
+ - childType
+ - createdTime
+ - updatedTime
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'parentId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'childId', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'domainId', 'UTF8', None, ), # 3
+ (4, TType.I32, 'childType', None, None, ), # 4
+ (5, TType.I64, 'createdTime', None, None, ), # 5
+ (6, TType.I64, 'updatedTime', None, None, ), # 6
+ )
+
+ def __init__(self, parentId=None, childId=None, domainId=None, childType=None, createdTime=None, updatedTime=None,):
+ self.parentId = parentId
+ self.childId = childId
+ self.domainId = domainId
+ self.childType = childType
+ self.createdTime = createdTime
+ self.updatedTime = updatedTime
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.parentId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.childId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.domainId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.I32:
+ self.childType = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.I64:
+ self.createdTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.I64:
+ self.updatedTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('GroupMembership')
+ if self.parentId is not None:
+ oprot.writeFieldBegin('parentId', TType.STRING, 1)
+ oprot.writeString(self.parentId.encode('utf-8') if sys.version_info[0] == 2 else self.parentId)
+ oprot.writeFieldEnd()
+ if self.childId is not None:
+ oprot.writeFieldBegin('childId', TType.STRING, 2)
+ oprot.writeString(self.childId.encode('utf-8') if sys.version_info[0] == 2 else self.childId)
+ oprot.writeFieldEnd()
+ if self.domainId is not None:
+ oprot.writeFieldBegin('domainId', TType.STRING, 3)
+ oprot.writeString(self.domainId.encode('utf-8') if sys.version_info[0] == 2 else self.domainId)
+ oprot.writeFieldEnd()
+ if self.childType is not None:
+ oprot.writeFieldBegin('childType', TType.I32, 4)
+ oprot.writeI32(self.childType)
+ oprot.writeFieldEnd()
+ if self.createdTime is not None:
+ oprot.writeFieldBegin('createdTime', TType.I64, 5)
+ oprot.writeI64(self.createdTime)
+ oprot.writeFieldEnd()
+ if self.updatedTime is not None:
+ oprot.writeFieldBegin('updatedTime', TType.I64, 6)
+ oprot.writeI64(self.updatedTime)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class EntityType(object):
+ """
+ <p>client defined entity types</p>
+ <li><b>entityTypeId</b> : Entity type id provided by the client</li>
+ <li><b>domainId</b> : Domain id of the domain.</li>
+ <li><b>name</b> : Name for the entity type. Should be a single word.</li>
+ <li>description : Short description for the entity type.</li>
+ <li>createdTime : Will be set by the system</li>
+ <li>updatedTime : Will be set by the system</li>
+
+
+ Attributes:
+ - entityTypeId
+ - domainId
+ - name
+ - description
+ - createdTime
+ - updatedTime
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'entityTypeId', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'domainId', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'name', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'description', 'UTF8', None, ), # 4
+ (5, TType.I64, 'createdTime', None, None, ), # 5
+ (6, TType.I64, 'updatedTime', None, None, ), # 6
+ )
+
+ def __init__(self, entityTypeId=None, domainId=None, name=None, description=None, createdTime=None, updatedTime=None,):
+ self.entityTypeId = entityTypeId
+ self.domainId = domainId
+ self.name = name
+ self.description = description
+ self.createdTime = createdTime
+ self.updatedTime = updatedTime
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.entityTypeId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.domainId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.name = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.description = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.I64:
+ self.createdTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.I64:
+ self.updatedTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('EntityType')
+ if self.entityTypeId is not None:
+ oprot.writeFieldBegin('entityTypeId', TType.STRING, 1)
+ oprot.writeString(self.entityTypeId.encode('utf-8') if sys.version_info[0] == 2 else self.entityTypeId)
+ oprot.writeFieldEnd()
+ if self.domainId is not None:
+ oprot.writeFieldBegin('domainId', TType.STRING, 2)
+ oprot.writeString(self.domainId.encode('utf-8') if sys.version_info[0] == 2 else self.domainId)
+ oprot.writeFieldEnd()
+ if self.name is not None:
+ oprot.writeFieldBegin('name', TType.STRING, 3)
+ oprot.writeString(self.name.encode('utf-8') if sys.version_info[0] == 2 else self.name)
+ oprot.writeFieldEnd()
+ if self.description is not None:
+ oprot.writeFieldBegin('description', TType.STRING, 4)
+ oprot.writeString(self.description.encode('utf-8') if sys.version_info[0] == 2 else self.description)
+ oprot.writeFieldEnd()
+ if self.createdTime is not None:
+ oprot.writeFieldBegin('createdTime', TType.I64, 5)
+ oprot.writeI64(self.createdTime)
+ oprot.writeFieldEnd()
+ if self.updatedTime is not None:
+ oprot.writeFieldBegin('updatedTime', TType.I64, 6)
+ oprot.writeI64(self.updatedTime)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class SearchCriteria(object):
+ """
+ <p>Container object for search criteria</p>
+ <li><b>searchField</b> : Entity search field</li>
+ <li><b>value</b> : Search value</li>
+ <li><b>searchCondition</b> : EQUAL, LIKE etc..</li>
+
+
+ Attributes:
+ - searchField
+ - value
+ - searchCondition
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'searchField', None, None, ), # 1
+ (2, TType.STRING, 'value', 'UTF8', None, ), # 2
+ (3, TType.I32, 'searchCondition', None, None, ), # 3
+ )
+
+ def __init__(self, searchField=None, value=None, searchCondition=None,):
+ self.searchField = searchField
+ self.value = value
+ self.searchCondition = searchCondition
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.searchField = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.value
<TRUNCATED>
[09/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/DataProductModel.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/DataProductModel.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/DataProductModel.java
index 931e94c..ec1c1bb 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/DataProductModel.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/DataProductModel.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.data.replica;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class DataProductModel implements org.apache.thrift.TBase<DataProductModel, DataProductModel._Fields>, java.io.Serializable, Cloneable, Comparable<DataProductModel> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("DataProductModel");
@@ -68,24 +41,21 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
private static final org.apache.thrift.protocol.TField PRODUCT_METADATA_FIELD_DESC = new org.apache.thrift.protocol.TField("productMetadata", org.apache.thrift.protocol.TType.MAP, (short)11);
private static final org.apache.thrift.protocol.TField REPLICA_LOCATIONS_FIELD_DESC = new org.apache.thrift.protocol.TField("replicaLocations", org.apache.thrift.protocol.TType.LIST, (short)12);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new DataProductModelStandardSchemeFactory());
- schemes.put(TupleScheme.class, new DataProductModelTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new DataProductModelStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new DataProductModelTupleSchemeFactory();
- private String productUri; // optional
- private String gatewayId; // optional
- private String parentProductUri; // optional
- private String productName; // optional
- private String productDescription; // optional
- private String ownerName; // optional
+ private java.lang.String productUri; // optional
+ private java.lang.String gatewayId; // optional
+ private java.lang.String parentProductUri; // optional
+ private java.lang.String productName; // optional
+ private java.lang.String productDescription; // optional
+ private java.lang.String ownerName; // optional
private DataProductType dataProductType; // optional
private int productSize; // optional
private long creationTime; // optional
private long lastModifiedTime; // optional
- private Map<String,String> productMetadata; // optional
- private List<DataReplicaLocationModel> replicaLocations; // optional
+ private java.util.Map<java.lang.String,java.lang.String> productMetadata; // optional
+ private java.util.List<DataReplicaLocationModel> replicaLocations; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -106,10 +76,10 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
PRODUCT_METADATA((short)11, "productMetadata"),
REPLICA_LOCATIONS((short)12, "replicaLocations");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -154,21 +124,21 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -177,7 +147,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -188,9 +158,9 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
private static final int __LASTMODIFIEDTIME_ISSET_ID = 2;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.PRODUCT_URI,_Fields.GATEWAY_ID,_Fields.PARENT_PRODUCT_URI,_Fields.PRODUCT_NAME,_Fields.PRODUCT_DESCRIPTION,_Fields.OWNER_NAME,_Fields.DATA_PRODUCT_TYPE,_Fields.PRODUCT_SIZE,_Fields.CREATION_TIME,_Fields.LAST_MODIFIED_TIME,_Fields.PRODUCT_METADATA,_Fields.REPLICA_LOCATIONS};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.PRODUCT_URI, new org.apache.thrift.meta_data.FieldMetaData("productUri", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.GATEWAY_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayId", org.apache.thrift.TFieldRequirementType.OPTIONAL,
@@ -218,7 +188,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
tmpMap.put(_Fields.REPLICA_LOCATIONS, new org.apache.thrift.meta_data.FieldMetaData("replicaLocations", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, DataReplicaLocationModel.class))));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(DataProductModel.class, metaDataMap);
}
@@ -255,11 +225,11 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
this.creationTime = other.creationTime;
this.lastModifiedTime = other.lastModifiedTime;
if (other.isSetProductMetadata()) {
- Map<String,String> __this__productMetadata = new HashMap<String,String>(other.productMetadata);
+ java.util.Map<java.lang.String,java.lang.String> __this__productMetadata = new java.util.HashMap<java.lang.String,java.lang.String>(other.productMetadata);
this.productMetadata = __this__productMetadata;
}
if (other.isSetReplicaLocations()) {
- List<DataReplicaLocationModel> __this__replicaLocations = new ArrayList<DataReplicaLocationModel>(other.replicaLocations.size());
+ java.util.List<DataReplicaLocationModel> __this__replicaLocations = new java.util.ArrayList<DataReplicaLocationModel>(other.replicaLocations.size());
for (DataReplicaLocationModel other_element : other.replicaLocations) {
__this__replicaLocations.add(new DataReplicaLocationModel(other_element));
}
@@ -290,11 +260,11 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
this.replicaLocations = null;
}
- public String getProductUri() {
+ public java.lang.String getProductUri() {
return this.productUri;
}
- public void setProductUri(String productUri) {
+ public void setProductUri(java.lang.String productUri) {
this.productUri = productUri;
}
@@ -313,11 +283,11 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
}
}
- public String getGatewayId() {
+ public java.lang.String getGatewayId() {
return this.gatewayId;
}
- public void setGatewayId(String gatewayId) {
+ public void setGatewayId(java.lang.String gatewayId) {
this.gatewayId = gatewayId;
}
@@ -336,11 +306,11 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
}
}
- public String getParentProductUri() {
+ public java.lang.String getParentProductUri() {
return this.parentProductUri;
}
- public void setParentProductUri(String parentProductUri) {
+ public void setParentProductUri(java.lang.String parentProductUri) {
this.parentProductUri = parentProductUri;
}
@@ -359,11 +329,11 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
}
}
- public String getProductName() {
+ public java.lang.String getProductName() {
return this.productName;
}
- public void setProductName(String productName) {
+ public void setProductName(java.lang.String productName) {
this.productName = productName;
}
@@ -382,11 +352,11 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
}
}
- public String getProductDescription() {
+ public java.lang.String getProductDescription() {
return this.productDescription;
}
- public void setProductDescription(String productDescription) {
+ public void setProductDescription(java.lang.String productDescription) {
this.productDescription = productDescription;
}
@@ -405,11 +375,11 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
}
}
- public String getOwnerName() {
+ public java.lang.String getOwnerName() {
return this.ownerName;
}
- public void setOwnerName(String ownerName) {
+ public void setOwnerName(java.lang.String ownerName) {
this.ownerName = ownerName;
}
@@ -469,16 +439,16 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
}
public void unsetProductSize() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __PRODUCTSIZE_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __PRODUCTSIZE_ISSET_ID);
}
/** Returns true if field productSize is set (has been assigned a value) and false otherwise */
public boolean isSetProductSize() {
- return EncodingUtils.testBit(__isset_bitfield, __PRODUCTSIZE_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __PRODUCTSIZE_ISSET_ID);
}
public void setProductSizeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __PRODUCTSIZE_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __PRODUCTSIZE_ISSET_ID, value);
}
public long getCreationTime() {
@@ -491,16 +461,16 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
}
public void unsetCreationTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
}
/** Returns true if field creationTime is set (has been assigned a value) and false otherwise */
public boolean isSetCreationTime() {
- return EncodingUtils.testBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
}
public void setCreationTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __CREATIONTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __CREATIONTIME_ISSET_ID, value);
}
public long getLastModifiedTime() {
@@ -513,34 +483,34 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
}
public void unsetLastModifiedTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __LASTMODIFIEDTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __LASTMODIFIEDTIME_ISSET_ID);
}
/** Returns true if field lastModifiedTime is set (has been assigned a value) and false otherwise */
public boolean isSetLastModifiedTime() {
- return EncodingUtils.testBit(__isset_bitfield, __LASTMODIFIEDTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __LASTMODIFIEDTIME_ISSET_ID);
}
public void setLastModifiedTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __LASTMODIFIEDTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __LASTMODIFIEDTIME_ISSET_ID, value);
}
public int getProductMetadataSize() {
return (this.productMetadata == null) ? 0 : this.productMetadata.size();
}
- public void putToProductMetadata(String key, String val) {
+ public void putToProductMetadata(java.lang.String key, java.lang.String val) {
if (this.productMetadata == null) {
- this.productMetadata = new HashMap<String,String>();
+ this.productMetadata = new java.util.HashMap<java.lang.String,java.lang.String>();
}
this.productMetadata.put(key, val);
}
- public Map<String,String> getProductMetadata() {
+ public java.util.Map<java.lang.String,java.lang.String> getProductMetadata() {
return this.productMetadata;
}
- public void setProductMetadata(Map<String,String> productMetadata) {
+ public void setProductMetadata(java.util.Map<java.lang.String,java.lang.String> productMetadata) {
this.productMetadata = productMetadata;
}
@@ -569,16 +539,16 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
public void addToReplicaLocations(DataReplicaLocationModel elem) {
if (this.replicaLocations == null) {
- this.replicaLocations = new ArrayList<DataReplicaLocationModel>();
+ this.replicaLocations = new java.util.ArrayList<DataReplicaLocationModel>();
}
this.replicaLocations.add(elem);
}
- public List<DataReplicaLocationModel> getReplicaLocations() {
+ public java.util.List<DataReplicaLocationModel> getReplicaLocations() {
return this.replicaLocations;
}
- public void setReplicaLocations(List<DataReplicaLocationModel> replicaLocations) {
+ public void setReplicaLocations(java.util.List<DataReplicaLocationModel> replicaLocations) {
this.replicaLocations = replicaLocations;
}
@@ -597,13 +567,13 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case PRODUCT_URI:
if (value == null) {
unsetProductUri();
} else {
- setProductUri((String)value);
+ setProductUri((java.lang.String)value);
}
break;
@@ -611,7 +581,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
if (value == null) {
unsetGatewayId();
} else {
- setGatewayId((String)value);
+ setGatewayId((java.lang.String)value);
}
break;
@@ -619,7 +589,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
if (value == null) {
unsetParentProductUri();
} else {
- setParentProductUri((String)value);
+ setParentProductUri((java.lang.String)value);
}
break;
@@ -627,7 +597,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
if (value == null) {
unsetProductName();
} else {
- setProductName((String)value);
+ setProductName((java.lang.String)value);
}
break;
@@ -635,7 +605,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
if (value == null) {
unsetProductDescription();
} else {
- setProductDescription((String)value);
+ setProductDescription((java.lang.String)value);
}
break;
@@ -643,7 +613,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
if (value == null) {
unsetOwnerName();
} else {
- setOwnerName((String)value);
+ setOwnerName((java.lang.String)value);
}
break;
@@ -659,7 +629,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
if (value == null) {
unsetProductSize();
} else {
- setProductSize((Integer)value);
+ setProductSize((java.lang.Integer)value);
}
break;
@@ -667,7 +637,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
if (value == null) {
unsetCreationTime();
} else {
- setCreationTime((Long)value);
+ setCreationTime((java.lang.Long)value);
}
break;
@@ -675,7 +645,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
if (value == null) {
unsetLastModifiedTime();
} else {
- setLastModifiedTime((Long)value);
+ setLastModifiedTime((java.lang.Long)value);
}
break;
@@ -683,7 +653,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
if (value == null) {
unsetProductMetadata();
} else {
- setProductMetadata((Map<String,String>)value);
+ setProductMetadata((java.util.Map<java.lang.String,java.lang.String>)value);
}
break;
@@ -691,14 +661,14 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
if (value == null) {
unsetReplicaLocations();
} else {
- setReplicaLocations((List<DataReplicaLocationModel>)value);
+ setReplicaLocations((java.util.List<DataReplicaLocationModel>)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case PRODUCT_URI:
return getProductUri();
@@ -737,13 +707,13 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
return getReplicaLocations();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -772,11 +742,11 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
case REPLICA_LOCATIONS:
return isSetReplicaLocations();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof DataProductModel)
@@ -787,6 +757,8 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
public boolean equals(DataProductModel that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_productUri = true && this.isSetProductUri();
boolean that_present_productUri = true && that.isSetProductUri();
@@ -901,69 +873,57 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_productUri = true && (isSetProductUri());
- list.add(present_productUri);
- if (present_productUri)
- list.add(productUri);
-
- boolean present_gatewayId = true && (isSetGatewayId());
- list.add(present_gatewayId);
- if (present_gatewayId)
- list.add(gatewayId);
-
- boolean present_parentProductUri = true && (isSetParentProductUri());
- list.add(present_parentProductUri);
- if (present_parentProductUri)
- list.add(parentProductUri);
-
- boolean present_productName = true && (isSetProductName());
- list.add(present_productName);
- if (present_productName)
- list.add(productName);
-
- boolean present_productDescription = true && (isSetProductDescription());
- list.add(present_productDescription);
- if (present_productDescription)
- list.add(productDescription);
-
- boolean present_ownerName = true && (isSetOwnerName());
- list.add(present_ownerName);
- if (present_ownerName)
- list.add(ownerName);
-
- boolean present_dataProductType = true && (isSetDataProductType());
- list.add(present_dataProductType);
- if (present_dataProductType)
- list.add(dataProductType.getValue());
-
- boolean present_productSize = true && (isSetProductSize());
- list.add(present_productSize);
- if (present_productSize)
- list.add(productSize);
-
- boolean present_creationTime = true && (isSetCreationTime());
- list.add(present_creationTime);
- if (present_creationTime)
- list.add(creationTime);
-
- boolean present_lastModifiedTime = true && (isSetLastModifiedTime());
- list.add(present_lastModifiedTime);
- if (present_lastModifiedTime)
- list.add(lastModifiedTime);
-
- boolean present_productMetadata = true && (isSetProductMetadata());
- list.add(present_productMetadata);
- if (present_productMetadata)
- list.add(productMetadata);
-
- boolean present_replicaLocations = true && (isSetReplicaLocations());
- list.add(present_replicaLocations);
- if (present_replicaLocations)
- list.add(replicaLocations);
-
- return list.hashCode();
+ int hashCode = 1;
+
+ hashCode = hashCode * 8191 + ((isSetProductUri()) ? 131071 : 524287);
+ if (isSetProductUri())
+ hashCode = hashCode * 8191 + productUri.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetGatewayId()) ? 131071 : 524287);
+ if (isSetGatewayId())
+ hashCode = hashCode * 8191 + gatewayId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetParentProductUri()) ? 131071 : 524287);
+ if (isSetParentProductUri())
+ hashCode = hashCode * 8191 + parentProductUri.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetProductName()) ? 131071 : 524287);
+ if (isSetProductName())
+ hashCode = hashCode * 8191 + productName.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetProductDescription()) ? 131071 : 524287);
+ if (isSetProductDescription())
+ hashCode = hashCode * 8191 + productDescription.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetOwnerName()) ? 131071 : 524287);
+ if (isSetOwnerName())
+ hashCode = hashCode * 8191 + ownerName.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetDataProductType()) ? 131071 : 524287);
+ if (isSetDataProductType())
+ hashCode = hashCode * 8191 + dataProductType.getValue();
+
+ hashCode = hashCode * 8191 + ((isSetProductSize()) ? 131071 : 524287);
+ if (isSetProductSize())
+ hashCode = hashCode * 8191 + productSize;
+
+ hashCode = hashCode * 8191 + ((isSetCreationTime()) ? 131071 : 524287);
+ if (isSetCreationTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(creationTime);
+
+ hashCode = hashCode * 8191 + ((isSetLastModifiedTime()) ? 131071 : 524287);
+ if (isSetLastModifiedTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(lastModifiedTime);
+
+ hashCode = hashCode * 8191 + ((isSetProductMetadata()) ? 131071 : 524287);
+ if (isSetProductMetadata())
+ hashCode = hashCode * 8191 + productMetadata.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetReplicaLocations()) ? 131071 : 524287);
+ if (isSetReplicaLocations())
+ hashCode = hashCode * 8191 + replicaLocations.hashCode();
+
+ return hashCode;
}
@Override
@@ -974,7 +934,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetProductUri()).compareTo(other.isSetProductUri());
+ lastComparison = java.lang.Boolean.valueOf(isSetProductUri()).compareTo(other.isSetProductUri());
if (lastComparison != 0) {
return lastComparison;
}
@@ -984,7 +944,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(other.isSetGatewayId());
+ lastComparison = java.lang.Boolean.valueOf(isSetGatewayId()).compareTo(other.isSetGatewayId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -994,7 +954,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetParentProductUri()).compareTo(other.isSetParentProductUri());
+ lastComparison = java.lang.Boolean.valueOf(isSetParentProductUri()).compareTo(other.isSetParentProductUri());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1004,7 +964,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetProductName()).compareTo(other.isSetProductName());
+ lastComparison = java.lang.Boolean.valueOf(isSetProductName()).compareTo(other.isSetProductName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1014,7 +974,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetProductDescription()).compareTo(other.isSetProductDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetProductDescription()).compareTo(other.isSetProductDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1024,7 +984,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetOwnerName()).compareTo(other.isSetOwnerName());
+ lastComparison = java.lang.Boolean.valueOf(isSetOwnerName()).compareTo(other.isSetOwnerName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1034,7 +994,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDataProductType()).compareTo(other.isSetDataProductType());
+ lastComparison = java.lang.Boolean.valueOf(isSetDataProductType()).compareTo(other.isSetDataProductType());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1044,7 +1004,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetProductSize()).compareTo(other.isSetProductSize());
+ lastComparison = java.lang.Boolean.valueOf(isSetProductSize()).compareTo(other.isSetProductSize());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1054,7 +1014,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCreationTime()).compareTo(other.isSetCreationTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetCreationTime()).compareTo(other.isSetCreationTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1064,7 +1024,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetLastModifiedTime()).compareTo(other.isSetLastModifiedTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetLastModifiedTime()).compareTo(other.isSetLastModifiedTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1074,7 +1034,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetProductMetadata()).compareTo(other.isSetProductMetadata());
+ lastComparison = java.lang.Boolean.valueOf(isSetProductMetadata()).compareTo(other.isSetProductMetadata());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1084,7 +1044,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetReplicaLocations()).compareTo(other.isSetReplicaLocations());
+ lastComparison = java.lang.Boolean.valueOf(isSetReplicaLocations()).compareTo(other.isSetReplicaLocations());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1102,16 +1062,16 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("DataProductModel(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("DataProductModel(");
boolean first = true;
if (isSetProductUri()) {
@@ -1238,7 +1198,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -1248,13 +1208,13 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
}
}
- private static class DataProductModelStandardSchemeFactory implements SchemeFactory {
+ private static class DataProductModelStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public DataProductModelStandardScheme getScheme() {
return new DataProductModelStandardScheme();
}
}
- private static class DataProductModelStandardScheme extends StandardScheme<DataProductModel> {
+ private static class DataProductModelStandardScheme extends org.apache.thrift.scheme.StandardScheme<DataProductModel> {
public void read(org.apache.thrift.protocol.TProtocol iprot, DataProductModel struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1350,9 +1310,9 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
if (schemeField.type == org.apache.thrift.protocol.TType.MAP) {
{
org.apache.thrift.protocol.TMap _map10 = iprot.readMapBegin();
- struct.productMetadata = new HashMap<String,String>(2*_map10.size);
- String _key11;
- String _val12;
+ struct.productMetadata = new java.util.HashMap<java.lang.String,java.lang.String>(2*_map10.size);
+ java.lang.String _key11;
+ java.lang.String _val12;
for (int _i13 = 0; _i13 < _map10.size; ++_i13)
{
_key11 = iprot.readString();
@@ -1370,7 +1330,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list14 = iprot.readListBegin();
- struct.replicaLocations = new ArrayList<DataReplicaLocationModel>(_list14.size);
+ struct.replicaLocations = new java.util.ArrayList<DataReplicaLocationModel>(_list14.size);
DataReplicaLocationModel _elem15;
for (int _i16 = 0; _i16 < _list14.size; ++_i16)
{
@@ -1467,7 +1427,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
oprot.writeFieldBegin(PRODUCT_METADATA_FIELD_DESC);
{
oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, struct.productMetadata.size()));
- for (Map.Entry<String, String> _iter17 : struct.productMetadata.entrySet())
+ for (java.util.Map.Entry<java.lang.String, java.lang.String> _iter17 : struct.productMetadata.entrySet())
{
oprot.writeString(_iter17.getKey());
oprot.writeString(_iter17.getValue());
@@ -1497,18 +1457,18 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
}
- private static class DataProductModelTupleSchemeFactory implements SchemeFactory {
+ private static class DataProductModelTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public DataProductModelTupleScheme getScheme() {
return new DataProductModelTupleScheme();
}
}
- private static class DataProductModelTupleScheme extends TupleScheme<DataProductModel> {
+ private static class DataProductModelTupleScheme extends org.apache.thrift.scheme.TupleScheme<DataProductModel> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, DataProductModel struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetProductUri()) {
optionals.set(0);
}
@@ -1579,7 +1539,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
if (struct.isSetProductMetadata()) {
{
oprot.writeI32(struct.productMetadata.size());
- for (Map.Entry<String, String> _iter19 : struct.productMetadata.entrySet())
+ for (java.util.Map.Entry<java.lang.String, java.lang.String> _iter19 : struct.productMetadata.entrySet())
{
oprot.writeString(_iter19.getKey());
oprot.writeString(_iter19.getValue());
@@ -1599,8 +1559,8 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, DataProductModel struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(12);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(12);
if (incoming.get(0)) {
struct.productUri = iprot.readString();
struct.setProductUriIsSet(true);
@@ -1644,9 +1604,9 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
if (incoming.get(10)) {
{
org.apache.thrift.protocol.TMap _map21 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.productMetadata = new HashMap<String,String>(2*_map21.size);
- String _key22;
- String _val23;
+ struct.productMetadata = new java.util.HashMap<java.lang.String,java.lang.String>(2*_map21.size);
+ java.lang.String _key22;
+ java.lang.String _val23;
for (int _i24 = 0; _i24 < _map21.size; ++_i24)
{
_key22 = iprot.readString();
@@ -1659,7 +1619,7 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
if (incoming.get(11)) {
{
org.apache.thrift.protocol.TList _list25 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
- struct.replicaLocations = new ArrayList<DataReplicaLocationModel>(_list25.size);
+ struct.replicaLocations = new java.util.ArrayList<DataReplicaLocationModel>(_list25.size);
DataReplicaLocationModel _elem26;
for (int _i27 = 0; _i27 < _list25.size; ++_i27)
{
@@ -1673,5 +1633,8 @@ public class DataProductModel implements org.apache.thrift.TBase<DataProductMode
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/DataProductType.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/DataProductType.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/DataProductType.java
index db4895d..5de03d0 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/DataProductType.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/DataProductType.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/DataReplicaLocationModel.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/DataReplicaLocationModel.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/DataReplicaLocationModel.java
index 151f9c2..a2e763c 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/DataReplicaLocationModel.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/DataReplicaLocationModel.java
@@ -16,42 +16,15 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.airavata.model.data.replica;
-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 javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.10.0)")
public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataReplicaLocationModel, DataReplicaLocationModel._Fields>, java.io.Serializable, Cloneable, Comparable<DataReplicaLocationModel> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("DataReplicaLocationModel");
@@ -68,24 +41,21 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
private static final org.apache.thrift.protocol.TField FILE_PATH_FIELD_DESC = new org.apache.thrift.protocol.TField("filePath", org.apache.thrift.protocol.TType.STRING, (short)11);
private static final org.apache.thrift.protocol.TField REPLICA_METADATA_FIELD_DESC = new org.apache.thrift.protocol.TField("replicaMetadata", org.apache.thrift.protocol.TType.MAP, (short)12);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new DataReplicaLocationModelStandardSchemeFactory());
- schemes.put(TupleScheme.class, new DataReplicaLocationModelTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new DataReplicaLocationModelStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new DataReplicaLocationModelTupleSchemeFactory();
- private String replicaId; // optional
- private String productUri; // optional
- private String replicaName; // optional
- private String replicaDescription; // optional
+ private java.lang.String replicaId; // optional
+ private java.lang.String productUri; // optional
+ private java.lang.String replicaName; // optional
+ private java.lang.String replicaDescription; // optional
private long creationTime; // optional
private long lastModifiedTime; // optional
private long validUntilTime; // optional
private ReplicaLocationCategory replicaLocationCategory; // optional
private ReplicaPersistentType replicaPersistentType; // optional
- private String storageResourceId; // optional
- private String filePath; // optional
- private Map<String,String> replicaMetadata; // optional
+ private java.lang.String storageResourceId; // optional
+ private java.lang.String filePath; // optional
+ private java.util.Map<java.lang.String,java.lang.String> replicaMetadata; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -110,10 +80,10 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
FILE_PATH((short)11, "filePath"),
REPLICA_METADATA((short)12, "replicaMetadata");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -158,21 +128,21 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.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) {
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -181,7 +151,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -192,9 +162,9 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
private static final int __VALIDUNTILTIME_ISSET_ID = 2;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.REPLICA_ID,_Fields.PRODUCT_URI,_Fields.REPLICA_NAME,_Fields.REPLICA_DESCRIPTION,_Fields.CREATION_TIME,_Fields.LAST_MODIFIED_TIME,_Fields.VALID_UNTIL_TIME,_Fields.REPLICA_LOCATION_CATEGORY,_Fields.REPLICA_PERSISTENT_TYPE,_Fields.STORAGE_RESOURCE_ID,_Fields.FILE_PATH,_Fields.REPLICA_METADATA};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.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);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.REPLICA_ID, new org.apache.thrift.meta_data.FieldMetaData("replicaId", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.PRODUCT_URI, new org.apache.thrift.meta_data.FieldMetaData("productUri", org.apache.thrift.TFieldRequirementType.OPTIONAL,
@@ -221,7 +191,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING),
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(DataReplicaLocationModel.class, metaDataMap);
}
@@ -261,7 +231,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
this.filePath = other.filePath;
}
if (other.isSetReplicaMetadata()) {
- Map<String,String> __this__replicaMetadata = new HashMap<String,String>(other.replicaMetadata);
+ java.util.Map<java.lang.String,java.lang.String> __this__replicaMetadata = new java.util.HashMap<java.lang.String,java.lang.String>(other.replicaMetadata);
this.replicaMetadata = __this__replicaMetadata;
}
}
@@ -289,11 +259,11 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
this.replicaMetadata = null;
}
- public String getReplicaId() {
+ public java.lang.String getReplicaId() {
return this.replicaId;
}
- public void setReplicaId(String replicaId) {
+ public void setReplicaId(java.lang.String replicaId) {
this.replicaId = replicaId;
}
@@ -312,11 +282,11 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
}
}
- public String getProductUri() {
+ public java.lang.String getProductUri() {
return this.productUri;
}
- public void setProductUri(String productUri) {
+ public void setProductUri(java.lang.String productUri) {
this.productUri = productUri;
}
@@ -335,11 +305,11 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
}
}
- public String getReplicaName() {
+ public java.lang.String getReplicaName() {
return this.replicaName;
}
- public void setReplicaName(String replicaName) {
+ public void setReplicaName(java.lang.String replicaName) {
this.replicaName = replicaName;
}
@@ -358,11 +328,11 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
}
}
- public String getReplicaDescription() {
+ public java.lang.String getReplicaDescription() {
return this.replicaDescription;
}
- public void setReplicaDescription(String replicaDescription) {
+ public void setReplicaDescription(java.lang.String replicaDescription) {
this.replicaDescription = replicaDescription;
}
@@ -391,16 +361,16 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
}
public void unsetCreationTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
}
/** Returns true if field creationTime is set (has been assigned a value) and false otherwise */
public boolean isSetCreationTime() {
- return EncodingUtils.testBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __CREATIONTIME_ISSET_ID);
}
public void setCreationTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __CREATIONTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __CREATIONTIME_ISSET_ID, value);
}
public long getLastModifiedTime() {
@@ -413,16 +383,16 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
}
public void unsetLastModifiedTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __LASTMODIFIEDTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __LASTMODIFIEDTIME_ISSET_ID);
}
/** Returns true if field lastModifiedTime is set (has been assigned a value) and false otherwise */
public boolean isSetLastModifiedTime() {
- return EncodingUtils.testBit(__isset_bitfield, __LASTMODIFIEDTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __LASTMODIFIEDTIME_ISSET_ID);
}
public void setLastModifiedTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __LASTMODIFIEDTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __LASTMODIFIEDTIME_ISSET_ID, value);
}
public long getValidUntilTime() {
@@ -435,16 +405,16 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
}
public void unsetValidUntilTime() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __VALIDUNTILTIME_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __VALIDUNTILTIME_ISSET_ID);
}
/** Returns true if field validUntilTime is set (has been assigned a value) and false otherwise */
public boolean isSetValidUntilTime() {
- return EncodingUtils.testBit(__isset_bitfield, __VALIDUNTILTIME_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __VALIDUNTILTIME_ISSET_ID);
}
public void setValidUntilTimeIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __VALIDUNTILTIME_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __VALIDUNTILTIME_ISSET_ID, value);
}
/**
@@ -509,11 +479,11 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
}
}
- public String getStorageResourceId() {
+ public java.lang.String getStorageResourceId() {
return this.storageResourceId;
}
- public void setStorageResourceId(String storageResourceId) {
+ public void setStorageResourceId(java.lang.String storageResourceId) {
this.storageResourceId = storageResourceId;
}
@@ -532,11 +502,11 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
}
}
- public String getFilePath() {
+ public java.lang.String getFilePath() {
return this.filePath;
}
- public void setFilePath(String filePath) {
+ public void setFilePath(java.lang.String filePath) {
this.filePath = filePath;
}
@@ -559,18 +529,18 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
return (this.replicaMetadata == null) ? 0 : this.replicaMetadata.size();
}
- public void putToReplicaMetadata(String key, String val) {
+ public void putToReplicaMetadata(java.lang.String key, java.lang.String val) {
if (this.replicaMetadata == null) {
- this.replicaMetadata = new HashMap<String,String>();
+ this.replicaMetadata = new java.util.HashMap<java.lang.String,java.lang.String>();
}
this.replicaMetadata.put(key, val);
}
- public Map<String,String> getReplicaMetadata() {
+ public java.util.Map<java.lang.String,java.lang.String> getReplicaMetadata() {
return this.replicaMetadata;
}
- public void setReplicaMetadata(Map<String,String> replicaMetadata) {
+ public void setReplicaMetadata(java.util.Map<java.lang.String,java.lang.String> replicaMetadata) {
this.replicaMetadata = replicaMetadata;
}
@@ -589,13 +559,13 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, java.lang.Object value) {
switch (field) {
case REPLICA_ID:
if (value == null) {
unsetReplicaId();
} else {
- setReplicaId((String)value);
+ setReplicaId((java.lang.String)value);
}
break;
@@ -603,7 +573,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
if (value == null) {
unsetProductUri();
} else {
- setProductUri((String)value);
+ setProductUri((java.lang.String)value);
}
break;
@@ -611,7 +581,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
if (value == null) {
unsetReplicaName();
} else {
- setReplicaName((String)value);
+ setReplicaName((java.lang.String)value);
}
break;
@@ -619,7 +589,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
if (value == null) {
unsetReplicaDescription();
} else {
- setReplicaDescription((String)value);
+ setReplicaDescription((java.lang.String)value);
}
break;
@@ -627,7 +597,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
if (value == null) {
unsetCreationTime();
} else {
- setCreationTime((Long)value);
+ setCreationTime((java.lang.Long)value);
}
break;
@@ -635,7 +605,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
if (value == null) {
unsetLastModifiedTime();
} else {
- setLastModifiedTime((Long)value);
+ setLastModifiedTime((java.lang.Long)value);
}
break;
@@ -643,7 +613,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
if (value == null) {
unsetValidUntilTime();
} else {
- setValidUntilTime((Long)value);
+ setValidUntilTime((java.lang.Long)value);
}
break;
@@ -667,7 +637,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
if (value == null) {
unsetStorageResourceId();
} else {
- setStorageResourceId((String)value);
+ setStorageResourceId((java.lang.String)value);
}
break;
@@ -675,7 +645,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
if (value == null) {
unsetFilePath();
} else {
- setFilePath((String)value);
+ setFilePath((java.lang.String)value);
}
break;
@@ -683,14 +653,14 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
if (value == null) {
unsetReplicaMetadata();
} else {
- setReplicaMetadata((Map<String,String>)value);
+ setReplicaMetadata((java.util.Map<java.lang.String,java.lang.String>)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case REPLICA_ID:
return getReplicaId();
@@ -729,13 +699,13 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
return getReplicaMetadata();
}
- throw new IllegalStateException();
+ throw new java.lang.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();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -764,11 +734,11 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
case REPLICA_METADATA:
return isSetReplicaMetadata();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
+ public boolean equals(java.lang.Object that) {
if (that == null)
return false;
if (that instanceof DataReplicaLocationModel)
@@ -779,6 +749,8 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
public boolean equals(DataReplicaLocationModel that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_replicaId = true && this.isSetReplicaId();
boolean that_present_replicaId = true && that.isSetReplicaId();
@@ -893,69 +865,57 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
-
- boolean present_replicaId = true && (isSetReplicaId());
- list.add(present_replicaId);
- if (present_replicaId)
- list.add(replicaId);
-
- boolean present_productUri = true && (isSetProductUri());
- list.add(present_productUri);
- if (present_productUri)
- list.add(productUri);
-
- boolean present_replicaName = true && (isSetReplicaName());
- list.add(present_replicaName);
- if (present_replicaName)
- list.add(replicaName);
-
- boolean present_replicaDescription = true && (isSetReplicaDescription());
- list.add(present_replicaDescription);
- if (present_replicaDescription)
- list.add(replicaDescription);
-
- boolean present_creationTime = true && (isSetCreationTime());
- list.add(present_creationTime);
- if (present_creationTime)
- list.add(creationTime);
-
- boolean present_lastModifiedTime = true && (isSetLastModifiedTime());
- list.add(present_lastModifiedTime);
- if (present_lastModifiedTime)
- list.add(lastModifiedTime);
-
- boolean present_validUntilTime = true && (isSetValidUntilTime());
- list.add(present_validUntilTime);
- if (present_validUntilTime)
- list.add(validUntilTime);
-
- boolean present_replicaLocationCategory = true && (isSetReplicaLocationCategory());
- list.add(present_replicaLocationCategory);
- if (present_replicaLocationCategory)
- list.add(replicaLocationCategory.getValue());
-
- boolean present_replicaPersistentType = true && (isSetReplicaPersistentType());
- list.add(present_replicaPersistentType);
- if (present_replicaPersistentType)
- list.add(replicaPersistentType.getValue());
-
- boolean present_storageResourceId = true && (isSetStorageResourceId());
- list.add(present_storageResourceId);
- if (present_storageResourceId)
- list.add(storageResourceId);
-
- boolean present_filePath = true && (isSetFilePath());
- list.add(present_filePath);
- if (present_filePath)
- list.add(filePath);
-
- boolean present_replicaMetadata = true && (isSetReplicaMetadata());
- list.add(present_replicaMetadata);
- if (present_replicaMetadata)
- list.add(replicaMetadata);
-
- return list.hashCode();
+ int hashCode = 1;
+
+ hashCode = hashCode * 8191 + ((isSetReplicaId()) ? 131071 : 524287);
+ if (isSetReplicaId())
+ hashCode = hashCode * 8191 + replicaId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetProductUri()) ? 131071 : 524287);
+ if (isSetProductUri())
+ hashCode = hashCode * 8191 + productUri.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetReplicaName()) ? 131071 : 524287);
+ if (isSetReplicaName())
+ hashCode = hashCode * 8191 + replicaName.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetReplicaDescription()) ? 131071 : 524287);
+ if (isSetReplicaDescription())
+ hashCode = hashCode * 8191 + replicaDescription.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetCreationTime()) ? 131071 : 524287);
+ if (isSetCreationTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(creationTime);
+
+ hashCode = hashCode * 8191 + ((isSetLastModifiedTime()) ? 131071 : 524287);
+ if (isSetLastModifiedTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(lastModifiedTime);
+
+ hashCode = hashCode * 8191 + ((isSetValidUntilTime()) ? 131071 : 524287);
+ if (isSetValidUntilTime())
+ hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(validUntilTime);
+
+ hashCode = hashCode * 8191 + ((isSetReplicaLocationCategory()) ? 131071 : 524287);
+ if (isSetReplicaLocationCategory())
+ hashCode = hashCode * 8191 + replicaLocationCategory.getValue();
+
+ hashCode = hashCode * 8191 + ((isSetReplicaPersistentType()) ? 131071 : 524287);
+ if (isSetReplicaPersistentType())
+ hashCode = hashCode * 8191 + replicaPersistentType.getValue();
+
+ hashCode = hashCode * 8191 + ((isSetStorageResourceId()) ? 131071 : 524287);
+ if (isSetStorageResourceId())
+ hashCode = hashCode * 8191 + storageResourceId.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetFilePath()) ? 131071 : 524287);
+ if (isSetFilePath())
+ hashCode = hashCode * 8191 + filePath.hashCode();
+
+ hashCode = hashCode * 8191 + ((isSetReplicaMetadata()) ? 131071 : 524287);
+ if (isSetReplicaMetadata())
+ hashCode = hashCode * 8191 + replicaMetadata.hashCode();
+
+ return hashCode;
}
@Override
@@ -966,7 +926,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetReplicaId()).compareTo(other.isSetReplicaId());
+ lastComparison = java.lang.Boolean.valueOf(isSetReplicaId()).compareTo(other.isSetReplicaId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -976,7 +936,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetProductUri()).compareTo(other.isSetProductUri());
+ lastComparison = java.lang.Boolean.valueOf(isSetProductUri()).compareTo(other.isSetProductUri());
if (lastComparison != 0) {
return lastComparison;
}
@@ -986,7 +946,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetReplicaName()).compareTo(other.isSetReplicaName());
+ lastComparison = java.lang.Boolean.valueOf(isSetReplicaName()).compareTo(other.isSetReplicaName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -996,7 +956,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetReplicaDescription()).compareTo(other.isSetReplicaDescription());
+ lastComparison = java.lang.Boolean.valueOf(isSetReplicaDescription()).compareTo(other.isSetReplicaDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1006,7 +966,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetCreationTime()).compareTo(other.isSetCreationTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetCreationTime()).compareTo(other.isSetCreationTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1016,7 +976,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetLastModifiedTime()).compareTo(other.isSetLastModifiedTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetLastModifiedTime()).compareTo(other.isSetLastModifiedTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1026,7 +986,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetValidUntilTime()).compareTo(other.isSetValidUntilTime());
+ lastComparison = java.lang.Boolean.valueOf(isSetValidUntilTime()).compareTo(other.isSetValidUntilTime());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1036,7 +996,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetReplicaLocationCategory()).compareTo(other.isSetReplicaLocationCategory());
+ lastComparison = java.lang.Boolean.valueOf(isSetReplicaLocationCategory()).compareTo(other.isSetReplicaLocationCategory());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1046,7 +1006,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetReplicaPersistentType()).compareTo(other.isSetReplicaPersistentType());
+ lastComparison = java.lang.Boolean.valueOf(isSetReplicaPersistentType()).compareTo(other.isSetReplicaPersistentType());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1056,7 +1016,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetStorageResourceId()).compareTo(other.isSetStorageResourceId());
+ lastComparison = java.lang.Boolean.valueOf(isSetStorageResourceId()).compareTo(other.isSetStorageResourceId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1066,7 +1026,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetFilePath()).compareTo(other.isSetFilePath());
+ lastComparison = java.lang.Boolean.valueOf(isSetFilePath()).compareTo(other.isSetFilePath());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1076,7 +1036,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetReplicaMetadata()).compareTo(other.isSetReplicaMetadata());
+ lastComparison = java.lang.Boolean.valueOf(isSetReplicaMetadata()).compareTo(other.isSetReplicaMetadata());
if (lastComparison != 0) {
return lastComparison;
}
@@ -1094,16 +1054,16 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).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);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("DataReplicaLocationModel(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("DataReplicaLocationModel(");
boolean first = true;
if (isSetReplicaId()) {
@@ -1230,7 +1190,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.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;
@@ -1240,13 +1200,13 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
}
}
- private static class DataReplicaLocationModelStandardSchemeFactory implements SchemeFactory {
+ private static class DataReplicaLocationModelStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public DataReplicaLocationModelStandardScheme getScheme() {
return new DataReplicaLocationModelStandardScheme();
}
}
- private static class DataReplicaLocationModelStandardScheme extends StandardScheme<DataReplicaLocationModel> {
+ private static class DataReplicaLocationModelStandardScheme extends org.apache.thrift.scheme.StandardScheme<DataReplicaLocationModel> {
public void read(org.apache.thrift.protocol.TProtocol iprot, DataReplicaLocationModel struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1350,9 +1310,9 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
if (schemeField.type == org.apache.thrift.protocol.TType.MAP) {
{
org.apache.thrift.protocol.TMap _map0 = iprot.readMapBegin();
- struct.replicaMetadata = new HashMap<String,String>(2*_map0.size);
- String _key1;
- String _val2;
+ struct.replicaMetadata = new java.util.HashMap<java.lang.String,java.lang.String>(2*_map0.size);
+ java.lang.String _key1;
+ java.lang.String _val2;
for (int _i3 = 0; _i3 < _map0.size; ++_i3)
{
_key1 = iprot.readString();
@@ -1455,7 +1415,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
oprot.writeFieldBegin(REPLICA_METADATA_FIELD_DESC);
{
oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, struct.replicaMetadata.size()));
- for (Map.Entry<String, String> _iter4 : struct.replicaMetadata.entrySet())
+ for (java.util.Map.Entry<java.lang.String, java.lang.String> _iter4 : struct.replicaMetadata.entrySet())
{
oprot.writeString(_iter4.getKey());
oprot.writeString(_iter4.getValue());
@@ -1471,18 +1431,18 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
}
- private static class DataReplicaLocationModelTupleSchemeFactory implements SchemeFactory {
+ private static class DataReplicaLocationModelTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public DataReplicaLocationModelTupleScheme getScheme() {
return new DataReplicaLocationModelTupleScheme();
}
}
- private static class DataReplicaLocationModelTupleScheme extends TupleScheme<DataReplicaLocationModel> {
+ private static class DataReplicaLocationModelTupleScheme extends org.apache.thrift.scheme.TupleScheme<DataReplicaLocationModel> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, DataReplicaLocationModel struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetReplicaId()) {
optionals.set(0);
}
@@ -1556,7 +1516,7 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
if (struct.isSetReplicaMetadata()) {
{
oprot.writeI32(struct.replicaMetadata.size());
- for (Map.Entry<String, String> _iter5 : struct.replicaMetadata.entrySet())
+ for (java.util.Map.Entry<java.lang.String, java.lang.String> _iter5 : struct.replicaMetadata.entrySet())
{
oprot.writeString(_iter5.getKey());
oprot.writeString(_iter5.getValue());
@@ -1567,8 +1527,8 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, DataReplicaLocationModel struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(12);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(12);
if (incoming.get(0)) {
struct.replicaId = iprot.readString();
struct.setReplicaIdIsSet(true);
@@ -1616,9 +1576,9 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
if (incoming.get(11)) {
{
org.apache.thrift.protocol.TMap _map6 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.replicaMetadata = new HashMap<String,String>(2*_map6.size);
- String _key7;
- String _val8;
+ struct.replicaMetadata = new java.util.HashMap<java.lang.String,java.lang.String>(2*_map6.size);
+ java.lang.String _key7;
+ java.lang.String _val8;
for (int _i9 = 0; _i9 < _map6.size; ++_i9)
{
_key7 = iprot.readString();
@@ -1631,5 +1591,8 @@ public class DataReplicaLocationModel implements org.apache.thrift.TBase<DataRep
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/ReplicaLocationCategory.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/ReplicaLocationCategory.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/ReplicaLocationCategory.java
index 6cf5a8e..b891ffe 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/ReplicaLocationCategory.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/ReplicaLocationCategory.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/ReplicaPersistentType.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/ReplicaPersistentType.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/ReplicaPersistentType.java
index 518ca9f..705d024 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/ReplicaPersistentType.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/data/replica/ReplicaPersistentType.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/CrudType.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/CrudType.java b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/CrudType.java
index 23947b1..1500d20 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/CrudType.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/dbevent/CrudType.java
@@ -16,7 +16,7 @@
*/
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.10.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
[43/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/ttypes.py
index 56bdc1f..3a24bad 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/sharing/ttypes.py
@@ -1,20 +1,14 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.sharing.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/ttypes.py
index e829011..2a5de1c 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/api/ttypes.py
@@ -1,12 +1,14 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.api.error.ttypes
import apache.airavata.model.security.ttypes
import apache.airavata.model.ttypes
@@ -29,12 +31,4 @@ import apache.airavata.model.data.replica.ttypes
import apache.airavata.model.group.ttypes
import apache.airavata.model.user.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appdeployment/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appdeployment/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appdeployment/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appdeployment/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appdeployment/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appdeployment/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appdeployment/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appdeployment/ttypes.py
index fd2e305..048f8f1 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appdeployment/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appdeployment/ttypes.py
@@ -1,699 +1,651 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.commons.ttypes
import apache.airavata.model.appcatalog.parallelism.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-
-class SetEnvPaths:
- """
- Key Value pairs to be used to set environments
-
- name:
- Name of the environment variable such as PATH, LD_LIBRARY_PATH, NETCDF_HOME.
-
- value:
- Value of the environment variable to set
-
- envPathOrder:
- The order of the setting of the env variables when there are multiple env variables
-
- Attributes:
- - name
- - value
- - envPathOrder
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'name', None, None, ), # 1
- (2, TType.STRING, 'value', None, None, ), # 2
- (3, TType.I32, 'envPathOrder', None, None, ), # 3
- )
-
- def __init__(self, name=None, value=None, envPathOrder=None,):
- self.name = name
- self.value = value
- self.envPathOrder = envPathOrder
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.name = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.value = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.I32:
- self.envPathOrder = iprot.readI32()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('SetEnvPaths')
- if self.name is not None:
- oprot.writeFieldBegin('name', TType.STRING, 1)
- oprot.writeString(self.name)
- oprot.writeFieldEnd()
- if self.value is not None:
- oprot.writeFieldBegin('value', TType.STRING, 2)
- oprot.writeString(self.value)
- oprot.writeFieldEnd()
- if self.envPathOrder is not None:
- oprot.writeFieldBegin('envPathOrder', TType.I32, 3)
- oprot.writeI32(self.envPathOrder)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.name is None:
- raise TProtocol.TProtocolException(message='Required field name is unset!')
- if self.value is None:
- raise TProtocol.TProtocolException(message='Required field value is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.name)
- value = (value * 31) ^ hash(self.value)
- value = (value * 31) ^ hash(self.envPathOrder)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class CommandObject:
- """
- Job commands to be used in Pre Job, Post Job and Module Load Commands
-
- command:
- The actual command in string format
-
- commandOrder:
- Order of the command in the multiple command situation
-
- Attributes:
- - command
- - commandOrder
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'command', None, None, ), # 1
- (2, TType.I32, 'commandOrder', None, None, ), # 2
- )
-
- def __init__(self, command=None, commandOrder=None,):
- self.command = command
- self.commandOrder = commandOrder
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.command = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.commandOrder = iprot.readI32()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('CommandObject')
- if self.command is not None:
- oprot.writeFieldBegin('command', TType.STRING, 1)
- oprot.writeString(self.command)
- oprot.writeFieldEnd()
- if self.commandOrder is not None:
- oprot.writeFieldBegin('commandOrder', TType.I32, 2)
- oprot.writeI32(self.commandOrder)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.command is None:
- raise TProtocol.TProtocolException(message='Required field command is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.command)
- value = (value * 31) ^ hash(self.commandOrder)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ApplicationModule:
- """
- Application Module Information. A module has to be registered before registering a deployment.
-
- appModuleId: Airavata Internal Unique Job ID. This is set by the registry.
-
- appModuleName:
- Name of the application module.
-
- appModuleVersion:
- Version of the application.
-
- appModuleDescription:
- Descriprion of the Module
-
-
- Attributes:
- - appModuleId
- - appModuleName
- - appModuleVersion
- - appModuleDescription
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'appModuleId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.STRING, 'appModuleName', None, None, ), # 2
- (3, TType.STRING, 'appModuleVersion', None, None, ), # 3
- (4, TType.STRING, 'appModuleDescription', None, None, ), # 4
- )
-
- def __init__(self, appModuleId=thrift_spec[1][4], appModuleName=None, appModuleVersion=None, appModuleDescription=None,):
- self.appModuleId = appModuleId
- self.appModuleName = appModuleName
- self.appModuleVersion = appModuleVersion
- self.appModuleDescription = appModuleDescription
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.appModuleId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.appModuleName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.appModuleVersion = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.appModuleDescription = iprot.readString()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ApplicationModule')
- if self.appModuleId is not None:
- oprot.writeFieldBegin('appModuleId', TType.STRING, 1)
- oprot.writeString(self.appModuleId)
- oprot.writeFieldEnd()
- if self.appModuleName is not None:
- oprot.writeFieldBegin('appModuleName', TType.STRING, 2)
- oprot.writeString(self.appModuleName)
- oprot.writeFieldEnd()
- if self.appModuleVersion is not None:
- oprot.writeFieldBegin('appModuleVersion', TType.STRING, 3)
- oprot.writeString(self.appModuleVersion)
- oprot.writeFieldEnd()
- if self.appModuleDescription is not None:
- oprot.writeFieldBegin('appModuleDescription', TType.STRING, 4)
- oprot.writeString(self.appModuleDescription)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.appModuleId is None:
- raise TProtocol.TProtocolException(message='Required field appModuleId is unset!')
- if self.appModuleName is None:
- raise TProtocol.TProtocolException(message='Required field appModuleName is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.appModuleId)
- value = (value * 31) ^ hash(self.appModuleName)
- value = (value * 31) ^ hash(self.appModuleVersion)
- value = (value * 31) ^ hash(self.appModuleDescription)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class ApplicationDeploymentDescription:
- """
- Application Deployment Description
-
- appDeploymentId: Airavata Internal Unique Job ID. This is set by the registry.
-
- appModuleName:
- Application Module Name. This has to be precise describing the binary.
-
- computeHostId:
- This ID maps application deployment to a particular resource previously described within Airavata.
- Example: Stampede is first registered and refered when registering WRF.
-
- moduleLoadCmd:
- Command string to load modules. This will be placed in the job submisison
- Ex: module load amber
-
- libPrependPaths:
- prepend to a path variable the value
-
- libAppendPaths:
- append to a path variable the value
-
- setEnvironment:
- assigns to the environment variable "NAME" the value
-
-
- Attributes:
- - appDeploymentId
- - appModuleId
- - computeHostId
- - executablePath
- - parallelism
- - appDeploymentDescription
- - moduleLoadCmds
- - libPrependPaths
- - libAppendPaths
- - setEnvironment
- - preJobCommands
- - postJobCommands
- - defaultQueueName
- - defaultNodeCount
- - defaultCPUCount
- - defaultWalltime
- - editableByUser
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'appDeploymentId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.STRING, 'appModuleId', None, None, ), # 2
- (3, TType.STRING, 'computeHostId', None, None, ), # 3
- (4, TType.STRING, 'executablePath', None, None, ), # 4
- (5, TType.I32, 'parallelism', None, 0, ), # 5
- (6, TType.STRING, 'appDeploymentDescription', None, None, ), # 6
- (7, TType.LIST, 'moduleLoadCmds', (TType.STRUCT,(CommandObject, CommandObject.thrift_spec)), None, ), # 7
- (8, TType.LIST, 'libPrependPaths', (TType.STRUCT,(SetEnvPaths, SetEnvPaths.thrift_spec)), None, ), # 8
- (9, TType.LIST, 'libAppendPaths', (TType.STRUCT,(SetEnvPaths, SetEnvPaths.thrift_spec)), None, ), # 9
- (10, TType.LIST, 'setEnvironment', (TType.STRUCT,(SetEnvPaths, SetEnvPaths.thrift_spec)), None, ), # 10
- (11, TType.LIST, 'preJobCommands', (TType.STRUCT,(CommandObject, CommandObject.thrift_spec)), None, ), # 11
- (12, TType.LIST, 'postJobCommands', (TType.STRUCT,(CommandObject, CommandObject.thrift_spec)), None, ), # 12
- (13, TType.STRING, 'defaultQueueName', None, None, ), # 13
- (14, TType.I32, 'defaultNodeCount', None, None, ), # 14
- (15, TType.I32, 'defaultCPUCount', None, None, ), # 15
- (16, TType.I32, 'defaultWalltime', None, None, ), # 16
- (17, TType.BOOL, 'editableByUser', None, None, ), # 17
- )
-
- def __init__(self, appDeploymentId=thrift_spec[1][4], appModuleId=None, computeHostId=None, executablePath=None, parallelism=thrift_spec[5][4], appDeploymentDescription=None, moduleLoadCmds=None, libPrependPaths=None, libAppendPaths=None, setEnvironment=None, preJobCommands=None, postJobCommands=None, defaultQueueName=None, defaultNodeCount=None, defaultCPUCount=None, defaultWalltime=None, editableByUser=None,):
- self.appDeploymentId = appDeploymentId
- self.appModuleId = appModuleId
- self.computeHostId = computeHostId
- self.executablePath = executablePath
- self.parallelism = parallelism
- self.appDeploymentDescription = appDeploymentDescription
- self.moduleLoadCmds = moduleLoadCmds
- self.libPrependPaths = libPrependPaths
- self.libAppendPaths = libAppendPaths
- self.setEnvironment = setEnvironment
- self.preJobCommands = preJobCommands
- self.postJobCommands = postJobCommands
- self.defaultQueueName = defaultQueueName
- self.defaultNodeCount = defaultNodeCount
- self.defaultCPUCount = defaultCPUCount
- self.defaultWalltime = defaultWalltime
- self.editableByUser = editableByUser
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.appDeploymentId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.appModuleId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.computeHostId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.STRING:
- self.executablePath = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I32:
- self.parallelism = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.appDeploymentDescription = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.LIST:
- self.moduleLoadCmds = []
- (_etype3, _size0) = iprot.readListBegin()
- for _i4 in xrange(_size0):
- _elem5 = CommandObject()
- _elem5.read(iprot)
- self.moduleLoadCmds.append(_elem5)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.LIST:
- self.libPrependPaths = []
- (_etype9, _size6) = iprot.readListBegin()
- for _i10 in xrange(_size6):
- _elem11 = SetEnvPaths()
- _elem11.read(iprot)
- self.libPrependPaths.append(_elem11)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.LIST:
- self.libAppendPaths = []
- (_etype15, _size12) = iprot.readListBegin()
- for _i16 in xrange(_size12):
- _elem17 = SetEnvPaths()
- _elem17.read(iprot)
- self.libAppendPaths.append(_elem17)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.LIST:
- self.setEnvironment = []
- (_etype21, _size18) = iprot.readListBegin()
- for _i22 in xrange(_size18):
- _elem23 = SetEnvPaths()
- _elem23.read(iprot)
- self.setEnvironment.append(_elem23)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 11:
- if ftype == TType.LIST:
- self.preJobCommands = []
- (_etype27, _size24) = iprot.readListBegin()
- for _i28 in xrange(_size24):
- _elem29 = CommandObject()
- _elem29.read(iprot)
- self.preJobCommands.append(_elem29)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 12:
- if ftype == TType.LIST:
- self.postJobCommands = []
- (_etype33, _size30) = iprot.readListBegin()
- for _i34 in xrange(_size30):
- _elem35 = CommandObject()
- _elem35.read(iprot)
- self.postJobCommands.append(_elem35)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 13:
- if ftype == TType.STRING:
- self.defaultQueueName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 14:
- if ftype == TType.I32:
- self.defaultNodeCount = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 15:
- if ftype == TType.I32:
- self.defaultCPUCount = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 16:
- if ftype == TType.I32:
- self.defaultWalltime = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 17:
- if ftype == TType.BOOL:
- self.editableByUser = iprot.readBool()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ApplicationDeploymentDescription')
- if self.appDeploymentId is not None:
- oprot.writeFieldBegin('appDeploymentId', TType.STRING, 1)
- oprot.writeString(self.appDeploymentId)
- oprot.writeFieldEnd()
- if self.appModuleId is not None:
- oprot.writeFieldBegin('appModuleId', TType.STRING, 2)
- oprot.writeString(self.appModuleId)
- oprot.writeFieldEnd()
- if self.computeHostId is not None:
- oprot.writeFieldBegin('computeHostId', TType.STRING, 3)
- oprot.writeString(self.computeHostId)
- oprot.writeFieldEnd()
- if self.executablePath is not None:
- oprot.writeFieldBegin('executablePath', TType.STRING, 4)
- oprot.writeString(self.executablePath)
- oprot.writeFieldEnd()
- if self.parallelism is not None:
- oprot.writeFieldBegin('parallelism', TType.I32, 5)
- oprot.writeI32(self.parallelism)
- oprot.writeFieldEnd()
- if self.appDeploymentDescription is not None:
- oprot.writeFieldBegin('appDeploymentDescription', TType.STRING, 6)
- oprot.writeString(self.appDeploymentDescription)
- oprot.writeFieldEnd()
- if self.moduleLoadCmds is not None:
- oprot.writeFieldBegin('moduleLoadCmds', TType.LIST, 7)
- oprot.writeListBegin(TType.STRUCT, len(self.moduleLoadCmds))
- for iter36 in self.moduleLoadCmds:
- iter36.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.libPrependPaths is not None:
- oprot.writeFieldBegin('libPrependPaths', TType.LIST, 8)
- oprot.writeListBegin(TType.STRUCT, len(self.libPrependPaths))
- for iter37 in self.libPrependPaths:
- iter37.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.libAppendPaths is not None:
- oprot.writeFieldBegin('libAppendPaths', TType.LIST, 9)
- oprot.writeListBegin(TType.STRUCT, len(self.libAppendPaths))
- for iter38 in self.libAppendPaths:
- iter38.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.setEnvironment is not None:
- oprot.writeFieldBegin('setEnvironment', TType.LIST, 10)
- oprot.writeListBegin(TType.STRUCT, len(self.setEnvironment))
- for iter39 in self.setEnvironment:
- iter39.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.preJobCommands is not None:
- oprot.writeFieldBegin('preJobCommands', TType.LIST, 11)
- oprot.writeListBegin(TType.STRUCT, len(self.preJobCommands))
- for iter40 in self.preJobCommands:
- iter40.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.postJobCommands is not None:
- oprot.writeFieldBegin('postJobCommands', TType.LIST, 12)
- oprot.writeListBegin(TType.STRUCT, len(self.postJobCommands))
- for iter41 in self.postJobCommands:
- iter41.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.defaultQueueName is not None:
- oprot.writeFieldBegin('defaultQueueName', TType.STRING, 13)
- oprot.writeString(self.defaultQueueName)
- oprot.writeFieldEnd()
- if self.defaultNodeCount is not None:
- oprot.writeFieldBegin('defaultNodeCount', TType.I32, 14)
- oprot.writeI32(self.defaultNodeCount)
- oprot.writeFieldEnd()
- if self.defaultCPUCount is not None:
- oprot.writeFieldBegin('defaultCPUCount', TType.I32, 15)
- oprot.writeI32(self.defaultCPUCount)
- oprot.writeFieldEnd()
- if self.defaultWalltime is not None:
- oprot.writeFieldBegin('defaultWalltime', TType.I32, 16)
- oprot.writeI32(self.defaultWalltime)
- oprot.writeFieldEnd()
- if self.editableByUser is not None:
- oprot.writeFieldBegin('editableByUser', TType.BOOL, 17)
- oprot.writeBool(self.editableByUser)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.appDeploymentId is None:
- raise TProtocol.TProtocolException(message='Required field appDeploymentId is unset!')
- if self.appModuleId is None:
- raise TProtocol.TProtocolException(message='Required field appModuleId is unset!')
- if self.computeHostId is None:
- raise TProtocol.TProtocolException(message='Required field computeHostId is unset!')
- if self.executablePath is None:
- raise TProtocol.TProtocolException(message='Required field executablePath is unset!')
- if self.parallelism is None:
- raise TProtocol.TProtocolException(message='Required field parallelism is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.appDeploymentId)
- value = (value * 31) ^ hash(self.appModuleId)
- value = (value * 31) ^ hash(self.computeHostId)
- value = (value * 31) ^ hash(self.executablePath)
- value = (value * 31) ^ hash(self.parallelism)
- value = (value * 31) ^ hash(self.appDeploymentDescription)
- value = (value * 31) ^ hash(self.moduleLoadCmds)
- value = (value * 31) ^ hash(self.libPrependPaths)
- value = (value * 31) ^ hash(self.libAppendPaths)
- value = (value * 31) ^ hash(self.setEnvironment)
- value = (value * 31) ^ hash(self.preJobCommands)
- value = (value * 31) ^ hash(self.postJobCommands)
- value = (value * 31) ^ hash(self.defaultQueueName)
- value = (value * 31) ^ hash(self.defaultNodeCount)
- value = (value * 31) ^ hash(self.defaultCPUCount)
- value = (value * 31) ^ hash(self.defaultWalltime)
- value = (value * 31) ^ hash(self.editableByUser)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class SetEnvPaths(object):
+ """
+ Key Value pairs to be used to set environments
+
+ name:
+ Name of the environment variable such as PATH, LD_LIBRARY_PATH, NETCDF_HOME.
+
+ value:
+ Value of the environment variable to set
+
+ envPathOrder:
+ The order of the setting of the env variables when there are multiple env variables
+
+ Attributes:
+ - name
+ - value
+ - envPathOrder
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'name', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'value', 'UTF8', None, ), # 2
+ (3, TType.I32, 'envPathOrder', None, None, ), # 3
+ )
+
+ def __init__(self, name=None, value=None, envPathOrder=None,):
+ self.name = name
+ self.value = value
+ self.envPathOrder = envPathOrder
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.name = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.value = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I32:
+ self.envPathOrder = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('SetEnvPaths')
+ if self.name is not None:
+ oprot.writeFieldBegin('name', TType.STRING, 1)
+ oprot.writeString(self.name.encode('utf-8') if sys.version_info[0] == 2 else self.name)
+ oprot.writeFieldEnd()
+ if self.value is not None:
+ oprot.writeFieldBegin('value', TType.STRING, 2)
+ oprot.writeString(self.value.encode('utf-8') if sys.version_info[0] == 2 else self.value)
+ oprot.writeFieldEnd()
+ if self.envPathOrder is not None:
+ oprot.writeFieldBegin('envPathOrder', TType.I32, 3)
+ oprot.writeI32(self.envPathOrder)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.name is None:
+ raise TProtocolException(message='Required field name is unset!')
+ if self.value is None:
+ raise TProtocolException(message='Required field value is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class CommandObject(object):
+ """
+ Job commands to be used in Pre Job, Post Job and Module Load Commands
+
+ command:
+ The actual command in string format
+
+ commandOrder:
+ Order of the command in the multiple command situation
+
+ Attributes:
+ - command
+ - commandOrder
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'command', 'UTF8', None, ), # 1
+ (2, TType.I32, 'commandOrder', None, None, ), # 2
+ )
+
+ def __init__(self, command=None, commandOrder=None,):
+ self.command = command
+ self.commandOrder = commandOrder
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.command = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I32:
+ self.commandOrder = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('CommandObject')
+ if self.command is not None:
+ oprot.writeFieldBegin('command', TType.STRING, 1)
+ oprot.writeString(self.command.encode('utf-8') if sys.version_info[0] == 2 else self.command)
+ oprot.writeFieldEnd()
+ if self.commandOrder is not None:
+ oprot.writeFieldBegin('commandOrder', TType.I32, 2)
+ oprot.writeI32(self.commandOrder)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.command is None:
+ raise TProtocolException(message='Required field command is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class ApplicationModule(object):
+ """
+ Application Module Information. A module has to be registered before registering a deployment.
+
+ appModuleId: Airavata Internal Unique Job ID. This is set by the registry.
+
+ appModuleName:
+ Name of the application module.
+
+ appModuleVersion:
+ Version of the application.
+
+ appModuleDescription:
+ Descriprion of the Module
+
+
+ Attributes:
+ - appModuleId
+ - appModuleName
+ - appModuleVersion
+ - appModuleDescription
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'appModuleId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.STRING, 'appModuleName', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'appModuleVersion', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'appModuleDescription', 'UTF8', None, ), # 4
+ )
+
+ def __init__(self, appModuleId=thrift_spec[1][4], appModuleName=None, appModuleVersion=None, appModuleDescription=None,):
+ self.appModuleId = appModuleId
+ self.appModuleName = appModuleName
+ self.appModuleVersion = appModuleVersion
+ self.appModuleDescription = appModuleDescription
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.appModuleId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.appModuleName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.appModuleVersion = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.appModuleDescription = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ApplicationModule')
+ if self.appModuleId is not None:
+ oprot.writeFieldBegin('appModuleId', TType.STRING, 1)
+ oprot.writeString(self.appModuleId.encode('utf-8') if sys.version_info[0] == 2 else self.appModuleId)
+ oprot.writeFieldEnd()
+ if self.appModuleName is not None:
+ oprot.writeFieldBegin('appModuleName', TType.STRING, 2)
+ oprot.writeString(self.appModuleName.encode('utf-8') if sys.version_info[0] == 2 else self.appModuleName)
+ oprot.writeFieldEnd()
+ if self.appModuleVersion is not None:
+ oprot.writeFieldBegin('appModuleVersion', TType.STRING, 3)
+ oprot.writeString(self.appModuleVersion.encode('utf-8') if sys.version_info[0] == 2 else self.appModuleVersion)
+ oprot.writeFieldEnd()
+ if self.appModuleDescription is not None:
+ oprot.writeFieldBegin('appModuleDescription', TType.STRING, 4)
+ oprot.writeString(self.appModuleDescription.encode('utf-8') if sys.version_info[0] == 2 else self.appModuleDescription)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.appModuleId is None:
+ raise TProtocolException(message='Required field appModuleId is unset!')
+ if self.appModuleName is None:
+ raise TProtocolException(message='Required field appModuleName is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class ApplicationDeploymentDescription(object):
+ """
+ Application Deployment Description
+
+ appDeploymentId: Airavata Internal Unique Job ID. This is set by the registry.
+
+ appModuleName:
+ Application Module Name. This has to be precise describing the binary.
+
+ computeHostId:
+ This ID maps application deployment to a particular resource previously described within Airavata.
+ Example: Stampede is first registered and refered when registering WRF.
+
+ moduleLoadCmd:
+ Command string to load modules. This will be placed in the job submisison
+ Ex: module load amber
+
+ libPrependPaths:
+ prepend to a path variable the value
+
+ libAppendPaths:
+ append to a path variable the value
+
+ setEnvironment:
+ assigns to the environment variable "NAME" the value
+
+
+ Attributes:
+ - appDeploymentId
+ - appModuleId
+ - computeHostId
+ - executablePath
+ - parallelism
+ - appDeploymentDescription
+ - moduleLoadCmds
+ - libPrependPaths
+ - libAppendPaths
+ - setEnvironment
+ - preJobCommands
+ - postJobCommands
+ - defaultQueueName
+ - defaultNodeCount
+ - defaultCPUCount
+ - defaultWalltime
+ - editableByUser
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'appDeploymentId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.STRING, 'appModuleId', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'computeHostId', 'UTF8', None, ), # 3
+ (4, TType.STRING, 'executablePath', 'UTF8', None, ), # 4
+ (5, TType.I32, 'parallelism', None, 0, ), # 5
+ (6, TType.STRING, 'appDeploymentDescription', 'UTF8', None, ), # 6
+ (7, TType.LIST, 'moduleLoadCmds', (TType.STRUCT, (CommandObject, CommandObject.thrift_spec), False), None, ), # 7
+ (8, TType.LIST, 'libPrependPaths', (TType.STRUCT, (SetEnvPaths, SetEnvPaths.thrift_spec), False), None, ), # 8
+ (9, TType.LIST, 'libAppendPaths', (TType.STRUCT, (SetEnvPaths, SetEnvPaths.thrift_spec), False), None, ), # 9
+ (10, TType.LIST, 'setEnvironment', (TType.STRUCT, (SetEnvPaths, SetEnvPaths.thrift_spec), False), None, ), # 10
+ (11, TType.LIST, 'preJobCommands', (TType.STRUCT, (CommandObject, CommandObject.thrift_spec), False), None, ), # 11
+ (12, TType.LIST, 'postJobCommands', (TType.STRUCT, (CommandObject, CommandObject.thrift_spec), False), None, ), # 12
+ (13, TType.STRING, 'defaultQueueName', 'UTF8', None, ), # 13
+ (14, TType.I32, 'defaultNodeCount', None, None, ), # 14
+ (15, TType.I32, 'defaultCPUCount', None, None, ), # 15
+ (16, TType.I32, 'defaultWalltime', None, None, ), # 16
+ (17, TType.BOOL, 'editableByUser', None, None, ), # 17
+ )
+
+ def __init__(self, appDeploymentId=thrift_spec[1][4], appModuleId=None, computeHostId=None, executablePath=None, parallelism=thrift_spec[5][4], appDeploymentDescription=None, moduleLoadCmds=None, libPrependPaths=None, libAppendPaths=None, setEnvironment=None, preJobCommands=None, postJobCommands=None, defaultQueueName=None, defaultNodeCount=None, defaultCPUCount=None, defaultWalltime=None, editableByUser=None,):
+ self.appDeploymentId = appDeploymentId
+ self.appModuleId = appModuleId
+ self.computeHostId = computeHostId
+ self.executablePath = executablePath
+ self.parallelism = parallelism
+ self.appDeploymentDescription = appDeploymentDescription
+ self.moduleLoadCmds = moduleLoadCmds
+ self.libPrependPaths = libPrependPaths
+ self.libAppendPaths = libAppendPaths
+ self.setEnvironment = setEnvironment
+ self.preJobCommands = preJobCommands
+ self.postJobCommands = postJobCommands
+ self.defaultQueueName = defaultQueueName
+ self.defaultNodeCount = defaultNodeCount
+ self.defaultCPUCount = defaultCPUCount
+ self.defaultWalltime = defaultWalltime
+ self.editableByUser = editableByUser
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.appDeploymentId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.appModuleId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.computeHostId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.executablePath = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.I32:
+ self.parallelism = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.appDeploymentDescription = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.LIST:
+ self.moduleLoadCmds = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in range(_size0):
+ _elem5 = CommandObject()
+ _elem5.read(iprot)
+ self.moduleLoadCmds.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.LIST:
+ self.libPrependPaths = []
+ (_etype9, _size6) = iprot.readListBegin()
+ for _i10 in range(_size6):
+ _elem11 = SetEnvPaths()
+ _elem11.read(iprot)
+ self.libPrependPaths.append(_elem11)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.LIST:
+ self.libAppendPaths = []
+ (_etype15, _size12) = iprot.readListBegin()
+ for _i16 in range(_size12):
+ _elem17 = SetEnvPaths()
+ _elem17.read(iprot)
+ self.libAppendPaths.append(_elem17)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.LIST:
+ self.setEnvironment = []
+ (_etype21, _size18) = iprot.readListBegin()
+ for _i22 in range(_size18):
+ _elem23 = SetEnvPaths()
+ _elem23.read(iprot)
+ self.setEnvironment.append(_elem23)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 11:
+ if ftype == TType.LIST:
+ self.preJobCommands = []
+ (_etype27, _size24) = iprot.readListBegin()
+ for _i28 in range(_size24):
+ _elem29 = CommandObject()
+ _elem29.read(iprot)
+ self.preJobCommands.append(_elem29)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 12:
+ if ftype == TType.LIST:
+ self.postJobCommands = []
+ (_etype33, _size30) = iprot.readListBegin()
+ for _i34 in range(_size30):
+ _elem35 = CommandObject()
+ _elem35.read(iprot)
+ self.postJobCommands.append(_elem35)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 13:
+ if ftype == TType.STRING:
+ self.defaultQueueName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 14:
+ if ftype == TType.I32:
+ self.defaultNodeCount = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 15:
+ if ftype == TType.I32:
+ self.defaultCPUCount = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 16:
+ if ftype == TType.I32:
+ self.defaultWalltime = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 17:
+ if ftype == TType.BOOL:
+ self.editableByUser = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ApplicationDeploymentDescription')
+ if self.appDeploymentId is not None:
+ oprot.writeFieldBegin('appDeploymentId', TType.STRING, 1)
+ oprot.writeString(self.appDeploymentId.encode('utf-8') if sys.version_info[0] == 2 else self.appDeploymentId)
+ oprot.writeFieldEnd()
+ if self.appModuleId is not None:
+ oprot.writeFieldBegin('appModuleId', TType.STRING, 2)
+ oprot.writeString(self.appModuleId.encode('utf-8') if sys.version_info[0] == 2 else self.appModuleId)
+ oprot.writeFieldEnd()
+ if self.computeHostId is not None:
+ oprot.writeFieldBegin('computeHostId', TType.STRING, 3)
+ oprot.writeString(self.computeHostId.encode('utf-8') if sys.version_info[0] == 2 else self.computeHostId)
+ oprot.writeFieldEnd()
+ if self.executablePath is not None:
+ oprot.writeFieldBegin('executablePath', TType.STRING, 4)
+ oprot.writeString(self.executablePath.encode('utf-8') if sys.version_info[0] == 2 else self.executablePath)
+ oprot.writeFieldEnd()
+ if self.parallelism is not None:
+ oprot.writeFieldBegin('parallelism', TType.I32, 5)
+ oprot.writeI32(self.parallelism)
+ oprot.writeFieldEnd()
+ if self.appDeploymentDescription is not None:
+ oprot.writeFieldBegin('appDeploymentDescription', TType.STRING, 6)
+ oprot.writeString(self.appDeploymentDescription.encode('utf-8') if sys.version_info[0] == 2 else self.appDeploymentDescription)
+ oprot.writeFieldEnd()
+ if self.moduleLoadCmds is not None:
+ oprot.writeFieldBegin('moduleLoadCmds', TType.LIST, 7)
+ oprot.writeListBegin(TType.STRUCT, len(self.moduleLoadCmds))
+ for iter36 in self.moduleLoadCmds:
+ iter36.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.libPrependPaths is not None:
+ oprot.writeFieldBegin('libPrependPaths', TType.LIST, 8)
+ oprot.writeListBegin(TType.STRUCT, len(self.libPrependPaths))
+ for iter37 in self.libPrependPaths:
+ iter37.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.libAppendPaths is not None:
+ oprot.writeFieldBegin('libAppendPaths', TType.LIST, 9)
+ oprot.writeListBegin(TType.STRUCT, len(self.libAppendPaths))
+ for iter38 in self.libAppendPaths:
+ iter38.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.setEnvironment is not None:
+ oprot.writeFieldBegin('setEnvironment', TType.LIST, 10)
+ oprot.writeListBegin(TType.STRUCT, len(self.setEnvironment))
+ for iter39 in self.setEnvironment:
+ iter39.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.preJobCommands is not None:
+ oprot.writeFieldBegin('preJobCommands', TType.LIST, 11)
+ oprot.writeListBegin(TType.STRUCT, len(self.preJobCommands))
+ for iter40 in self.preJobCommands:
+ iter40.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.postJobCommands is not None:
+ oprot.writeFieldBegin('postJobCommands', TType.LIST, 12)
+ oprot.writeListBegin(TType.STRUCT, len(self.postJobCommands))
+ for iter41 in self.postJobCommands:
+ iter41.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.defaultQueueName is not None:
+ oprot.writeFieldBegin('defaultQueueName', TType.STRING, 13)
+ oprot.writeString(self.defaultQueueName.encode('utf-8') if sys.version_info[0] == 2 else self.defaultQueueName)
+ oprot.writeFieldEnd()
+ if self.defaultNodeCount is not None:
+ oprot.writeFieldBegin('defaultNodeCount', TType.I32, 14)
+ oprot.writeI32(self.defaultNodeCount)
+ oprot.writeFieldEnd()
+ if self.defaultCPUCount is not None:
+ oprot.writeFieldBegin('defaultCPUCount', TType.I32, 15)
+ oprot.writeI32(self.defaultCPUCount)
+ oprot.writeFieldEnd()
+ if self.defaultWalltime is not None:
+ oprot.writeFieldBegin('defaultWalltime', TType.I32, 16)
+ oprot.writeI32(self.defaultWalltime)
+ oprot.writeFieldEnd()
+ if self.editableByUser is not None:
+ oprot.writeFieldBegin('editableByUser', TType.BOOL, 17)
+ oprot.writeBool(self.editableByUser)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.appDeploymentId is None:
+ raise TProtocolException(message='Required field appDeploymentId is unset!')
+ if self.appModuleId is None:
+ raise TProtocolException(message='Required field appModuleId is unset!')
+ if self.computeHostId is None:
+ raise TProtocolException(message='Required field computeHostId is unset!')
+ if self.executablePath is None:
+ raise TProtocolException(message='Required field executablePath is unset!')
+ if self.parallelism is None:
+ raise TProtocolException(message='Required field parallelism is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appinterface/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appinterface/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appinterface/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appinterface/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appinterface/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appinterface/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appinterface/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appinterface/ttypes.py
index 757058a..b7cfd58 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appinterface/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/appinterface/ttypes.py
@@ -1,219 +1,201 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.application.io.ttypes
import apache.airavata.model.commons.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-
-class ApplicationInterfaceDescription:
- """
- Application Interface Description
-
- applicationModules:
- Associate all application modules with versions which interface is applicable to.
-
- applicationInputs:
- Inputs to be passed to the application
-
- applicationOutputs:
- Outputs generated from the application
-
-
- Attributes:
- - applicationInterfaceId
- - applicationName
- - applicationDescription
- - applicationModules
- - applicationInputs
- - applicationOutputs
- - archiveWorkingDirectory
- - hasOptionalFileInputs
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'applicationInterfaceId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.STRING, 'applicationName', None, None, ), # 2
- (3, TType.STRING, 'applicationDescription', None, None, ), # 3
- (4, TType.LIST, 'applicationModules', (TType.STRING,None), None, ), # 4
- (5, TType.LIST, 'applicationInputs', (TType.STRUCT,(apache.airavata.model.application.io.ttypes.InputDataObjectType, apache.airavata.model.application.io.ttypes.InputDataObjectType.thrift_spec)), None, ), # 5
- (6, TType.LIST, 'applicationOutputs', (TType.STRUCT,(apache.airavata.model.application.io.ttypes.OutputDataObjectType, apache.airavata.model.application.io.ttypes.OutputDataObjectType.thrift_spec)), None, ), # 6
- (7, TType.BOOL, 'archiveWorkingDirectory', None, False, ), # 7
- (8, TType.BOOL, 'hasOptionalFileInputs', None, None, ), # 8
- )
-
- def __init__(self, applicationInterfaceId=thrift_spec[1][4], applicationName=None, applicationDescription=None, applicationModules=None, applicationInputs=None, applicationOutputs=None, archiveWorkingDirectory=thrift_spec[7][4], hasOptionalFileInputs=None,):
- self.applicationInterfaceId = applicationInterfaceId
- self.applicationName = applicationName
- self.applicationDescription = applicationDescription
- self.applicationModules = applicationModules
- self.applicationInputs = applicationInputs
- self.applicationOutputs = applicationOutputs
- self.archiveWorkingDirectory = archiveWorkingDirectory
- self.hasOptionalFileInputs = hasOptionalFileInputs
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.applicationInterfaceId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.applicationName = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.applicationDescription = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.LIST:
- self.applicationModules = []
- (_etype3, _size0) = iprot.readListBegin()
- for _i4 in xrange(_size0):
- _elem5 = iprot.readString()
- self.applicationModules.append(_elem5)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.LIST:
- self.applicationInputs = []
- (_etype9, _size6) = iprot.readListBegin()
- for _i10 in xrange(_size6):
- _elem11 = apache.airavata.model.application.io.ttypes.InputDataObjectType()
- _elem11.read(iprot)
- self.applicationInputs.append(_elem11)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.LIST:
- self.applicationOutputs = []
- (_etype15, _size12) = iprot.readListBegin()
- for _i16 in xrange(_size12):
- _elem17 = apache.airavata.model.application.io.ttypes.OutputDataObjectType()
- _elem17.read(iprot)
- self.applicationOutputs.append(_elem17)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.BOOL:
- self.archiveWorkingDirectory = iprot.readBool()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.BOOL:
- self.hasOptionalFileInputs = iprot.readBool()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('ApplicationInterfaceDescription')
- if self.applicationInterfaceId is not None:
- oprot.writeFieldBegin('applicationInterfaceId', TType.STRING, 1)
- oprot.writeString(self.applicationInterfaceId)
- oprot.writeFieldEnd()
- if self.applicationName is not None:
- oprot.writeFieldBegin('applicationName', TType.STRING, 2)
- oprot.writeString(self.applicationName)
- oprot.writeFieldEnd()
- if self.applicationDescription is not None:
- oprot.writeFieldBegin('applicationDescription', TType.STRING, 3)
- oprot.writeString(self.applicationDescription)
- oprot.writeFieldEnd()
- if self.applicationModules is not None:
- oprot.writeFieldBegin('applicationModules', TType.LIST, 4)
- oprot.writeListBegin(TType.STRING, len(self.applicationModules))
- for iter18 in self.applicationModules:
- oprot.writeString(iter18)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.applicationInputs is not None:
- oprot.writeFieldBegin('applicationInputs', TType.LIST, 5)
- oprot.writeListBegin(TType.STRUCT, len(self.applicationInputs))
- for iter19 in self.applicationInputs:
- iter19.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.applicationOutputs is not None:
- oprot.writeFieldBegin('applicationOutputs', TType.LIST, 6)
- oprot.writeListBegin(TType.STRUCT, len(self.applicationOutputs))
- for iter20 in self.applicationOutputs:
- iter20.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.archiveWorkingDirectory is not None:
- oprot.writeFieldBegin('archiveWorkingDirectory', TType.BOOL, 7)
- oprot.writeBool(self.archiveWorkingDirectory)
- oprot.writeFieldEnd()
- if self.hasOptionalFileInputs is not None:
- oprot.writeFieldBegin('hasOptionalFileInputs', TType.BOOL, 8)
- oprot.writeBool(self.hasOptionalFileInputs)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.applicationInterfaceId is None:
- raise TProtocol.TProtocolException(message='Required field applicationInterfaceId is unset!')
- if self.applicationName is None:
- raise TProtocol.TProtocolException(message='Required field applicationName is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.applicationInterfaceId)
- value = (value * 31) ^ hash(self.applicationName)
- value = (value * 31) ^ hash(self.applicationDescription)
- value = (value * 31) ^ hash(self.applicationModules)
- value = (value * 31) ^ hash(self.applicationInputs)
- value = (value * 31) ^ hash(self.applicationOutputs)
- value = (value * 31) ^ hash(self.archiveWorkingDirectory)
- value = (value * 31) ^ hash(self.hasOptionalFileInputs)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class ApplicationInterfaceDescription(object):
+ """
+ Application Interface Description
+
+ applicationModules:
+ Associate all application modules with versions which interface is applicable to.
+
+ applicationInputs:
+ Inputs to be passed to the application
+
+ applicationOutputs:
+ Outputs generated from the application
+
+
+ Attributes:
+ - applicationInterfaceId
+ - applicationName
+ - applicationDescription
+ - applicationModules
+ - applicationInputs
+ - applicationOutputs
+ - archiveWorkingDirectory
+ - hasOptionalFileInputs
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'applicationInterfaceId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.STRING, 'applicationName', 'UTF8', None, ), # 2
+ (3, TType.STRING, 'applicationDescription', 'UTF8', None, ), # 3
+ (4, TType.LIST, 'applicationModules', (TType.STRING, 'UTF8', False), None, ), # 4
+ (5, TType.LIST, 'applicationInputs', (TType.STRUCT, (apache.airavata.model.application.io.ttypes.InputDataObjectType, apache.airavata.model.application.io.ttypes.InputDataObjectType.thrift_spec), False), None, ), # 5
+ (6, TType.LIST, 'applicationOutputs', (TType.STRUCT, (apache.airavata.model.application.io.ttypes.OutputDataObjectType, apache.airavata.model.application.io.ttypes.OutputDataObjectType.thrift_spec), False), None, ), # 6
+ (7, TType.BOOL, 'archiveWorkingDirectory', None, False, ), # 7
+ (8, TType.BOOL, 'hasOptionalFileInputs', None, None, ), # 8
+ )
+
+ def __init__(self, applicationInterfaceId=thrift_spec[1][4], applicationName=None, applicationDescription=None, applicationModules=None, applicationInputs=None, applicationOutputs=None, archiveWorkingDirectory=thrift_spec[7][4], hasOptionalFileInputs=None,):
+ self.applicationInterfaceId = applicationInterfaceId
+ self.applicationName = applicationName
+ self.applicationDescription = applicationDescription
+ self.applicationModules = applicationModules
+ self.applicationInputs = applicationInputs
+ self.applicationOutputs = applicationOutputs
+ self.archiveWorkingDirectory = archiveWorkingDirectory
+ self.hasOptionalFileInputs = hasOptionalFileInputs
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.applicationInterfaceId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.applicationName = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.applicationDescription = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.LIST:
+ self.applicationModules = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in range(_size0):
+ _elem5 = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ self.applicationModules.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.LIST:
+ self.applicationInputs = []
+ (_etype9, _size6) = iprot.readListBegin()
+ for _i10 in range(_size6):
+ _elem11 = apache.airavata.model.application.io.ttypes.InputDataObjectType()
+ _elem11.read(iprot)
+ self.applicationInputs.append(_elem11)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.LIST:
+ self.applicationOutputs = []
+ (_etype15, _size12) = iprot.readListBegin()
+ for _i16 in range(_size12):
+ _elem17 = apache.airavata.model.application.io.ttypes.OutputDataObjectType()
+ _elem17.read(iprot)
+ self.applicationOutputs.append(_elem17)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.BOOL:
+ self.archiveWorkingDirectory = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.BOOL:
+ self.hasOptionalFileInputs = iprot.readBool()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('ApplicationInterfaceDescription')
+ if self.applicationInterfaceId is not None:
+ oprot.writeFieldBegin('applicationInterfaceId', TType.STRING, 1)
+ oprot.writeString(self.applicationInterfaceId.encode('utf-8') if sys.version_info[0] == 2 else self.applicationInterfaceId)
+ oprot.writeFieldEnd()
+ if self.applicationName is not None:
+ oprot.writeFieldBegin('applicationName', TType.STRING, 2)
+ oprot.writeString(self.applicationName.encode('utf-8') if sys.version_info[0] == 2 else self.applicationName)
+ oprot.writeFieldEnd()
+ if self.applicationDescription is not None:
+ oprot.writeFieldBegin('applicationDescription', TType.STRING, 3)
+ oprot.writeString(self.applicationDescription.encode('utf-8') if sys.version_info[0] == 2 else self.applicationDescription)
+ oprot.writeFieldEnd()
+ if self.applicationModules is not None:
+ oprot.writeFieldBegin('applicationModules', TType.LIST, 4)
+ oprot.writeListBegin(TType.STRING, len(self.applicationModules))
+ for iter18 in self.applicationModules:
+ oprot.writeString(iter18.encode('utf-8') if sys.version_info[0] == 2 else iter18)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.applicationInputs is not None:
+ oprot.writeFieldBegin('applicationInputs', TType.LIST, 5)
+ oprot.writeListBegin(TType.STRUCT, len(self.applicationInputs))
+ for iter19 in self.applicationInputs:
+ iter19.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.applicationOutputs is not None:
+ oprot.writeFieldBegin('applicationOutputs', TType.LIST, 6)
+ oprot.writeListBegin(TType.STRUCT, len(self.applicationOutputs))
+ for iter20 in self.applicationOutputs:
+ iter20.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.archiveWorkingDirectory is not None:
+ oprot.writeFieldBegin('archiveWorkingDirectory', TType.BOOL, 7)
+ oprot.writeBool(self.archiveWorkingDirectory)
+ oprot.writeFieldEnd()
+ if self.hasOptionalFileInputs is not None:
+ oprot.writeFieldBegin('hasOptionalFileInputs', TType.BOOL, 8)
+ oprot.writeBool(self.hasOptionalFileInputs)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.applicationInterfaceId is None:
+ raise TProtocolException(message='Required field applicationInterfaceId is unset!')
+ if self.applicationName is None:
+ raise TProtocolException(message='Required field applicationName is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/computeresource/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/computeresource/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/computeresource/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/computeresource/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/appcatalog/computeresource/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *
[31/51] [partial] airavata git commit: AIRAVATA-2505 Upgrade Airavata
to Thrift 0.10.0
Posted by ma...@apache.org.
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/task/ttypes.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/task/ttypes.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/task/ttypes.py
index 213598b..0163b1f 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/task/ttypes.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/task/ttypes.py
@@ -1,12 +1,14 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
import apache.airavata.model.commons.ttypes
import apache.airavata.model.appcatalog.computeresource.ttypes
import apache.airavata.model.data.movement.ttypes
@@ -14,706 +16,656 @@ import apache.airavata.model.application.io.ttypes
import apache.airavata.model.status.ttypes
import apache.airavata.model.job.ttypes
-
from thrift.transport import TTransport
-from thrift.protocol import TBinaryProtocol, TProtocol
-try:
- from thrift.protocol import fastbinary
-except:
- fastbinary = None
-
-
-class TaskTypes:
- """
- TaskTypes: An enumerated list of TaskTypes. Task being generic, the task type will provide the concrete interpretation.
-
- """
- ENV_SETUP = 0
- DATA_STAGING = 1
- JOB_SUBMISSION = 2
- ENV_CLEANUP = 3
- MONITORING = 4
- OUTPUT_FETCHING = 5
-
- _VALUES_TO_NAMES = {
- 0: "ENV_SETUP",
- 1: "DATA_STAGING",
- 2: "JOB_SUBMISSION",
- 3: "ENV_CLEANUP",
- 4: "MONITORING",
- 5: "OUTPUT_FETCHING",
- }
-
- _NAMES_TO_VALUES = {
- "ENV_SETUP": 0,
- "DATA_STAGING": 1,
- "JOB_SUBMISSION": 2,
- "ENV_CLEANUP": 3,
- "MONITORING": 4,
- "OUTPUT_FETCHING": 5,
- }
-
-class DataStageType:
- """
- DataStagingTaskModel: A structure holding the data staging task details.
-
- Source and Destination locations includes standard representation of protocol, host, port and path
- A friendly description of the task, usally used to communicate information to users.
-
- """
- INPUT = 0
- OUPUT = 1
- ARCHIVE_OUTPUT = 2
-
- _VALUES_TO_NAMES = {
- 0: "INPUT",
- 1: "OUPUT",
- 2: "ARCHIVE_OUTPUT",
- }
-
- _NAMES_TO_VALUES = {
- "INPUT": 0,
- "OUPUT": 1,
- "ARCHIVE_OUTPUT": 2,
- }
-
-
-class TaskModel:
- """
- TaskModel: A structure holding the generic task details.
-
- taskDetail:
- A friendly description of the task, usally used to communicate information to users.
-
- subTaskModel:
- A generic byte object for the Task developer to store internal serialized data into registry catalogs.
-
- Attributes:
- - taskId
- - taskType
- - parentProcessId
- - creationTime
- - lastUpdateTime
- - taskStatuses
- - taskDetail
- - subTaskModel
- - taskErrors
- - jobs
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'taskId', None, "DO_NOT_SET_AT_CLIENTS", ), # 1
- (2, TType.I32, 'taskType', None, None, ), # 2
- (3, TType.STRING, 'parentProcessId', None, None, ), # 3
- (4, TType.I64, 'creationTime', None, None, ), # 4
- (5, TType.I64, 'lastUpdateTime', None, None, ), # 5
- (6, TType.LIST, 'taskStatuses', (TType.STRUCT,(apache.airavata.model.status.ttypes.TaskStatus, apache.airavata.model.status.ttypes.TaskStatus.thrift_spec)), None, ), # 6
- (7, TType.STRING, 'taskDetail', None, None, ), # 7
- (8, TType.STRING, 'subTaskModel', None, None, ), # 8
- (9, TType.LIST, 'taskErrors', (TType.STRUCT,(apache.airavata.model.commons.ttypes.ErrorModel, apache.airavata.model.commons.ttypes.ErrorModel.thrift_spec)), None, ), # 9
- (10, TType.LIST, 'jobs', (TType.STRUCT,(apache.airavata.model.job.ttypes.JobModel, apache.airavata.model.job.ttypes.JobModel.thrift_spec)), None, ), # 10
- )
-
- def __init__(self, taskId=thrift_spec[1][4], taskType=None, parentProcessId=None, creationTime=None, lastUpdateTime=None, taskStatuses=None, taskDetail=None, subTaskModel=None, taskErrors=None, jobs=None,):
- self.taskId = taskId
- self.taskType = taskType
- self.parentProcessId = parentProcessId
- self.creationTime = creationTime
- self.lastUpdateTime = lastUpdateTime
- self.taskStatuses = taskStatuses
- self.taskDetail = taskDetail
- self.subTaskModel = subTaskModel
- self.taskErrors = taskErrors
- self.jobs = jobs
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.taskId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.taskType = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.STRING:
- self.parentProcessId = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.I64:
- self.creationTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I64:
- self.lastUpdateTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.LIST:
- self.taskStatuses = []
- (_etype3, _size0) = iprot.readListBegin()
- for _i4 in xrange(_size0):
- _elem5 = apache.airavata.model.status.ttypes.TaskStatus()
- _elem5.read(iprot)
- self.taskStatuses.append(_elem5)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.STRING:
- self.taskDetail = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.STRING:
- self.subTaskModel = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 9:
- if ftype == TType.LIST:
- self.taskErrors = []
- (_etype9, _size6) = iprot.readListBegin()
- for _i10 in xrange(_size6):
- _elem11 = apache.airavata.model.commons.ttypes.ErrorModel()
- _elem11.read(iprot)
- self.taskErrors.append(_elem11)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- elif fid == 10:
- if ftype == TType.LIST:
- self.jobs = []
- (_etype15, _size12) = iprot.readListBegin()
- for _i16 in xrange(_size12):
- _elem17 = apache.airavata.model.job.ttypes.JobModel()
- _elem17.read(iprot)
- self.jobs.append(_elem17)
- iprot.readListEnd()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('TaskModel')
- if self.taskId is not None:
- oprot.writeFieldBegin('taskId', TType.STRING, 1)
- oprot.writeString(self.taskId)
- oprot.writeFieldEnd()
- if self.taskType is not None:
- oprot.writeFieldBegin('taskType', TType.I32, 2)
- oprot.writeI32(self.taskType)
- oprot.writeFieldEnd()
- if self.parentProcessId is not None:
- oprot.writeFieldBegin('parentProcessId', TType.STRING, 3)
- oprot.writeString(self.parentProcessId)
- oprot.writeFieldEnd()
- if self.creationTime is not None:
- oprot.writeFieldBegin('creationTime', TType.I64, 4)
- oprot.writeI64(self.creationTime)
- oprot.writeFieldEnd()
- if self.lastUpdateTime is not None:
- oprot.writeFieldBegin('lastUpdateTime', TType.I64, 5)
- oprot.writeI64(self.lastUpdateTime)
- oprot.writeFieldEnd()
- if self.taskStatuses is not None:
- oprot.writeFieldBegin('taskStatuses', TType.LIST, 6)
- oprot.writeListBegin(TType.STRUCT, len(self.taskStatuses))
- for iter18 in self.taskStatuses:
- iter18.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.taskDetail is not None:
- oprot.writeFieldBegin('taskDetail', TType.STRING, 7)
- oprot.writeString(self.taskDetail)
- oprot.writeFieldEnd()
- if self.subTaskModel is not None:
- oprot.writeFieldBegin('subTaskModel', TType.STRING, 8)
- oprot.writeString(self.subTaskModel)
- oprot.writeFieldEnd()
- if self.taskErrors is not None:
- oprot.writeFieldBegin('taskErrors', TType.LIST, 9)
- oprot.writeListBegin(TType.STRUCT, len(self.taskErrors))
- for iter19 in self.taskErrors:
- iter19.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- if self.jobs is not None:
- oprot.writeFieldBegin('jobs', TType.LIST, 10)
- oprot.writeListBegin(TType.STRUCT, len(self.jobs))
- for iter20 in self.jobs:
- iter20.write(oprot)
- oprot.writeListEnd()
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.taskId is None:
- raise TProtocol.TProtocolException(message='Required field taskId is unset!')
- if self.taskType is None:
- raise TProtocol.TProtocolException(message='Required field taskType is unset!')
- if self.parentProcessId is None:
- raise TProtocol.TProtocolException(message='Required field parentProcessId is unset!')
- if self.creationTime is None:
- raise TProtocol.TProtocolException(message='Required field creationTime is unset!')
- if self.lastUpdateTime is None:
- raise TProtocol.TProtocolException(message='Required field lastUpdateTime is unset!')
- if self.taskStatuses is None:
- raise TProtocol.TProtocolException(message='Required field taskStatuses is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.taskId)
- value = (value * 31) ^ hash(self.taskType)
- value = (value * 31) ^ hash(self.parentProcessId)
- value = (value * 31) ^ hash(self.creationTime)
- value = (value * 31) ^ hash(self.lastUpdateTime)
- value = (value * 31) ^ hash(self.taskStatuses)
- value = (value * 31) ^ hash(self.taskDetail)
- value = (value * 31) ^ hash(self.subTaskModel)
- value = (value * 31) ^ hash(self.taskErrors)
- value = (value * 31) ^ hash(self.jobs)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class DataStagingTaskModel:
- """
- Attributes:
- - source
- - destination
- - type
- - transferStartTime
- - transferEndTime
- - transferRate
- - processInput
- - processOutput
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'source', None, None, ), # 1
- (2, TType.STRING, 'destination', None, None, ), # 2
- (3, TType.I32, 'type', None, None, ), # 3
- (4, TType.I64, 'transferStartTime', None, None, ), # 4
- (5, TType.I64, 'transferEndTime', None, None, ), # 5
- (6, TType.STRING, 'transferRate', None, None, ), # 6
- (7, TType.STRUCT, 'processInput', (apache.airavata.model.application.io.ttypes.InputDataObjectType, apache.airavata.model.application.io.ttypes.InputDataObjectType.thrift_spec), None, ), # 7
- (8, TType.STRUCT, 'processOutput', (apache.airavata.model.application.io.ttypes.OutputDataObjectType, apache.airavata.model.application.io.ttypes.OutputDataObjectType.thrift_spec), None, ), # 8
- )
-
- def __init__(self, source=None, destination=None, type=None, transferStartTime=None, transferEndTime=None, transferRate=None, processInput=None, processOutput=None,):
- self.source = source
- self.destination = destination
- self.type = type
- self.transferStartTime = transferStartTime
- self.transferEndTime = transferEndTime
- self.transferRate = transferRate
- self.processInput = processInput
- self.processOutput = processOutput
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.source = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.STRING:
- self.destination = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.I32:
- self.type = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 4:
- if ftype == TType.I64:
- self.transferStartTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 5:
- if ftype == TType.I64:
- self.transferEndTime = iprot.readI64()
- else:
- iprot.skip(ftype)
- elif fid == 6:
- if ftype == TType.STRING:
- self.transferRate = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 7:
- if ftype == TType.STRUCT:
- self.processInput = apache.airavata.model.application.io.ttypes.InputDataObjectType()
- self.processInput.read(iprot)
- else:
- iprot.skip(ftype)
- elif fid == 8:
- if ftype == TType.STRUCT:
- self.processOutput = apache.airavata.model.application.io.ttypes.OutputDataObjectType()
- self.processOutput.read(iprot)
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('DataStagingTaskModel')
- if self.source is not None:
- oprot.writeFieldBegin('source', TType.STRING, 1)
- oprot.writeString(self.source)
- oprot.writeFieldEnd()
- if self.destination is not None:
- oprot.writeFieldBegin('destination', TType.STRING, 2)
- oprot.writeString(self.destination)
- oprot.writeFieldEnd()
- if self.type is not None:
- oprot.writeFieldBegin('type', TType.I32, 3)
- oprot.writeI32(self.type)
- oprot.writeFieldEnd()
- if self.transferStartTime is not None:
- oprot.writeFieldBegin('transferStartTime', TType.I64, 4)
- oprot.writeI64(self.transferStartTime)
- oprot.writeFieldEnd()
- if self.transferEndTime is not None:
- oprot.writeFieldBegin('transferEndTime', TType.I64, 5)
- oprot.writeI64(self.transferEndTime)
- oprot.writeFieldEnd()
- if self.transferRate is not None:
- oprot.writeFieldBegin('transferRate', TType.STRING, 6)
- oprot.writeString(self.transferRate)
- oprot.writeFieldEnd()
- if self.processInput is not None:
- oprot.writeFieldBegin('processInput', TType.STRUCT, 7)
- self.processInput.write(oprot)
- oprot.writeFieldEnd()
- if self.processOutput is not None:
- oprot.writeFieldBegin('processOutput', TType.STRUCT, 8)
- self.processOutput.write(oprot)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.source is None:
- raise TProtocol.TProtocolException(message='Required field source is unset!')
- if self.destination is None:
- raise TProtocol.TProtocolException(message='Required field destination is unset!')
- if self.type is None:
- raise TProtocol.TProtocolException(message='Required field type is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.source)
- value = (value * 31) ^ hash(self.destination)
- value = (value * 31) ^ hash(self.type)
- value = (value * 31) ^ hash(self.transferStartTime)
- value = (value * 31) ^ hash(self.transferEndTime)
- value = (value * 31) ^ hash(self.transferRate)
- value = (value * 31) ^ hash(self.processInput)
- value = (value * 31) ^ hash(self.processOutput)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class EnvironmentSetupTaskModel:
- """
- EnvironmentSetupTaskModel: A structure holding the environment creation task details
-
-
- Attributes:
- - location
- - protocol
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.STRING, 'location', None, None, ), # 1
- (2, TType.I32, 'protocol', None, None, ), # 2
- )
-
- def __init__(self, location=None, protocol=None,):
- self.location = location
- self.protocol = protocol
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.STRING:
- self.location = iprot.readString()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.protocol = iprot.readI32()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('EnvironmentSetupTaskModel')
- if self.location is not None:
- oprot.writeFieldBegin('location', TType.STRING, 1)
- oprot.writeString(self.location)
- oprot.writeFieldEnd()
- if self.protocol is not None:
- oprot.writeFieldBegin('protocol', TType.I32, 2)
- oprot.writeI32(self.protocol)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.location is None:
- raise TProtocol.TProtocolException(message='Required field location is unset!')
- if self.protocol is None:
- raise TProtocol.TProtocolException(message='Required field protocol is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.location)
- value = (value * 31) ^ hash(self.protocol)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class JobSubmissionTaskModel:
- """
- Attributes:
- - jobSubmissionProtocol
- - monitorMode
- - wallTime
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'jobSubmissionProtocol', None, None, ), # 1
- (2, TType.I32, 'monitorMode', None, None, ), # 2
- (3, TType.I32, 'wallTime', None, None, ), # 3
- )
-
- def __init__(self, jobSubmissionProtocol=None, monitorMode=None, wallTime=None,):
- self.jobSubmissionProtocol = jobSubmissionProtocol
- self.monitorMode = monitorMode
- self.wallTime = wallTime
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.jobSubmissionProtocol = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 2:
- if ftype == TType.I32:
- self.monitorMode = iprot.readI32()
- else:
- iprot.skip(ftype)
- elif fid == 3:
- if ftype == TType.I32:
- self.wallTime = iprot.readI32()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('JobSubmissionTaskModel')
- if self.jobSubmissionProtocol is not None:
- oprot.writeFieldBegin('jobSubmissionProtocol', TType.I32, 1)
- oprot.writeI32(self.jobSubmissionProtocol)
- oprot.writeFieldEnd()
- if self.monitorMode is not None:
- oprot.writeFieldBegin('monitorMode', TType.I32, 2)
- oprot.writeI32(self.monitorMode)
- oprot.writeFieldEnd()
- if self.wallTime is not None:
- oprot.writeFieldBegin('wallTime', TType.I32, 3)
- oprot.writeI32(self.wallTime)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.jobSubmissionProtocol is None:
- raise TProtocol.TProtocolException(message='Required field jobSubmissionProtocol is unset!')
- if self.monitorMode is None:
- raise TProtocol.TProtocolException(message='Required field monitorMode is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.jobSubmissionProtocol)
- value = (value * 31) ^ hash(self.monitorMode)
- value = (value * 31) ^ hash(self.wallTime)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
-
-class MonitorTaskModel:
- """
- Attributes:
- - monitorMode
- """
-
- thrift_spec = (
- None, # 0
- (1, TType.I32, 'monitorMode', None, None, ), # 1
- )
-
- def __init__(self, monitorMode=None,):
- self.monitorMode = monitorMode
-
- def read(self, iprot):
- if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
- fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
- return
- iprot.readStructBegin()
- while True:
- (fname, ftype, fid) = iprot.readFieldBegin()
- if ftype == TType.STOP:
- break
- if fid == 1:
- if ftype == TType.I32:
- self.monitorMode = iprot.readI32()
- else:
- iprot.skip(ftype)
- else:
- iprot.skip(ftype)
- iprot.readFieldEnd()
- iprot.readStructEnd()
-
- def write(self, oprot):
- if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
- oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
- return
- oprot.writeStructBegin('MonitorTaskModel')
- if self.monitorMode is not None:
- oprot.writeFieldBegin('monitorMode', TType.I32, 1)
- oprot.writeI32(self.monitorMode)
- oprot.writeFieldEnd()
- oprot.writeFieldStop()
- oprot.writeStructEnd()
-
- def validate(self):
- if self.monitorMode is None:
- raise TProtocol.TProtocolException(message='Required field monitorMode is unset!')
- return
-
-
- def __hash__(self):
- value = 17
- value = (value * 31) ^ hash(self.monitorMode)
- return value
-
- def __repr__(self):
- L = ['%s=%r' % (key, value)
- for key, value in self.__dict__.iteritems()]
- return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
-
- def __eq__(self, other):
- return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
-
- def __ne__(self, other):
- return not (self == other)
+
+
+class TaskTypes(object):
+ """
+ TaskTypes: An enumerated list of TaskTypes. Task being generic, the task type will provide the concrete interpretation.
+
+ """
+ ENV_SETUP = 0
+ DATA_STAGING = 1
+ JOB_SUBMISSION = 2
+ ENV_CLEANUP = 3
+ MONITORING = 4
+ OUTPUT_FETCHING = 5
+
+ _VALUES_TO_NAMES = {
+ 0: "ENV_SETUP",
+ 1: "DATA_STAGING",
+ 2: "JOB_SUBMISSION",
+ 3: "ENV_CLEANUP",
+ 4: "MONITORING",
+ 5: "OUTPUT_FETCHING",
+ }
+
+ _NAMES_TO_VALUES = {
+ "ENV_SETUP": 0,
+ "DATA_STAGING": 1,
+ "JOB_SUBMISSION": 2,
+ "ENV_CLEANUP": 3,
+ "MONITORING": 4,
+ "OUTPUT_FETCHING": 5,
+ }
+
+
+class DataStageType(object):
+ """
+ DataStagingTaskModel: A structure holding the data staging task details.
+
+ Source and Destination locations includes standard representation of protocol, host, port and path
+ A friendly description of the task, usally used to communicate information to users.
+
+ """
+ INPUT = 0
+ OUPUT = 1
+ ARCHIVE_OUTPUT = 2
+
+ _VALUES_TO_NAMES = {
+ 0: "INPUT",
+ 1: "OUPUT",
+ 2: "ARCHIVE_OUTPUT",
+ }
+
+ _NAMES_TO_VALUES = {
+ "INPUT": 0,
+ "OUPUT": 1,
+ "ARCHIVE_OUTPUT": 2,
+ }
+
+
+class TaskModel(object):
+ """
+ TaskModel: A structure holding the generic task details.
+
+ taskDetail:
+ A friendly description of the task, usally used to communicate information to users.
+
+ subTaskModel:
+ A generic byte object for the Task developer to store internal serialized data into registry catalogs.
+
+ Attributes:
+ - taskId
+ - taskType
+ - parentProcessId
+ - creationTime
+ - lastUpdateTime
+ - taskStatuses
+ - taskDetail
+ - subTaskModel
+ - taskErrors
+ - jobs
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'taskId', 'UTF8', "DO_NOT_SET_AT_CLIENTS", ), # 1
+ (2, TType.I32, 'taskType', None, None, ), # 2
+ (3, TType.STRING, 'parentProcessId', 'UTF8', None, ), # 3
+ (4, TType.I64, 'creationTime', None, None, ), # 4
+ (5, TType.I64, 'lastUpdateTime', None, None, ), # 5
+ (6, TType.LIST, 'taskStatuses', (TType.STRUCT, (apache.airavata.model.status.ttypes.TaskStatus, apache.airavata.model.status.ttypes.TaskStatus.thrift_spec), False), None, ), # 6
+ (7, TType.STRING, 'taskDetail', 'UTF8', None, ), # 7
+ (8, TType.STRING, 'subTaskModel', 'BINARY', None, ), # 8
+ (9, TType.LIST, 'taskErrors', (TType.STRUCT, (apache.airavata.model.commons.ttypes.ErrorModel, apache.airavata.model.commons.ttypes.ErrorModel.thrift_spec), False), None, ), # 9
+ (10, TType.LIST, 'jobs', (TType.STRUCT, (apache.airavata.model.job.ttypes.JobModel, apache.airavata.model.job.ttypes.JobModel.thrift_spec), False), None, ), # 10
+ )
+
+ def __init__(self, taskId=thrift_spec[1][4], taskType=None, parentProcessId=None, creationTime=None, lastUpdateTime=None, taskStatuses=None, taskDetail=None, subTaskModel=None, taskErrors=None, jobs=None,):
+ self.taskId = taskId
+ self.taskType = taskType
+ self.parentProcessId = parentProcessId
+ self.creationTime = creationTime
+ self.lastUpdateTime = lastUpdateTime
+ self.taskStatuses = taskStatuses
+ self.taskDetail = taskDetail
+ self.subTaskModel = subTaskModel
+ self.taskErrors = taskErrors
+ self.jobs = jobs
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.taskId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I32:
+ self.taskType = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.STRING:
+ self.parentProcessId = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.I64:
+ self.creationTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.I64:
+ self.lastUpdateTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.LIST:
+ self.taskStatuses = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in range(_size0):
+ _elem5 = apache.airavata.model.status.ttypes.TaskStatus()
+ _elem5.read(iprot)
+ self.taskStatuses.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.STRING:
+ self.taskDetail = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.STRING:
+ self.subTaskModel = iprot.readBinary()
+ else:
+ iprot.skip(ftype)
+ elif fid == 9:
+ if ftype == TType.LIST:
+ self.taskErrors = []
+ (_etype9, _size6) = iprot.readListBegin()
+ for _i10 in range(_size6):
+ _elem11 = apache.airavata.model.commons.ttypes.ErrorModel()
+ _elem11.read(iprot)
+ self.taskErrors.append(_elem11)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 10:
+ if ftype == TType.LIST:
+ self.jobs = []
+ (_etype15, _size12) = iprot.readListBegin()
+ for _i16 in range(_size12):
+ _elem17 = apache.airavata.model.job.ttypes.JobModel()
+ _elem17.read(iprot)
+ self.jobs.append(_elem17)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('TaskModel')
+ if self.taskId is not None:
+ oprot.writeFieldBegin('taskId', TType.STRING, 1)
+ oprot.writeString(self.taskId.encode('utf-8') if sys.version_info[0] == 2 else self.taskId)
+ oprot.writeFieldEnd()
+ if self.taskType is not None:
+ oprot.writeFieldBegin('taskType', TType.I32, 2)
+ oprot.writeI32(self.taskType)
+ oprot.writeFieldEnd()
+ if self.parentProcessId is not None:
+ oprot.writeFieldBegin('parentProcessId', TType.STRING, 3)
+ oprot.writeString(self.parentProcessId.encode('utf-8') if sys.version_info[0] == 2 else self.parentProcessId)
+ oprot.writeFieldEnd()
+ if self.creationTime is not None:
+ oprot.writeFieldBegin('creationTime', TType.I64, 4)
+ oprot.writeI64(self.creationTime)
+ oprot.writeFieldEnd()
+ if self.lastUpdateTime is not None:
+ oprot.writeFieldBegin('lastUpdateTime', TType.I64, 5)
+ oprot.writeI64(self.lastUpdateTime)
+ oprot.writeFieldEnd()
+ if self.taskStatuses is not None:
+ oprot.writeFieldBegin('taskStatuses', TType.LIST, 6)
+ oprot.writeListBegin(TType.STRUCT, len(self.taskStatuses))
+ for iter18 in self.taskStatuses:
+ iter18.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.taskDetail is not None:
+ oprot.writeFieldBegin('taskDetail', TType.STRING, 7)
+ oprot.writeString(self.taskDetail.encode('utf-8') if sys.version_info[0] == 2 else self.taskDetail)
+ oprot.writeFieldEnd()
+ if self.subTaskModel is not None:
+ oprot.writeFieldBegin('subTaskModel', TType.STRING, 8)
+ oprot.writeBinary(self.subTaskModel)
+ oprot.writeFieldEnd()
+ if self.taskErrors is not None:
+ oprot.writeFieldBegin('taskErrors', TType.LIST, 9)
+ oprot.writeListBegin(TType.STRUCT, len(self.taskErrors))
+ for iter19 in self.taskErrors:
+ iter19.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.jobs is not None:
+ oprot.writeFieldBegin('jobs', TType.LIST, 10)
+ oprot.writeListBegin(TType.STRUCT, len(self.jobs))
+ for iter20 in self.jobs:
+ iter20.write(oprot)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.taskId is None:
+ raise TProtocolException(message='Required field taskId is unset!')
+ if self.taskType is None:
+ raise TProtocolException(message='Required field taskType is unset!')
+ if self.parentProcessId is None:
+ raise TProtocolException(message='Required field parentProcessId is unset!')
+ if self.creationTime is None:
+ raise TProtocolException(message='Required field creationTime is unset!')
+ if self.lastUpdateTime is None:
+ raise TProtocolException(message='Required field lastUpdateTime is unset!')
+ if self.taskStatuses is None:
+ raise TProtocolException(message='Required field taskStatuses is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class DataStagingTaskModel(object):
+ """
+ Attributes:
+ - source
+ - destination
+ - type
+ - transferStartTime
+ - transferEndTime
+ - transferRate
+ - processInput
+ - processOutput
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'source', 'UTF8', None, ), # 1
+ (2, TType.STRING, 'destination', 'UTF8', None, ), # 2
+ (3, TType.I32, 'type', None, None, ), # 3
+ (4, TType.I64, 'transferStartTime', None, None, ), # 4
+ (5, TType.I64, 'transferEndTime', None, None, ), # 5
+ (6, TType.STRING, 'transferRate', 'UTF8', None, ), # 6
+ (7, TType.STRUCT, 'processInput', (apache.airavata.model.application.io.ttypes.InputDataObjectType, apache.airavata.model.application.io.ttypes.InputDataObjectType.thrift_spec), None, ), # 7
+ (8, TType.STRUCT, 'processOutput', (apache.airavata.model.application.io.ttypes.OutputDataObjectType, apache.airavata.model.application.io.ttypes.OutputDataObjectType.thrift_spec), None, ), # 8
+ )
+
+ def __init__(self, source=None, destination=None, type=None, transferStartTime=None, transferEndTime=None, transferRate=None, processInput=None, processOutput=None,):
+ self.source = source
+ self.destination = destination
+ self.type = type
+ self.transferStartTime = transferStartTime
+ self.transferEndTime = transferEndTime
+ self.transferRate = transferRate
+ self.processInput = processInput
+ self.processOutput = processOutput
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.source = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.STRING:
+ self.destination = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I32:
+ self.type = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.I64:
+ self.transferStartTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.I64:
+ self.transferEndTime = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.STRING:
+ self.transferRate = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.STRUCT:
+ self.processInput = apache.airavata.model.application.io.ttypes.InputDataObjectType()
+ self.processInput.read(iprot)
+ else:
+ iprot.skip(ftype)
+ elif fid == 8:
+ if ftype == TType.STRUCT:
+ self.processOutput = apache.airavata.model.application.io.ttypes.OutputDataObjectType()
+ self.processOutput.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('DataStagingTaskModel')
+ if self.source is not None:
+ oprot.writeFieldBegin('source', TType.STRING, 1)
+ oprot.writeString(self.source.encode('utf-8') if sys.version_info[0] == 2 else self.source)
+ oprot.writeFieldEnd()
+ if self.destination is not None:
+ oprot.writeFieldBegin('destination', TType.STRING, 2)
+ oprot.writeString(self.destination.encode('utf-8') if sys.version_info[0] == 2 else self.destination)
+ oprot.writeFieldEnd()
+ if self.type is not None:
+ oprot.writeFieldBegin('type', TType.I32, 3)
+ oprot.writeI32(self.type)
+ oprot.writeFieldEnd()
+ if self.transferStartTime is not None:
+ oprot.writeFieldBegin('transferStartTime', TType.I64, 4)
+ oprot.writeI64(self.transferStartTime)
+ oprot.writeFieldEnd()
+ if self.transferEndTime is not None:
+ oprot.writeFieldBegin('transferEndTime', TType.I64, 5)
+ oprot.writeI64(self.transferEndTime)
+ oprot.writeFieldEnd()
+ if self.transferRate is not None:
+ oprot.writeFieldBegin('transferRate', TType.STRING, 6)
+ oprot.writeString(self.transferRate.encode('utf-8') if sys.version_info[0] == 2 else self.transferRate)
+ oprot.writeFieldEnd()
+ if self.processInput is not None:
+ oprot.writeFieldBegin('processInput', TType.STRUCT, 7)
+ self.processInput.write(oprot)
+ oprot.writeFieldEnd()
+ if self.processOutput is not None:
+ oprot.writeFieldBegin('processOutput', TType.STRUCT, 8)
+ self.processOutput.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.source is None:
+ raise TProtocolException(message='Required field source is unset!')
+ if self.destination is None:
+ raise TProtocolException(message='Required field destination is unset!')
+ if self.type is None:
+ raise TProtocolException(message='Required field type is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class EnvironmentSetupTaskModel(object):
+ """
+ EnvironmentSetupTaskModel: A structure holding the environment creation task details
+
+
+ Attributes:
+ - location
+ - protocol
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRING, 'location', 'UTF8', None, ), # 1
+ (2, TType.I32, 'protocol', None, None, ), # 2
+ )
+
+ def __init__(self, location=None, protocol=None,):
+ self.location = location
+ self.protocol = protocol
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRING:
+ self.location = iprot.readString().decode('utf-8') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I32:
+ self.protocol = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('EnvironmentSetupTaskModel')
+ if self.location is not None:
+ oprot.writeFieldBegin('location', TType.STRING, 1)
+ oprot.writeString(self.location.encode('utf-8') if sys.version_info[0] == 2 else self.location)
+ oprot.writeFieldEnd()
+ if self.protocol is not None:
+ oprot.writeFieldBegin('protocol', TType.I32, 2)
+ oprot.writeI32(self.protocol)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.location is None:
+ raise TProtocolException(message='Required field location is unset!')
+ if self.protocol is None:
+ raise TProtocolException(message='Required field protocol is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class JobSubmissionTaskModel(object):
+ """
+ Attributes:
+ - jobSubmissionProtocol
+ - monitorMode
+ - wallTime
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'jobSubmissionProtocol', None, None, ), # 1
+ (2, TType.I32, 'monitorMode', None, None, ), # 2
+ (3, TType.I32, 'wallTime', None, None, ), # 3
+ )
+
+ def __init__(self, jobSubmissionProtocol=None, monitorMode=None, wallTime=None,):
+ self.jobSubmissionProtocol = jobSubmissionProtocol
+ self.monitorMode = monitorMode
+ self.wallTime = wallTime
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.jobSubmissionProtocol = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I32:
+ self.monitorMode = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I32:
+ self.wallTime = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('JobSubmissionTaskModel')
+ if self.jobSubmissionProtocol is not None:
+ oprot.writeFieldBegin('jobSubmissionProtocol', TType.I32, 1)
+ oprot.writeI32(self.jobSubmissionProtocol)
+ oprot.writeFieldEnd()
+ if self.monitorMode is not None:
+ oprot.writeFieldBegin('monitorMode', TType.I32, 2)
+ oprot.writeI32(self.monitorMode)
+ oprot.writeFieldEnd()
+ if self.wallTime is not None:
+ oprot.writeFieldBegin('wallTime', TType.I32, 3)
+ oprot.writeI32(self.wallTime)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.jobSubmissionProtocol is None:
+ raise TProtocolException(message='Required field jobSubmissionProtocol is unset!')
+ if self.monitorMode is None:
+ raise TProtocolException(message='Required field monitorMode is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+
+class MonitorTaskModel(object):
+ """
+ Attributes:
+ - monitorMode
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.I32, 'monitorMode', None, None, ), # 1
+ )
+
+ def __init__(self, monitorMode=None,):
+ self.monitorMode = monitorMode
+
+ def read(self, iprot):
+ if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None:
+ iprot._fast_decode(self, iprot, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.I32:
+ self.monitorMode = iprot.readI32()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot._fast_encode is not None and self.thrift_spec is not None:
+ oprot.trans.write(oprot._fast_encode(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('MonitorTaskModel')
+ if self.monitorMode is not None:
+ oprot.writeFieldBegin('monitorMode', TType.I32, 1)
+ oprot.writeI32(self.monitorMode)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ if self.monitorMode is None:
+ raise TProtocolException(message='Required field monitorMode is unset!')
+ return
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.items()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
http://git-wip-us.apache.org/repos/asf/airavata/blob/9d165bd8/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/tenant/constants.py
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/tenant/constants.py b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/tenant/constants.py
index 4a6492b..eb0d35a 100644
--- a/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/tenant/constants.py
+++ b/airavata-api/airavata-client-sdks/airavata-python-sdk/src/main/resources/lib/apache/airavata/model/tenant/constants.py
@@ -1,11 +1,12 @@
#
-# Autogenerated by Thrift Compiler (0.9.3)
+# Autogenerated by Thrift Compiler (0.10.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
# options string: py
#
-from thrift.Thrift import TType, TMessageType, TException, TApplicationException
-from ttypes import *
-
+from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
+from thrift.protocol.TProtocol import TProtocolException
+import sys
+from .ttypes import *