dmishin / python-remote Goto Github PK
View Code? Open in Web Editor NEWLibrary for transparent communication between several python processes
Library for transparent communication between several python processes
Simple RPC client/server in pure python, allowing transparent access to the remote objects. Developed and tested in Python 2.5 and 2.7. What is it: 1) Take some application, supporting Python (such as Golly). 2) In that application, create and run the RPC server from this script (PythonServer class) 3) Now in the regular Pyhton script, you can do the following: #Create client client = FarSide( ... some appropriate parameters here ... ) #Import module, available only at the server remote_golly = client.import_module( "golly" ) #call any method of theremote module. remote_golly.message( "Hello" ) All calls to the remote objects are serialized, sent to the sever via socket, then executed on the server, and results are received on the client. Everything is done absolutely transparently, client can work ith remote objects in the absolutely same way as if they were available locally. Not only modules can be remoted: any object can be (remember, that functions, methods etc are also objects in Python). If you have a remote function, that expects a remote object as argument, you can call this function without any additional work. Possible usages: - Integration of many Python-enabled applications in one script. - Centralized testing of the applications, providing Python interface. Drawbacks: It is slow. Each call to the remote method involves serialization (with pickle), transfer via socket and deserialization. Classes: PythonServer - server object. SHould be created in the application. FarSide - client object. Gives transparent access to the objects, exposed to the server. Files: python_remote.py - the library itself. pysock_server.py - sample server code. pysock_client.py - sample client code.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.