Showing posts with label Spring. Show all posts
Showing posts with label Spring. Show all posts

Friday, August 9, 2013

How to use Spring in a Liferay Portlet

This post shows how add Spring into a Liferay portlet.
In certain cases, we might need to have IoC in our existing application. eg, lookup configuration from xml.
adding Spring in our application might ease the xml lookup.

Steps:
1. add Spring jar from Liferay classpath
    a) add the following Spring libraries into an existing Liferay portlet project from Liferay Portal
    spring-aop.jar,\
    spring-asm.jar,\
    spring-beans.jar,\
    spring-context-support.jar,\
    spring-context.jar,\
    spring-core.jar,\
    spring-expression.jar,\
    spring-web.jar
    refer this post to know how to add Liferay Portal libraries into a portlet.

LinkWithin

Related Posts Plugin for WordPress, Blogger...