Suche senden
Hochladen
Asynchronous Programming
•
0 gefällt mir
•
807 views
LearnNowOnline
Folgen
All about Asynchronous Programming: where it fits in, using the new async.
Weniger lesen
Mehr lesen
Melden
Teilen
Melden
Teilen
1 von 61
Jetzt herunterladen
Downloaden Sie, um offline zu lesen
Empfohlen
Web API HTTP Pipeline
Web API HTTP Pipeline
LearnNowOnline
Continuous Integration Best Practices for Software Development Teams - AWS On...
Continuous Integration Best Practices for Software Development Teams - AWS On...
Amazon Web Services
Serverless in production, an experience report (London DevOps)
Serverless in production, an experience report (London DevOps)
Yan Cui
React Native Workshop
React Native Workshop
Amazon Web Services
Frappé / ERPNext Open Day October 2015
Frappé / ERPNext Open Day October 2015
Anand Doshi
Effective Testing with Ruby
Effective Testing with Ruby
Akira Sosa
Implementing Testing for Behavior-Driven Development Using Cucumber
Implementing Testing for Behavior-Driven Development Using Cucumber
TechWell
Frappé / ERPNext Open Day November 2015
Frappé / ERPNext Open Day November 2015
Anand Doshi
Weitere ähnliche Inhalte
Was ist angesagt?
Chicago Tech Day Jan 2015: Foundry - HTTP2
Chicago Tech Day Jan 2015: Foundry - HTTP2
Akamai Technologies
Edge 2014: Million Browser Botnet - Live Demonstration
Edge 2014: Million Browser Botnet - Live Demonstration
Akamai Technologies
Rafaëla Breed - Tracing performance of your service calls - Codemotion Amster...
Rafaëla Breed - Tracing performance of your service calls - Codemotion Amster...
Codemotion
Frappé / ERPNext Open Day February 2016
Frappé / ERPNext Open Day February 2016
Anand Doshi
Chicago Tech Day Jan 2015: Hidden Features
Chicago Tech Day Jan 2015: Hidden Features
Akamai Technologies
Edge 2014: Increasing Control with Property Manager with eBay
Edge 2014: Increasing Control with Property Manager with eBay
Akamai Technologies
ERPNext Open Day - March / April 2015
ERPNext Open Day - March / April 2015
rushabh_mehta
Startup Pitching and Mobile App Startup
Startup Pitching and Mobile App Startup
Kobkrit Viriyayudhakorn
2015 Velocity SC: Convince your CFO that #perfmatters
2015 Velocity SC: Convince your CFO that #perfmatters
Colin Bendell
SFScon18 - Juri Strumpflohner - End-to-end testing done right!
SFScon18 - Juri Strumpflohner - End-to-end testing done right!
South Tyrol Free Software Conference
Frappe / ERPNext Open Day May 14
Frappe / ERPNext Open Day May 14
rushabh_mehta
Resolution for a Faster Site
Resolution for a Faster Site
Ido Safruti
QuizBrahma by Sagar Kadam
QuizBrahma by Sagar Kadam
Sagar Kadam
Getting started with Visual Testing using Applitools - @TPC, Feb2020
Getting started with Visual Testing using Applitools - @TPC, Feb2020
Anand Bagmar
Lambdaless and AWS CDK
Lambdaless and AWS CDK
MooYeol Lee
Yelowsoft delivers super app to bbr one of the biggest ride hailing companies...
Yelowsoft delivers super app to bbr one of the biggest ride hailing companies...
Yelowsoft
Yelowsoft delivers super app to bbr one of the biggest ride hailing companies...
Yelowsoft delivers super app to bbr one of the biggest ride hailing companies...
Yelowsoft
Automated Acceptance Test Practices and Pitfalls
Automated Acceptance Test Practices and Pitfalls
Wyn B. Van Devanter
Was ist angesagt?
(18)
Chicago Tech Day Jan 2015: Foundry - HTTP2
Chicago Tech Day Jan 2015: Foundry - HTTP2
Edge 2014: Million Browser Botnet - Live Demonstration
Edge 2014: Million Browser Botnet - Live Demonstration
Rafaëla Breed - Tracing performance of your service calls - Codemotion Amster...
Rafaëla Breed - Tracing performance of your service calls - Codemotion Amster...
Frappé / ERPNext Open Day February 2016
Frappé / ERPNext Open Day February 2016
Chicago Tech Day Jan 2015: Hidden Features
Chicago Tech Day Jan 2015: Hidden Features
Edge 2014: Increasing Control with Property Manager with eBay
Edge 2014: Increasing Control with Property Manager with eBay
ERPNext Open Day - March / April 2015
ERPNext Open Day - March / April 2015
Startup Pitching and Mobile App Startup
Startup Pitching and Mobile App Startup
2015 Velocity SC: Convince your CFO that #perfmatters
2015 Velocity SC: Convince your CFO that #perfmatters
SFScon18 - Juri Strumpflohner - End-to-end testing done right!
SFScon18 - Juri Strumpflohner - End-to-end testing done right!
Frappe / ERPNext Open Day May 14
Frappe / ERPNext Open Day May 14
Resolution for a Faster Site
Resolution for a Faster Site
QuizBrahma by Sagar Kadam
QuizBrahma by Sagar Kadam
Getting started with Visual Testing using Applitools - @TPC, Feb2020
Getting started with Visual Testing using Applitools - @TPC, Feb2020
Lambdaless and AWS CDK
Lambdaless and AWS CDK
Yelowsoft delivers super app to bbr one of the biggest ride hailing companies...
Yelowsoft delivers super app to bbr one of the biggest ride hailing companies...
Yelowsoft delivers super app to bbr one of the biggest ride hailing companies...
Yelowsoft delivers super app to bbr one of the biggest ride hailing companies...
Automated Acceptance Test Practices and Pitfalls
Automated Acceptance Test Practices and Pitfalls
Andere mochten auch
WPF: Working with Data
WPF: Working with Data
LearnNowOnline
Windows 8: Shapes and Geometries
Windows 8: Shapes and Geometries
LearnNowOnline
New in the Visual Studio 2012 IDE
New in the Visual Studio 2012 IDE
LearnNowOnline
WPF Binding
WPF Binding
LearnNowOnline
SQL: Permissions and Data Protection
SQL: Permissions and Data Protection
LearnNowOnline
Attributes, reflection, and dynamic programming
Attributes, reflection, and dynamic programming
LearnNowOnline
Andere mochten auch
(6)
WPF: Working with Data
WPF: Working with Data
Windows 8: Shapes and Geometries
Windows 8: Shapes and Geometries
New in the Visual Studio 2012 IDE
New in the Visual Studio 2012 IDE
WPF Binding
WPF Binding
SQL: Permissions and Data Protection
SQL: Permissions and Data Protection
Attributes, reflection, and dynamic programming
Attributes, reflection, and dynamic programming
Ähnlich wie Asynchronous Programming
JavaScript: Operators and Expressions
JavaScript: Operators and Expressions
LearnNowOnline
Web API Basics
Web API Basics
LearnNowOnline
.NET Variables and Data Types
.NET Variables and Data Types
LearnNowOnline
Building Windows 8 Metro Style Applications Using JavaScript and HTML5
Building Windows 8 Metro Style Applications Using JavaScript and HTML5
LearnNowOnline
Using The .NET Framework
Using The .NET Framework
LearnNowOnline
Creating a User Interface
Creating a User Interface
LearnNowOnline
SQL Server: Security
SQL Server: Security
LearnNowOnline
Working with Controllers and Actions in MVC
Working with Controllers and Actions in MVC
LearnNowOnline
KnockOutJS with ASP.NET MVC
KnockOutJS with ASP.NET MVC
LearnNowOnline
What's new in Silverlight 5
What's new in Silverlight 5
LearnNowOnline
.Net branching and flow control
.Net branching and flow control
LearnNowOnline
Managing site collections
Managing site collections
LearnNowOnline
Generics
Generics
LearnNowOnline
Bring a Web Page Alive with jQuery
Bring a Web Page Alive with jQuery
LearnNowOnline
Object oriented techniques
Object oriented techniques
LearnNowOnline
Introducing LINQ
Introducing LINQ
LearnNowOnline
The Entity Data Model
The Entity Data Model
LearnNowOnline
Object-Oriented JavaScript
Object-Oriented JavaScript
LearnNowOnline
Flink Forward Berlin 2018: Wei-Che (Tony) Wei - "Lessons learned from Migrati...
Flink Forward Berlin 2018: Wei-Che (Tony) Wei - "Lessons learned from Migrati...
Flink Forward
Introduction to ASP.NET MVC
Introduction to ASP.NET MVC
LearnNowOnline
Ähnlich wie Asynchronous Programming
(20)
JavaScript: Operators and Expressions
JavaScript: Operators and Expressions
Web API Basics
Web API Basics
.NET Variables and Data Types
.NET Variables and Data Types
Building Windows 8 Metro Style Applications Using JavaScript and HTML5
Building Windows 8 Metro Style Applications Using JavaScript and HTML5
Using The .NET Framework
Using The .NET Framework
Creating a User Interface
Creating a User Interface
SQL Server: Security
SQL Server: Security
Working with Controllers and Actions in MVC
Working with Controllers and Actions in MVC
KnockOutJS with ASP.NET MVC
KnockOutJS with ASP.NET MVC
What's new in Silverlight 5
What's new in Silverlight 5
.Net branching and flow control
.Net branching and flow control
Managing site collections
Managing site collections
Generics
Generics
Bring a Web Page Alive with jQuery
Bring a Web Page Alive with jQuery
Object oriented techniques
Object oriented techniques
Introducing LINQ
Introducing LINQ
The Entity Data Model
The Entity Data Model
Object-Oriented JavaScript
Object-Oriented JavaScript
Flink Forward Berlin 2018: Wei-Che (Tony) Wei - "Lessons learned from Migrati...
Flink Forward Berlin 2018: Wei-Che (Tony) Wei - "Lessons learned from Migrati...
Introduction to ASP.NET MVC
Introduction to ASP.NET MVC
Mehr von LearnNowOnline
A tour of SQL Server
A tour of SQL Server
LearnNowOnline
SharePoint Document Management
SharePoint Document Management
LearnNowOnline
SharePoint: Introduction to InfoPath
SharePoint: Introduction to InfoPath
LearnNowOnline
Sql 2012 development and programming
Sql 2012 development and programming
LearnNowOnline
Expression Blend Motion & Interaction Design
Expression Blend Motion & Interaction Design
LearnNowOnline
Introducing the Entity Framework
Introducing the Entity Framework
LearnNowOnline
Mehr von LearnNowOnline
(6)
A tour of SQL Server
A tour of SQL Server
SharePoint Document Management
SharePoint Document Management
SharePoint: Introduction to InfoPath
SharePoint: Introduction to InfoPath
Sql 2012 development and programming
Sql 2012 development and programming
Expression Blend Motion & Interaction Design
Expression Blend Motion & Interaction Design
Introducing the Entity Framework
Introducing the Entity Framework
Asynchronous Programming
1.
Asynchronous Programming
Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
2.
Asynchronous Programming
http:// www.LearnNowOnline.com Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
3.
Understanding the Problem with
Previous Async Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
4.
Understanding the Problem with
Previous Async • Demo Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
5.
Where Async Fits
In Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
6.
Where Async Fits
In • Traditional code is synchronous Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
7.
Where Async Fits
In • Traditional code is synchronous • Call method, block until call returns, continue processing Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
8.
Where Async Fits
In • Traditional code is synchronous • Call method, block until call returns, continue processing • Asynchronous (async) is non-blocking Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
9.
Where Async Fits
In • Traditional code is synchronous • Call method, block until call returns, continue processing • Asynchronous (async) is non-blocking • Call, return immediately to continue processing, called method continues running Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
10.
Where Async Fits
In • Traditional code is synchronous • Call method, block until call returns, continue processing • Asynchronous (async) is non-blocking • Call, return immediately to continue processing, called method continues running • UI is responsive and good use of server Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
11.
Previous Async
Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
12.
Previous Async • Asynchronous
Programming Model (APM) Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
13.
Previous Async • Asynchronous
Programming Model (APM) • Relies on delegates to handle execution and callback Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
14.
Previous Async • Asynchronous
Programming Model (APM) • Relies on delegates to handle execution and callback • Complex Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
15.
Previous Async • Asynchronous
Programming Model (APM) • Relies on delegates to handle execution and callback • Complex • Event-based Asynchronous Pattern (EAP) Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
16.
Previous Async • Asynchronous
Programming Model (APM) • Relies on delegates to handle execution and callback • Complex • Event-based Asynchronous Pattern (EAP) • Simpler and more features than APM Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
17.
Using the New
async and await Keywords Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
18.
Using the New
async and await Keywords • Demo Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
19.
Anatomy of an
Async Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
20.
Anatomy of an
Async • Modify method as async (required) Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
21.
Anatomy of an
Async • Modify method as async (required) • Call method with await (optional) Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
22.
Anatomy of an
Async • Modify method as async (required) • Call method with await (optional) • Without await: generates compiler warning and method runs synchronously Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
23.
Anatomy of an
Async • Modify method as async (required) • Call method with await (optional) • Without await: generates compiler warning and method runs synchronously • Method, lambda, or anonymous method Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
24.
Anatomy of an
Async • Modify method as async (required) • Call method with await (optional) • Without await: generates compiler warning and method runs synchronously • Method, lambda, or anonymous method • Add Async suffix to method name Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
25.
Async Return Values
Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
26.
Async Return Values •
Can be void, Task, or Task<TResult> Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
27.
Async Return Values •
Can be void, Task, or Task<TResult> • Use void for fire-and-forget Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
28.
Async Return Values •
Can be void, Task, or Task<TResult> • Use void for fire-and-forget • Warning: can’t catch exception with void Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
29.
Async Return Values •
Can be void, Task, or Task<TResult> • Use void for fire-and-forget • Warning: can’t catch exception with void • Appropriate for async event handlers Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
30.
Async Return Values •
Can be void, Task, or Task<TResult> • Use void for fire-and-forget • Warning: can’t catch exception with void • Appropriate for async event handlers • Task and Task<TResult> lets callers await your method Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
31.
Async Return Values •
Can be void, Task, or Task<TResult> • Use void for fire-and-forget • Warning: can’t catch exception with void • Appropriate for async event handlers • Task and Task<TResult> lets callers await your method • Assign awaited value to variable and continue with rest of method Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
32.
Managing Async Tasks
Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
33.
Managing Async Tasks •
Demo Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
34.
About Async Threads
Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
35.
About Async Threads •
Call to await returns to caller on same thread Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
36.
About Async Threads •
Call to await returns to caller on same thread • Control automatically marshaled back to UI thread after await Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
37.
Awaiting in Sequence
Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
38.
Awaiting in Sequence •
You can have as many awaits in a method that you want Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
39.
Awaiting in Sequence •
You can have as many awaits in a method that you want • After one await completes, the next one executes Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
40.
Awaiting in Parallel
Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
41.
Awaiting in Parallel •
You can await multiple methods together Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
42.
Awaiting in Parallel •
You can await multiple methods together • Add all methods to List<Task<TResult>> Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
43.
Awaiting in Parallel •
You can await multiple methods together • Add all methods to List<Task<TResult>> • Call await on Task.WhenAll to process results after all tasks complete Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
44.
Awaiting in Parallel •
You can await multiple methods together • Add all methods to List<Task<TResult>> • Call await on Task.WhenAll to process results after all tasks complete • Call await on Task.WhenAny to process results for each result as it completes Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
45.
Exceptions, Cancellations, and
Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
46.
Exceptions, Cancellations, and • Demo
Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
47.
Handling Exceptions
Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
48.
Handling Exceptions • You
can handle both synchronous and async code together Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
49.
Handling Exceptions • You
can handle both synchronous and async code together • Use try/catch around await and it works Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
50.
Cancellation
Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
51.
Cancellation • Use CancellationTokenSource
Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
52.
Cancellation • Use CancellationTokenSource •
Pass Token to async methods Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
53.
Cancellation • Use CancellationTokenSource •
Pass Token to async methods • Wrap in try/catch for OperationCancelledException Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
54.
Cancellation • Use CancellationTokenSource •
Pass Token to async methods • Wrap in try/catch for OperationCancelledException • Awaited code can check token for cancellation and throw Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
55.
Progress Reporting
Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
56.
Progress Reporting • Modify
async method to accept an IProgress<T> Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
57.
Progress Reporting • Modify
async method to accept an IProgress<T> • Caller instantiates ProgressReport with callback Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
58.
Progress Reporting • Modify
async method to accept an IProgress<T> • Caller instantiates ProgressReport with callback • Caller passes the ProgressReport instance to the async method Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
59.
Progress Reporting • Modify
async method to accept an IProgress<T> • Caller instantiates ProgressReport with callback • Caller passes the ProgressReport instance to the async method • The async method calls Report on IProgress<T> instance Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
60.
Questions?
Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
61.
Questions?
http:// www.LearnNowOnline.com Learn More @ http://www.learnnowonline.com Copyright © by Application Developers Training Company
Hinweis der Redaktion
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
Jetzt herunterladen