Register for EarthWeb's Million Dollar Sweepstakes!
home account info subscribe login search My ITKnowledge FAQ/help site map contact us


 
Brief Full
 Advanced
      Search
 Search Tips
To access the contents, click the chapter and section titles.

Platinum Edition Using HTML 4, XML, and Java 1.2
(Publisher: Macmillan Computer Publishing)
Author(s): Eric Ladd
ISBN: 078971759x
Publication Date: 11/01/98

Bookmark It

Search this book:
 
Previous Table of Contents Next


FastCGI

FastCGI, created by Open Market Inc., extends the capabilities of CGI while removing the overhead associated with executing CGI scripts. Much like CGI, FastCGI is a non-proprietary system in which script run continuously in the background, handling requests as needed.

Like CGI, FastCGI is language independent. You can create scripts in the language that you are most comfortable with. Like CGI, scripts created with FastCGI run separately from the Web server maintaining the security associated with CGI.


NOTE:  The Apache Web server is one of the most used Web servers that supports the FastCGI specification. If you’re interested in FastCGI and Apache, you should also check out mod_perl, which will greatly increase the speed of CGI scripts.

FastCGI also makes use of distributed computing. Instead of serving documents and executing CGI scripts on one machine, you can use multiple machines sharing the load.

ON THE WEB
http://www.fastcgi.com/ Contains additional information on the FastCGI specification, along with examples on how to convert your current CGI applications to take advantage of the FastCGI specification.

Java Servlets

Java Servlets were created to eliminate the problems that currently exist when using Java as CGI applications. Normally server-side Java applications require the use and overhead of the Java Virtual Machine. Each time a server-side Java application runs, the virtual machine needs to be loaded as well. Also, server-side Java applications have difficulty accessing environmental variables, which are commonly used in CGI scripting. Java servlets reduce these problems. Sun Microsystems has started development that includes an API that enables Java applications to act as CGI applications. Of course, your applications are not limited to serving requests from the Web, they can access existing sockets, protocols created by the developer, or both.

See Chapter 36, “Introduction to Java,” p. 963, to find out more information on Java and building Java applications.

Applications created that use the Java Server API are commonly known as servlets. Servlets are simply server-side applets. The difference between server-side applets and client-side applets, however, is that servlets do not utilize a user interface like that associated with client-side Java applets.

Servlets are Java applications that extend the traditional functionality of Web servers. Even so, servlets are not confined to the world of the Web. When a connection is made to the servlet, the servlet can create a connection between a client-side applet and a servlet, which communicate using a custom protocol with a new connection.


NOTE:  Java servlets work with many Web servers, including Sun’s Java Web server, the Apache Web server using the mod_jserv module, and with Microsoft’s Web server (MIIS) using LiveSoftware’s JRun.

You can run servlets continuously in the background or dynamically load them in a running server (if the server allows this function). You can also execute them either from a local disk or from the network. As such, a new servlet does not have to be executed for every request, thus greatly reducing the load of the server. The Web server calls the servlet, which in turn, responds to the request. Lastly, servlets don’t need to be running in a Web server environment. The servlet API was designed so that servlets can run in conjunction with other types of servers as long as those servers can be accessed via the net.

ON THE WEB
http://jserv.java.sun.com/products/java-server/servlets/environments.html Lists various Web servers that allow the use of Java servlets.
http://www.javasoft.com/products/java-server/servlets/index.html The Java servlet white paper and the Servlet Development Kit can be found at this site.
http://www.javasoft.com/products/java-server/alpha2/doc/servlet_tutorial/examples.html Provides an example of a counter servlet and contains additional examples on how to use Java servlets.

Server-Side JavaScript

Just as Java has been used to run on the server side, Netscape, using LiveWire, has created an environment to do the same thing with JavaScript (Microsoft provides some reference to using server-side JavaScript as a batch file with ScriptEase 4.0). JavaScript as a server-side application can be used to extend the capabilities of the server. By using JavaScript, the Web server can do more without calling external programs. This makes it easier for Web developers to add features to their pages where the browser is used in conjunction with the application running on the server while reducing the load on the Web server.

See Chapter 18, “Introduction to JavaScripting,” p. 439, for more information on JavaScript.

Visual Basic, Scripting Edition and Active Server Pages

Following the incredible popularity of the Internet and the unprecedented success of companies such as Netscape, Microsoft entered the arena and declared war. With its own Web server, its own browsers, and a plethora of back end services—and don’t forget unparalleled marketing muscle and name recognition—Microsoft has already made an impact on the way people look at and use the Internet.

Along with some spectacular blunders, Microsoft has had its share of spectacular successes. One such success is Visual Basic, the all-purpose, almost-anyone-can-learn-it Windows programming language. VB was so successful that Microsoft made it the backbone of their office application suite. Visual Basic for Applications (VBA) has become the de facto standard scripting language for Windows. Although not as lean as some other options (Borland’s Delphi in some regards, or C programs in general), VB nevertheless has two golden advantages: it’s easy to learn, and it has widespread support from third-party vendors and users.


Previous Table of Contents Next


Products |  Contact Us |  About Us |  Privacy  |  Ad Info  |  Home

Use of this site is subject to certain Terms & Conditions, Copyright © 1996-2000 EarthWeb Inc.
All rights reserved. Reproduction whole or in part in any form or medium without express written permission of EarthWeb is prohibited. Read EarthWeb's privacy statement.