Esempio n. 1
0
 def create_connection(self):
     try:
         self.uri = pyro.create_uri(self.address, self.port, "ForArbiter", self.__class__.use_ssl)
         self.con = pyro.getProxy(self.uri)
         pyro.set_timeout(self.con, self.timeout)
     except Pyro_exp_pack , exp:
         self.con = None
         logger.log('Error : in creation connexion for %s : %s' % (self.get_name(), str(exp)))
 def create_connection(self):
     try:
         self.uri = pyro.create_uri(self.address, self.port, "ForArbiter", self.__class__.use_ssl)
         # By default Pyro got problem in connect() function that can take
         # long seconds to raise a timeout. And even with the _setTimeout()
         # call. So we change the whole default connect() timeout
         socket.setdefaulttimeout(self.timeout)
         self.con = pyro.getProxy(self.uri)
         # But the multiprocessing module is not copatible with it!
         # so we must disable it imadiatly after
         socket.setdefaulttimeout(None)
         pyro.set_timeout(self.con, self.timeout)
     except Pyro_exp_pack , exp:
         # But the multiprocessing module is not copatible with it!
         # so we must disable it imadiatly after
         socket.setdefaulttimeout(None)
         self.con = None
         logger.log('Error : in creation connection for %s : %s' % (self.get_name(), str(exp)))
Esempio n. 3
0
 def create_connection(self):
     try:
         self.uri = pyro.create_uri(self.arb_satmap['address'],
                                    self.arb_satmap['port'], "ForArbiter",
                                    self.__class__.use_ssl)
         # By default Pyro got problem in connect() function that can take
         # long seconds to raise a timeout. And even with the _setTimeout()
         # call. So we change the whole default connect() timeout
         socket.setdefaulttimeout(self.timeout)
         self.con = pyro.getProxy(self.uri)
         # But the multiprocessing module is not copatible with it!
         # so we must disable it imadiatly after
         socket.setdefaulttimeout(None)
         pyro.set_timeout(self.con, self.timeout)
     except Pyro_exp_pack, exp:
         # But the multiprocessing module is not compatible with it!
         # so we must disable it imadiatly after
         socket.setdefaulttimeout(None)
         self.con = None
         logger.error("Creating connection for %s: %s" %
                      (self.get_name(), str(exp)))
Esempio n. 4
0
 def create_connection(self):
     self.uri = pyro.create_uri(self.address, self.port, "ForArbiter", self.__class__.use_ssl)
     self.con = pyro.getProxy(self.uri)
     pyro.set_timeout(self.con, self.timeout)
Esempio n. 5
0
 def create_connexion(self):
     self.uri = pyro.create_uri(self.address, self.port, "ForArbiter",
                                self.__class__.use_ssl)
     self.con = pyro.getProxy(self.uri)
     pyro.set_timeout(self.con, self.timeout)