简体   繁体   中英

Server send events are getting delayed in azure web app

I have created server send events to send the messages from node server. Everything works fine in localhost but when I deploy it to azure web app it takes nearly 15 to 20 seconds to send the data to the client. Do i need to configure anything in azure. Hope someone can help me out from this issue. Thanks in advance.

"

It could be a buffering issue. Depending on your browser and which polyfill you are using, messages get cached until the cache is flushed.

Since it works locally, there may be a difference in the node version running locally and the version on the App Service (I am assuming that you are running the node app in App Service, and using the same browser to test locally and in Azure).

For more details see: https://github.com/EventSource/eventsource/issues/88

In my case it was buffering issue. I did not get a response or got with huge delay.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM