dbapi.py
changeset 8670 f02139297beb
parent 8669 62213a34726e
child 8673 8ea63a2cc2cc
equal deleted inserted replaced
8669:62213a34726e 8670:f02139297beb
   123                 nsgroup = 'cubicweb'
   123                 nsgroup = 'cubicweb'
   124                 nsid = path
   124                 nsid = path
   125             return ns_get_proxy(nsid, defaultnsgroup=nsgroup, nshost=puri.netloc)
   125             return ns_get_proxy(nsid, defaultnsgroup=nsgroup, nshost=puri.netloc)
   126         except Exception, ex:
   126         except Exception, ex:
   127             raise ConnectionError(str(ex))
   127             raise ConnectionError(str(ex))
   128     elif method == 'tcp': # use zmq (see zmq documentation)
   128     elif method.startswith('zmqpickle-'):
   129         from cubicweb.zmqclient import ZMQRepositoryClient
   129         from cubicweb.zmqclient import ZMQRepositoryClient
   130         return ZMQRepositoryClient(uri)
   130         return ZMQRepositoryClient(uri)
   131     else:
   131     else:
   132         raise ConnectionError('unknown protocol: `%s`' % method)
   132         raise ConnectionError('unknown protocol: `%s`' % method)
   133 
   133