airavata-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From shame...@apache.org
Subject [5/6] airavata git commit: Added archive flag to process model
Date Sat, 05 Mar 2016 02:30:55 GMT
Added archive flag to process model


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

Branch: refs/heads/develop
Commit: 5f29e9f96f6c9cdca530fae5ea1b9218311f5bf4
Parents: 97ea70c
Author: Shameera Rathnayaka <shameerainfo@gmail.com>
Authored: Fri Mar 4 16:17:01 2016 -0500
Committer: Shameera Rathnayaka <shameerainfo@gmail.com>
Committed: Fri Mar 4 16:17:01 2016 -0500

----------------------------------------------------------------------
 .../lib/airavata/process_model_types.cpp        |  22 ++++
 .../lib/airavata/process_model_types.h          |  12 ++-
 .../lib/Airavata/Model/Process/Types.php        |  23 ++++
 .../lib/apache/airavata/model/process/ttypes.py |  15 ++-
 .../airavata/model/process/ProcessModel.java    | 107 ++++++++++++++++++-
 .../catalog/impl/ExperimentRegistry.java        |   2 +
 .../core/experiment/catalog/model/Process.java  |  12 ++-
 .../catalog/resources/ProcessResource.java      |  10 ++
 .../experiment/catalog/resources/Utils.java     |   1 +
 .../utils/ThriftDataModelConversion.java        |   1 +
 .../process_model.thrift                        |   3 +-
 11 files changed, 199 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/airavata/blob/5f29e9f9/airavata-api/airavata-client-sdks/airavata-cpp-sdk/src/main/resources/lib/airavata/process_model_types.cpp
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-cpp-sdk/src/main/resources/lib/airavata/process_model_types.cpp
b/airavata-api/airavata-client-sdks/airavata-cpp-sdk/src/main/resources/lib/airavata/process_model_types.cpp
index 629b78f..fa5d0c8 100644
--- a/airavata-api/airavata-client-sdks/airavata-cpp-sdk/src/main/resources/lib/airavata/process_model_types.cpp
+++ b/airavata-api/airavata-client-sdks/airavata-cpp-sdk/src/main/resources/lib/airavata/process_model_types.cpp
@@ -143,6 +143,11 @@ void ProcessModel::__set_experimentDataDir(const std::string& val)
{
 __isset.experimentDataDir = true;
 }
 
+void ProcessModel::__set_archive(const bool val) {
+  this->archive = val;
+__isset.archive = true;
+}
+
 uint32_t ProcessModel::read(::apache::thrift::protocol::TProtocol* iprot) {
 
   apache::thrift::protocol::TInputRecursionTracker tracker(*iprot);
@@ -390,6 +395,14 @@ uint32_t ProcessModel::read(::apache::thrift::protocol::TProtocol* iprot)
{
           xfer += iprot->skip(ftype);
         }
         break;
+      case 23:
+        if (ftype == ::apache::thrift::protocol::T_BOOL) {
+          xfer += iprot->readBool(this->archive);
+          this->__isset.archive = true;
+        } else {
+          xfer += iprot->skip(ftype);
+        }
+        break;
       default:
         xfer += iprot->skip(ftype);
         break;
@@ -551,6 +564,11 @@ uint32_t ProcessModel::write(::apache::thrift::protocol::TProtocol* oprot)
const
     xfer += oprot->writeString(this->experimentDataDir);
     xfer += oprot->writeFieldEnd();
   }
+  if (this->__isset.archive) {
+    xfer += oprot->writeFieldBegin("archive", ::apache::thrift::protocol::T_BOOL, 23);
+    xfer += oprot->writeBool(this->archive);
+    xfer += oprot->writeFieldEnd();
+  }
   xfer += oprot->writeFieldStop();
   xfer += oprot->writeStructEnd();
   return xfer;
@@ -580,6 +598,7 @@ void swap(ProcessModel &a, ProcessModel &b) {
   swap(a.userDn, b.userDn);
   swap(a.generateCert, b.generateCert);
   swap(a.experimentDataDir, b.experimentDataDir);
+  swap(a.archive, b.archive);
   swap(a.__isset, b.__isset);
 }
 
