Thrift PHP TSocketPool client

Summary: Client that connects to one of an arbitrary pool of servers

Reviewed By: aditya


git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@664795 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/test/php/TestClient.php b/test/php/TestClient.php
index 27a66ea..235abbe 100644
--- a/test/php/TestClient.php
+++ b/test/php/TestClient.php
@@ -17,7 +17,7 @@
 require_once $GLOBALS['THRIFT_ROOT'].'/protocol/TBinaryProtocol.php';
 
 /** Include the socket layer */
-require_once $GLOBALS['THRIFT_ROOT'].'/transport/TSocket.php';
+require_once $GLOBALS['THRIFT_ROOT'].'/transport/TSocketPool.php';
 
 /** Include the socket layer */
 require_once $GLOBALS['THRIFT_ROOT'].'/transport/TBufferedTransport.php';
@@ -36,7 +36,11 @@
   $host = $argv[1];
 }
 
+$hosts = array('localhost', '8.2.3.5');
+
 $socket = new TSocket($host, $port);
+$socket = new TSocketPool($hosts, $port);
+$socket->setDebug(TRUE);
 
 if ($MODE == 'inline') {
   $transport = $socket;