What is the PortletBridge Portlet?

The PortletBridge Portlet is a JSR 168 compliant portlet that allows a downstream web site to be proxied as a portlet. By default it only displays the content of the BODY but custom XSLT can be used to transform the data from the downstream site.

What is the difference between the PortletBridge Portlet and an IFrame

There are several differences between using an IFrame and the PortletBridge Portlet. Probably the biggest advantage to using an IFrame is that it is simpler than the PortletBridge Portlet and the downstream site will often be more faithfully rendered. There are however several advantages to using the PortletBridge Portlet.

  • Where an IFrame is like a window onto another site, the PortletBridge Portlet bahaves more like a portlet, providing a block of HTML into your portal page.
  • IFrames don't resize easily to accomodate the size of the downstream content (this may be an advantage but you can change the PortletBridge Portlet to do the same by putting a fixed size div into the XSLT around the content).
  • IFrame URL's take you out of the Portal. This is often not the behaviour you'd expect from a Portlet (The PortletBridge Portlet can be configured either way using the "scope" preference).
  • You may not want to expose the whole downstream site to the general public. An IFrame URL must be reachable by your browser.
  • You can't rewrite the content of your IFrame which means that it while looks exactly like the downstream site, it may not look like the rest of your portal. The PortletBridge portlet allows you to modify the XSLT that transforms the content.
  • An IFrame will show everything from the downstream site. The PortletBridge Portlet allows for "web clipping" using custom XSLT which means you only get what you want.
  • Finally, while IFrames work on most browsers, they don't work on them all nor are they supported in the XHTML spec. PortletBridge would probably be a better choice under these circumstances.


How do I deploy into Pluto?

Installing Portlets in Pluto

How do I deploy into JBoss?

Copy the portlet war into the %JBOSS_HOME%/server/default/deploy directory

How do I deploy into Liferay?

Hot deploying portlets into Liferay

NOTE: If you're deploying into Liferay on top of JBoss, you will have to remove the commons-logging jar from the portletbridge-portlet.war file to make it work.

How do I deploy into Weblogic?

Deploying JSR 168 portlets into Weblogic Portal 8.1

How do I deploy into Gridsphere?

In order to deploy into Gridsphere you will need to:

  • Download Gridsphere portal 2.1.1
  • Put an expanded copy of PortletBridge portlet into your Gridsphere tomcat webapps directory
  • Put an empty file called "portletbridge-portlet" into $CATALINA_HOME/webapps/gridsphere/WEB-INF/CustomPortal/portlets
  • Copy gridsphere-ui-tags-2.1.jar from $CATALINA_HOME/webapps/gridsphere/WEB-INF/lib to $CATALINA_HOME/webapps/portletbridge-portlet/WEB-INF/lib
  • Add the following to $CATALINA_HOME/webapps/portletbridge-portlet/WEB-INF/web.xml:
  • Use <portlet-class>portletbridge-portlet#PortletBridgePortlet</portlet-class> when placing the portlet into a layout


I'm getting an InvalidClassException, what should I do?
If your exception looks something like the snippet below it's because the serialversionid of the class changed and tomcat is trying to unfreeze an old instance of the object from the session. You should be able to ignore this. If not, let me know (dkfn at

14:04:45,295 ERROR [org.apache.catalina.session.ManagerBase] Exception loading s essions from persistent storage org.portletbridge.portlet.DefaultBridgeRequest; l ocal class incompatible: stream classdesc serialVersionUID = -785819319195243178 6, local class serialVersionUID = 4504756989609725196

I'm getting a "Log4JLogger does not implement Log" error using JBoss?
Remove commons logging from the portletbridge-portlet.war file.
How do I get https to work for untrusted certificates?
The JVM won't trust self signed certificates or certificates signed by an untrusted publisher. You will need to install them into your keystore. Follow the instructions found here to install your certificate into your JVM.
Why am I getting the "No memento defined" error?
This happens because the memento (which stores user state, like cookies etc.) cannot be found in the session. One reason for this could be because the servlet engine isn't sharing sessions between the PortletBridgePortlet and the PortletBridgeServlet. More information on how to configure tomcat to share its sessions is available here.
Does PortletBridge support XHTML?
Not by default, unfortunately. Differences between parsing and transforming XHTML and HTML mean that the PortletBridge can't currently support a mixed XHTML and HTML environment, so HTML is chosen by default. Mixed mode HTML and XHTML is planned for the 2.0 release of PortletBridge provided I can find a way to do it...