Clone a repo with limited history and specific branch
git clone --depth 10 --single-branch --branch <mybranch> <therepo>
|set -euo pipefail|
|# e=if a command fails the shell will exit (i.e. return > 0)|
|# u=write an error when trying to expand a variable that is not set|
|# o=set pipefail When used in combination with set -e, pipefail will make a script exit if any command in a pipeline errors.|
|## Fetching params by name rather than position|
Provides a good guide to the size of the object header in Java and what it is made up of, for 64bit (compressed oops on and off) and 32 bit JVM.
Excellent guide to memory layout: http://psy-lob-saw.blogspot.com/2013/05/know-thy-java-object-memory-layout.html
The tool jol is a library that can be used to identify the expected size of an object.
Oops stands for ordinary object pointer and refers to the object references in the JVM.
On 64bit hardware a pointer is sized at 64 bits, whereas in the 32bit world obviously 32bits.
32 bit means the addressable memory is 4GB.
64 bit means the addressable memory is 2^64 bytes, which is a lot.