What is use of Model listeners and how to implement them?
How to Overriding Liferay Startup Events?
What is diff b/w global.startup.events and application.startup.events?
What is diff b/w ant deploy and ant direct deploy?
Explain workflow and kalio work flow?
Integration with Solr and LDAP?
How to achieve custom authentication instead of liferay default login?
Explain AUto login functionality in liferay?
What WSRP?
Explain steps tp connect multiple data bases in liferay?
What is diff web content portlet and Asset publisher portlet?
Where did you used hook in your project?
Page rendering flow in Liferay?
Ans: 1. Request comes in through MainServlet.Various attributes are stored in the session and request. The request attribute WebKeys.CURRENT_URL holds the currently requested path (stripped of protocol,host, and port).
2.The "service pre action" handler com.liferay.portal.events.ServicePreAction(servicePre() method) is called, where the layout and theme to display are determined. The following values are stored as a below request attributes.
WebKeys.LAYOUT key : To store current Layout.
WebKeys.LAYOUTS key : The other available layouts.
WebKeys.THEME key : To store the theme to display
WebKeys.COLOR_SCHEME key: color scheme to use .
The theme and color scheme are usually determined by querying the layout once it has been determined.
3.Struts is called to handle the request, and Liferay uses the custom Struts request processor com.liferay.portal.struts.PortalRequestProcessor.The PortalRequestProcessor.getLastPath() method computes the last path visited, and supplies a default path for the first entry into the portal. The default path upon entry into the portal is ://:/portal/layout.
4.This initial request for /portal/layout is handled by com.liferay.portal.action.LayoutAction. /html/common/themes/portal.jsp is the "top level" display page.
5.It selects the portal_normal.jsp or portal_pop_up.jsp based on the current state of the theme's display, and includes it using the custom tag, implemented by com.liferay.taglib.theme.IncludeTag, which in turn calls com.liferay.taglib.util.ThemeUtil.include() method.
6.Eventually, for each portlet, the method com.liferay.portal.util.PortalUtil.renderPortlet() gets called, which calls /portal/portal-web/docroot/html/portal/render_portlet.jsp to render the contents of an individual portlet.
7.That in turn calls /portal/portal-web/docroot/html/common/themes/portlet.jsp, which ends up calling /portal/portal-web/docroot/html/common/themes/portlet_content.jsp
Request flow in Liferay:
1.The initial request comes into the portal server from the browser, and hits the service() method of the classcom.liferay.portal.servlet.MainServlet. Here, a variety of objects are created and added to the request for use by code downstream (such as company Id, user objects, etc.)
2.Code passes through the servicePre() method of the class com.liferay.portal.events.ServicePreAction. Here is where the ThemeDisplay object is created and populated for downstream code use.
3.The theme infrastucture code will call into the class com.liferay.taglib.util.ThemeUtil to render the content of a theme. It will call either the mehod includeJSP() to include JSP rendered content, or inclu deVM() to include Velocity rendered content.
4.When using a Velocity based theme, the request will flow thru the class com.liferay.portal.velocity.VelocityVariablesand the method insertVariables(). That method is where various Velocity variables for use by the theme system is added to the Velocity context.
5.For each column in the page's layout, the PortletColumnLogic class processes each portlet using the processContent()method. In this method, the HTML that surrounds every portlet is generated. Further processing is then delegated to the RuntimePortletUtil via the processPortlet() method. Then on to the actual rendering..
6.An individual portlet is rendered by the render_portlet.jsp code located (in Tomcat) in the webapps/ROOT/html/portaldirectory. This JSP is called to render each portlet on the page. Debug code can be added to this file to see exactly what is going on just before and just after the code in your custom portlet is executed.
7.As will be found by looking through the JSP code, render_portlet.jsp uses InvokerPortletImpl's render() method to render portlets. The primary function of this method is to check if a portlet's expiration-cache has been set or has expired. If the expiration-cache has been set, InvokerPortletImpl then checks whether the portlet's most recently cached content is fresh enough to us
How to Overriding Liferay Startup Events?
What is diff b/w global.startup.events and application.startup.events?
What is diff b/w ant deploy and ant direct deploy?
Explain workflow and kalio work flow?
Integration with Solr and LDAP?
How to achieve custom authentication instead of liferay default login?
Explain AUto login functionality in liferay?
What WSRP?
Explain steps tp connect multiple data bases in liferay?
What is diff web content portlet and Asset publisher portlet?
Where did you used hook in your project?
Page rendering flow in Liferay?
Ans: 1. Request comes in through MainServlet.Various attributes are stored in the session and request. The request attribute WebKeys.CURRENT_URL holds the currently requested path (stripped of protocol,host, and port).
2.The "service pre action" handler com.liferay.portal.events.ServicePreAction(servicePre() method) is called, where the layout and theme to display are determined. The following values are stored as a below request attributes.
WebKeys.LAYOUT key : To store current Layout.
WebKeys.LAYOUTS key : The other available layouts.
WebKeys.THEME key : To store the theme to display
WebKeys.COLOR_SCHEME key: color scheme to use .
The theme and color scheme are usually determined by querying the layout once it has been determined.
3.Struts is called to handle the request, and Liferay uses the custom Struts request processor com.liferay.portal.struts.PortalRequestProcessor.The PortalRequestProcessor.getLastPath() method computes the last path visited, and supplies a default path for the first entry into the portal. The default path upon entry into the portal is ://:/portal/layout.
4.This initial request for /portal/layout is handled by com.liferay.portal.action.LayoutAction. /html/common/themes/portal.jsp is the "top level" display page.
5.It selects the portal_normal.jsp or portal_pop_up.jsp based on the current state of the theme's display, and includes it using the custom tag, implemented by com.liferay.taglib.theme.IncludeTag, which in turn calls com.liferay.taglib.util.ThemeUtil.include() method.
6.Eventually, for each portlet, the method com.liferay.portal.util.PortalUtil.renderPortlet() gets called, which calls /portal/portal-web/docroot/html/portal/render_portlet.jsp to render the contents of an individual portlet.
7.That in turn calls /portal/portal-web/docroot/html/common/themes/portlet.jsp, which ends up calling /portal/portal-web/docroot/html/common/themes/portlet_content.jsp
Request flow in Liferay:
1.The initial request comes into the portal server from the browser, and hits the service() method of the classcom.liferay.portal.servlet.MainServlet. Here, a variety of objects are created and added to the request for use by code downstream (such as company Id, user objects, etc.)
2.Code passes through the servicePre() method of the class com.liferay.portal.events.ServicePreAction. Here is where the ThemeDisplay object is created and populated for downstream code use.
3.The theme infrastucture code will call into the class com.liferay.taglib.util.ThemeUtil to render the content of a theme. It will call either the mehod includeJSP() to include JSP rendered content, or inclu deVM() to include Velocity rendered content.
4.When using a Velocity based theme, the request will flow thru the class com.liferay.portal.velocity.VelocityVariablesand the method insertVariables(). That method is where various Velocity variables for use by the theme system is added to the Velocity context.
5.For each column in the page's layout, the PortletColumnLogic class processes each portlet using the processContent()method. In this method, the HTML that surrounds every portlet is generated. Further processing is then delegated to the RuntimePortletUtil via the processPortlet() method. Then on to the actual rendering..
6.An individual portlet is rendered by the render_portlet.jsp code located (in Tomcat) in the webapps/ROOT/html/portaldirectory. This JSP is called to render each portlet on the page. Debug code can be added to this file to see exactly what is going on just before and just after the code in your custom portlet is executed.
7.As will be found by looking through the JSP code, render_portlet.jsp uses InvokerPortletImpl's render() method to render portlets. The primary function of this method is to check if a portlet's expiration-cache has been set or has expired. If the expiration-cache has been set, InvokerPortletImpl then checks whether the portlet's most recently cached content is fresh enough to us