Monday, October 11, 2010

Servlet API's gluten strength



In the September 26, 2005, Sun introduced the latest version of Servlet API: Servlet2.5. The Servlet API and the previous Servlet is very different. The biggest difference is Servlet2.5 is based solely on J2SE5.0 of. Therefore, it naturally has all the characteristics of the J2SE5.0. Servlet2.5 use J2SE5.0 the configuration of the comment features make it easier. However, in 2005 J2SE5.0 introduced not long ago, the Web server to support J2SE5.0 not many, it was Servlet2.5 in use and did not immediately popular. Two years later, Sun has introduced the Servlet based J2SE5.0 the second version of 3.0 (that is JSR-315). In this version added a lot of interesting features. Such as programmable login logout configuration through annotations, asynchronous communication. Let us look at Servet3.0 following main features.

A more flexible Web Framework

Now almost all Java-based Web frameworks are built on top of the Servlet. Most Web frameworks are by Servlets or web.xml to configure and released. The newly added annotation features J2SE provides us with a better choice. We can use annotation to set Servlets, Listeners, filters and so on. But the comment is written directly in the program and can not dynamically change the configuration, therefore, JSR also provides two ways to operate Servlet. This Web application will have more flexibility.

2, EOD support

Servlet3.0 will use a variety of techniques to enhance the capacity of API. Such as the type of use Note to declare the program. This will be one of the goals EOD: make Web program zero configuration. In other words we will use the release to cover the traditional description of the configuration of the article. There is the generic application, will greatly enhance the process of Servlet's expression. J2SE version of the will in the future by adding the ability to support other languages, it also helps increase the strength of Servlet API itself.

Third, support for asynchronous communication

Servlet3.0 asynchronous communication support the following features:

1. Nonblocking (Non-blocking) input: the use of such input, the data for some reason can not yet arrived when the program will not be blocked.

2. Non-blocking output: and non-blocking input similar to that when writing data due to network problems and slow process will not be blocked.

3. Delay request processing: in AJAXWeb client program can send asynchronous requests to the server until the timeout or event returns to handle the request. Delay request is also very useful in other areas, such as processing of data before we have to get some resources, but these resources are in remote networks, but the speed is not fast. This requires asynchronous to deal with this situation.

4. Obstruction - non-blocking notification: This function is to inform the information into blocking or non-blocking events. Then extracted by the client is responsible.

5. Support channel: channel is JDK1.4 and above to provide a new communication API. Channel can be better used for network communication. Can also enhance the creation, subscription, cancellation and other security operations.

6. Security: support for logon and log off function.

7. Other features

(1) support the Welcome screen.

(2) ServletContentListener sort.

(3) initialize the size of the container can be customized.

(4) can monitor the file upload process.

The above is only a part of properties Servlet3.0. These features can be seen from, Servlet API does have a lot of flying, in addition to Servlet, EJB3.0 also use the new features J2SE5.0 rebirth. Perhaps in the near future Servlet3.0 and EJB3.0 will become the new combination, in the J2EE application plays an important role, let us wait and see!







Recommended links:



DivX To IPhone



svchost exe fix automatic solution



MPEG To 3GPP



AVI to FLV



No comments:

Post a Comment