Code on demand
Encyclopedia
In distributed computing
Distributed computing
Distributed computing is a field of computer science that studies distributed systems. A distributed system consists of multiple autonomous computers that communicate through a computer network. The computers interact with each other in order to achieve a common goal...

, code on demand is a general term for any technology that sends executable software programs from a server computer to a client computer upon request from the client's software (e.g., browser).

Code on demand is a specific use of mobile code
Mobile code
In computer science, mobile code is software transferred between systems, e.g. transferred across a network or via a USB flash drive, and executed on a local system without explicit installation or execution by the recipient...

. A well-known example for the code on demand paradigm are Java applet
Java applet
A Java applet is an applet delivered to users in the form of Java bytecode. Java applets can run in a Web browser using a Java Virtual Machine , or in Sun's AppletViewer, a stand-alone tool for testing applets...

s: An applet's program code lies inactive on some web server
Web server
Web server can refer to either the hardware or the software that helps to deliver content that can be accessed through the Internet....

 until a user (client) requests a web page that contains a link to the applet using the client's web browser
Web browser
A web browser is a software application for retrieving, presenting, and traversing information resources on the World Wide Web. An information resource is identified by a Uniform Resource Identifier and may be a web page, image, video, or other piece of content...

. Upon this request, the web page and the applet are transported to the user's machine using HTTP. When the page is displayed, the applet is started in the browser and executes locally, inside the user's computer until it is stopped (e.g., by the user leaving the applet's web page). This completes the applet's life cycle.
The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK