airavata-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ramin...@apache.org
Subject [1/2] git commit: modified the connection class and added send timeout (thanks to supun)
Date Thu, 03 Jul 2014 15:33:06 GMT
Repository: airavata
Updated Branches:
  refs/heads/master 15c863015 -> 226250038


modified the connection class and added send timeout (thanks to supun)


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

Branch: refs/heads/master
Commit: ca1662b7f916bdc77357d7f5ccd98b669aba1013
Parents: 0a00253
Author: raminder <raminder@apache.org>
Authored: Thu Jul 3 11:32:24 2014 -0400
Committer: raminder <raminder@apache.org>
Committed: Thu Jul 3 11:32:24 2014 -0400

----------------------------------------------------------------------
 .../php-cli-samples/add-compute-resources.php   |  1 +
 .../airavata-client-api-tester.php              |  1 +
 .../airavata-client-properties.ini              |  2 +-
 .../php-cli-samples/cloneExperiment.php         | 13 ++----
 .../php-cli-samples/createExperiment.php        |  9 ++--
 .../resources/php-cli-samples/createProject.php | 10 ++---
 .../resources/php-cli-samples/getAPIVersion.php | 11 ++---
 .../php-cli-samples/getAiravataClient.php       | 44 ++++++++++++++++++++
 .../getAllExperimentsInProject.php              | 10 ++---
 .../php-cli-samples/getAllUserExperiments.php   | 12 ++----
 .../php-cli-samples/getAllUserProjects.php      |  9 ++--
 .../resources/php-cli-samples/getAppModule.php  |  9 ++--
 .../getApplicationDeployedResources.php         |  9 ++--
 .../resources/php-cli-samples/getExperiment.php |  9 ++--
 .../php-cli-samples/getExperimentOutputs.php    | 10 ++---
 .../php-cli-samples/getExperimentStatus.php     |  9 ++--
 .../php-cli-samples/launchExperiment.php        |  9 ++--
 .../list-application-interfaces.php             |  1 +
 .../php-cli-samples/list-compute-resources.php  |  1 +
 .../php-cli-samples/registerAppModule.php       |  9 ++--
 .../search_experiments_by_application.php       |  9 ++--
 .../search_experiments_by_description.php       |  9 ++--
 .../search_experiments_by_name.php              |  9 ++--
 .../php-cli-samples/terminateExperiment.php     |  9 ++--
 .../php-cli-samples/updateExperiment.php        |  9 ++--
 .../resources/php-cli-samples/updateProject.php | 10 ++---
 26 files changed, 110 insertions(+), 133 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/add-compute-resources.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/add-compute-resources.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/add-compute-resources.php
index 0413903..628f40c 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/add-compute-resources.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/add-compute-resources.php
@@ -41,6 +41,7 @@ $airavataconfig = parse_ini_file("airavata-client-properties.ini");
 
 $transport = new TSocket($airavataconfig['APP_CATALOG_SERVER'], $airavataconfig['APP_CATALOG_PORT']);
 $transport->setRecvTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
+$transport->setSendTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
 
 $protocol = new TBinaryProtocol($transport);
 

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/airavata-client-api-tester.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/airavata-client-api-tester.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/airavata-client-api-tester.php
index 17d4b80..04f0fce 100755
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/airavata-client-api-tester.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/airavata-client-api-tester.php
@@ -50,6 +50,7 @@ $transport->setRecvTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
 */
 $transport = new TSocket('gw127.iu.xsede.org', 8930);
 $transport->setRecvTimeout(20000);
+$transport->setSendTimeout(20000);
 $protocol = new TBinaryProtocol($transport);
 $transport->open();
 $airavataclient = new AiravataClient($protocol);

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/airavata-client-properties.ini
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/airavata-client-properties.ini
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/airavata-client-properties.ini
index 1a94ffd..0c38851 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/airavata-client-properties.ini
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/airavata-client-properties.ini
@@ -15,4 +15,4 @@ AIRAVATA_SERVER = "localhost"
 AIRAVATA_PORT = 8930
 
 ; Time out value to give enough breathing room for client to get synchronous responses back
