dispenser.getPropertyResolverIterator(),
new DefaultPropertyResolver()));
runtimeConfig.setVariableResolverChainHead(getApplicationObject(VariableResolver.class,
dispenser.getVariableResolverIterator(),
new VariableResolverImpl()));
// configure ManagedBeanDestroyer to listen to PreDestroyCustomScopeEvent and PreDestroyViewMapEvent
ManagedBeanDestroyer mbDestroyer = new ManagedBeanDestroyer();
application.subscribeToEvent(PreDestroyCustomScopeEvent.class, mbDestroyer);
application.subscribeToEvent(PreDestroyViewMapEvent.class, mbDestroyer);