JSF 2.2 spec includes some changes related to view scope behavior:
- There is a new CDI annotation javax.faces.view.ViewScoped
- In UIViewRoot.getViewMap() javadoc it says: "... For reasons made clear in ViewScoped, this map must ultimately be stored in the session. For this reason, a true value for the create argument will force the session to be created with a call to ExternalContext.getSession(boolean). "
- Both @ViewScoped annotations javadoc include this: "... The runtime must ensure that any methods on the bean annotated with PostConstruct or PreDestroy are called when the scope begins and ends, respectively. Two circumstances can cause the scope to end. ..."
- "... In the session expiration case, the runtime must ensure that FacesContext.getCurrentInstance() returns a valid instance if it is called during the processing of the @PreDestroy annotated method. The set of methods on FacesContext that are valid to call in this circumstance is identical to those documented as "valid to call this method during application startup or shutdown". On the ExternalContext returned from that FacesContext, all of the methods documented as "valid to call this method during application startup or shutdown" are valid to call. In addition, the method ExternalContext.getSessionMap() is also valid to call. ..."