ICEfaces
  1. ICEfaces
  2. ICE-3229

Bridge cannot dispose of multiple views within a single window (portlets).

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.7.1
    • Fix Version/s: 1.7.2
    • Component/s: Bridge, Framework
    • Labels:
      None
    • Environment:
      portal portlet

      Description

      In certain defined circumstances, like unloading a page, the bridge typically disposes of the existing view associated with that window. However in a portlet environment, there can be multiple views associated with a single window (one per ICEfaces portlet). Currently, the bridge only disposes of a single view. When this happens, the undisposed views are not properly cleaned up. So we need to adjust the bridge/framework to be able to dispose of one or many views when required.

        Issue Links

          Activity

          Hide
          Deryk Sinotte added a comment -

          Assigning to Mircea

          Show
          Deryk Sinotte added a comment - Assigning to Mircea
          Hide
          Mircea Toma added a comment -

          In a portal environment with applications deployed in separate WARs the views contained in a window can belong to different sessions. Because of this the message sent for disposing the views needs to be handled by AHS which is the common access point that can notify all other deployed applications about the views that need to be disposed.
          There seems to be an additional constrained due to browser's limitation of being capable to send only one XMLHTTPRequest on document.onbeforeunload event, after the first request the browser's document and all other objects belonging to the window are disposed by the browser.

          Show
          Mircea Toma added a comment - In a portal environment with applications deployed in separate WARs the views contained in a window can belong to different sessions. Because of this the message sent for disposing the views needs to be handled by AHS which is the common access point that can notify all other deployed applications about the views that need to be disposed. There seems to be an additional constrained due to browser's limitation of being capable to send only one XMLHTTPRequest on document.onbeforeunload event, after the first request the browser's document and all other objects belonging to the window are disposed by the browser.
          Hide
          Mircea Toma added a comment -

          Jack,

          Please have a look at my comments and commits for this issue. We need to handle the 'dispose-views' message in the AHS. The implementation would be a bit different then the one I updated in the 'core'. If you have concerns with the message structure let me know so we can keep both implementation consistent.

          Show
          Mircea Toma added a comment - Jack, Please have a look at my comments and commits for this issue. We need to handle the 'dispose-views' message in the AHS. The implementation would be a bit different then the one I updated in the 'core'. If you have concerns with the message structure let me know so we can keep both implementation consistent.
          Hide
          Jack Van Ooststroom added a comment -

          I changed AHS to receive the new HTTP POST request .../block/dispose-views containing the following parameter:

          ice.views=<ICEfaces ID>:<View Number>,<ICEfaces ID>:<View Number>,etc.

          The JavaScript Bridge needs to be updated in order to send this new format.

          AHS sends out a DisposeViews message type JMS message to the Core framework telling which Views can be disposed. Currently, the MainServlet has a MessageServiceClient instance that receives and parses the DisposeViews message.

          Show
          Jack Van Ooststroom added a comment - I changed AHS to receive the new HTTP POST request .../block/dispose-views containing the following parameter: ice.views=<ICEfaces ID>:<View Number>,<ICEfaces ID>:<View Number>,etc. The JavaScript Bridge needs to be updated in order to send this new format. AHS sends out a DisposeViews message type JMS message to the Core framework telling which Views can be disposed. Currently, the MainServlet has a MessageServiceClient instance that receives and parses the DisposeViews message.
          Hide
          Jack Van Ooststroom added a comment -

          Re-assigning to Mircea for further work.

          Show
          Jack Van Ooststroom added a comment - Re-assigning to Mircea for further work.
          Hide
          Mircea Toma added a comment -

          Create message handler per session. Change 'dispose-views' request format to avoid changes to the bridge. Refactor & simplify.

          Show
          Mircea Toma added a comment - Create message handler per session. Change 'dispose-views' request format to avoid changes to the bridge. Refactor & simplify.

            People

            • Assignee:
              Unassigned
              Reporter:
              Deryk Sinotte
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: