Server-Side Development Section Index
What features are in Servlet 3.0?
Servlet 3.0 makes key changes from Servlet 2.5 to deliver greater simplicity and ease of development.
What are the new features in Java EE 6?
Java EE 6 introduces a number of key new features.
What is the Java EE 6 Web Profile?
The Java EE 6 Web Profile reduces the download and runtime sizes for applications that don't need the full Java EE 6 version.
How do I check if a Connection is still valid / has been closed?
With JDBC 4.0, you can call the isValid(int timeout) method. The timeout represents the number of seconds to wait for a reply. If no reply is acquired during the time, false is returned and the ca...more
When using getMessagesByUID(long start, long end) to fetch a range of messages by UID, how to I specify the last available UID?
The UIDFolder class has a LASTUID constant for just such a purpose.
How do I use the @PostConstruct annotation in EJB 3.0?
How do I use the @PostConstruct annotation in EJB 3.0?
What is the difference between RequestDispatcher's forward(ServletRequest request, ServletResponse response) method and HttpServletResponse's sendRedirect(String location) method?
What is the difference between RequestDispatcher's forward(ServletRequest request, ServletResponse response) method and HttpServletResponse's sendRedirect(String location) method?
I want to run JSP files using the Tomcat server, where should I place my JSP files?
I want to run JSP files using the Tomcat server, where should I place my JSP files?
How can I print the stack trace of an Exception out to my JSP page?
How can I print the stack trace of an Exception out to my JSP page?
How can I serve Word/Excel documents to a web client from JSP's and/or servlets?
How can I serve Word/Excel documents to a web client from JSP's and/or servlets?
Cross Site Scripting (XSS) with Jakarta Tomcat.
Hi,
The XSS vulnerability has been found at the time Tomcat 4.0.3 has been released (and 4.1.2 was in beta). The problem was connected to the fact that it was possible to run some specific classes...more
I am writing a simple jsp to retrieve and save from/to my MySQL db. My retrieve and save functions work great. Now, depending on the action in the browser, I would only like to invoke one of the methods. For example, for the onChange event, I would like to get the info from the db. For the onClick event, I would like to save the info to the db. Considering these actions are on the client side and jsp is on the server side, is there a way to do this? If not, does anyone have a suggestion on how this can be done?
I am writing a simple jsp to retrieve and save from/to my MySQL db. My retrieve and save functions work great. Now, depending on the action in the browser, I would only like to invoke one of the m...more
What's difference between Servlet/JSP session and EJB session?
From a logical point of view, a Servlet/JSP session is similar to an EJB session. Using a session, in fact, a client can connect to a server and maintain his state.
But, is important to understan...more
What is session facade?
Session facade is one design pattern that is often used while developing enterprise applications.
It is implemented as a higher level component (i.e.: Session EJB), and it contains all the iteract...more
What is the role of the controller in MVC architecture?
The role of controller is to dictate what to do behind the scenes and what to display in the view next.
1. Controller receives a request
2. Controller decides the requested activities based on re...more