python - ZeroRPC and IronPython -
i utilize first-class zerorpc project uses ironpython, doesn't seem supported.
i have tried downloading zip of source zerorpc
, running
"c:\program files (x86)\ironpython 2.7\ipy.exe" setup.py install
but see along way:
warning: build_py: byte-compiling disabled, skipping.
this not contradict answer: fast , scalable rpc between c# , cpython.
my question(s):
is possible zerorpc running ironpython , if so, please give me hint of how it? if not, there other equivalent packages provide functionality in ironpython? there's list here: what current selection doing rpc in python?, know if of these work ironpython?update 2 next @paweljasinski suggestion , updates pyzmq ironpython-backend, have tried following:
installed ironpython 2.7.5b2 or later installed 32 bit version of zeromq http://zeromq.org/distro:microsoft-windows cloneironpython-backend
branch https://github.com/paweljasinski/pyzmq/tree/ironpython-backend in pyzmq
dir, run ipy.exe setup.py install --user
clone zerorpc https://github.com/dotcloud/zerorpc-python in zerorpc-python
, run ipy.exe setup.py install --user
set environment variable: set pyzmq_backend=zmq.backend.ctypes
attempted utilize 'cooler' class illustration https://github.com/dotcloud/zerorpc-python, running ipy.exe -x:frames cooler.py
(cooler.py):
class cooler(object): """ various convenience methods create things cooler. """ def add_man(self, sentence): """ end sentence ", man!" create sound cooler, , homecoming result. """ homecoming sentence + ", man!" def add_42(self, n): """ add together 42 integer argument create cooler, , homecoming result. """ homecoming n + 42 def boat(self, sentence): """ replace sentence "i'm on boat!", , homecoming that, because it's cooler. """ homecoming "i'm on boat!" import zerorpc s = zerorpc.server(cooler()) s.bind("tcp://0.0.0.0:4242") s.run()
now see error:
traceback (most recent phone call last): file "c:\users\nlindop\appdata\roaming\python\ironpython27\site-packages\zmq\backend\select.py", line 26, in select_backend file "c:\users\nlindop\appdata\roaming\python\ironpython27\site-packages\zmq\backend\ctypes\__init__.py", line 26, in <module> file "c:\users\nlindop\appdata\roaming\python\ironpython27\site-packages\zmq\backend\ctypes\constants.py", line 16, in <module> importerror: no module named zmq
zerorpc appears pure python , based on pyzmq. in case can seek pyzmq ctypes
backend ironpython. https://github.com/paweljasinski/pyzmq/tree/ironpython-backend
ipy.exe setup.py install --user
. install should observe zmq , pick right dll activate ctypes backend, set environment variable pyzmq_backend=zmq.backend.ctypes
update: zerorpc has dependency on gevent
not available under ironpython, above instructions valid pyzmq under ironpython
python ironpython rpc zeromq
No comments:
Post a Comment