@@ -606,6 +625,7 @@ ProcessModel::ProcessModel(const ProcessModel& other24) {
   userDn = other24.userDn;
   generateCert = other24.generateCert;
   experimentDataDir = other24.experimentDataDir;
+  archive = other24.archive;
   __isset = other24.__isset;
 }
 ProcessModel& ProcessModel::operator=(const ProcessModel& other25) {
@@ -631,6 +651,7 @@ ProcessModel& ProcessModel::operator=(const ProcessModel& other25)
{
   userDn = other25.userDn;
   generateCert = other25.generateCert;
   experimentDataDir = other25.experimentDataDir;
+  archive = other25.archive;
   __isset = other25.__isset;
   return *this;
 }
@@ -659,6 +680,7 @@ void ProcessModel::printTo(std::ostream& out) const {
   out << ", " << "userDn="; (__isset.userDn ? (out << to_string(userDn))
: (out << "<null>"));
   out << ", " << "generateCert="; (__isset.generateCert ? (out << to_string(generateCert))
: (out << "<null>"));
   out << ", " << "experimentDataDir="; (__isset.experimentDataDir ? (out <<
to_string(experimentDataDir)) : (out << "<null>"));
+  out << ", " << "archive="; (__isset.archive ? (out << to_string(archive))
: (out << "<null>"));
   out << ")";
 }
 

http://git-wip-us.apache.org/repos/asf/airavata/blob/5f29e9f9/airavata-api/airavata-client-sdks/airavata-cpp-sdk/src/main/resources/lib/airavata/process_model_types.h
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-cpp-sdk/src/main/resources/lib/airavata/process_model_types.h
b/airavata-api/airavata-client-sdks/airavata-cpp-sdk/src/main/resources/lib/airavata/process_model_types.h
index efa30d1..b459e5a 100644
--- a/airavata-api/airavata-client-sdks/airavata-cpp-sdk/src/main/resources/lib/airavata/process_model_types.h
+++ b/airavata-api/airavata-client-sdks/airavata-cpp-sdk/src/main/resources/lib/airavata/process_model_types.h
@@ -44,7 +44,7 @@ namespace apache { namespace airavata { namespace model { namespace process
{
 class ProcessModel;
 
 typedef struct _ProcessModel__isset {
-  _ProcessModel__isset() : creationTime(false), lastUpdateTime(false), processStatus(false),
processDetail(false), applicationInterfaceId(false), applicationDeploymentId(false), computeResourceId(false),
processInputs(false), processOutputs(false), resourceSchedule(false), tasks(false), taskDag(false),
processError(false), gatewayExecutionId(false), enableEmailNotification(false), emailAddresses(false),
storageResourceId(false), userDn(false), generateCert(true), experimentDataDir(false) {}
+  _ProcessModel__isset() : creationTime(false), lastUpdateTime(false), processStatus(false),
processDetail(false), applicationInterfaceId(false), applicationDeploymentId(false), computeResourceId(false),
processInputs(false), processOutputs(false), resourceSchedule(false), tasks(false), taskDag(false),
processError(false), gatewayExecutionId(false), enableEmailNotification(false), emailAddresses(false),
storageResourceId(false), userDn(false), generateCert(true), experimentDataDir(false), archive(false)
{}
   bool creationTime :1;
   bool lastUpdateTime :1;
   bool processStatus :1;
@@ -65,6 +65,7 @@ typedef struct _ProcessModel__isset {
   bool userDn :1;
   bool generateCert :1;
   bool experimentDataDir :1;
+  bool archive :1;
 } _ProcessModel__isset;
 
 class ProcessModel {
@@ -72,7 +73,7 @@ class ProcessModel {
 
   ProcessModel(const ProcessModel&);
   ProcessModel& operator=(const ProcessModel&);
-  ProcessModel() : processId("DO_NOT_SET_AT_CLIENTS"), experimentId(), creationTime(0), lastUpdateTime(0),
processDetail(), applicationInterfaceId(), applicationDeploymentId(), computeResourceId(),
taskDag(), gatewayExecutionId(), enableEmailNotification(0), storageResourceId(), userDn(),
generateCert(false), experimentDataDir() {
+  ProcessModel() : processId("DO_NOT_SET_AT_CLIENTS"), experimentId(), creationTime(0), lastUpdateTime(0),
processDetail(), applicationInterfaceId(), applicationDeploymentId(), computeResourceId(),
taskDag(), gatewayExecutionId(), enableEmailNotification(0), storageResourceId(), userDn(),
generateCert(false), experimentDataDir(), archive(0) {
   }
 
   virtual ~ProcessModel() throw();
@@ -98,6 +99,7 @@ class ProcessModel {
   std::string userDn;
   bool generateCert;
   std::string experimentDataDir;
+  bool archive;
 
   _ProcessModel__isset __isset;
 
@@ -145,6 +147,8 @@ class ProcessModel {
 
   void __set_experimentDataDir(const std::string& val);
 
+  void __set_archive(const bool val);
+
   bool operator == (const ProcessModel & rhs) const
   {
     if (!(processId == rhs.processId))
@@ -231,6 +235,10 @@ class ProcessModel {
       return false;
     else if (__isset.experimentDataDir && !(experimentDataDir == rhs.experimentDataDir))
       return false;
+    if (__isset.archive != rhs.__isset.archive)
+      return false;
+    else if (__isset.archive && !(archive == rhs.archive))
+      return false;
     return true;
   }
   bool operator != (const ProcessModel &rhs) const {

http://git-wip-us.apache.org/repos/asf/airavata/blob/5f29e9f9/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 c0000d0..41187c5 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
@@ -117,6 +117,10 @@ class ProcessModel {
    * @var string
    */
   public $experimentDataDir = null;
+  /**
+   * @var bool
+   */
+  public $archive = null;
 
   public function __construct($vals=null) {
     if (!isset(self::$_TSPEC)) {
@@ -231,6 +235,10 @@ class ProcessModel {
           'var' => 'experimentDataDir',
           'type' => TType::STRING,
           ),
+        23 => array(
+          'var' => 'archive',
+          'type' => TType::BOOL,
+          ),
         );
     }
     if (is_array($vals)) {
@@ -300,6 +308,9 @@ class ProcessModel {
       if (isset($vals['experimentDataDir'])) {
         $this->experimentDataDir = $vals['experimentDataDir'];
       }
+      if (isset($vals['archive'])) {
+        $this->archive = $vals['archive'];
+      }
     }
   }
 
@@ -522,6 +533,13 @@ class ProcessModel {
             $xfer += $input->skip($ftype);
           }
           break;
+        case 23:
+          if ($ftype == TType::BOOL) {
+            $xfer += $input->readBool($this->archive);
+          } else {
+            $xfer += $input->skip($ftype);
+          }
+          break;
         default:
           $xfer += $input->skip($ftype);
           break;
@@ -702,6 +720,11 @@ class ProcessModel {
       $xfer += $output->writeString($this->experimentDataDir);
       $xfer += $output->writeFieldEnd();
     }
+    if ($this->archive !== null) {
+      $xfer += $output->writeFieldBegin('archive', TType::BOOL, 23);
+      $xfer += $output->writeBool($this->archive);
+      $xfer += $output->writeFieldEnd();
+    }
     $xfer += $output->writeFieldStop();
     $xfer += $output->writeStructEnd();
     return $xfer;

http://git-wip-us.apache.org/repos/asf/airavata/blob/5f29e9f9/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 7355759..d8afe65 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
@@ -56,6 +56,7 @@ class ProcessModel:
    - userDn
    - generateCert
    - experimentDataDir
+   - archive
   """
 
   thrift_spec = (
@@ -82,9 +83,10 @@ class ProcessModel:
     (20, TType.STRING, 'userDn', None, None, ), # 20
     (21, TType.BOOL, 'generateCert', None, False, ), # 21
     (22, TType.STRING, 'experimentDataDir', None, None, ), # 22
+    (23, TType.BOOL, 'archive', None, None, ), # 23
   )
 
-  def __init__(self, processId=thrift_spec[1][4], experimentId=None, creationTime=None, lastUpdateTime=None,
processStatus=None, processDetail=None, applicationInterfaceId=None, applicationDeploymentId=None,
computeResourceId=None, processInputs=None, processOutputs=None, resourceSchedule=None, tasks=None,
taskDag=None, processError=None, gatewayExecutionId=None, enableEmailNotification=None, emailAddresses=None,
storageResourceId=None, userDn=None, generateCert=thrift_spec[21][4], experimentDataDir=None,):
+  def __init__(self, processId=thrift_spec[1][4], experimentId=None, creationTime=None, lastUpdateTime=None,
processStatus=None, processDetail=None, applicationInterfaceId=None, applicationDeploymentId=None,
computeResourceId=None, processInputs=None, processOutputs=None, resourceSchedule=None, tasks=None,
taskDag=None, processError=None, gatewayExecutionId=None, enableEmailNotification=None, emailAddresses=None,
storageResourceId=None, userDn=None, generateCert=thrift_spec[21][4], experimentDataDir=None,
archive=None,):
     self.processId = processId
     self.experimentId = experimentId
     self.creationTime = creationTime
@@ -107,6 +109,7 @@ class ProcessModel:
     self.userDn = userDn
     self.generateCert = generateCert
     self.experimentDataDir = experimentDataDir
+    self.archive = archive
 
   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:
@@ -253,6 +256,11 @@ class ProcessModel:
           self.experimentDataDir = iprot.readString()
         else:
           iprot.skip(ftype)
+      elif fid == 23:
+        if ftype == TType.BOOL:
+          self.archive = iprot.readBool()
+        else:
+          iprot.skip(ftype)
       else:
         iprot.skip(ftype)
       iprot.readFieldEnd()
@@ -363,6 +371,10 @@ class ProcessModel:
       oprot.writeFieldBegin('experimentDataDir', TType.STRING, 22)
       oprot.writeString(self.experimentDataDir)
       oprot.writeFieldEnd()
+    if self.archive is not None:
+      oprot.writeFieldBegin('archive', TType.BOOL, 23)
+      oprot.writeBool(self.archive)
+      oprot.writeFieldEnd()
     oprot.writeFieldStop()
     oprot.writeStructEnd()
 
@@ -398,6 +410,7 @@ class ProcessModel:
     value = (value * 31) ^ hash(self.userDn)
     value = (value * 31) ^ hash(self.generateCert)
     value = (value * 31) ^ hash(self.experimentDataDir)
+    value = (value * 31) ^ hash(self.archive)
     return value
 
   def __repr__(self):

http://git-wip-us.apache.org/repos/asf/airavata/blob/5f29e9f9/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/process/ProcessModel.java
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/process/ProcessModel.java
b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/process/ProcessModel.java
index 24db81f..2ff4730 100644
--- a/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/process/ProcessModel.java
+++ b/airavata-api/airavata-data-models/src/main/java/org/apache/airavata/model/process/ProcessModel.java
@@ -86,6 +86,7 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
   private static final org.apache.thrift.protocol.TField USER_DN_FIELD_DESC = new org.apache.thrift.protocol.TField("userDn",
org.apache.thrift.protocol.TType.STRING, (short)20);
   private static final org.apache.thrift.protocol.TField GENERATE_CERT_FIELD_DESC = new org.apache.thrift.protocol.TField("generateCert",
org.apache.thrift.protocol.TType.BOOL, (short)21);
   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)22);
+  private static final org.apache.thrift.protocol.TField ARCHIVE_FIELD_DESC = new org.apache.thrift.protocol.TField("archive",
org.apache.thrift.protocol.TType.BOOL, (short)23);
 
   private static final Map<Class<? extends IScheme>, SchemeFactory> schemes =
new HashMap<Class<? extends IScheme>, SchemeFactory>();
   static {
@@ -115,6 +116,7 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
   private String userDn; // optional
   private boolean generateCert; // optional
   private String experimentDataDir; // optional
+  private boolean archive; // 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 {
@@ -139,7 +141,8 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
     STORAGE_RESOURCE_ID((short)19, "storageResourceId"),
     USER_DN((short)20, "userDn"),
     GENERATE_CERT((short)21, "generateCert"),
-    EXPERIMENT_DATA_DIR((short)22, "experimentDataDir");
+    EXPERIMENT_DATA_DIR((short)22, "experimentDataDir"),
+    ARCHIVE((short)23, "archive");
 
     private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
 
@@ -198,6 +201,8 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
           return GENERATE_CERT;
         case 22: // EXPERIMENT_DATA_DIR
           return EXPERIMENT_DATA_DIR;
+        case 23: // ARCHIVE
+          return ARCHIVE;
         default:
           return null;
       }
@@ -242,8 +247,9 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
   private static final int __LASTUPDATETIME_ISSET_ID = 1;
   private static final int __ENABLEEMAILNOTIFICATION_ISSET_ID = 2;
   private static final int __GENERATECERT_ISSET_ID = 3;
+  private static final int __ARCHIVE_ISSET_ID = 4;
   private byte __isset_bitfield = 0;
-  private static final _Fields optionals[] = {_Fields.CREATION_TIME,_Fields.LAST_UPDATE_TIME,_Fields.PROCESS_STATUS,_Fields.PROCESS_DETAIL,_Fields.APPLICATION_INTERFACE_ID,_Fields.APPLICATION_DEPLOYMENT_ID,_Fields.COMPUTE_RESOURCE_ID,_Fields.PROCESS_INPUTS,_Fields.PROCESS_OUTPUTS,_Fields.RESOURCE_SCHEDULE,_Fields.TASKS,_Fields.TASK_DAG,_Fields.PROCESS_ERROR,_Fields.GATEWAY_EXECUTION_ID,_Fields.ENABLE_EMAIL_NOTIFICATION,_Fields.EMAIL_ADDRESSES,_Fields.STORAGE_RESOURCE_ID,_Fields.USER_DN,_Fields.GENERATE_CERT,_Fields.EXPERIMENT_DATA_DIR};
+  private static final _Fields optionals[] = {_Fields.CREATION_TIME,_Fields.LAST_UPDATE_TIME,_Fields.PROCESS_STATUS,_Fields.PROCESS_DETAIL,_Fields.APPLICATION_INTERFACE_ID,_Fields.APPLICATION_DEPLOYMENT_ID,_Fields.COMPUTE_RESOURCE_ID,_Fields.PROCESS_INPUTS,_Fields.PROCESS_OUTPUTS,_Fields.RESOURCE_SCHEDULE,_Fields.TASKS,_Fields.TASK_DAG,_Fields.PROCESS_ERROR,_Fields.GATEWAY_EXECUTION_ID,_Fields.ENABLE_EMAIL_NOTIFICATION,_Fields.EMAIL_ADDRESSES,_Fields.STORAGE_RESOURCE_ID,_Fields.USER_DN,_Fields.GENERATE_CERT,_Fields.EXPERIMENT_DATA_DIR,_Fields.ARCHIVE};
   public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
   static {
     Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields,
org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
@@ -295,6 +301,8 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
         new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
     tmpMap.put(_Fields.EXPERIMENT_DATA_DIR, new org.apache.thrift.meta_data.FieldMetaData("experimentDataDir",
org.apache.thrift.TFieldRequirementType.OPTIONAL, 
         new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
+    tmpMap.put(_Fields.ARCHIVE, new org.apache.thrift.meta_data.FieldMetaData("archive",
org.apache.thrift.TFieldRequirementType.OPTIONAL, 
+        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
     metaDataMap = Collections.unmodifiableMap(tmpMap);
     org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ProcessModel.class, metaDataMap);
   }
@@ -391,6 +399,7 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
     if (other.isSetExperimentDataDir()) {
       this.experimentDataDir = other.experimentDataDir;
     }
+    this.archive = other.archive;
   }
 
   public ProcessModel deepCopy() {
@@ -426,6 +435,8 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
     this.generateCert = false;
 
     this.experimentDataDir = null;
+    setArchiveIsSet(false);
+    this.archive = false;
   }
 
   public String getProcessId() {
@@ -990,6 +1001,28 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
     }
   }
 
+  public boolean isArchive() {
+    return this.archive;
+  }
+
+  public void setArchive(boolean archive) {
+    this.archive = archive;
+    setArchiveIsSet(true);
+  }
+
+  public void unsetArchive() {
+    __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ARCHIVE_ISSET_ID);
+  }
+
+  /** Returns true if field archive is set (has been assigned a value) and false otherwise
*/
+  public boolean isSetArchive() {
+    return EncodingUtils.testBit(__isset_bitfield, __ARCHIVE_ISSET_ID);
+  }
+
+  public void setArchiveIsSet(boolean value) {
+    __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ARCHIVE_ISSET_ID, value);
+  }
+
   public void setFieldValue(_Fields field, Object value) {
     switch (field) {
     case PROCESS_ID:
@@ -1168,6 +1201,14 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
       }
       break;
 
+    case ARCHIVE:
+      if (value == null) {
+        unsetArchive();
+      } else {
+        setArchive((Boolean)value);
+      }
+      break;
+
     }
   }
 
@@ -1239,6 +1280,9 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
     case EXPERIMENT_DATA_DIR:
       return getExperimentDataDir();
 
+    case ARCHIVE:
+      return isArchive();
+
     }
     throw new IllegalStateException();
   }
@@ -1294,6 +1338,8 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
       return isSetGenerateCert();
     case EXPERIMENT_DATA_DIR:
       return isSetExperimentDataDir();
+    case ARCHIVE:
+      return isSetArchive();
     }
     throw new IllegalStateException();
   }
@@ -1509,6 +1555,15 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
         return false;
     }
 
+    boolean this_present_archive = true && this.isSetArchive();
+    boolean that_present_archive = true && that.isSetArchive();
+    if (this_present_archive || that_present_archive) {
+      if (!(this_present_archive && that_present_archive))
+        return false;
+      if (this.archive != that.archive)
+        return false;
+    }
+
     return true;
   }
 
@@ -1626,6 +1681,11 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
     if (present_experimentDataDir)
       list.add(experimentDataDir);
 
+    boolean present_archive = true && (isSetArchive());
+    list.add(present_archive);
+    if (present_archive)
+      list.add(archive);
+
     return list.hashCode();
   }
 
@@ -1857,6 +1917,16 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
         return lastComparison;
       }
     }
+    lastComparison = Boolean.valueOf(isSetArchive()).compareTo(other.isSetArchive());
+    if (lastComparison != 0) {
+      return lastComparison;
+    }
+    if (isSetArchive()) {
+      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.archive, other.archive);
+      if (lastComparison != 0) {
+        return lastComparison;
+      }
+    }
     return 0;
   }
 
@@ -2076,6 +2146,12 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
       }
       first = false;
     }
+    if (isSetArchive()) {
+      if (!first) sb.append(", ");
+      sb.append("archive:");
+      sb.append(this.archive);
+      first = false;
+    }
     sb.append(")");
     return sb.toString();
   }
@@ -2360,6 +2436,14 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
               org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
             }
             break;
+          case 23: // ARCHIVE
+            if (schemeField.type == org.apache.thrift.protocol.TType.BOOL) {
+              struct.archive = iprot.readBool();
+              struct.setArchiveIsSet(true);
+            } else { 
+              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+            }
+            break;
           default:
             org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
         }
@@ -2543,6 +2627,11 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
           oprot.writeFieldEnd();
         }
       }
+      if (struct.isSetArchive()) {
+        oprot.writeFieldBegin(ARCHIVE_FIELD_DESC);
+        oprot.writeBool(struct.archive);
+        oprot.writeFieldEnd();
+      }
       oprot.writeFieldStop();
       oprot.writeStructEnd();
     }
@@ -2623,7 +2712,10 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
       if (struct.isSetExperimentDataDir()) {
         optionals.set(19);
       }
-      oprot.writeBitSet(optionals, 20);
+      if (struct.isSetArchive()) {
+        optionals.set(20);
+      }
+      oprot.writeBitSet(optionals, 21);
       if (struct.isSetCreationTime()) {
         oprot.writeI64(struct.creationTime);
       }
@@ -2708,6 +2800,9 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
       if (struct.isSetExperimentDataDir()) {
         oprot.writeString(struct.experimentDataDir);
       }
+      if (struct.isSetArchive()) {
+        oprot.writeBool(struct.archive);
+      }
     }
 
     @Override
@@ -2717,7 +2812,7 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
       struct.setProcessIdIsSet(true);
       struct.experimentId = iprot.readString();
       struct.setExperimentIdIsSet(true);
-      BitSet incoming = iprot.readBitSet(20);
+      BitSet incoming = iprot.readBitSet(21);
       if (incoming.get(0)) {
         struct.creationTime = iprot.readI64();
         struct.setCreationTimeIsSet(true);
@@ -2840,6 +2935,10 @@ public class ProcessModel implements org.apache.thrift.TBase<ProcessModel,
Proce
         struct.experimentDataDir = iprot.readString();
         struct.setExperimentDataDirIsSet(true);
       }
+      if (incoming.get(20)) {
+        struct.archive = iprot.readBool();
+        struct.setArchiveIsSet(true);
+      }
     }
   }
 

http://git-wip-us.apache.org/repos/asf/airavata/blob/5f29e9f9/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/impl/ExperimentRegistry.java
----------------------------------------------------------------------
diff --git a/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/impl/ExperimentRegistry.java
b/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/impl/ExperimentRegistry.java
index 7a7538a..acf76d6 100644
--- a/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/impl/ExperimentRegistry.java
+++ b/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/impl/ExperimentRegistry.java
@@ -281,6 +281,7 @@ public class ExperimentRegistry {
             processResource.setUserDn(process.getUserDn());
             processResource.setGenerateCert(process.isGenerateCert());
             processResource.setExperimentDataDir(process.getExperimentDataDir());
+            processResource.setArchive(process.isArchive());
             if(process.isEnableEmailNotification()){
                 processResource.setEnableEmailNotification(true);
                 if(process.getEmailAddresses() != null){
@@ -736,6 +737,7 @@ public class ExperimentRegistry {
             processResource.setUserDn(process.getUserDn());
             processResource.setGenerateCert(process.isGenerateCert());
             processResource.setExperimentDataDir(process.getExperimentDataDir());
+            processResource.setArchive(process.isArchive());
             if(process.isEnableEmailNotification()){
                 processResource.setEnableEmailNotification(true);
                 if(process.getEmailAddresses() != null){

http://git-wip-us.apache.org/repos/asf/airavata/blob/5f29e9f9/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/model/Process.java
----------------------------------------------------------------------
diff --git a/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/model/Process.java
b/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/model/Process.java
index 222ae03..a1449cc 100644
--- a/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/model/Process.java
+++ b/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/model/Process.java
@@ -54,6 +54,7 @@ public class Process {
     private Collection<Task> tasks;
     private String userDn;
     private boolean generateCert;
+    private boolean archive;
 
     @Id
     @Column(name = "PROCESS_ID")
@@ -203,7 +204,16 @@ public class Process {
         this.experimentDataDir = experimentDataDir;
     }
 
-//    @Override
+    @Column(name = "ARCHIVE")
+    public boolean isArchive() {
+        return archive;
+    }
+
+    public void setArchive(boolean archive) {
+        this.archive = archive;
+    }
+
+    //    @Override
 //    public boolean equals(Object o) {
 //        if (this == o) return true;
 //        if (o == null || getClass() != o.getClass()) return false;

http://git-wip-us.apache.org/repos/asf/airavata/blob/5f29e9f9/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/resources/ProcessResource.java
----------------------------------------------------------------------
diff --git a/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/resources/ProcessResource.java
b/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/resources/ProcessResource.java
index e1720de..3918981 100644
--- a/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/resources/ProcessResource.java
+++ b/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/resources/ProcessResource.java
@@ -56,6 +56,7 @@ public class ProcessResource extends AbstractExpCatResource {
     private String userDn;
     private boolean generateCert;
     private String experimentDataDir;
+    private boolean archive;
 
     public String getProcessId() {
         return processId;
@@ -185,6 +186,14 @@ public class ProcessResource extends AbstractExpCatResource {
         this.experimentDataDir = experimentDataDir;
     }
 
+    public boolean isArchive() {
+        return archive;
+    }
+
+    public void setArchive(boolean archive) {
+        this.archive = archive;
+    }
+
     public ExperimentCatResource create(ResourceType type) throws RegistryException{
        switch (type){
            case PROCESS_ERROR:
@@ -590,6 +599,7 @@ public class ProcessResource extends AbstractExpCatResource {
             process.setUserDn(userDn);
             process.setGenerateCert(generateCert);
             process.setExperimentDataDir(experimentDataDir);
+            process.setArchive(archive);
             if (existingProcess == null){
                 em.persist(process);
             }else {

http://git-wip-us.apache.org/repos/asf/airavata/blob/5f29e9f9/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/resources/Utils.java
----------------------------------------------------------------------
diff --git a/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/resources/Utils.java
b/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/resources/Utils.java
index 75215d0..1a6c4e2 100644
--- a/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/resources/Utils.java
+++ b/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/resources/Utils.java
@@ -539,6 +539,7 @@ public class Utils {
             processResource.setUserDn(o.getUserDn());
             processResource.setGenerateCert(o.getGenerateCert());
             processResource.setExperimentDataDir(o.getExperimentDataDir());
+            processResource.setArchive(o.isArchive());
         }
         return processResource;
     }

http://git-wip-us.apache.org/repos/asf/airavata/blob/5f29e9f9/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/utils/ThriftDataModelConversion.java
----------------------------------------------------------------------
diff --git a/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/utils/ThriftDataModelConversion.java
b/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/utils/ThriftDataModelConversion.java
index 36b1e1e..639d83f 100644
--- a/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/utils/ThriftDataModelConversion.java
+++ b/modules/registry/registry-core/src/main/java/org/apache/airavata/registry/core/experiment/catalog/utils/ThriftDataModelConversion.java
@@ -352,6 +352,7 @@ public class ThriftDataModelConversion {
             processModel.setComputeResourceId(processResource.getComputeResourceId());
             processModel.setEnableEmailNotification(processResource.getEnableEmailNotification());
             processModel.setExperimentDataDir(processResource.getExperimentDataDir());
+            processModel.setArchive(processResource.isArchive());
             if (processModel.isEnableEmailNotification()){
                 String notificationEmails = processResource.getEmailAddresses();
                 processModel.setEmailAddresses(getEmailAddresses(notificationEmails.split(",")));

http://git-wip-us.apache.org/repos/asf/airavata/blob/5f29e9f9/thrift-interface-descriptions/data-models/experiment-catalog-models/process_model.thrift
----------------------------------------------------------------------
diff --git a/thrift-interface-descriptions/data-models/experiment-catalog-models/process_model.thrift
b/thrift-interface-descriptions/data-models/experiment-catalog-models/process_model.thrift
index d46a7f4..fa55deb 100644
--- a/thrift-interface-descriptions/data-models/experiment-catalog-models/process_model.thrift
+++ b/thrift-interface-descriptions/data-models/experiment-catalog-models/process_model.thrift
@@ -61,5 +61,6 @@ struct ProcessModel {
     19: optional string storageResourceId,
     20: optional string userDn,
     21: optional bool generateCert = 0,
-    22: optional string experimentDataDir
+    22: optional string experimentDataDir,
+    23: optional bool archive
 }
\ No newline at end of file


Mime
View raw message