예제 #1
0
 def test_xdcr_queries(self):
     XDCRReplicationBaseTest.setUp(self)
     self.load(self.gens_load)
     self._wait_for_replication_to_catchup()
     bucket = self._get_bucket('default', self.src_master)
     self.do_merge_bucket(self.src_master, self.dest_master, False, bucket)
     fn = getattr(self, self.method_name)
     fn()
     if self.with_reb == 'src':
         srv_in = self.servers[self.src_init +
                               self.dest_init:self.src_init +
                               self.dest_init + self.nodes_in]
         task = self.cluster.async_rebalance(self.servers[:self.src_init],
                                             srv_in, [])
     elif self.with_reb == 'dest':
         srv_in = self.servers[self.src_init +
                               self.dest_init:self.src_init +
                               self.dest_init + self.nodes_in]
         task = self.cluster.async_rebalance(
             self.servers[self.src_init:self.src_init + self.dest_init],
             srv_in, [])
     else:
         self.sleep(self.wait_timeout, "Wait some time and try again")
     fn = getattr(self, self.method_name)
     fn()
     if self.with_reb:
         task.result()
예제 #2
0
 def test_xdcr_queries(self):
     XDCRReplicationBaseTest.setUp(self)
     self.load(self.gens_load)
     self._wait_for_replication_to_catchup()
     bucket = self._get_bucket('default', self.src_master)
     self.do_merge_bucket(self.src_master, self.dest_master, False, bucket)
     fn = getattr(self, self.method_name)
     fn()
     if self.with_reb == 'src':
         srv_in = self.servers[self.src_init + self.dest_init :
                               self.src_init + self.dest_init + self.nodes_in]
         task = self.cluster.async_rebalance(self.servers[:self.src_init],
                            srv_in, [])
     elif self.with_reb == 'dest':
         srv_in = self.servers[self.src_init + self.dest_init :
                               self.src_init + self.dest_init + self.nodes_in]
         task = self.cluster.async_rebalance(self.servers[self.src_init:
                                                          self.src_init + self.dest_init],
                            srv_in, [])
     else:
         self.sleep(self.wait_timeout, "Wait some time and try again")
     fn = getattr(self, self.method_name)
     fn()
     if self.with_reb:
         task.result()
예제 #3
0
 def tearDown(self):
     try:
         XDCRReplicationBaseTest.tearDown(self)
     except:
         self.cluster.shutdown()
     if not self._testMethodName in ['suite_tearDown', 'suite_setUp']:
         return
     super(XDCRTests, self).tearDown()
예제 #4
0
 def tearDown(self):
     try:
         XDCRReplicationBaseTest.tearDown(self)
     except:
             self.cluster.shutdown()
     if not self._testMethodName in ['suite_tearDown', 'suite_setUp']:
         return
     super(XDCRTests, self).tearDown()
예제 #5
0
 def tearDown(self):
     if not self._testMethodName in ['suite_tearDown',
                                     'suite_setUp']:
         try:
             XDCRReplicationBaseTest.tearDown(self)
             return
         finally:
             self.cluster.shutdown()
     super(XDCRTests, self).tearDown()
예제 #6
0
 def test_xdcr_queries(self):
     XDCRReplicationBaseTest.setUp(self)
     self.load(self.gens_load)
     self._wait_for_replication_to_catchup()
     bucket = self._get_bucket('default', self.src_master)
     self.do_merge_bucket(self.src_master, self.dest_master, False, bucket)
     fn = getattr(self, self.method_name)
     fn()
     self.sleep(self.wait_timeout, "Wait some time and try again")
     fn = getattr(self, self.method_name)
     fn()