Details
-
Type: Bug
-
Status: Closed
-
Priority: Major
-
Resolution: Won't Fix
-
Affects Version/s: EE-3.3.0.GA_P02, 4.0
-
Fix Version/s: EE-4.1.0.GA, EE-3.3.0.GA_P04
-
Labels:None
-
Environment:All
-
Support Case References:Support Case #13302 - https://icesoft.my.salesforce.com/50070000011uDmq
Description
In this scenario, a page uses a Window Scoped bean. This bean uses the @PreDestroy annotation. If the page is closed before it has a chance to finish loading this annotated method is not called. This also puts the state of new bean instances out of sync.
The scenario is as follows with some logging:
- Page is loaded and allowed to finish rendering and the page is closed.
TestBean Constructor Called 31768553
PostConstruct Called 31768553
PreDestroy Called 31768553
- The page is loaded again but this time it is closed before it finishes loading.
TestBean Constructor Called 32617693
PostConstruct Called 32617693
- A new page instance is loaded and allowed to finish.
TestBean Constructor Called 1021952
PostConstruct Called 1021952
- The previous page is closed and a new one is opened. In this instance the previous page bean is cleared when the new instance is loaded.
PreDestroy Called 1021952
TestBean Constructor Called 21790214
PostConstruct Called 21790214
- The first bean instance (32617693) that is closed before finished loading never calls it's PreDestroy method.
The scenario is as follows with some logging:
- Page is loaded and allowed to finish rendering and the page is closed.
TestBean Constructor Called 31768553
PostConstruct Called 31768553
PreDestroy Called 31768553
- The page is loaded again but this time it is closed before it finishes loading.
TestBean Constructor Called 32617693
PostConstruct Called 32617693
- A new page instance is loaded and allowed to finish.
TestBean Constructor Called 1021952
PostConstruct Called 1021952
- The previous page is closed and a new one is opened. In this instance the previous page bean is cleared when the new instance is loaded.
PreDestroy Called 1021952
TestBean Constructor Called 21790214
PostConstruct Called 21790214
- The first bean instance (32617693) that is closed before finished loading never calls it's PreDestroy method.
Attached test case that shows this issue. The server output will have similar logging as mentioned in the case description.