Widget Render-Time Monitoring

If you want to know where your time is spent

Hourglass, CC by-sa 2.0

In the ancient past, Liferay had a feature to discover individual portlet's rendering times. It looks like this got lost with the move to OSGi -  but it's also reasonably simple to replace. Especially when it's for portlets only (fragments are still on the to-do list)

Some portlets take longer than others. While that's ok - they typically provide more value and dynamic content - you might want to limit their use to the less frequented page and not have them on your most public landing page.

Here's a quick proof-of-concept that you can use to display each individual widget's rendering time. It's also a sample for introducing a PortletFilter to each and every existing portlet in the system.

Let me know if you find it useful, discover bugs, or have extensions that you'd like to see in there.

One doesn't stop learning: The old feature is still there, runtime-configurable through Control Panel / Platform / Infrastructure / Monitoring. The UI however is unchanged from the ancient one: The results will be hidden within a HTML comment close to the end of the page. Not the most comfortable place to find the results in. ​​​​​​​Thank you, Daniel Reuther, for pointing this out.