【发布时间】:2018-07-10 01:01:38
【问题描述】:
OpenTok 有一个“小”问题,无法使用。
当我尝试创建新会话时,系统卡住了。 :(
我已将问题定位到一个名为“createSession”的函数,位于“/OpenTok/Util/Client.php”。
这是函数:
public function createSession($options)
{
$request = new Request('POST', '/session/create');
try {
$response = $this->client->send($request, [
'debug' => $this->isDebug(),
'form_params' => $this->postFieldsForOptions($options)
]);
$sessionXml = $this->getResponseXml($response);
} catch (\RuntimeException $e) {
// TODO: test if we have a parse exception and handle it, otherwise throw again
throw $e;
} catch (\Exception $e) {
$this->handleException($e);
return;
}
return $sessionXml;
}
一旦尝试将数据发送到 $response,它就会卡住。
正在发送的数据是:
$this->isDebug() = bool(false);
$this->postFieldsForOptions($options) = Array ( [archiveMode] => manual [p2p.preference] => enabled [api_key] => 46118732 )
一开始我还以为是synk时间不通,影响JWTas described in this post的问题,但是按照那里描述的,我也解决不了。
谁能指导我找到正确的解决方案?
提前致谢,
阿米特。
【问题讨论】:
-
TokBox 开发者布道者在这里。能否分享一下您使用的是哪个 SDK 版本?
-
'OPENTOK_SDK_VERSION', '4.0.0')
-
谢谢,阿米特。您能否在 repo 上创建一个问题,以便我们进一步调查? github.com/opentok/OpenTok-PHP-SDK