grails-events-push
grails-events-push copied to clipboard
In IE8 event listening is not working properly
Hi I am trying to use events-push plugin on IE8. In chrome it is working fine. Below is the code how it looks like
someView.gsp
<r:script> $(document).ready(function () {
var grailsEvents = new grails.Events("http://localhost:8080",{shared:true,logLevel:'debug', maxRequest:70, transport: 'websocket'});
grailsEvents.on('myEvent'+myUserId, function (data) {
alert ("Testing data : "+data)
});
});
/r:script
someController.groovy
def myNewEvent() { event (for:'browser', topic:'myEvent'+userId, data:new JSONObject(jsonEventObj.content),fork:false) }
someService.groovy
def myNewEventService() { event (for:'browser', topic:'myEvent'+userId, data:new JSONObject(jsonEventObj.content),fork:false) .... // event triggers are called in multiple places. }
When the events are triggered IE8 sometimes gets last 2 events or the 1st event message or sometimes nothing. Is there a parameter that can specify listen for event every time. Because the same code works fine in chrome but it is not in IE8.
i can confirm this issue, had the same one today (see here: http://grails.1312388.n4.nabble.com/Grails-Events-Push-Internet-Explorer-not-triggering-every-Event-via-long-polling-td4650373.html). it would be really greate if the IE could respond to all sent events every time!