0
$\begingroup$

Let's say I have two computers on a network. I want to write code in some language on machine A, send the code in an efficient way over a network, and run the code on machine B. It seems to me that this would be inherently slow and would run into a bundle of problems (not having required dependencies) but perhaps some work has already been done on this problem? Is there any known processes or systems that already do this?

$\endgroup$
  • $\begingroup$ Lots of work have been done by ... writers of viruses that execute remote code. $\endgroup$ – Apass.Jack Jan 12 at 18:23
  • 1
    $\begingroup$ Cross-compiler if machine A and B differ, RPC if you have access to second machine. If this is about pure code, the standard way is to send all dependencies or package if the language supports it. Standard way is to do deployment (release), that is compiled or precompiled. In current form your goal is not clear to me. $\endgroup$ – Evil Jan 12 at 18:52
  • $\begingroup$ I don't really see how missing dependencies on B would be any bigger problem than missing dependencies on A. They're just one of the things you have to sort out when you want to compile and execute code. Just like you'd need to ensure that machine B had the executing-code-remotely software installed. $\endgroup$ – David Richerby Jan 12 at 20:34
  • $\begingroup$ Also, what are you looking for in an answer, here? Talking about known processes or systems makes this sound like more of a programming question (which would be off-topic) than a question about the underlying science. At the CS level, I'm not sure this is conceptually much different from RPC, except that you're sending the code across to the remote machine instead of invoking code that's already there. But code is just a fancy form of data, so RPC with the code as the function argument is a solution at the CS level. $\endgroup$ – David Richerby Jan 13 at 9:57
  • 1
    $\begingroup$ @Evil Oh, OK. It wasn't clear that that was what you meant by "have access." $\endgroup$ – David Richerby Jan 13 at 15:03
0
$\begingroup$

From memory Java applets and COM components could do this (But mostly discontinued due to security reasons) The approach was mostly based on a pull strategy. That is Machine B pulled code from Machine A and then executed in Machine B.

OS and application updates (e.g. Windows Update) also do this approach. They download the update from a different machine and execute locally.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.