Posts

Showing posts from December, 2012

Lightweight Web Application Framework : PrimeFaces (JSF) + Guice + MyBatis (PART1)

Recently, my friend asks me how to build a lightweight java web application. Many Java web developer would choose Spring and hibernate to build a traditional web application. However, it may not be lightweight enough. I suggested him try to use Guice and MyBatis to build the application framework. Although Spring is more feature-riched than Guice, I admitted that Guice is more lightweight and easier to use. MyBatis is also a lightweight SQL map framework. It can integrate with Guice framework very well. Here, I will try to set up a simple web application with PrimeFaces, Guice and MyBatis. I hope that my friend could learn how to do it. :) Using MyFaces and PrimeFaces in presentation layer. Integrate MyFaces and PrimeFaces is simple. Just simply get the JARS file from MyFaces website and PrimeFaces website . For MyFaces, just add the following sample configuration into your web.xml. <display-name>TestGuice</display-name> <context-param> <param-name...