Sign in

E-mail *, (xx@domain.com)
Password *

Register | Forgot password

Blogs

Recent blogs

RSS - Blogs
March 9, 2010
State of OSGi in the Java world
March 4, 2010
Reach more people with Google Translate
March 3, 2010
Get My Advice
February 26, 2010
What? Where!?!
February 11, 2010
Split it!

All Blogs...


WCBs and Portlets

March 4, 2008

This article gives an overview of the integration possibilities of WebManager Component Bundles (WCBs) and Portlets. It also explains how these two concepts are complementary and can be used together for a more effective online channel.

WCB characteristics

GX WebManager offers WebManager Component Bundles (WCBs); a plug-in system for adding new functionality or add-ons runtime to the product. WCBs consist of three, open source and open standards based technologies:

OSGI: The open standard OSGi (www.osgi.org), with the implementation Apache Felix (http://felix.apache.org/)

JCR: The open standard JCR or Java Content Repository (JSR-170/JSR-283, http://www.jcp.org/en/jsr/detail?id=283), with the implementation Apache Jackrabbit (http://jackrabbit.apache.org/). GX is a member of the JSR-283 Expert Group and official committer for Apache Jackrabbit.

Spring MVC: the Model View Controller framework of the well-known Spring Application Framework (http://www.springframework.org/)


This combination of three open standards and technologies results in a number of interesting characteristics:

  • Lifecycle management
    A plug-in needs to be read, installed and started, but also stopped and uninstalled. This lifecycle management of plug-ins is delivered by the OSGi framework.
  • Persistence
    In many cases a plug-in needs to be able to store and retrieve data or content. JCR not only does this in a standard way, but also relates data of different plug-ins to each other, because the data resides in one single data store. Import and export of data is easy and standardized, which is an important requirement for OTAP environments.
  • Controller framework
    Receive requests and send these to the correct presentation layer (view), with the correct data model is done by the Spring MVC framework. The result is a standardized structure and output of all plug-ins, which allows for reuse and makes the underlying code easy to read.
  • Runtime deployment
    OSGi makes it possible to add plug-ins runtime to the system. Restarting the application is not necessary at all. This concept allows organizations to become agile by adding new functionalities to their websites and portals quickly, easily and in a reliable way.
  • Dependency management
    Dependencies between plugins are controlled by OSGi. If plug-in A depends on plug-in B and B is stopped or uninstalled, plug-in A will be stopped as well.
  • Headless Services
    Plug-ins don’t necessarily need a UI layer but can also run as a background process. These so-called headless services are suitable e.g. as import tools or generic APIs that can be used by other plug-ins.
  • View and edit presentation
    Spring MVC creates a strict separation between the view and edit mode of a WCB. The view side is shown at the front-end of a website managed by GX WebManager and the edit side used in the edit environment.
  • OTAP support and merge conflict resolution with UUIDs
    JCR makes use of the concept Universally Unique IDs. This mechanism, which gives content in the repository a universally unique identifier, is a great help for maintaining consistency when changing content during OTAP.
  • Version control
    OSGi assigns a version number to a plug-in which is crucial for OTAP processes.
  • Schema evolution
    The combination of JCR and version control allows the smooth transformation of the data model of a WCB to a newer version of that WCB. Especially for dynamic content types this is an important feature.

Portlets characteristics

After an objective analysis of the WCB concept we can concludes that WCBs do not compete or interfere with portlets, but that the two concepts are complementary. Portlets have the following characteristics:

  • Presentation & rendering
    Portlets can be considered small web pages within a portal environment. Portlets have little to no influence on the surrounding HTML but they do have within the portlet itself. The presentation of portlets is similar to servlets and uses the doRender() method. The advantage is that the developer can focus on the layout of the portlet only.
  • Window states
    A portlet has a certain state; e.g. maximized, minimized or closed. A simple but very efficient concept, especially from a usability perspective.
  • Lifecycle management
    Portlets can be added or removed easily from a portal environment by the users as instances. Portlet modesPortlets can be presented in three ways; view mode, edit mode and a help mode.
  • Portlet filter
    Filters between the portlet container and the portlet itself allow for authorization checks or other actions before or after the portlet is rendered.
  • Portal framework
    The portal framework is very important because it takes care of authorization, storage of preferences, layout around the portlet and managing portlet requests. Portal frameworks are not very flexible with regard to the graphical design and offer little configuration  and content management functionality. This has to be done within the portlet itself.
  • Deploytime installation
    Where WCBs can be installed runtime, portlets require deploytime installation. However, after installation, users can add multiple instances of the same portlet.

Standard portlets have normally no support for dependency management, version control, schema evolution or persistence. The obvious advantage is that portlet developers have more freedom to implement a portlet the way they want. The disadvantage is that without clear rules and guidelines for developers a portal environment can become very complex. Although using portlets creates a clear and consistent user experience, it restricts the possibilities to meet e.g. house style requirements or add new trends like user-generated content. It is not impossible, but sometimes it can be fairly complex.

WCBs and Portlets: two complementary technologies

Portals en portlets are widely adopted for intranet environments for which they are very useful. Portals and portlets are specifically good for integrating applications, content, internal workflow procedures, documents and other important enterprise information at user level. I would say that in those situations portals and portlets are more suitable than WCM products. For external, consumer-facing websites however,  portal platforms and portles are less suitable, mainly because of the lack of flexibility and the other reasons mentioned above.  This is the reason why GX has made the choice to use the combination of OSGi, JCR and Spring MVC in the WCB concept. Meeting the expectations of today’s online consumers requires speed, flexibility, focus on traffic and conversion, ease of development, stability and agility in one system and no hassle. High-end WCM products like GX WebManager have been developed especially for these situations. Nevertheless, it is very well possible to combine portlets and WCBs in one system. The Web Content Management product is then used for its complete freedom in dealing with graphical design, integration and authorization, WCBs are used for integrating additional functionalities and content and portlets are used at the front-end. These portlets can be configured by the end-user.

About the Author

Return to all blogs

Martijn van Berkum

Martijn is chief technology officer of GX. Besides a visionairy leader of GX, Martijn participates in several international expert groups, among them the JSR-283.

Read all Martijns blog entries

Other blog entries:

March 9, 2010
State of OSGi in the Java world
May 12, 2009
Traffic and Conversion
May 26, 2008
Open Development: From Transparency to Quality
April 21, 2008
GX WebManager Community Edition Officially Launched!
March 8, 2008
GX WebManager platform strategy
February 15, 2008
Welcome!


Share:

del.icio.us
digg
Technorati
Slashdot
Reddit
YahooMyWeb
NewsVine
ekudos
© 2010 GX creative online development B.V.

Disclaimer

This website (GXdeveloperweb.com) may discuss or contain opinions, (sample) coding, software or other information that does not include GX official interfaces, instructions or guidelines and therefore is not supported by GX. Changes made based on this information are not supported.  GX will not be held liable for any damages caused by using or misusing the information, software, instructions, code or methods suggested on this website, and anyone using these methods does so at his/her own risk. GX offers no guarantees and assumes no responsibility or liability of any type with respect to the content of this website, including any liability resulting from incompatibility between the content of this website and the materials and services offered by GX. By using this website you will not hold, or seek to hold, GX responsible or liable with respect to the content of this website.