// Add self as ELContextListener to the Faces App so we can add the
// portletConfig to any newly created contexts.
ApplicationFactory appFactory =
(ApplicationFactory) FactoryFinder.getFactory(FactoryFinder.APPLICATION_FACTORY);
Application app = appFactory.getApplication();
app.addELContextListener(this);
// Process and cache the FacesServlet mappings for use by
// ExternalContext
WebConfigurationProcessor webConfig = new WebConfigurationProcessor(portletContext);
mFacesMappings = webConfig.getFacesMappings();