Skip to content

Instantly share code, notes, and snippets.

@RahulJyala7
Last active July 30, 2019 11:58
Show Gist options
  • Save RahulJyala7/ac4191f66aa783e8fbb5e731c1def42b to your computer and use it in GitHub Desktop.
Save RahulJyala7/ac4191f66aa783e8fbb5e731c1def42b to your computer and use it in GitHub Desktop.
hello DOTNET-CORE
Transient objects are always different; a new instance is provided to every controller and every service.
Scoped objects are the same within a request, but different across different requests.
Singleton objects are the same for every object and every request.
--------------------------------CLR--------------------------------------------
https://www.geeksforgeeks.org/common-language-runtime-clr-in-c-sharp/
------------------------- INT vs INT32 vs INT64 ------------------------------------------
The only real difference here is the size. All of the int types here are signed integer values which have varying sizes
Int16: 2 bytes
Int32 and int: 4 bytes
Int64 : 8 bytes
There is one small difference between Int64 and the rest. On a 32 bit platform assignments to an Int64 storage location are not guaranteed to be atomic. It is guaranteed for all of the other types.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment