The Java-Enabled Web Server: Servlets, JSP, JSTL, XML, and Applets
Server-based applications-applications that run on a server, but which provide a client-side user interface- are becoming more and more popular. They solve the problem of software deployment by centralizing that deployment to the server itself. They also lend themselves to web applications, where the UI is hosted by a browser. Unfortunately, building a quality user interface for this environment can be tricky.Java integrates several technologies that can work in concert to built a client-side UI for a server-based application: Servlets and Java Server Pages (JSP) let you easily handle forms built using HTML and delivered via HTTP and the Web server. XML/XSLT allow you to specify the look and feel of the UI without committing to a specific HTML implementation, and also allow you to pass information from the client to server side in a semistructured way. Applets are small client-side applications, deployed dynamically on a per-use basis, that allow you to offload simple work such as data validation from the server to the client side.
This class discusses these technologies from the programming point of view, showing you how to use them effectively to deploy a UI from your sever. In addition to the technology itself, we'll look at overall architectural issues, discussing both how to mix and match these technologies to solve specific problems and how to deploy a server-based UI over an object-oriented underlying system (using signed jar files, for example). Finally, we'll discuss an alternative to server-based applications: a client-side application that updates itself automatically from a server-side cache.
This class assumes a solid understanding of the Java programming language. We will not discuss web-server configuration issues.
Outline
- Distributed-system Architectures
- Web Servers
- App Servers
- Messaging
- Networking infrastructure Overview
- URLs
- Sockets
- RMI
- JMS
- EJB
- Thin vs. thick clients
- Model/View/Controller
- Presentation/Abstraction/Control
- Visual Proxy: An Object-oriented architecture for thin clients
- HTML
- Basic tags
- style sheets
- A simplified look at JavaScript
- XML
- Terminology
- DTDs
- Schema
- DOM Parsing
- SAX Parsing
- JDOM Parsing
- Roll-your-own Parser
- Recursive Descent
- Yacc-based parsers
- XML for markup
- Translation to HTML using XSLT
- Servlets
- Architecture
- HTTPServlet
- Initialization
- Get requests
- Post requests
- Session Management
- Cookies
- Deployment
- WAR files
- Servlet Filters
- JSP
- JSP vs. Servlets
- Creating JSP pages
- Built-in JSP tags
- Directives
- Declarations
- Expressions
- Scriptlets
- Beans
- Custom Tags and Tag libraries
- JSTL
- Overview and Design Principles
- The JSTL Expression Language
- Expressions
- Operators
- Types and Literals
- Methods
- Conditions
- Iteration
- Configuration
- Localization (II8N)
- Formatting
- Database
- XML
- STRUTS
- Architecture and Overview
- Applets
- The Java Plugin
- Building an applet
- Inter-applet communication
- Client-side automatic updating
- Custom class loaders
- zip-file management
