Click here to Skip to main content
15,867,771 members
Articles / General Programming / Threads

Understanding Synchronization Context; Task.ConfigureAwait in Action

Rate me:
Please Sign up or sign in to vote.
5.00/5 (10 votes)
28 Aug 2021CPOL10 min read 11.3K   14  
SynchronizationContext class and how it affects code behavior in action, and a look at Task.ConfigureAwait()
When dealing with asynchronous code, one of the most important concepts that you must have a solid understanding of is synchronization context. Synchronization context is one of the most ignored concepts in the asynchronous programming realm as it is often hard for developers to understand. Today, we will try to simplify things as much as we can. We will have a look at SynchronizationContext classes and see how it affects code behavior in action. We will also have a look at one of the most important methods in TPL library, Task.ConfigureAwait().

Views

Daily Counts

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Technical Lead
Egypt Egypt
Mohammad Elsheimy is a developer, trainer, and technical writer currently hired by one of the leading fintech companies in Middle East, as a technical lead.

Mohammad is a MCP, MCTS, MCPD, MCSA, MCSE, and MCT expertized in Microsoft technologies, data management, analytics, Azure and DevOps solutions. He is also a Project Management Professional (PMP) and a Quranic Readings college (Al-Azhar) graduate specialized in Quranic readings, Islamic legislation, and the Arabic language.

Mohammad was born in Egypt. He loves his machine and his code more than anything else!

Currently, Mohammad runs two blogs: "Just Like [a] Magic" (http://JustLikeAMagic.com) and "مع الدوت نت" (http://WithdDotNet.net), both dedicated for programming and Microsoft technologies.

You can reach Mohammad at elsheimy[at]live[dot]com

Comments and Discussions