Monday, November 24, 2008

How will the Servlet Work??


A servlet is loaded by the servlet container the first time the servlet is requested. The servlet then forwards the user request, processes it, and returns the response to the servlet container, which in turn sends the response back to the user. After that, the servlet stays in memory waiting for other requests—it will not be unloaded from the memory unless the servlet container sees a shortage of memory. Each time the servlet is requested, however, the servlet container compares the timestamp of the loaded servlet with the servlet class file. If the class file timestamp is more recent, the servlet is reloaded into memory. The main steps are illustrated by the flowchart above.

Thursday, November 20, 2008

Enterprise Java Beans(EJB) and Java Server Pages(JSP)


EJB is a managed, server-side component architecture for modular construction of enterprise applications.
The EJB specification is one of several Java APIs in the Java Platform, Enterprise Edition. EJB is a server-side model that encapsulates the business logic of an application.

JSP is a Java technology that allows software developers to dynamically generate HTML, XML or other types of documents in response to a Web client request. The technology allows Java code and certain pre-defined actions to be embedded into static content.

Fig 1 and Fig 2 best illustrates the example of EJB and JSP in application architectures. They will be very useful in the creation of the technologies needed to program web applications in Java using Servlets 2.3, JSP 1.2, EJB 2.0 and client-side programming with JavaScript.

New Architecture


This latest architecture best suits our system, and our prototype will be based on it. We had already set up our server, prepared the HTML, jsp and XML codes, completed a test database, now we are concentrating on the EJB and DOM part.

ref:http://wnws.sourceforge.net/