Yes, there is definitely a bug here; we're still working to understand it fully, will post an update then.

In the meantime, thanks for the report.

By on 10/28/2009 11:24 AM ()

I might be wrong but I assumed that Async.StartChild would only make sense in the context of the parent computation, and that, consequently, the disposal you mention would be natural.

That being said, is there a reason to use

1
2
3
4
5
6
let work1 = List.init 10 (fun i ->
   async {
     let! r = Async.StartChild( callToWebService1 i )
     return r
   })

instead of

1
let work1 = List.init 10 callToWebService1
By on 10/27/2009 11:49 AM ()

Idea behind this example is to call WS and not await for results until they needed. I have code which works for few seconds and after that I need results from WS. Using Async.StartChild looks like easiest way to do WS call in parallel with my code. If I modify my code in manner you proposed this will cause Async.Parallel to actually wait until last WS call completed and then fetch results from another WS and only then time will came for my own code.
Is there more natural way to achieve this goal?

By on 10/28/2009 12:48 AM ()
IntelliFactory Offices Copyright (c) 2011-2012 IntelliFactory. All rights reserved.
Home | Products | Consulting | Trainings | Blogs | Jobs | Contact Us | Terms of Use | Privacy Policy | Cookie Policy
Built with WebSharper