This is an automated email from the ASF dual-hosted git repository.
dcelasun pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/thrift.git
The following commit(s) were added to refs/heads/master by this push:
new 3b5c40c THRIFT-4970: PHP tutorial doesn't work with Thrift v0.12.0+
3b5c40c is described below
commit 3b5c40c6ea469ade1d537d558c43dfcd82d5d17f
Author: Kengo Seki <[email protected]>
AuthorDate: Wed Oct 9 06:53:14 2019 +0900
THRIFT-4970: PHP tutorial doesn't work with Thrift v0.12.0+
Client: php
This closes #1890.
---
tutorial/php/PhpClient.php | 6 +++---
tutorial/php/PhpServer.php | 6 +++---
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/tutorial/php/PhpClient.php b/tutorial/php/PhpClient.php
index 92dc3cb..eb2c2e5 100755
--- a/tutorial/php/PhpClient.php
+++ b/tutorial/php/PhpClient.php
@@ -5,7 +5,7 @@ namespace tutorial\php;
error_reporting(E_ALL);
-require_once __DIR__.'/../../lib/php/lib/ClassLoader/ThriftClassLoader.php';
+require_once __DIR__.'/../../vendor/autoload.php';
use Thrift\ClassLoader\ThriftClassLoader;
@@ -13,8 +13,8 @@ $GEN_DIR = realpath(dirname(__FILE__).'/..').'/gen-php';
$loader = new ThriftClassLoader();
$loader->registerNamespace('Thrift', __DIR__ . '/../../lib/php/lib');
-$loader->registerDefinition('shared', $GEN_DIR);
-$loader->registerDefinition('tutorial', $GEN_DIR);
+$loader->registerNamespace('shared', $GEN_DIR);
+$loader->registerNamespace('tutorial', $GEN_DIR);
$loader->register();
/*
diff --git a/tutorial/php/PhpServer.php b/tutorial/php/PhpServer.php
index 5a9b49b..749da3a 100755
--- a/tutorial/php/PhpServer.php
+++ b/tutorial/php/PhpServer.php
@@ -5,7 +5,7 @@ namespace tutorial\php;
error_reporting(E_ALL);
-require_once __DIR__.'/../../lib/php/lib/ClassLoader/ThriftClassLoader.php';
+require_once __DIR__.'/../../vendor/autoload.php';
use Thrift\ClassLoader\ThriftClassLoader;
@@ -13,8 +13,8 @@ $GEN_DIR = realpath(dirname(__FILE__).'/..').'/gen-php';
$loader = new ThriftClassLoader();
$loader->registerNamespace('Thrift', __DIR__ . '/../../lib/php/lib');
-$loader->registerDefinition('shared', $GEN_DIR);
-$loader->registerDefinition('tutorial', $GEN_DIR);
+$loader->registerNamespace('shared', $GEN_DIR);
+$loader->registerNamespace('tutorial', $GEN_DIR);
$loader->register();
/*