c# - How many asynchronous (not multi-threaded) operations are started at once? Is this configurable? -
- if call example
webclient.downloadstringtaskasync()100 times how many of tasks parallelly processed? - can configure or need maintain number using
list<task>,task.waitany()? - is there easy way see number in debugger?
- what best practices in situations this(processing large number of async tasks)?
note: i'm not using task.run() no additional threads started (as far know)
the degree of parallelism controlled servicepoint infrastructure don't understand. default limit servicepointmanager.defaultconnectionlimit. uses. have never seen use servicepoint.
i recommend disabling limit , implementing limiting yourself. using 1 global limit entire appdomain doesn't make sense me. it's hidden , undocumented rely on defaultconnectionlimit. further, defaultconnectionlimit defaults different default values depending on environment (2 vs. int.maxvalue!).
(4) there code floating around allows process sequence of items asynchronously degree of parallelism. way go. controlled parallelism, async , streaming processing constant memory usage.
Comments
Post a Comment