Java Reference
In-Depth Information
deploylet is implemented as a two-parts entity: a client and a server act as one and are syn-
chronized throughout the application lifecycle. For client-server communication, they use the
RMI protocol. The client side is implemented as a Plug-In-enabled applet for taking advantage
of its basic deployment features.
Figure 7.9 shows the deploylet activation sequence.
2HTTP GET
request
3 creation
method call
7
launch
Servlet
Server
Repository
Web
Browser
7HTML page
returned (with
OBJECT tag)
6 d name
returned
1End-user
specifies
Web address
4class
creation
5 instance
d created
8 The HTML
page is shown
to the user
Server
Deploylet
Client
Environment
End-User
F IGURE 7.9
The deploylet activation sequence.
Referring to Figure 7.9, we can individuate the following steps:
1. An end-user points the browser to the account applet page, in which a launching servlet
is activated.
2. The launch servlet requests the deploylet server-side creation service to a special RMI
server, and returns an HTML page containing the client-side deploylet to the browser
(implemented as an applet). From here on, the applet communicates directly with its
server-side counterpart, and the launch servlet is not invoked any more.
3. The final end-user experience is an applet appearing in its Web browser. If the Plug-In is
not installed on the client computer, a preliminary installation phase takes place (see pre-
ceding example for such details).
In Figures 7.9 and following Figure 7.10, the arrow shape indicates the kind of communication
mechanism employed. Normal arrows indicate normal (“local”) class reference or user interac-
tion, thick arrows denote HTTP communication, and dotted arrows mean RMI invocation.
After the applet is activated, the Plug-In features are used (that is, full J2SE applet support),
and the execution proceeds, as described in Figure 7.10.
Search WWH ::




Custom Search