Professional Documents
Culture Documents
Agenda
• What does asynchrony mean?
• Reason for asynchrony.
• Task
• Async-await
• SynchronizationContext
• Best practices
Synchronous vs Asynchronous
Reason for asynchrony
• Responsiveness
• Scalability
Task
• Represents an asynchronous operation
• Stored on heap
await Awaitables
Message Loop/pump
• It fetches message from the message queue and dispatches it.
SynchronizationContext
• Abstraction over the place where you are running
• Represents a target for work
Post()
WinRTSynchronizationContext – CoreDispatcher.RunAsync()
UnitySynchronizationContext