示例#1
0
 public function __construct($options = array())
 {
     $this->config = array_merge($this->config, $options);
     $this->ip = $_SERVER['SERVER_ADDR'];
     $this->providersCluster = Cluster::getInstance();
     $this->zookeeper = $this->getZookeeper($this->config['registry_address']);
 }
示例#2
0
 public function __construct($options = array())
 {
     $this->config = array_merge($this->config, $options);
     $this->ip = $this->achieveRegisterIp();
     $this->providersCluster = Cluster::getInstance();
     $this->zookeeper = $this->makeZookeeper($this->config['registry_address']);
 }
示例#3
0
 public function __construct($url = null, $debug = false)
 {
     // server URL
     $this->url = $url;
     $this->id = 1;
     $this->debug;
     $this->cluster = Cluster::getInstance();
 }