Hi,
I am new to Flex and Flex dataservices. I have to write an application where flash clients have to update themselves when they receive messages (real-time) from a J2EE server (Glassfish) through BlazeDS.
I tried to implement this via the mx:producer/mx:consumer paradigm. I used some of the code from the "chat" tutorial to achieve this.
When I ran it in the browser (Internet Explorer 6), the flash client(s) did not receive the messages that I send either via a flash producer nor via a servlet from the J2EE server. However, if I press <F5> (refresh) in the browser to do a refresh, from that moment on, all the messages that are send, are received by the flash application in the browser.
Why do I have to do a refresh? Does this look like a coding error?
Any help is very much appreciated.
Petran.
Solved! Go to Solution.
Views
Replies
Total Likes
Hi,
Inside messaging-config.xml try to use the channels if you use my-polling-amf try to set the
<polling-enabled>true</polling-enabled>
<polling-interval-seconds>1</polling-interval-seconds>
Code in messaging-config.xml:
<destination id="messagesForFlex" >
<channels>
<channel ref="my-polling-amf" />
</channels>
</destination>
Also you can use ServerPush for this type of applications.
Views
Replies
Total Likes
Hi,
Inside messaging-config.xml try to use the channels if you use my-polling-amf try to set the
<polling-enabled>true</polling-enabled>
<polling-interval-seconds>1</polling-interval-seconds>
Code in messaging-config.xml:
<destination id="messagesForFlex" >
<channels>
<channel ref="my-polling-amf" />
</channels>
</destination>
Also you can use ServerPush for this type of applications.
Views
Replies
Total Likes
Hi namala,
Thanks for your response.
With your suggestions, the program ran without me first needed to do a refresh (F5) in the IE explorer window!
In my messaging-config.xml file, the original default channel definition did not contain any polling parameters for the "my-polling-amf" channel. The first default definition pointed to the "my-streaming-amf" channel. Also in my destination definition, I had not defined any channel.
Does this mean that it tried streaming (first default)? Would it work with streaming as well (maybe with additional params)?
Petran.
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies