示例#1
0
文件: Clear.php 项目: nekufa/basis
 public function run(Client $client)
 {
     $schema = $client->getSpace('_vspace');
     $response = $schema->select([], Index::SPACE_NAME);
     $data = $response->getData();
     foreach ($data as $row) {
         if ($row[1] == 0) {
             // user space
             $client->evaluate('box.space.' . $row[2] . ':drop{}');
         }
     }
 }
示例#2
0
 protected static function getTotalSelectCalls()
 {
     $response = self::$client->evaluate('return box.stat().SELECT.total');
     return $response->getData()[0];
 }
示例#3
0
 public function testGetConnection()
 {
     $this->assertSame($this->connection, $this->client->getConnection());
 }