Repository: airavata
Updated Branches:
  refs/heads/master 01f648a5c -> 4d338df24


http://git-wip-us.apache.org/repos/asf/airavata/blob/4d338df2/samples/php-cli-samples/getExperimentOutputs.php
----------------------------------------------------------------------
diff --git a/samples/php-cli-samples/getExperimentOutputs.php 
b/samples/php-cli-samples/getExperimentOutputs.php
deleted file mode 100644
index 34b5d6e..0000000
--- a/samples/php-cli-samples/getExperimentOutputs.php
+++ /dev/null
@@ -1,113 +0,0 @@
-<?php
-namespace Airavata\Client\Samples;
-
-$airavataconfig = parse_ini_file("airavata-client-properties.ini");
-
-$GLOBALS['THRIFT_ROOT'] = $airavataconfig['THRIFT_LIB_DIR'];
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TTransport.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TSocket.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TBinaryProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TApplicationException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TProtocolException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Base/TBase.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TMessageType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Factory/TStringFuncFactory.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/TStringFunc.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/Core.php';
-
-$GLOBALS['AIRAVATA_ROOT'] = $airavataconfig['AIRAVATA_PHP_STUBS_DIR'];
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Airavata.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'Model/Workspace/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 
'Model/Workspace/Experiment/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Error/Types.php';
-
-use Airavata\API\Error\AiravataClientException;
-use Airavata\API\Error\AiravataSystemException;
-use Airavata\API\Error\ExperimentNotFoundException;
-use Airavata\API\Error\InvalidRequestException;
-use Airavata\Client\AiravataClientFactory;
-use Airavata\Model\Workspace\Experiment\ExperimentState;
-use Thrift\Exception\TTransportException;
-use Thrift\Protocol\TBinaryProtocol;
-use Thrift\Transport\TBufferedTransport;
-use Thrift\Transport\TSocket;
-use Airavata\API\AiravataClient;
-
-$transport = new TSocket($airavataconfig['AIRAVATA_SERVER'], 
$airavataconfig['AIRAVATA_PORT']);
-$transport->setRecvTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
-
-$protocol = new TBinaryProtocol($transport);
-$transport->open();
-$airavataclient = new AiravataClient($protocol);
-
-
-
-if ($argc != 2)
-{
-    exit("php getExperimentOutputs.php <experiment_id> \n");
-}
-
-$expId = $argv[1];
-
-$outputs = get_experiment_outputs($expId);
-
-foreach ($outputs as $output)
-{
-    echo "$output->type: $output->value      <br><br>";
-}
-
-var_dump($outputs);
-
-
-
-
-
-
-$transport->close();
-
-
-/**
- * Get the experiment with the given ID
- * @param $expId
- * @return null
- */
-function get_experiment_outputs($expId)
-{
-    global $airavataclient;
-
-    try
-    {
-        return $airavataclient->getExperimentOutputs($expId);
-    }
-    catch (InvalidRequestException $ire)
-    {
-        echo 'InvalidRequestException!<br><br>' . $ire->getMessage();
-    }
-    catch (ExperimentNotFoundException $enf)
-    {
-        echo 'ExperimentNotFoundException!<br><br>' . $enf->getMessage();
-    }
-    catch (AiravataClientException $ace)
-    {
-        echo 'AiravataClientException!<br><br>' . $ace->getMessage();
-    }
-    catch (AiravataSystemException $ase)
-    {
-        echo 'AiravataSystemException!<br><br>' . $ase->getMessage();
-    }
-    catch (TTransportException $tte)
-    {
-        echo 'TTransportException!<br><br>' . $tte->getMessage();
-    }
-    catch (\Exception $e)
-    {
-        echo 'Exception!<br><br>' . $e->getMessage();
-    }
-
-}
-
-?>
-

