Accessing RPyC from other applications

54 views
Skip to first unread message

Cooch

unread,
Nov 9, 2009, 5:11:09 PM11/9/09
to rpyc
Hi, guys!

I'm not sure is it possible to do using RPyC, but I think you could
give me right direction.
Problem:
I want to have server, written in Python. And I want to have a client
written for example in C++, but it should connect to my server and
it's network API is python code. It looks similar to RPyC except for
client implementation language of client. Any possibilities, ideas?

Dmitry

Tal Einat

unread,
Nov 9, 2009, 5:16:50 PM11/9/09
to rp...@googlegroups.com
You shouldn't be using RPyC for this, since RPyC only works with Python on both sides. If you insist you can embed Python in your C++ client but that's probably much more complicated than other solutions.

I suggest using a different RPC protocol which has implementations in both languages, such as XML-RPC. Asking on comp.lang.python or general programming forums should yield more detailed answers.

Good luck,
- Tal

Cooch

unread,
Nov 10, 2009, 3:28:51 AM11/10/09
to rpyc
Hi, Tal!

Thank you for quick answer!

There's one trouble with XML-RPC: I want client to have very flexible
solution - so it could use any python construction. Probably, I really
should ask my question in python general group.

Dmitry.

Timothy Baldridge

unread,
Nov 10, 2009, 9:33:12 AM11/10/09
to rp...@googlegroups.com
> There's one trouble with XML-RPC: I want client to have very flexible
> solution - so it could use any python construction. Probably, I really
> should ask my question in python general group.


well, a very hack-ish way would be as follows:

Embed Python into your C++ app. Call Python routines from your C++
code. Use write these python routines such that they access Rpyc
objects across the net.

Yes, having the C++ part 100% C++ is not going to be easy/possible but
having your client be a C++/Python hybrid may be possible.

Timothy

--
“One of the main causes of the fall of the Roman Empire was
that–lacking zero–they had no way to indicate successful termination
of their C programs.”
(Robert Firth)

Reply all
Reply to author
Forward
0 new messages