CallBack Function never gets called

22 views
Skip to first unread message

Jagan

unread,
Jun 25, 2011, 11:12:25 PM6/25/11
to meteorserver
Hi,

I can see that the webpage gets data packets from the server but for
some reason makeTxt() never gets invoked? Any suggestion?

Jagan

====== Firebug LOG ======================
Loading URL 'http://<server>/stream.html' into frame...
Frame registered
GET http://<server>/push/912345/xhrinteractive/demo.b5?nc=1309057587408
Received channel info for channel demo: resume from 0
Ping
Ping
Ping
Ping
Ping
GET ...


=======WEBPAGE========================

<head>
<script type="text/javascript" src="/js/meteor.js"></script>
</head>

<body>

<!-- Set Meteor stuff -->
<script type="text/javascript">
// Set this to something unique to this client
Meteor.hostid = '912345';
// Our Meteor server serves both static and dynamic content from
port 80
Meteor.host = location.hostname;
Meteor.debugmode = true;
// Call the test() function when data arrives
Meteor.registerEventCallback("process", makeTxt);
// Join the demo channel and get last five events, then stream
Meteor.joinChannel('demo', 5);
Meteor.mode = 'stream';
// Start streaming!
Meteor.connect();
// Handle incoming events
function makeTxt(data){
document.write(data);
}
</script>
<!-- Meteor Stuff: Until here -->

<div id="meteorlogoutput"></div>

</html>

Andrew Betts

unread,
Jun 26, 2011, 10:03:23 AM6/26/11
to meteor...@googlegroups.com
Your firebug debug doesn't show Meteor receving any messages.  Your callback function will not be called for pings or channel info notifications.

Jagan

unread,
Jun 26, 2011, 12:47:52 PM6/26/11
to meteorserver
Thanks for your response.

My bad, I also get these GET commands but did not paste them in my
original message.
These looks like data chunks but still the callback function never
gets invoked.
BTW, I checked it on FF, Chrome, and Safari.


http://<server>/push/49977502705/poll/demo.b5?nc=1309065055264

-------- contains --
<script>p(4307,"demo","{"entity":"<someval>","val":"604021"}");</
script>
<script>p(4308,"demo","{"entity":"<someval>","val":"715390"}");</
script>
<script>p(4309,"demo","{"entity":"<someval>","val":"599191"}");</
script>
<script>p(4310,"demo","{"entity":"<someval>","val":"40082"}");</
script>
<script>p(4311,"demo","{"entity":"<someval>","val":"70622"}");</
script>
Reply all
Reply to author
Forward
0 new messages