http://git-wip-us.apache.org/repos/asf/airavata/blob/4d338df2/samples/php-cli-samples/getExperimentStatus.php
----------------------------------------------------------------------
diff --git a/samples/php-cli-samples/getExperimentStatus.php 
b/samples/php-cli-samples/getExperimentStatus.php
deleted file mode 100644
index e931a4e..0000000
--- a/samples/php-cli-samples/getExperimentStatus.php
+++ /dev/null
@@ -1,97 +0,0 @@
-<?php
-namespace Airavata\Client\Samples;
-
-$airavataconfig = parse_ini_file("airavata-client-properties.ini");
-
-$GLOBALS['THRIFT_ROOT'] = $airavataconfig['THRIFT_LIB_DIR'];
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TTransport.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TSocket.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TBinaryProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TApplicationException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TProtocolException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Base/TBase.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TMessageType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Factory/TStringFuncFactory.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/TStringFunc.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/Core.php';
-
-$GLOBALS['AIRAVATA_ROOT'] = $airavataconfig['AIRAVATA_PHP_STUBS_DIR'];
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Airavata.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'Model/Workspace/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 
'Model/Workspace/Experiment/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Error/Types.php';
-
-use Airavata\API\Error\AiravataClientException;
-use Airavata\API\Error\AiravataSystemException;
-use Airavata\API\Error\ExperimentNotFoundException;
-use Airavata\API\Error\InvalidRequestException;
-use Airavata\Client\AiravataClientFactory;
-use Airavata\Model\Workspace\Experiment\ExperimentState;
-use Thrift\Protocol\TBinaryProtocol;
-use Thrift\Transport\TBufferedTransport;
-use Thrift\Transport\TSocket;
-use Airavata\API\AiravataClient;
-
-$transport = new TSocket($airavataconfig['AIRAVATA_SERVER'], 
$airavataconfig['AIRAVATA_PORT']);
-$transport->setRecvTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
-
-$protocol = new TBinaryProtocol($transport);
-$transport->open();
-$airavataclient = new AiravataClient($protocol);
-
-
-if (count($argv) < 2) {
-    exit("Please provide an experimentID. \n");
-}
-
-$expId = $argv[1];   
-
-$experimentStatusString = get_experiment_status($expId);
-echo "experiment status = " . $experimentStatusString . "       \n<br>";
-
-
-$transport->close();
-
-
-/**
- * Get a string containing the given experiment's status
- * @param $expId
- * @return mixed
- */
-function get_experiment_status($expId)
-{
-    global $airavataclient;
-
-    try
-    {
-        $experimentStatus = $airavataclient->getExperimentStatus($expId);
-    }
-    catch (InvalidRequestException $ire)
-    {
-        echo 'InvalidRequestException!<br><br>' . $ire->getMessage();
-    }
-    catch (ExperimentNotFoundException $enf)
-    {
-        echo 'ExperimentNotFoundException!<br><br>' . $enf->getMessage();
-    }
-    catch (AiravataClientException $ace)
-    {
-        echo 'AiravataClientException!<br><br>' . $ace->getMessage();
-    }
-    catch (AiravataSystemException $ase)
-    {
-        echo 'AiravataSystemException!<br><br>' . $ase->getMessage();
-    }
-    catch (\Exception $e)
-    {
-        echo 'Exception!<br><br>' . $e->getMessage();
-    }
-
-    return ExperimentState::$__names[$experimentStatus->experimentState];
-}
-
-?>
-

http://git-wip-us.apache.org/repos/asf/airavata/blob/4d338df2/samples/php-cli-samples/launchExperiment.php
----------------------------------------------------------------------
diff --git a/samples/php-cli-samples/launchExperiment.php 
b/samples/php-cli-samples/launchExperiment.php
deleted file mode 100755
index 4f528b6..0000000
--- a/samples/php-cli-samples/launchExperiment.php
+++ /dev/null
@@ -1,82 +0,0 @@
-<?php
-namespace Airavata\Client\Samples;
-
-$airavataconfig = parse_ini_file("airavata-client-properties.ini");
-
-$GLOBALS['THRIFT_ROOT'] = $airavataconfig['THRIFT_LIB_DIR'];
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TTransport.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TSocket.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TBinaryProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TApplicationException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TProtocolException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Base/TBase.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TMessageType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Factory/TStringFuncFactory.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/TStringFunc.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/Core.php';
-
-$GLOBALS['AIRAVATA_ROOT'] = $airavataconfig['AIRAVATA_PHP_STUBS_DIR'];
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Airavata.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'Model/Workspace/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 
'Model/Workspace/Experiment/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Error/Types.php';
-
-use Airavata\API\Error\AiravataClientException;
-use Airavata\API\Error\AiravataSystemException;
-use Airavata\API\Error\ExperimentNotFoundException;
-use Airavata\API\Error\InvalidRequestException;
-use Airavata\Client\AiravataClientFactory;
-use Thrift\Protocol\TBinaryProtocol;
-use Thrift\Transport\TBufferedTransport;
-use Thrift\Transport\TSocket;
-use Airavata\API\AiravataClient;
-
-use Airavata\Model\Workspace\Project;
-use Airavata\Model\Workspace\Experiment\Experiment;
-
-$transport = new TSocket($airavataconfig['AIRAVATA_SERVER'], 
$airavataconfig['AIRAVATA_PORT']);
-$transport->setRecvTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
-
-$protocol = new TBinaryProtocol($transport);
-$transport->open();
-$airavataclient = new AiravataClient($protocol);
-
-try
-{
-   if (count($argv) < 2) {
-       exit("Please provide an experimentID. \n");
-   }
-
-   $expId = $argv[1];  
-   $airavataclient->launchExperiment($expId, 'airavataToken');
-   echo "Experiment $expId is launched.";
-}
-catch (InvalidRequestException $ire)
-{
-    print 'InvalidRequestException: ' . $ire->getMessage()."\n";
-}
-catch (AiravataClientException $ace)
-{
-    print 'Airavata System Exception: ' . $ace->getMessage()."\n";
-}
-catch (AiravataSystemException $ase)
-{
-    print 'Airavata System Exception: ' . $ase->getMessage()."\n";
-}
-catch (ExperimentNotFoundException $enf)
-{
-    print 'Experiment Not Found Exception: ' . $enf->getMessage()."\n";
-}
-
-
-
-
-
-
-$transport->close();
-
-?>
-

