当前位置: 代码迷 >> PHP >> php创设zookeeper临时变量
  详细解决方案

php创设zookeeper临时变量

热度:83   发布时间:2016-04-28 18:24:22.0
php创建zookeeper临时变量

临时变量会在连接断开之后被删除。

<?php        $zookeeper = new Zookeeper("127.0.0.1:2182");        $k = "/zk_test3";        $acl = array(                array(                'perms' => Zookeeper::PERM_ALL,                'scheme' => 'world',                'id' => 'anyone',        ));        $zookeeper->create("/zk_test3", "1000", $acl, Zookeeper::EPHEMERAL);        print_r(array(                $zookeeper->get($k),         ));        sleep(5);

?

?

?

  相关解决方案