flash.net.URLRequest电话留在待定 [英] flash.net.URLRequest call stays in pending

查看:124
本文介绍了flash.net.URLRequest电话留在待定的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有这个Flash / Flex应用程序和问题,的URLRequest 通话。当调用由服务器我得到的内容就好了。之后,内容存储在缓存中,并在下一次的URLRequest使用本地缓存中检索它。 有时候它的工作原理,但有时打电话永远不会结束 - 留在待定。我使用的是最新版本的Flash播放器和不同的浏览器。在我的电脑,我可以使用Chrome和同事可以在Firefox中复制复制的问题。我看了flash播放器日志文件,并没有什么不同的,当调用成功,当电话留在待定...

I've got this flash/flex application and issue with URLRequest call. When call is made to server I get content just fine. After that content is stored in cache and next time URLRequest uses local cache to retrieve it. Sometimes it works, but sometimes call is never finished - stays in pending. I'm using latest flash player and different browsers. On my computer I can replicate issue using chrome and colleague can replicate on firefox. I've looked at flash player log files and there's nothing different when call is successful and when call stays in pending ...

也是我的朋友无法复制这个问题,直到他的Flash Player升级到最新版本。

Also my friend couldn't replicate this issue until he upgraded flash player to latest version.

我相信这不是一个服务器端的问题,因为Web服务器日志说,有在谷歌浏览器的问题,网络工具的时间内没有请求确认,那个时候请求使用本地缓存。

I believe this isn't a server-side issue because web server logs says there's no request at the time of the issue and network tool in google chrome confirmed that that time request is using local cache.

目前我已经通过强制客户端不使用高速缓存使用到期日和无缓存,但我想用缓存,我想明白为什么会这样解决了这一点。

Currently I've resolved this by forcing client not to use cache using expiration date and no-cache, but I would like to use cache and I would like to understand why this happens.

非常感谢!

负责code:

loader = new utils.URLLoader();
loader.dataFormat = flash.net.URLLoaderDataFormat.BINARY;
loader.addEventListener(flash.events.Event.COMPLETE, this.onLoad);
loader.addEventListener(flash.events.IOErrorEvent.IO_ERROR, this.onErr);
loader.load(new flash.net.URLRequest(URL));


更新:


update:

现在我发现缓存没有resposible它。我每次清理缓存请求之前,仍然我可以重现这个错误。 GET请求仍然显示为待定,但这次我得到了Wireshark的运行,显示有趣的结果 - 未登录Wireshark的困扰GET请求。这怎么可能呢?

Now I found out that cache isn't resposible for it. I've cleaned cache every time before a request and still I can reproduce this error. GET request is still displayed as pending, but this time I got wireshark running which shows interesting result - troubled GET request isn't logged in wireshark. How can this be possible?

推荐答案

在html的包装code嵌入您的SWF,请尝试更改的allowScriptAccess =导航特殊来的allowScriptAccess =总是。它出现了两次。

In the .html wrapper code that embeds your swf, try changing allowScriptAccess="sameDomain" to allowScriptAccess="always". It appears twice.

这篇关于flash.net.URLRequest电话留在待定的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