http://git-wip-us.apache.org/repos/asf/airavata/blob/4d338df2/samples/php-cli-samples/list-application-interfaces.php
----------------------------------------------------------------------
diff --git a/samples/php-cli-samples/list-application-interfaces.php 
b/samples/php-cli-samples/list-application-interfaces.php
deleted file mode 100644
index 7d7c9ce..0000000
--- a/samples/php-cli-samples/list-application-interfaces.php
+++ /dev/null
@@ -1,76 +0,0 @@
-<?php
-namespace Airavata\Client\Samples;
-
-$GLOBALS['THRIFT_ROOT'] = '../lib/Thrift/';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TTransport.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TSocket.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TBinaryProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TApplicationException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TProtocolException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Base/TBase.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TMessageType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Factory/TStringFuncFactory.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/TStringFunc.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/Core.php';
-
-$GLOBALS['AIRAVATA_ROOT'] = '../lib/Airavata/';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Airavata.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 
'API/AppCatalog/ApplicationCatalogAPI.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 
'Model/Workspace/Experiment/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'Model/AppCatalog/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Error/Types.php';
-
-use Airavata\Model\Workspace\Experiment\ComputationalResourceScheduling;
-use Airavata\Model\Workspace\Experiment\DataObjectType;
-use Airavata\Model\Workspace\Experiment\UserConfigurationData;
-use Airavata\Model\ComputeResourceDescription;
-use Airavata\Model\ApplicationInterface;
-use Thrift\Protocol\TBinaryProtocol;
-use Thrift\Transport\TSocket;
-use Airavata\API\AiravataClient;
-use Airavata\API\AppCatalog\ApplicationCatalogAPIClient;
-use Airavata\Model\Workspace\Experiment\Experiment;
-use Airavata\Model\AppCatalog\JobSubmissionProtocol;
-use Airavata\Model\AppCatalog\DataMovementProtocol;
-
-$airavataconfig = parse_ini_file("airavata-client-properties.ini");
-
-$transport = new TSocket($airavataconfig['APP_CATALOG_SERVER'], 
$airavataconfig['APP_CATALOG_PORT']);
-$transport->setRecvTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
-
-$protocol = new TBinaryProtocol($transport);
-
-$airavataclient = new ApplicationCatalogAPIClient($protocol);
-$transport->open();
-
-echo "Airavata Server Version is: " . $airavataclient->getAPIVersion() . "\n";
-
-echo "Listing Application Interfaces.... "."\n";
-
-$id_list = $airavataclient->listApplicationInterfaceIds();
-
-foreach($id_list as $id){
-       echo "Application Interface Id : ".$id."\n";
-       $app_interface = $airavataclient->getApplicationInterface($id);
-       echo "\t"."Interface Data : " . 
$app_interface->applicationInterfaceData."\n";
-       echo "\t".count($app_interface->applicationDeployments)." 
Deployments"."\n";
-       foreach($app_interface->applicationDeployments as $deployment){
-               echo "\t\t"."Compute Resource : 
".$deployment->computeResourceDescription->hostName."\n";
-               echo "\t\t\t"."Application 
Data".$deployment->applicationDescriptor->applicationDescriptorData."\n";
-       }
-}
-
-//$compute_resource = new \ComputeResourceDescription();
-//$compute_resource->hostName="localhost";
-//$compute_resource->hostAliases=array("localhost");
-//$compute_resource->ipAddresses=array("127.0.0.1");
-
-//Create a Experiment
-$transport->close();
-
-?>
-
-

http://git-wip-us.apache.org/repos/asf/airavata/blob/4d338df2/samples/php-cli-samples/list-compute-resources.php
----------------------------------------------------------------------
diff --git a/samples/php-cli-samples/list-compute-resources.php 
b/samples/php-cli-samples/list-compute-resources.php
deleted file mode 100644
index cc5c790..0000000
--- a/samples/php-cli-samples/list-compute-resources.php
+++ /dev/null
@@ -1,101 +0,0 @@
-<?php
-namespace Airavata\Client\Samples;
-
-$GLOBALS['THRIFT_ROOT'] = '../lib/Thrift/';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TTransport.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TSocket.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TBinaryProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TApplicationException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TProtocolException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Base/TBase.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TMessageType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Factory/TStringFuncFactory.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/TStringFunc.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/Core.php';
-
-$GLOBALS['AIRAVATA_ROOT'] = '../lib/Airavata/';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Airavata.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 
'API/AppCatalog/ApplicationCatalogAPI.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 
'Model/Workspace/Experiment/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'Model/AppCatalog/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Error/Types.php';
-
-use Airavata\Model\Workspace\Experiment\ComputationalResourceScheduling;
-use Airavata\Model\Workspace\Experiment\DataObjectType;
-use Airavata\Model\Workspace\Experiment\UserConfigurationData;
-use Airavata\Model\ComputeResourceDescription;
-use Thrift\Protocol\TBinaryProtocol;
-use Thrift\Transport\TSocket;
-use Airavata\API\AiravataClient;
-use Airavata\API\AppCatalog\ApplicationCatalogAPIClient;
-use Airavata\Model\Workspace\Experiment\Experiment;
-use Airavata\Model\AppCatalog\JobSubmissionProtocol;
-use Airavata\Model\AppCatalog\DataMovementProtocol;
-use Airavata\Model\AppCatalog\ResourceJobManager;
-
-$airavataconfig = parse_ini_file("airavata-client-properties.ini");
-
-$transport = new TSocket($airavataconfig['APP_CATALOG_SERVER'], 
$airavataconfig['APP_CATALOG_PORT']);
-echo $airavataconfig['AIRAVATA_TIMEOUT']."\n";
-$transport->setRecvTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
-
-$protocol = new TBinaryProtocol($transport);
-
-$airavataclient = new ApplicationCatalogAPIClient($protocol);
-$transport->open();
-
-echo "Airavata Server Version is: " . $airavataclient->getAPIVersion() . "\n";
-
-echo "Listing Compute Resources.... "."\n";
-
-$id_list = $airavataclient->listComputeResourceDescriptions();
-
-foreach($id_list as $id){
-       echo "Compute Resource Id : ".$id."\n";
-       $compute_resource = $airavataclient->getComputeResourceDescription($id);
-       echo "\t"."Host name : " . $compute_resource->hostName ."\n";
-       echo "\t"."Aliases : " . 
implode(",",array_keys($compute_resource->hostAliases)) ."\n";
-       echo "\t"."Ip addresses : " . 
implode(",",array_keys($compute_resource->ipAddresses)) ."\n";
-       echo "\t".count($compute_resource->jobSubmissionProtocols)." Job 
Submission Protocols Supported"."\n";
-       foreach($compute_resource->jobSubmissionProtocols as $protocol_data_id 
=> $protocol_type){
-               echo 
"\t\t".$protocol_data_id."[".JobSubmissionProtocol::$__names[$protocol_type]. 
"]"."\n";
-               switch ($protocol_type){
-                       case JobSubmissionProtocol::GRAM:
-                               
$globus_data=$airavataclient->getGlobusJobSubmissionProtocol($protocol_data_id);
-                               echo "\t\t\tGate Keeper Endpoint(s) : 
".implode(",",($globus_data->globusGateKeeperEndPoint))."\n";
-                               break;
-                       case JobSubmissionProtocol::GSISSH:
-                               
$gsissh_data=$airavataclient->getGSISSHJobSubmissionProtocol($protocol_data_id);
-                               echo "\t\t\tResource Job Manager : 
".ResourceJobManager::$__names[$gsissh_data->resourceJobManager]."\n";
-                               echo "\t\t\tInstalled Path : 
".$gsissh_data->installedPath."\n";
-                               echo "\t\t\tSSH port : 
".$gsissh_data->sshPort."\n";
-                               echo "\t\t\tMonitor Mode : 
".$gsissh_data->monitorMode."\n";
-                               break;
-               }
-       }
-       echo "\t".count($compute_resource->dataMovementProtocols)." Data 
Movement Protocols Supported"."\n";
-       foreach($compute_resource->dataMovementProtocols as $protocol_data_id 
=> $protocol_type){
-               echo 
"\t\t".$protocol_data_id."[".DataMovementProtocol::$__names[$protocol_type] . 
"]"."\n";
-                       switch ($protocol_type){
-                       case DataMovementProtocol::GridFTP:
-                               
$gridftp_data=$airavataclient->getGridFTPDataMovementProtocol($protocol_data_id);
-                               echo "\t\t\tGrid FTP Endpoint(s) : 
".implode(",",($gridftp_data->gridFTPEndPoint))."\n";
-                               break;
-               }
-       }
-}
-
-//$compute_resource = new \ComputeResourceDescription();
-//$compute_resource->hostName="localhost";
-//$compute_resource->hostAliases=array("localhost");
-//$compute_resource->ipAddresses=array("127.0.0.1");
-
-//Create a Experiment
-$transport->close();
-
-?>
-
-

http://git-wip-us.apache.org/repos/asf/airavata/blob/4d338df2/samples/php-cli-samples/registerAppModule.php
----------------------------------------------------------------------
diff --git a/samples/php-cli-samples/registerAppModule.php 
b/samples/php-cli-samples/registerAppModule.php
deleted file mode 100755
index 7bec80e..0000000
--- a/samples/php-cli-samples/registerAppModule.php
+++ /dev/null
@@ -1,102 +0,0 @@
-<?php
-namespace Airavata\Client\Samples;
-
-$airavataconfig = parse_ini_file("airavata-client-properties.ini");
-
-$GLOBALS['THRIFT_ROOT'] = $airavataconfig['THRIFT_LIB_DIR'];
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TTransport.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TSocket.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TBinaryProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TApplicationException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TProtocolException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Base/TBase.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TMessageType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Factory/TStringFuncFactory.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/TStringFunc.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/Core.php';
-
-$GLOBALS['AIRAVATA_ROOT'] = $airavataconfig['AIRAVATA_PHP_STUBS_DIR'];
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Airavata.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Error/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 
'Model/AppCatalog/AppDeployment/Types.php';
-
-
-use Airavata\API\Error\AiravataClientException;
-use Airavata\API\Error\AiravataSystemException;
-use Airavata\API\Error\InvalidRequestException;
-use Airavata\Client\AiravataClientFactory;
-use Airavata\Model\AppCatalog\AppDeployment\ApplicationModule;
-use Thrift\Protocol\TBinaryProtocol;
-use Thrift\Transport\TBufferedTransport;
-use Thrift\Transport\TSocket;
-use Airavata\API\AiravataClient;
-
-use Airavata\Model\Workspace\Project;
-use Airavata\Model\Workspace\Experiment\Experiment;
-use Airavata\Model\Workspace\Experiment\DataObjectType;
-use Airavata\Model\Workspace\Experiment\UserConfigurationData;
-use Airavata\Model\Workspace\Experiment\ComputationalResourceScheduling;
-use Airavata\Model\Workspace\Experiment\DataType;
-
-$transport = new TSocket($airavataconfig['AIRAVATA_SERVER'], 
$airavataconfig['AIRAVATA_PORT']);
-$transport->setRecvTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
-
-$protocol = new TBinaryProtocol($transport);
-$transport->open();
-$airavataclient = new AiravataClient($protocol);
-
-try
-{
-    if ($argc != 4)
-    {
-        echo 'php registerAppModule.php <appModuleName> <appModuleVersion> 
<appModuleDescription>';
-    }
-    else
-    {
-        $appModuleName = $argv[1];
-        $appModuleVersion = $argv[2];
-        $appModuleDescription = $argv[3];
-
-
-        $appModule = new ApplicationModule();
-        $appModule->appModuleName = $appModuleName;
-        $appModule->appModuleVersion = $appModuleVersion;
-        $appModule->appModuleDescription = $appModuleDescription;
-
-        $appModuleId = $airavataclient->registerAppicationModule($appModule);
-
-        if ($appModuleId)
-        {
-            var_dump($appModule);
-            echo "Application Module $appModuleId is registered! \n    ";
-        }
-        else
-        {
-            echo "Failed to register application module. \n";
-        }
-    }
-}
-catch (InvalidRequestException $ire)
-{
-    print 'InvalidRequestException: ' . $ire->getMessage()."\n";
-}
-catch (AiravataClientException $ace)
-{
-    print 'Airavata System Exception: ' . $ace->getMessage()."\n";
-}
-catch (AiravataSystemException $ase)
-{
-    print 'Airavata System Exception: ' . $ase->getMessage()."\n";
-}
-catch (\Exception $e)
-{
-    echo 'Exception!<br><br>' . $e->getMessage();
-}
-
-$transport->close();
-
-?>
-

http://git-wip-us.apache.org/repos/asf/airavata/blob/4d338df2/samples/php-cli-samples/search_experiments_by_application.php
----------------------------------------------------------------------
diff --git a/samples/php-cli-samples/search_experiments_by_application.php 
b/samples/php-cli-samples/search_experiments_by_application.php
deleted file mode 100644
index 4340f9e..0000000
--- a/samples/php-cli-samples/search_experiments_by_application.php
+++ /dev/null
@@ -1,79 +0,0 @@
-<?php
-namespace Airavata\Client\Samples;
-
-$airavataconfig = parse_ini_file("airavata-client-properties.ini");
-
-$GLOBALS['THRIFT_ROOT'] = $airavataconfig['THRIFT_LIB_DIR'];
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TTransport.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TSocket.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TBinaryProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TApplicationException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TProtocolException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Base/TBase.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TMessageType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Factory/TStringFuncFactory.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/TStringFunc.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/Core.php';
-
-$GLOBALS['AIRAVATA_ROOT'] = $airavataconfig['AIRAVATA_PHP_STUBS_DIR'];
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Airavata.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'Model/Workspace/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 
'Model/Workspace/Experiment/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Error/Types.php';
-
-use Airavata\API\Error\AiravataClientException;
-use Airavata\API\Error\AiravataSystemException;
-use Airavata\API\Error\InvalidRequestException;
-use Airavata\Client\AiravataClientFactory;
-use Thrift\Protocol\TBinaryProtocol;
-use Thrift\Transport\TBufferedTransport;
-use Thrift\Transport\TSocket;
-use Airavata\API\AiravataClient;
-
-$transport = new TSocket($airavataconfig['AIRAVATA_SERVER'], 
$airavataconfig['AIRAVATA_PORT']);
-$transport->setRecvTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
-
-$protocol = new TBinaryProtocol($transport);
-$transport->open();
-$airavataclient = new AiravataClient($protocol);
-
-
-try
-{
-
-    if ($argc != 3) {
-        echo 'php search_experiments_by_application.php <username> 
<project_ID>';
-    }
-
-    else {
-        $experiments = 
$airavataclient->searchExperimentsByApplication($argv[1], $argv[2]);
-        echo '# results = ' . sizeof($experiments) . '         <br><br>';
-        var_dump($experiments);
-    }
-
-
-}
-catch (InvalidRequestException $ire)
-{
-    print 'InvalidRequestException: ' . $ire->getMessage()."\n";
-}
-catch (AiravataClientException $ace)
-{
-    print 'Airavata System Exception: ' . $ace->getMessage()."\n";
-}
-catch (AiravataSystemException $ase)
-{
-    print 'Airavata System Exception: ' . $ase->getMessage()."\n";
-}
-
-
-
-
-
-$transport->close();
-
-?>
-

http://git-wip-us.apache.org/repos/asf/airavata/blob/4d338df2/samples/php-cli-samples/search_experiments_by_description.php
----------------------------------------------------------------------
diff --git a/samples/php-cli-samples/search_experiments_by_description.php 
b/samples/php-cli-samples/search_experiments_by_description.php
deleted file mode 100644
index 631ad15..0000000
--- a/samples/php-cli-samples/search_experiments_by_description.php
+++ /dev/null
@@ -1,79 +0,0 @@
-<?php
-namespace Airavata\Client\Samples;
-
-$airavataconfig = parse_ini_file("airavata-client-properties.ini");
-
-$GLOBALS['THRIFT_ROOT'] = $airavataconfig['THRIFT_LIB_DIR'];
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TTransport.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TSocket.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TBinaryProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TApplicationException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TProtocolException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Base/TBase.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TMessageType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Factory/TStringFuncFactory.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/TStringFunc.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/Core.php';
-
-$GLOBALS['AIRAVATA_ROOT'] = $airavataconfig['AIRAVATA_PHP_STUBS_DIR'];
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Airavata.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'Model/Workspace/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 
'Model/Workspace/Experiment/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Error/Types.php';
-
-use Airavata\API\Error\AiravataClientException;
-use Airavata\API\Error\AiravataSystemException;
-use Airavata\API\Error\InvalidRequestException;
-use Airavata\Client\AiravataClientFactory;
-use Thrift\Protocol\TBinaryProtocol;
-use Thrift\Transport\TBufferedTransport;
-use Thrift\Transport\TSocket;
-use Airavata\API\AiravataClient;
-
-$transport = new TSocket($airavataconfig['AIRAVATA_SERVER'], 
$airavataconfig['AIRAVATA_PORT']);
-$transport->setRecvTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
-
-$protocol = new TBinaryProtocol($transport);
-$transport->open();
-$airavataclient = new AiravataClient($protocol);
-
-
-try
-{
-
-    if ($argc != 3) {
-        echo 'php search_experiments_by_description.php <username> 
<project_ID>';
-    }
-
-    else {
-        $experiments = $airavataclient->searchExperimentsByDesc($argv[1], 
$argv[2]);
-        echo '# results = ' . sizeof($experiments) . '         <br><br>';
-        var_dump($experiments);
-    }
-
-
-}
-catch (InvalidRequestException $ire)
-{
-    print 'InvalidRequestException: ' . $ire->getMessage()."\n";
-}
-catch (AiravataClientException $ace)
-{
-    print 'Airavata System Exception: ' . $ace->getMessage()."\n";
-}
-catch (AiravataSystemException $ase)
-{
-    print 'Airavata System Exception: ' . $ase->getMessage()."\n";
-}
-
-
-
-
-
-$transport->close();
-
-?>
-

http://git-wip-us.apache.org/repos/asf/airavata/blob/4d338df2/samples/php-cli-samples/search_experiments_by_name.php
----------------------------------------------------------------------
diff --git a/samples/php-cli-samples/search_experiments_by_name.php 
b/samples/php-cli-samples/search_experiments_by_name.php
deleted file mode 100644
index d71a166..0000000
--- a/samples/php-cli-samples/search_experiments_by_name.php
+++ /dev/null
@@ -1,79 +0,0 @@
-<?php
-namespace Airavata\Client\Samples;
-
-$airavataconfig = parse_ini_file("airavata-client-properties.ini");
-
-$GLOBALS['THRIFT_ROOT'] = $airavataconfig['THRIFT_LIB_DIR'];
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TTransport.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TSocket.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TBinaryProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TApplicationException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TProtocolException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Base/TBase.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TMessageType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Factory/TStringFuncFactory.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/TStringFunc.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/Core.php';
-
-$GLOBALS['AIRAVATA_ROOT'] = $airavataconfig['AIRAVATA_PHP_STUBS_DIR'];
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Airavata.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'Model/Workspace/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 
'Model/Workspace/Experiment/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Error/Types.php';
-
-use Airavata\API\Error\AiravataClientException;
-use Airavata\API\Error\AiravataSystemException;
-use Airavata\API\Error\InvalidRequestException;
-use Airavata\Client\AiravataClientFactory;
-use Thrift\Protocol\TBinaryProtocol;
-use Thrift\Transport\TBufferedTransport;
-use Thrift\Transport\TSocket;
-use Airavata\API\AiravataClient;
-
-$transport = new TSocket($airavataconfig['AIRAVATA_SERVER'], 
$airavataconfig['AIRAVATA_PORT']);
-$transport->setRecvTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
-
-$protocol = new TBinaryProtocol($transport);
-$transport->open();
-$airavataclient = new AiravataClient($protocol);
-
-
-try
-{
-
-    if ($argc != 3) {
-        echo 'php search_experiments_by_name.php <username> <project_ID>';
-    }
-
-    else {
-        $experiments = $airavataclient->searchExperimentsByName($argv[1], 
$argv[2]);
-        echo '# results = ' . sizeof($experiments) . '         <br><br>';
-        var_dump($experiments);
-    }
-
-
-}
-catch (InvalidRequestException $ire)
-{
-    print 'InvalidRequestException: ' . $ire->getMessage()."\n";
-}
-catch (AiravataClientException $ace)
-{
-    print 'Airavata System Exception: ' . $ace->getMessage()."\n";
-}
-catch (AiravataSystemException $ase)
-{
-    print 'Airavata System Exception: ' . $ase->getMessage()."\n";
-}
-
-
-
-
-
-$transport->close();
-
-?>
-

http://git-wip-us.apache.org/repos/asf/airavata/blob/4d338df2/samples/php-cli-samples/terminateExperiment.php
----------------------------------------------------------------------
diff --git a/samples/php-cli-samples/terminateExperiment.php 
b/samples/php-cli-samples/terminateExperiment.php
deleted file mode 100644
index b701abf..0000000
--- a/samples/php-cli-samples/terminateExperiment.php
+++ /dev/null
@@ -1,101 +0,0 @@
-<?php
-namespace Airavata\Client\Samples;
-
-$airavataconfig = parse_ini_file("airavata-client-properties.ini");
-
-$GLOBALS['THRIFT_ROOT'] = $airavataconfig['THRIFT_LIB_DIR'];
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TTransport.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TSocket.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TBinaryProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TApplicationException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TProtocolException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Base/TBase.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TMessageType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Factory/TStringFuncFactory.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/TStringFunc.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/Core.php';
-
-$GLOBALS['AIRAVATA_ROOT'] = $airavataconfig['AIRAVATA_PHP_STUBS_DIR'];
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Airavata.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'Model/Workspace/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 
'Model/Workspace/Experiment/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Error/Types.php';
-
-use Airavata\API\Error\AiravataClientException;
-use Airavata\API\Error\AiravataSystemException;
-use Airavata\API\Error\ExperimentNotFoundException;
-use Airavata\API\Error\InvalidRequestException;
-use Airavata\Client\AiravataClientFactory;
-use Airavata\Model\Workspace\Experiment\ExperimentState;
-use Thrift\Exception\TTransportException;
-use Thrift\Protocol\TBinaryProtocol;
-use Thrift\Transport\TBufferedTransport;
-use Thrift\Transport\TSocket;
-use Airavata\API\AiravataClient;
-
-$transport = new TSocket($airavataconfig['AIRAVATA_SERVER'], 
$airavataconfig['AIRAVATA_PORT']);
-$transport->setRecvTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
-
-$protocol = new TBinaryProtocol($transport);
-$transport->open();
-$airavataclient = new AiravataClient($protocol);
-
-
-if ($argc != 2)
-{
-    echo 'php terminateExperiment.php <experiment_id>';
-}
-else
-{
-    terminate_experiment($argv[1]);
-
-    echo 'If there are no exceptions, assume the experiment terminated 
successfully';
-}
-
-
-$transport->close();
-
-
-/**
- * End the experiment with the given ID
- * @param $expId
- */
-function terminate_experiment($expId)
-{
-    global $airavataclient;
-
-    try
-    {
-        $airavataclient->terminateExperiment($expId);
-    }
-    catch (InvalidRequestException $ire)
-    {
-        echo 'InvalidRequestException!\n\n' . $ire->getMessage();
-    }
-    catch (ExperimentNotFoundException $enf)
-    {
-        echo 'ExperimentNotFoundException!\n\n' . $enf->getMessage();
-    }
-    catch (AiravataClientException $ace)
-    {
-        echo 'AiravataClientException!\n\n' . $ace->getMessage();
-    }
-    catch (AiravataSystemException $ase)
-    {
-        echo 'AiravataSystemException!\n\n' . $ase->getMessage();
-    }
-    catch (TTransportException $tte)
-    {
-        echo 'TTransportException!\n\n' . $tte->getMessage();
-    }
-    catch (\Exception $e)
-    {
-        echo 'Exception!\n\n' . $e->getMessage();
-    }
-}
-
-?>
-

http://git-wip-us.apache.org/repos/asf/airavata/blob/4d338df2/samples/php-cli-samples/updateExperiment.php
----------------------------------------------------------------------
diff --git a/samples/php-cli-samples/updateExperiment.php 
b/samples/php-cli-samples/updateExperiment.php
deleted file mode 100644
index e3aefd3..0000000
--- a/samples/php-cli-samples/updateExperiment.php
+++ /dev/null
@@ -1,155 +0,0 @@
-<?php
-namespace Airavata\Client\Samples;
-
-$airavataconfig = parse_ini_file("airavata-client-properties.ini");
-
-$GLOBALS['THRIFT_ROOT'] = $airavataconfig['THRIFT_LIB_DIR'];
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TTransport.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TSocket.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TBinaryProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TApplicationException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TProtocolException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Base/TBase.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TMessageType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Factory/TStringFuncFactory.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/TStringFunc.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/Core.php';
-
-$GLOBALS['AIRAVATA_ROOT'] = $airavataconfig['AIRAVATA_PHP_STUBS_DIR'];
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Airavata.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'Model/Workspace/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 
'Model/Workspace/Experiment/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Error/Types.php';
-
-use Airavata\API\Error\AiravataClientException;
-use Airavata\API\Error\AiravataSystemException;
-use Airavata\API\Error\ExperimentNotFoundException;
-use Airavata\API\Error\InvalidRequestException;
-use Airavata\Client\AiravataClientFactory;
-use Airavata\Model\Workspace\Experiment\ExperimentState;
-use Thrift\Exception\TTransportException;
-use Thrift\Protocol\TBinaryProtocol;
-use Thrift\Transport\TBufferedTransport;
-use Thrift\Transport\TSocket;
-use Airavata\API\AiravataClient;
-
-$transport = new TSocket($airavataconfig['AIRAVATA_SERVER'], 
$airavataconfig['AIRAVATA_PORT']);
-$transport->setRecvTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
-
-$protocol = new TBinaryProtocol($transport);
-$transport->open();
-$airavataclient = new AiravataClient($protocol);
-
-
-
-
-if ($argc != 2)
-{
-    echo 'php updateExperiment.php <experiment_id>';
-}
-else
-{
-    update_experiment($argv[1]);
-}
-
-
-
-
-
-
-
-
-
-
-$transport->close();
-
-
-/**
- * Get the experiment with the given ID
- * @param $expId
- * @return null
- */
-function get_experiment($expId)
-{
-    global $airavataclient;
-
-    try
-    {
-        return $airavataclient->getExperiment($expId);
-    }
-    catch (InvalidRequestException $ire)
-    {
-        echo 'InvalidRequestException!<br><br>' . $ire->getMessage();
-    }
-    catch (ExperimentNotFoundException $enf)
-    {
-        echo 'ExperimentNotFoundException!<br><br>' . $enf->getMessage();
-    }
-    catch (AiravataClientException $ace)
-    {
-        echo 'AiravataClientException!<br><br>' . $ace->getMessage();
-    }
-    catch (AiravataSystemException $ase)
-    {
-        echo 'AiravataSystemException during get!<br><br>' . 
$ase->getMessage();
-    }
-    catch (TTransportException $tte)
-    {
-        echo 'TTransportException!<br><br>' . $tte->getMessage();
-    }
-    catch (\Exception $e)
-    {
-        echo 'Exception!<br><br>' . $e->getMessage();
-    }
-
-}
-
-/**
- * Update the experiment with the given ID
- * @param $expId
- * @return null
- */
-function update_experiment($expId)
-{
-    global $airavataclient;
-
-    try
-    {
-        //create new experiment to receive the clone
-        $experiment = $airavataclient->getExperiment($expId);
-        $experiment->name .= time();
-
-        $airavataclient->updateExperiment($expId, $experiment);
-
-        $updatedExperiment = $airavataclient->getExperiment($expId);
-
-        echo "Experiment $experiment->name updated:\n\n";
-        var_dump($updatedExperiment);
-    }
-    catch (InvalidRequestException $ire)
-    {
-        echo 'InvalidRequestException!<br><br>' . $ire->getMessage();
-    }
-    catch (ExperimentNotFoundException $enf)
-    {
-        echo 'ExperimentNotFoundException!<br><br>' . $enf->getMessage();
-    }
-    catch (AiravataClientException $ace)
-    {
-        echo 'AiravataClientException!<br><br>' . $ace->getMessage();
-    }
-    catch (AiravataSystemException $ase)
-    {
-        echo 'AiravataSystemException during update!<br><br>' . 
$ase->getMessage();
-    }
-    catch (TTransportException $tte)
-    {
-        echo 'TTransportException!<br><br>' . $tte->getMessage();
-    }
-}
-
-?>
-

http://git-wip-us.apache.org/repos/asf/airavata/blob/4d338df2/samples/php-cli-samples/updateProject.php
----------------------------------------------------------------------
diff --git a/samples/php-cli-samples/updateProject.php 
b/samples/php-cli-samples/updateProject.php
deleted file mode 100644
index f77ab8c..0000000
--- a/samples/php-cli-samples/updateProject.php
+++ /dev/null
@@ -1,75 +0,0 @@
-<?php
-namespace Airavata\Client\Samples;
-
-$airavataconfig = parse_ini_file("airavata-client-properties.ini");
-
-$GLOBALS['THRIFT_ROOT'] = $airavataconfig['THRIFT_LIB_DIR'];
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TTransport.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Transport/TSocket.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Protocol/TBinaryProtocol.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TApplicationException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Exception/TProtocolException.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Base/TBase.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Type/TMessageType.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'Factory/TStringFuncFactory.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/TStringFunc.php';
-require_once $GLOBALS['THRIFT_ROOT'] . 'StringFunc/Core.php';
-
-$GLOBALS['AIRAVATA_ROOT'] = $airavataconfig['AIRAVATA_PHP_STUBS_DIR'];
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Airavata.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'Model/Workspace/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 
'Model/Workspace/Experiment/Types.php';
-require_once $GLOBALS['AIRAVATA_ROOT'] . 'API/Error/Types.php';
-
-use Airavata\API\Error\AiravataClientException;
-use Airavata\API\Error\AiravataSystemException;
-use Airavata\API\Error\InvalidRequestException;
-use Airavata\Client\AiravataClientFactory;
-use Thrift\Protocol\TBinaryProtocol;
-use Thrift\Transport\TBufferedTransport;
-use Thrift\Transport\TSocket;
-use Airavata\API\AiravataClient;
-
-$transport = new TSocket($airavataconfig['AIRAVATA_SERVER'], 
$airavataconfig['AIRAVATA_PORT']);
-$transport->setRecvTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
-
-$protocol = new TBinaryProtocol($transport);
-$transport->open();
-$airavataclient = new AiravataClient($protocol);
-
-
-try 
-{
-                 if($argc != 3) 
-                 {
-                                        echo 'php updateProject.php 
<project_id> <project_description>';
-                 }
-                 else
-                 {
-                                        
$project=$airavataclient->getProject($argv[1]);
-                                        $project->description = $argv[2];
-                                        
$airavataclient->updateProject($argv[1], $project);
-                                        echo 'Project '.$argv[1] . ' 
succesfully modified.';
-                 }
-}
-
-catch (InvalidRequestException $ire)
-{
-    print 'InvalidRequestException: ' . $ire->getMessage()."\n";
-}
-catch (AiravataClientException $ace)
-{
-    print 'Airavata System Exception: ' . $ace->getMessage()."\n";
-}
-catch (AiravataSystemException $ase)
-{
-    print 'Airavata System Exception: ' . $ase->getMessage()."\n";
-}
-
-$transport->close();
-
-?>
-

Reply via email to