Application Integration and Remoting Technologies

I've been thinking a bit about the different technologies available to those thinking about integrating external applications into portal environments. One of the most requested questions we get in client situtations is "How do we integrate our exising applications written in PHP, Perl, Ruby, etc?

I wish there was a straightforward answer to that, but unfortunately the answer is: it depends. It really depends what you're trying to integrate and how much you're trying to integrate. From my experience we've seen that the level of integration is directly proportional to the level of effort required. On one end of the spectrum you have those who are simply trying to pull in static content from a content management system, and on the other end you're talking close integration with portal artifacts: Window States, Modes, Two-Phase Commit, Single-Sign On, Permissions, Asset Management, Tagging, etc. Currently there are several solutions already available address these integrations.

IFrame

IFrame is probably the simplest and cheapest technology to implement. It requires very little development effort to get up and going, and if you have a "Smarter" IFrame portlet, it will authenticate, perform single sign-on and even resize the portlet window depending on how much content contained in the target application. However there are some serious drawbacks:

  • State loss (ie when switching portal pages)
  • No look and feel integration (ie you'll have two sets of headers and footers)
  • No integration with portal artifacts
  • Little to no control of the target application's content

 

Web Proxy

A web proxy allows you to fetch content from an external application on the server side proxy it into the portlet environment. PortletBridge provides a good implementation of this, however it seems that development has stopped in the past two years. One of the greatest features of PortletBridge is that it allows you to filter the content using a regex so that you have a chance to rewrite content and URL before it is presented to the user. This allows you to strip out content (like headers and footers) that the IFrame could not do.

While this solution addresses some of the problem from the IFrame option, it introduces some of it's own. The most significant problem is the potential for a type cross-site scripting. There's actually a pretty good chance that proxied app or the portal itself will have interfering CSS, Javascript, or HTML that will cause one or both applications not to function.

However, if you have some control of the target application, this can be minimized.

WSRP

WSRP is the most powerful, yet most complex application integration option. The idea behind WSRP is that any WSRP consumer should be able to consume portlets seamlessly from a WSRP compliant producer (ie Liferay should be able consume portlets from a remote BEA, Oracle, or IBM portal server). Unlike the IFrame and Web Proxy solutions, WSRP actually respects a lot of the Portlet artifacts like Window States, Modes, and a Two Phase Commit. Theoretically this seems like a great, seamless technology.

In practice however, this is hardly the case. There are enough ambiguities in the WSRP specification that make it pretty difficult to consume more than the simplest of portlets. Anything requiring SSO, file uploads, or other complex interaction is not possible without some propreitary integration. The whole point to WSRP is the removal of anything propreitary.

Just Migrate the Whole Thing!

And of course the cleanest integration is to migrate the whole thing into a Portlet JSR-168 environment. As we know many companies with large legacy applications do not always have the resources to do this. However, this does provide most seamless solution.

Final Thoughts

There really isn't a one-stop solution for application integration, the solution really depends on what problems you're trying to solve and your resource situation.

I've been having some discussions with Jorge and some others within Liferay how we can improve our application integration options. Already we have a prototype available for the Liferay WAI. There's also an idea for Simple Remote Portlets. We've been looking at the likes of Facebook, Google Gadgets, and REST-style architectures to see what we can provide for future versions of Liferay, and we think the future is bright.

Jorge will be giving talk at W-JAX in Munich, Germany on Nov 1 about this future.

Blogs
Nice... This would make a nice slide presentation in the trainings.
Nice... This would make a nice slide presentation in the trainings.