protected IPortletDefinition getPortletDefinition( IPortletWindowId portletWindowId, HttpServletRequest request) { final IPortletWindow portletWindow = this.portletWindowRegistry.getPortletWindow(request, portletWindowId); final IPortletEntity parentPortletEntity = portletWindow.getPortletEntity(); return parentPortletEntity.getPortletDefinition(); }
@Override public void postExecution( HttpServletRequest request, HttpServletResponse response, IPortletExecutionContext context, Exception e) { final IPortletWindowId portletWindowId = context.getPortletWindowId(); final IPortletWindow portletWindow = this.portletWindowRegistry.getPortletWindow(request, portletWindowId); final IPortletEntity portletEntity = portletWindow.getPortletEntity(); final IPortletDefinition portletDefinition = portletEntity.getPortletDefinition(); final IPortletDescriptorKey portletDescriptorKey = portletDefinition.getPortletDescriptorKey(); final AtomicInteger counter = this.executionCount.get(portletDescriptorKey); counter.incrementAndGet(); }