官术网_书友最值得收藏!

Understanding a portal

By now, you have probably heard that "Liferay is a Portal Server"! Now the question is, "What do we really mean when we use the term Portal Server?"

Well, to get the answer we should first understand what a portal is. A portal is a web-based application or gateway which hosts and runs different applications required by the user. All these applications are integrated to achieve different benefits, such as availability of information at a central location, collaboration, reducing costs, and streamlining your business processes.

To make sure all of the above-mentioned benefits are achieved, Liferay Portal adds one or more applications on a portal page. This application is known as a portlet .

A portlet is a web application which runs in a fragment of a page. These portlets are used by portals as pluggable user-interface components which provide a presentation layer to the Information System. One or more portlets get combined and generate a complete web page or document, which is displayed to a user. This is known as aggregation. Liferay Portlet Container plays a vital role in achieving this. In the following screenshot, three portlets have been aggregated by the Portlet Container to form the welcome page:

Understanding a portal

The Portlet Container is a logical component in Liferay (and in any standard Portal Server) which runs the portlets and provides them with the required runtime environment. It is also responsible for managing the lifecycle of a portlet. To understand the role of the portlet container, let's look at what happens when you request to access a page in a portal:

  1. You send an HTTP request via a web browser to the portal.
  2. The portal receives the request.
  3. The portal determines if your request contains any action targeted to any of the portlets which are associated with the page.
  4. If there is any action involved, the portal requests Portlet Container to invoke that particular portlet to process the action. Rest of the portlet will only get re-rendered once the action phase of the portlet is completed.
  5. The Portlet Container provides the fragment of the individual portlet back to the portal. The fragment can be any markup (HTML/XHTML/WML).
  6. The portal aggregates the output of the portlets on the portal page and sends it back to the browser for you to access.

The lifecycle is explained in the following diagram:

Understanding a portal

Liferay Portal supports portlet standards JSR-168 and JSR-286, which are also known as Portlet 1.0 and Portlet 2.0 specifications, respectively.

主站蜘蛛池模板: 安吉县| 崇州市| 榆林市| 彰化市| 丰都县| 额济纳旗| 剑川县| 芜湖县| 改则县| 肇州县| 海丰县| 大化| 那坡县| 汾阳市| 海宁市| 达州市| 青海省| 南丹县| 陇川县| 康乐县| 许昌县| 沙湾县| 大关县| 友谊县| 凌源市| 沁水县| 鲜城| 南陵县| 山西省| 舞阳县| 宜宾县| 桦南县| 郎溪县| 肥城市| 唐山市| 洛川县| 海林市| 岳西县| 比如县| 平果县| 循化|