Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Error Popup When using AJAX or Dynamic Action Refresh for Region or Report

tdsacilowskiAug 30 2013 — edited Oct 9 2013

Hello,

I've been having an issue with an application I developed and I've been banging my head against the wall with this for some time without any success. Several pages in my application rely on using AJAX to refresh a region on the page with updated data, running every 5 seconds. I have the following code in my Region Footer:

var refresh_region = function (region_in) {

    try {

        jQuery(region_in).trigger('apexrefresh');

    } catch (e) {

        //Suppress error messages

    } finally {

        setTimeout(function() {refresh_region(region_in)}, 5000);

    }

}

refresh_region('##REGION_STATIC_ID#');

What happens is that I often get an popup window with the title "Message from webpage:" and one of the following error descriptions (with the latter being the most common):

  •     Error: error - HTTP Version Not Supported
  •     Error: error - Unknown

The problem is that this page is used on keyboard-less kiosks, and once the error popup displays, the page stops responding and user interaction is required to click the "Ok" button. Another issue, which is even more frustrating, is that these windows will pile up on top of each other almost a hundred deep at times, to the point where sometimes I need to force quit the browser or reboot the kiosk. There are also instances where the entire application becomes unresponsive and none of the pages will load. The only way to resolve this is to have my DBA restart Glassfish. He's gone through some of the logs but he's not seeing anything specific that's helping him understand why this keeps happening but he feels that all these popups are eating up connections until the server runs out.

This has been a recurring issue since the application went live and I had hoped that using a try{} catch{} block would prevent these errors popups but no luck. I also made a copy of the page today and moved the refresh functionality into a Dynamic Action using the Timer plugin but the popup still appears. I'm monitoring to see if it happens as often as with the AJAX approach.

Ultimately, there are two issues here:

  1. What's causing the error in the first place?
  2. How can I prevent the error popup windows until I can figure out #1

I've tried anything I can find online for disabling the popups, all without any luck:

  • Using try{} catch{}
  • Disabling script debugging in IE
  • Unchecking  "Display a notification about every script error"
  • Intercepting the window.onerror event

Does anyone have any suggestions on how I can prevent these popups?

I have a copy of the application on apex.oracle.com:

  • Workspace: SCCC_TEST
  • User/Pass: TEST/test
  • Page: 5

Thanks!

This post has been answered by Tom Petrus on Sep 17 2013
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 6 2013
Added on Aug 30 2013
12 comments
5,720 views