Ok, thanks for your explanation!<br>
<br>
I am having a problem with Chrome that is somewhat connected to my
original question. It is not about aborting a XMLHttpRequest, but about
loading large files in a web worker and passing the (parsed) content to
the main script:<br>
<a href="http://code.google.com/p/chromium/issues/detail?id=50360">http://code.google.com/p/chromium/issues/detail?id=50360</a><br><br><br><div class="gmail_quote">On Tue, Jul 27, 2010 at 8:40 PM, Dmitry Titov <span dir="ltr"><<a href="mailto:dimich@chromium.org">dimich@chromium.org</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">That would be a bug in the browser. Just as when a regular page is simply closed, the termination of the worker releases the resources kept by the worker, including XmlHttpRequests, Databases, etc. So yes, in this sense the XHR is closed properly.<div>
<div></div><div class="h5"><br>
<br><div class="gmail_quote">On Mon, Jul 26, 2010 at 11:47 PM, Tobias Sauerwein <span dir="ltr"><<a href="mailto:tobias.sauerwein@camptocamp.com" target="_blank">tobias.sauerwein@camptocamp.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
XMLHttpRequest has a "abort()" method [1], so maybe whatever this method does "closes the request properly"? I was just worried that the connection stays open after the web worker is terminated, and then after a while a kind of "max. open connections" limit is reached, so that I won't be able to make a new request. I don't know if there is such a limit.<br>


<br>[1]: <a href="http://www.w3.org/TR/XMLHttpRequest/#the-abort-method" target="_blank">http://www.w3.org/TR/XMLHttpRequest/#the-abort-method</a><div><div></div><div><br><br><br><div class="gmail_quote">On Mon, Jul 26, 2010 at 9:15 PM, Dmitry Titov <span dir="ltr"><<a href="mailto:dimich@chromium.org" target="_blank">dimich@chromium.org</a>></span> wrote:<br>


<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">What is "closed properly"? As far as implementation goes, Chromium for example will drop the request at some point, asynchronously but quite close to termination and discard any results, so it can be at any phase of completion. A mechanism with more guarantees would definitely require an explicit  spec language.<br>



<br><div class="gmail_quote"><div><div></div><div>On Thu, Jul 22, 2010 at 7:11 AM, Tobias Sauerwein <span dir="ltr"><<a href="mailto:tobias.sauerwein@camptocamp.com" target="_blank">tobias.sauerwein@camptocamp.com</a>></span> wrote:<br>


</div></div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div><div></div><div>
Hi!<br><br>I am wondering what happens when I start an asynchronous XMLHttpRequest in a web worker and then terminate the web worker from the main script. Can I assume that the request is closed properly? Because the "terminate a worker algorithm" [1] does not explicitly say how to deal with open requests.<br>





<br>Thanks,<br>Tobias<br><br><br>[1]: <a href="http://www.whatwg.org/specs/web-workers/current-work/#terminate-a-worker" target="_blank">http://www.whatwg.org/specs/web-workers/current-work/#terminate-a-worker</a><br>
<br></div></div>_______________________________________________<br>
Help mailing list<br>
<a href="mailto:Help@lists.whatwg.org" target="_blank">Help@lists.whatwg.org</a><br>
<a href="http://lists.whatwg.org/listinfo.cgi/help-whatwg.org" target="_blank">http://lists.whatwg.org/listinfo.cgi/help-whatwg.org</a><br>
<br></blockquote></div><br>
</blockquote></div><br>
</div></div></blockquote></div><br>
</div></div></blockquote></div><br>