There are a surprising number of types of locks, more than this short chapter can possibly do justice to. The following sections discuss exclusive locks (Section ), reader-writer locks (Section ), and multi-role locks (Section ).