-AIRAVATA_TIMEOUT = 5000
\ No newline at end of file
+AIRAVATA_TIMEOUT = 5000

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/cloneExperiment.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/cloneExperiment.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/cloneExperiment.php
index 35cd70c..61a2d45 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/cloneExperiment.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/cloneExperiment.php
@@ -37,16 +37,9 @@ 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);
-
-
-//$expId = 'experiment2_8f9c0ccc-6392-47b3-bcde-f4e82557bc32';
-
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 if ($argc != 2)
 {

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/createExperiment.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/createExperiment.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/createExperiment.php
index e37c463..da8b6d4 100755
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/createExperiment.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/createExperiment.php
@@ -40,12 +40,9 @@ 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);
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 try
 {

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/createProject.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/createProject.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/createProject.php
index 6e33199..daa6da5 100755
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/createProject.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/createProject.php
@@ -34,13 +34,9 @@ use Thrift\Transport\TSocket;
 use Airavata\API\AiravataClient;
 use Airavata\Model\Workspace\Project;
 
-$transport = new TSocket($airavataconfig['AIRAVATA_SERVER'], $airavataconfig['AIRAVATA_PORT']);
-$transport->setRecvTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
-
-$protocol = new TBinaryProtocol($transport);
-$transport->open();
-$airavataclient = new AiravataClient($protocol);
-
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 try
 {

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAPIVersion.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAPIVersion.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAPIVersion.php
index 7a2e82e..d52f110 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAPIVersion.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAPIVersion.php
@@ -32,16 +32,13 @@ 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);
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 try
 {
-    $version = $airavataclient->getAPIVersion();
+	$version = $airavataclient->getAPIVersion();
 }
 catch (TException $texp)
 {

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAiravataClient.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAiravataClient.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAiravataClient.php
new file mode 100644
index 0000000..2a39752
--- /dev/null
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAiravataClient.php
@@ -0,0 +1,44 @@
+<?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/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']);
+$transport->setSendTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
+
+$protocol = new TBinaryProtocol($transport);
+$transport->open();
+$airavataclient = new AiravataClient($protocol);
+
+
+?>

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAllExperimentsInProject.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAllExperimentsInProject.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAllExperimentsInProject.php
index 0de2d2c..10a1ec4 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAllExperimentsInProject.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAllExperimentsInProject.php
@@ -33,13 +33,9 @@ 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);
-
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 try
 {

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAllUserExperiments.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAllUserExperiments.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAllUserExperiments.php
index f1877a0..d0d3afc 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAllUserExperiments.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAllUserExperiments.php
@@ -33,15 +33,9 @@ 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);
-
-
-
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 try
 {

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAllUserProjects.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAllUserProjects.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAllUserProjects.php
index 274f5d9..6da7521 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAllUserProjects.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAllUserProjects.php
@@ -33,12 +33,9 @@ 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);
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 
 

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAppModule.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAppModule.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAppModule.php
index 9af252e..746de5d 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAppModule.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getAppModule.php
@@ -35,12 +35,9 @@ 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);
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 
 if (count($argv) < 2) {

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getApplicationDeployedResources.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getApplicationDeployedResources.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getApplicationDeployedResources.php
index eccc201..5de6e52 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getApplicationDeployedResources.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getApplicationDeployedResources.php
@@ -35,12 +35,9 @@ 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);
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 
 

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getExperiment.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getExperiment.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getExperiment.php
index 2872a61..b809927 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getExperiment.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getExperiment.php
@@ -35,12 +35,9 @@ 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);
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 
 if (count($argv) < 2) {

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getExperimentOutputs.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getExperimentOutputs.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getExperimentOutputs.php
index 34b5d6e..3e9f557 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getExperimentOutputs.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getExperimentOutputs.php
@@ -36,13 +36,9 @@ 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);
-
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 
 if ($argc != 2)

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getExperimentStatus.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getExperimentStatus.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getExperimentStatus.php
index e931a4e..2ef5afa 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getExperimentStatus.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/getExperimentStatus.php
@@ -35,12 +35,9 @@ 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);
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 
 if (count($argv) < 2) {

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/launchExperiment.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/launchExperiment.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/launchExperiment.php
index 4f528b6..d248064 100755
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/launchExperiment.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/launchExperiment.php
@@ -37,12 +37,9 @@ 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);
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 try
 {

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/list-application-interfaces.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/list-application-interfaces.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/list-application-interfaces.php
index 7d7c9ce..6d308fc 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/list-application-interfaces.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/list-application-interfaces.php
@@ -40,6 +40,7 @@ $airavataconfig = parse_ini_file("airavata-client-properties.ini");
 
 $transport = new TSocket($airavataconfig['APP_CATALOG_SERVER'], $airavataconfig['APP_CATALOG_PORT']);
 $transport->setRecvTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
+$transport->setSendTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
 
 $protocol = new TBinaryProtocol($transport);
 

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/list-compute-resources.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/list-compute-resources.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/list-compute-resources.php
index cc5c790..c381551 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/list-compute-resources.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/list-compute-resources.php
@@ -41,6 +41,7 @@ $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']);
+$transport->setSendTimeout($airavataconfig['AIRAVATA_TIMEOUT']);
 
 $protocol = new TBinaryProtocol($transport);
 

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/registerAppModule.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/registerAppModule.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/registerAppModule.php
index e939610..db053ac 100755
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/registerAppModule.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/registerAppModule.php
@@ -41,12 +41,9 @@ 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);
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 try
 {

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/search_experiments_by_application.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/search_experiments_by_application.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/search_experiments_by_application.php
index 4340f9e..3d4419e 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/search_experiments_by_application.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/search_experiments_by_application.php
@@ -33,12 +33,9 @@ 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);
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 
 try

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/search_experiments_by_description.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/search_experiments_by_description.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/search_experiments_by_description.php
index 631ad15..9951aa6 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/search_experiments_by_description.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/search_experiments_by_description.php
@@ -33,12 +33,9 @@ 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);
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 
 try

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/search_experiments_by_name.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/search_experiments_by_name.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/search_experiments_by_name.php
index d71a166..932cfc9 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/search_experiments_by_name.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/search_experiments_by_name.php
@@ -33,12 +33,9 @@ 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);
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 
 try

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/terminateExperiment.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/terminateExperiment.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/terminateExperiment.php
index b701abf..5f81875 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/terminateExperiment.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/terminateExperiment.php
@@ -36,12 +36,9 @@ 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);
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 
 if ($argc != 2)

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/updateExperiment.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/updateExperiment.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/updateExperiment.php
index e3aefd3..af806c2 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/updateExperiment.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/updateExperiment.php
@@ -36,12 +36,9 @@ 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);
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 
 

http://git-wip-us.apache.org/repos/asf/airavata/blob/ca1662b7/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/updateProject.php
----------------------------------------------------------------------
diff --git a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/updateProject.php
b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/updateProject.php
index f77ab8c..ea9f5c5 100644
--- a/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/updateProject.php
+++ b/airavata-api/airavata-client-sdks/airavata-php-sdk/src/main/resources/php-cli-samples/updateProject.php
@@ -33,13 +33,9 @@ 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);
-
+include 'getAiravataClient.php';
+global $airavataclient;
+global $transport;
 
 try 
 {


Mime
View raw message