Thursday 23 October 2014

Eclipse keyboard shortcuts

1. Convert all letters to capitalcase -
 Ctrl + Shift + X 
2. Convert all letters to lowercase -
 Ctrl + Shift + Y 

Friday 17 October 2014

The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory

Get rid of any servletcontainer-specific libraries such as jsp-api.jar in your /WEB-INF/lib folder. This exception indicates that you've put servletcontainer-specific libraries of a container which supports only Servlet 2.4 / JSP 2.0 or older in there (the getJspApplicationContext() method was introduced in Servlet 2.5 / JSP 2.1). This is a major mistake. Those libraries don't belong in the webapp's classpath.

Perhaps you did this to overcome project compilation errors, which is indeed a pretty common beginner's mistake. This should have been solved differently, you should refer the target runtime in your project, not copy some libraries of an arbitraty servletcontainer make/version into your project. It would make your project incompatible with servletcontainers of a different make and/or version.

Monday 6 October 2014

Logging not working in spring mvc webapp project

Add the log4j.properties or the log4j.xml to a folder named classes inside web-inf folder