adfemg
  1. adfemg
  2. ADFEMG-118

af:poll with interval set to 5000 and timeout set to 5001 doesn't stop polling after on roundtrip

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Labels:
      None
    • Environment:

      JDev 11.1.1.6.0, HR DB schema

      Description

      A remake of Frank's (Frank Nimphius) article How to auto-dismiss af:popup dialogs and the sample 105, a user on OTN JDev & ADF forum tried to get this running on JDeveloper 11.1.1.6.0. Franks sample was built using JDeveloper 11.1.2.3.0 and can't be run without changes in JDeveloper 11.1.1.6.0.
      As it turned out there is a problem with the af:poll component and the timeout setting. This timeout setting should cancel the poll component after the given period of time (which should work in 11.1.2.3). This was one key feature in Frank's original article. Using 11.1.1.6.0 it turned out, that the af:poll remains active even after the timeout period should have canceled any further events to the poll listener.
      The sample application for this can be loaed from http://java.net/projects/smuenchadf/sources/samples/content/BlogSelfClosingPopup.zip
      A full description of the problem can be found at http://tompeez.wordpress.com/2013/03/24/jdeveloper-11-1-1-6-0-self-closing-popup/
      A workaround for this is implemented in sample http://java.net/projects/smuenchadf/sources/samples/content/BlogSelfClosingPopup_v2.zip

        Activity

        Hide
        Timo_Hahn added a comment -

        My thinking
        Thanks Chris

        Show
        Timo_Hahn added a comment - My thinking Thanks Chris
        Hide
        chriscmuir added a comment -

        Let's close the issue, we'd have to put up a vigorous case to engineering for the ER and I think our time is best spent elsewhere.

        CM.

        Show
        chriscmuir added a comment - Let's close the issue, we'd have to put up a vigorous case to engineering for the ER and I think our time is best spent elsewhere. CM.
        Hide
        Timo_Hahn added a comment -

        Chris,
        I found the reason for this behavior. In the help for the af:poll the documentation has changed describing exactly what I see. From the timeout property documentation:

        ...
        Note that polling will restart if user activity is detected again after timeout but before the session has expired. If this value is set to -1, the page will never timeout.
        ...

        The log I posted generates new poll messages if you move the mouse over the page which starts the poll again, even if its timeout was reached before. I have verified this behavior (and can provide a video if needed).
        The thing to discuss (maybe) is if this is what you would expect from the af:poll component with the timeout property set. At least its documented.
        From my point of view I stay with the workaround given for the given use case.

        I think we can close this issue or do you see any reason to go further (file an ER to add a flag to definitely stop the poll)?

        Timo

        Show
        Timo_Hahn added a comment - Chris, I found the reason for this behavior. In the help for the af:poll the documentation has changed describing exactly what I see. From the timeout property documentation: ... Note that polling will restart if user activity is detected again after timeout but before the session has expired. If this value is set to -1, the page will never timeout. ... The log I posted generates new poll messages if you move the mouse over the page which starts the poll again, even if its timeout was reached before. I have verified this behavior (and can provide a video if needed). The thing to discuss (maybe) is if this is what you would expect from the af:poll component with the timeout property set. At least its documented. From my point of view I stay with the workaround given for the given use case. I think we can close this issue or do you see any reason to go further (file an ER to add a flag to definitely stop the poll)? Timo
        Hide
        Timo_Hahn added a comment -

        Chris, I'll retest this on different OS today and produce a video showing the effect I mentioned in my last post.

        Timo

        Show
        Timo_Hahn added a comment - Chris, I'll retest this on different OS today and produce a video showing the effect I mentioned in my last post. Timo
        Hide
        chriscmuir added a comment -

        Timo, I had a look at this again today after receiving feedback from development. I confirmed with dev that this patch did go into 12.1.3. On reinvestigating the issue, while I do see some of the messages you've highlighted in your last update, on watching the network traffic via Chrome's Developer Tools, beyond the initial timeout I can't see further periodic polls. Pretty much after 10 seconds the page and server sits idle.

        (admittedly I can see 2 extra client/server roundtrips beyond the initial polls, but this then stops)

        CM.

        Show
        chriscmuir added a comment - Timo, I had a look at this again today after receiving feedback from development. I confirmed with dev that this patch did go into 12.1.3. On reinvestigating the issue, while I do see some of the messages you've highlighted in your last update, on watching the network traffic via Chrome's Developer Tools, beyond the initial timeout I can't see further periodic polls. Pretty much after 10 seconds the page and server sits idle. (admittedly I can see 2 extra client/server roundtrips beyond the initial polls, but this then stops) CM.

          People

          • Assignee:
            Unassigned
            Reporter:
            Timo_Hahn
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: