Created
June 5, 2012 23:14
-
-
Save tugberkugurlu/2878730 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public async Task<ActionResult> Foo() { | |
//some sync stuff | |
//runs the async method | |
var foobar = await _someClass.GetAsync(); | |
//this continuation ends up in another thread. | |
//cannot access some static instances such as HttpContext.Current | |
doSomeWork(); | |
//some other stuff | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This might be the solution?