DotnetAssembly.png
Ref.
o Andrew Troelsen and Philip Japikse - C# 6.0 and the .NET 4.6 Framework
============================================================================================
DotnetProcessAppdomainThreadContext
o Active threads can be moved to other AppDomains and Context boundaries by the CLR to fit the perfomance.
But it's impossible for a single thread to be working in more than one AppDomain at once.
==============================================================================================
LoadingStoringValueInILcode================================================================================================
DotnetLanguageCompileProcess==================================================================================================
RunDotnetApp===============================================================================================
CreateAssemblyByILlanguage
Ref.
o Andrew Troelsen and Philip Japikse - C# 6.0 and the .NET 4.6 Framework
=================================================================================================
DotnetClrCtsClsBaseclassRef.
o Andrew Troelsen and Philip Japikse - C# 6.0 and the .NET 4.6 Framework
================================================================================================
DotnetVersionHistory
Ref.
o Andrew Troelsen and Philip Japikse - C# 6.0 and the .NET 4.6 Framework
===============================================================================================
ManagedUnmanagedCodeAppAndPlatform
Ref.
o Andrew Troelsen and Philip Japikse - C# 6.0 and the .NET 4.6 Framework
================================================================================================
ThreadAndSynchronousRef.
===============================================================================================
ConcurrencyByMultithreadAndAsynchronous
===============================================================================================
AsyncAwaito The thing you should note is that when you use "async and await" feature you're not going to sure whether the task which you're trying to process asynchronously is processed on another thread or same calling thread.
That is decided by the CLR, however, CLR allocates the task which you're trying to process asynchronously on another thread against the calling thread as it can as possible.
==============================================================================================
DelegateAndAsyncButCallingThreadGotBlockedWithWaitingResultFromOtherThreadRef.
o Andrew Troelsen and Philip Japikse - C# 6.0 and the .NET 4.6 Framework
============================================================================================
AsyncCallBackInDelegate
Ref.
o Andrew Troelsen and Philip Japikse - C# 6.0 and the .NET 4.6 Framework
=============================================================================================
LockKeywordForPrivateInstanceMethod
Ref.
o Andrew Troelsen and Philip Japikse - C# 6.0 and the .NET 4.6 Framework
=============================================================================================
LockKeywordForPublicMemberOfTheClassMore techniques:
1.Monitor: This is nothing but a shorthand using for lock keyword.
Using lock keyword is converted to the Monitor using after compiled.
2.Interlock.
3.[Synchronization] attribute.
This way can be simple but lazy.
The downfall of this way is that this way makes code rigid because all other codes which doesn't need to be thread-safe are also becoming thread-safe.
4.ThreadPool.
You can pass the method as a argument into WaitCallBack delegate, which you want to execute on secondary threads.
Then delegate object containing above methods can be queued into thread pool via QueueUserWorkItem() method.
And on the secondary threads against primary thread, you can invoke method which you want to invoke.
ThreadPool has pros and cons.
Ref.
o Andrew Troelsen and Philip Japikse - C# 6.0 and the .NET 4.6 Framework
==========================================================================================
Serialization==========================================================================================
ObjectGraph1==========================================================================================
ObjectGraph2==========================================================================================
IFormatterAndIRemotingFormatter
==========================================================================================
BinaryAndXmlAndSoapDifferences==========================================================================================
BinaryDataRepresentation==========================================================================================
XmlAttributes==========================================================================================
CustomSerialize==========================================================================================
chapter13-1 and 13-2
13-2